cfg80211: pass netdev to change_virtual_intf

If there was a reason I'm passing the ifidx I cannot
remember it any more and don't see one now, so let's
just pass the pointer itself.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
Johannes Berg
2009-06-09 21:04:43 +02:00
committed by John W. Linville
parent e5a8a896f5
commit e36d56b648
6 changed files with 17 additions and 33 deletions

View File

@ -167,20 +167,15 @@ int iwm_cfg80211_inform_bss(struct iwm_priv *iwm)
return 0;
}
static int iwm_cfg80211_change_iface(struct wiphy *wiphy, int ifindex,
static int iwm_cfg80211_change_iface(struct wiphy *wiphy,
struct net_device *ndev,
enum nl80211_iftype type, u32 *flags,
struct vif_params *params)
{
struct net_device *ndev;
struct wireless_dev *wdev;
struct iwm_priv *iwm;
u32 old_mode;
/* we're under RTNL */
ndev = __dev_get_by_index(&init_net, ifindex);
if (!ndev)
return -ENODEV;
wdev = ndev->ieee80211_ptr;
iwm = ndev_to_iwm(ndev);
old_mode = iwm->conf.mode;