rndis_wlan: set ieee80211_ptr->iftype in rndis_change_virtual_intf
authorJussi Kivilinna <jussi.kivilinna@mbnet.fi>
Fri, 28 Aug 2009 09:59:21 +0000 (12:59 +0300)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 28 Aug 2009 18:40:57 +0000 (14:40 -0400)
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/rndis_wlan.c

index c28fde59c32bf05c73e8a7e40963445f7e9a8b5d..d11762011dc22fb061b5c3a1eb60bf937a1ba3fe 100644 (file)
@@ -1526,7 +1526,8 @@ static int rndis_change_virtual_intf(struct wiphy *wiphy,
                                        enum nl80211_iftype type, u32 *flags,
                                        struct vif_params *params)
 {
-       struct usbnet *usbdev = netdev_priv(dev);
+       struct rndis_wlan_private *priv = wiphy_priv(wiphy);
+       struct usbnet *usbdev = priv->usbdev;
        int mode;
 
        switch (type) {
@@ -1540,6 +1541,8 @@ static int rndis_change_virtual_intf(struct wiphy *wiphy,
                return -EINVAL;
        }
 
+       priv->wdev.iftype = type;
+
        return set_infra_mode(usbdev, mode);
 }