]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
wireless: fix fallout from device_create removal
authorStephen Rothwell <sfr@canb.auug.org.au>
Mon, 16 Jun 2008 05:35:10 +0000 (15:35 +1000)
committerJohn W. Linville <linville@tuxdriver.com>
Thu, 26 Jun 2008 20:49:14 +0000 (16:49 -0400)
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/mac80211_hwsim.c

index 8da352ae6825ad41934dcfe83de059e0cc8c9b2d..5d30c57e3969cfe4ed4d65da9d57d0f9728122ca 100644 (file)
@@ -430,15 +430,16 @@ static int __init init_mac80211_hwsim(void)
                hwsim_radios[i] = hw;
 
                data = hw->priv;
-               data->dev = device_create(hwsim_class, NULL, 0, "hwsim%d", i);
+               data->dev = device_create_drvdata(hwsim_class, NULL, 0, hw,
+                                               "hwsim%d", i);
                if (IS_ERR(data->dev)) {
-                       printk(KERN_DEBUG "mac80211_hwsim: device_create "
+                       printk(KERN_DEBUG
+                              "mac80211_hwsim: device_create_drvdata "
                               "failed (%ld)\n", PTR_ERR(data->dev));
                        err = -ENOMEM;
                        goto failed;
                }
                data->dev->driver = &mac80211_hwsim_driver;
-               dev_set_drvdata(data->dev, hw);
 
                SET_IEEE80211_DEV(hw, data->dev);
                addr[3] = i >> 8;