aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r--drivers/net/wireless/adm8211.c12
-rw-r--r--drivers/net/wireless/at76c50x-usb.c6
-rw-r--r--drivers/net/wireless/ath/ar9170/main.c8
-rw-r--r--drivers/net/wireless/ath/ath5k/base.c18
-rw-r--r--drivers/net/wireless/ath/ath9k/main.c28
-rw-r--r--drivers/net/wireless/b43/main.c26
-rw-r--r--drivers/net/wireless/b43legacy/main.c24
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-core.c20
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-core.h4
-rw-r--r--drivers/net/wireless/libertas_tf/main.c10
-rw-r--r--drivers/net/wireless/mac80211_hwsim.c18
-rw-r--r--drivers/net/wireless/mwl8k.c14
-rw-r--r--drivers/net/wireless/p54/main.c12
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00.h4
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00mac.c26
-rw-r--r--drivers/net/wireless/rtl818x/rtl8180_dev.c12
-rw-r--r--drivers/net/wireless/rtl818x/rtl8187_dev.c10
-rw-r--r--drivers/net/wireless/wl12xx/wl1251_main.c14
-rw-r--r--drivers/net/wireless/wl12xx/wl1271_main.c10
-rw-r--r--drivers/net/wireless/zd1211rw/zd_mac.c10
20 files changed, 143 insertions, 143 deletions
diff --git a/drivers/net/wireless/adm8211.c b/drivers/net/wireless/adm8211.c
index 39410016b4ff..e1f04bb437e3 100644
--- a/drivers/net/wireless/adm8211.c
+++ b/drivers/net/wireless/adm8211.c
@@ -1400,15 +1400,15 @@ static void adm8211_configure_filter(struct ieee80211_hw *dev,
1400} 1400}
1401 1401
1402static int adm8211_add_interface(struct ieee80211_hw *dev, 1402static int adm8211_add_interface(struct ieee80211_hw *dev,
1403 struct ieee80211_if_init_conf *conf) 1403 struct ieee80211_vif *vif)
1404{ 1404{
1405 struct adm8211_priv *priv = dev->priv; 1405 struct adm8211_priv *priv = dev->priv;
1406 if (priv->mode != NL80211_IFTYPE_MONITOR) 1406 if (priv->mode != NL80211_IFTYPE_MONITOR)
1407 return -EOPNOTSUPP; 1407 return -EOPNOTSUPP;
1408 1408
1409 switch (conf->type) { 1409 switch (vif->type) {
1410 case NL80211_IFTYPE_STATION: 1410 case NL80211_IFTYPE_STATION:
1411 priv->mode = conf->type; 1411 priv->mode = vif->type;
1412 break; 1412 break;
1413 default: 1413 default:
1414 return -EOPNOTSUPP; 1414 return -EOPNOTSUPP;
@@ -1416,8 +1416,8 @@ static int adm8211_add_interface(struct ieee80211_hw *dev,
1416 1416
1417 ADM8211_IDLE(); 1417 ADM8211_IDLE();
1418 1418
1419 ADM8211_CSR_WRITE(PAR0, le32_to_cpu(*(__le32 *)conf->mac_addr)); 1419 ADM8211_CSR_WRITE(PAR0, le32_to_cpu(*(__le32 *)vif->addr));
1420 ADM8211_CSR_WRITE(PAR1, le16_to_cpu(*(__le16 *)(conf->mac_addr + 4))); 1420 ADM8211_CSR_WRITE(PAR1, le16_to_cpu(*(__le16 *)(vif->addr + 4)));
1421 1421
1422 adm8211_update_mode(dev); 1422 adm8211_update_mode(dev);
1423 1423
@@ -1427,7 +1427,7 @@ static int adm8211_add_interface(struct ieee80211_hw *dev,
1427} 1427}
1428 1428
1429static void adm8211_remove_interface(struct ieee80211_hw *dev, 1429static void adm8211_remove_interface(struct ieee80211_hw *dev,
1430 struct ieee80211_if_init_conf *conf) 1430 struct ieee80211_vif *vif)
1431{ 1431{
1432 struct adm8211_priv *priv = dev->priv; 1432 struct adm8211_priv *priv = dev->priv;
1433 priv->mode = NL80211_IFTYPE_MONITOR; 1433 priv->mode = NL80211_IFTYPE_MONITOR;
diff --git a/drivers/net/wireless/at76c50x-usb.c b/drivers/net/wireless/at76c50x-usb.c
index 2517364d3ebe..0fb419936dff 100644
--- a/drivers/net/wireless/at76c50x-usb.c
+++ b/drivers/net/wireless/at76c50x-usb.c
@@ -1789,7 +1789,7 @@ static void at76_mac80211_stop(struct ieee80211_hw *hw)
1789} 1789}
1790 1790
1791static int at76_add_interface(struct ieee80211_hw *hw, 1791static int at76_add_interface(struct ieee80211_hw *hw,
1792 struct ieee80211_if_init_conf *conf) 1792 struct ieee80211_vif *vif)
1793{ 1793{
1794 struct at76_priv *priv = hw->priv; 1794 struct at76_priv *priv = hw->priv;
1795 int ret = 0; 1795 int ret = 0;
@@ -1798,7 +1798,7 @@ static int at76_add_interface(struct ieee80211_hw *hw,
1798 1798
1799 mutex_lock(&priv->mtx); 1799 mutex_lock(&priv->mtx);
1800 1800
1801 switch (conf->type) { 1801 switch (vif->type) {
1802 case NL80211_IFTYPE_STATION: 1802 case NL80211_IFTYPE_STATION:
1803 priv->iw_mode = IW_MODE_INFRA; 1803 priv->iw_mode = IW_MODE_INFRA;
1804 break; 1804 break;
@@ -1814,7 +1814,7 @@ exit:
1814} 1814}
1815 1815
1816static void at76_remove_interface(struct ieee80211_hw *hw, 1816static void at76_remove_interface(struct ieee80211_hw *hw,
1817 struct ieee80211_if_init_conf *conf) 1817 struct ieee80211_vif *vif)
1818{ 1818{
1819 at76_dbg(DBG_MAC80211, "%s()", __func__); 1819 at76_dbg(DBG_MAC80211, "%s()", __func__);
1820} 1820}
diff --git a/drivers/net/wireless/ath/ar9170/main.c b/drivers/net/wireless/ath/ar9170/main.c
index 20f04ab2b13e..4d27f7f67c76 100644
--- a/drivers/net/wireless/ath/ar9170/main.c
+++ b/drivers/net/wireless/ath/ar9170/main.c
@@ -1939,7 +1939,7 @@ err_free:
1939} 1939}
1940 1940
1941static int ar9170_op_add_interface(struct ieee80211_hw *hw, 1941static int ar9170_op_add_interface(struct ieee80211_hw *hw,
1942 struct ieee80211_if_init_conf *conf) 1942 struct ieee80211_vif *vif)
1943{ 1943{
1944 struct ar9170 *ar = hw->priv; 1944 struct ar9170 *ar = hw->priv;
1945 struct ath_common *common = &ar->common; 1945 struct ath_common *common = &ar->common;
@@ -1952,8 +1952,8 @@ static int ar9170_op_add_interface(struct ieee80211_hw *hw,
1952 goto unlock; 1952 goto unlock;
1953 } 1953 }
1954 1954
1955 ar->vif = conf->vif; 1955 ar->vif = vif;
1956 memcpy(common->macaddr, conf->mac_addr, ETH_ALEN); 1956 memcpy(common->macaddr, vif->addr, ETH_ALEN);
1957 1957
1958 if (modparam_nohwcrypt || (ar->vif->type != NL80211_IFTYPE_STATION)) { 1958 if (modparam_nohwcrypt || (ar->vif->type != NL80211_IFTYPE_STATION)) {
1959 ar->rx_software_decryption = true; 1959 ar->rx_software_decryption = true;
@@ -1973,7 +1973,7 @@ unlock:
1973} 1973}
1974 1974
1975static void ar9170_op_remove_interface(struct ieee80211_hw *hw, 1975static void ar9170_op_remove_interface(struct ieee80211_hw *hw,
1976 struct ieee80211_if_init_conf *conf) 1976 struct ieee80211_vif *vif)
1977{ 1977{
1978 struct ar9170 *ar = hw->priv; 1978 struct ar9170 *ar = hw->priv;
1979 1979
diff --git a/drivers/net/wireless/ath/ath5k/base.c b/drivers/net/wireless/ath/ath5k/base.c
index a4c086f069b1..20c7e5b450aa 100644
--- a/drivers/net/wireless/ath/ath5k/base.c
+++ b/drivers/net/wireless/ath/ath5k/base.c
@@ -225,9 +225,9 @@ static int ath5k_reset_wake(struct ath5k_softc *sc);
225static int ath5k_start(struct ieee80211_hw *hw); 225static int ath5k_start(struct ieee80211_hw *hw);
226static void ath5k_stop(struct ieee80211_hw *hw); 226static void ath5k_stop(struct ieee80211_hw *hw);
227static int ath5k_add_interface(struct ieee80211_hw *hw, 227static int ath5k_add_interface(struct ieee80211_hw *hw,
228 struct ieee80211_if_init_conf *conf); 228 struct ieee80211_vif *vif);
229static void ath5k_remove_interface(struct ieee80211_hw *hw, 229static void ath5k_remove_interface(struct ieee80211_hw *hw,
230 struct ieee80211_if_init_conf *conf); 230 struct ieee80211_vif *vif);
231static int ath5k_config(struct ieee80211_hw *hw, u32 changed); 231static int ath5k_config(struct ieee80211_hw *hw, u32 changed);
232static u64 ath5k_prepare_multicast(struct ieee80211_hw *hw, 232static u64 ath5k_prepare_multicast(struct ieee80211_hw *hw,
233 int mc_count, struct dev_addr_list *mc_list); 233 int mc_count, struct dev_addr_list *mc_list);
@@ -2785,7 +2785,7 @@ static void ath5k_stop(struct ieee80211_hw *hw)
2785} 2785}
2786 2786
2787static int ath5k_add_interface(struct ieee80211_hw *hw, 2787static int ath5k_add_interface(struct ieee80211_hw *hw,
2788 struct ieee80211_if_init_conf *conf) 2788 struct ieee80211_vif *vif)
2789{ 2789{
2790 struct ath5k_softc *sc = hw->priv; 2790 struct ath5k_softc *sc = hw->priv;
2791 int ret; 2791 int ret;
@@ -2796,22 +2796,22 @@ static int ath5k_add_interface(struct ieee80211_hw *hw,
2796 goto end; 2796 goto end;
2797 } 2797 }
2798 2798
2799 sc->vif = conf->vif; 2799 sc->vif = vif;
2800 2800
2801 switch (conf->type) { 2801 switch (vif->type) {
2802 case NL80211_IFTYPE_AP: 2802 case NL80211_IFTYPE_AP:
2803 case NL80211_IFTYPE_STATION: 2803 case NL80211_IFTYPE_STATION:
2804 case NL80211_IFTYPE_ADHOC: 2804 case NL80211_IFTYPE_ADHOC:
2805 case NL80211_IFTYPE_MESH_POINT: 2805 case NL80211_IFTYPE_MESH_POINT:
2806 case NL80211_IFTYPE_MONITOR: 2806 case NL80211_IFTYPE_MONITOR:
2807 sc->opmode = conf->type; 2807 sc->opmode = vif->type;
2808 break; 2808 break;
2809 default: 2809 default:
2810 ret = -EOPNOTSUPP; 2810 ret = -EOPNOTSUPP;
2811 goto end; 2811 goto end;
2812 } 2812 }
2813 2813
2814 ath5k_hw_set_lladdr(sc->ah, conf->mac_addr); 2814 ath5k_hw_set_lladdr(sc->ah, vif->addr);
2815 ath5k_mode_setup(sc); 2815 ath5k_mode_setup(sc);
2816 2816
2817 ret = 0; 2817 ret = 0;
@@ -2822,13 +2822,13 @@ end:
2822 2822
2823static void 2823static void
2824ath5k_remove_interface(struct ieee80211_hw *hw, 2824ath5k_remove_interface(struct ieee80211_hw *hw,
2825 struct ieee80211_if_init_conf *conf) 2825 struct ieee80211_vif *vif)
2826{ 2826{
2827 struct ath5k_softc *sc = hw->priv; 2827 struct ath5k_softc *sc = hw->priv;
2828 u8 mac[ETH_ALEN] = {}; 2828 u8 mac[ETH_ALEN] = {};
2829 2829
2830 mutex_lock(&sc->lock); 2830 mutex_lock(&sc->lock);
2831 if (sc->vif != conf->vif) 2831 if (sc->vif != vif)
2832 goto end; 2832 goto end;
2833 2833
2834 ath5k_hw_set_lladdr(sc->ah, mac); 2834 ath5k_hw_set_lladdr(sc->ah, mac);
diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c
index 3f5b887d0fcd..446bd23756e5 100644
--- a/drivers/net/wireless/ath/ath9k/main.c
+++ b/drivers/net/wireless/ath/ath9k/main.c
@@ -2534,12 +2534,12 @@ static void ath9k_stop(struct ieee80211_hw *hw)
2534} 2534}
2535 2535
2536static int ath9k_add_interface(struct ieee80211_hw *hw, 2536static int ath9k_add_interface(struct ieee80211_hw *hw,
2537 struct ieee80211_if_init_conf *conf) 2537 struct ieee80211_vif *vif)
2538{ 2538{
2539 struct ath_wiphy *aphy = hw->priv; 2539 struct ath_wiphy *aphy = hw->priv;
2540 struct ath_softc *sc = aphy->sc; 2540 struct ath_softc *sc = aphy->sc;
2541 struct ath_common *common = ath9k_hw_common(sc->sc_ah); 2541 struct ath_common *common = ath9k_hw_common(sc->sc_ah);
2542 struct ath_vif *avp = (void *)conf->vif->drv_priv; 2542 struct ath_vif *avp = (void *)vif->drv_priv;
2543 enum nl80211_iftype ic_opmode = NL80211_IFTYPE_UNSPECIFIED; 2543 enum nl80211_iftype ic_opmode = NL80211_IFTYPE_UNSPECIFIED;
2544 int ret = 0; 2544 int ret = 0;
2545 2545
@@ -2551,7 +2551,7 @@ static int ath9k_add_interface(struct ieee80211_hw *hw,
2551 goto out; 2551 goto out;
2552 } 2552 }
2553 2553
2554 switch (conf->type) { 2554 switch (vif->type) {
2555 case NL80211_IFTYPE_STATION: 2555 case NL80211_IFTYPE_STATION:
2556 ic_opmode = NL80211_IFTYPE_STATION; 2556 ic_opmode = NL80211_IFTYPE_STATION;
2557 break; 2557 break;
@@ -2562,11 +2562,11 @@ static int ath9k_add_interface(struct ieee80211_hw *hw,
2562 ret = -ENOBUFS; 2562 ret = -ENOBUFS;
2563 goto out; 2563 goto out;
2564 } 2564 }
2565 ic_opmode = conf->type; 2565 ic_opmode = vif->type;
2566 break; 2566 break;
2567 default: 2567 default:
2568 ath_print(common, ATH_DBG_FATAL, 2568 ath_print(common, ATH_DBG_FATAL,
2569 "Interface type %d not yet supported\n", conf->type); 2569 "Interface type %d not yet supported\n", vif->type);
2570 ret = -EOPNOTSUPP; 2570 ret = -EOPNOTSUPP;
2571 goto out; 2571 goto out;
2572 } 2572 }
@@ -2598,18 +2598,18 @@ static int ath9k_add_interface(struct ieee80211_hw *hw,
2598 * Enable MIB interrupts when there are hardware phy counters. 2598 * Enable MIB interrupts when there are hardware phy counters.
2599 * Note we only do this (at the moment) for station mode. 2599 * Note we only do this (at the moment) for station mode.
2600 */ 2600 */
2601 if ((conf->type == NL80211_IFTYPE_STATION) || 2601 if ((vif->type == NL80211_IFTYPE_STATION) ||
2602 (conf->type == NL80211_IFTYPE_ADHOC) || 2602 (vif->type == NL80211_IFTYPE_ADHOC) ||
2603 (conf->type == NL80211_IFTYPE_MESH_POINT)) { 2603 (vif->type == NL80211_IFTYPE_MESH_POINT)) {
2604 sc->imask |= ATH9K_INT_MIB; 2604 sc->imask |= ATH9K_INT_MIB;
2605 sc->imask |= ATH9K_INT_TSFOOR; 2605 sc->imask |= ATH9K_INT_TSFOOR;
2606 } 2606 }
2607 2607
2608 ath9k_hw_set_interrupts(sc->sc_ah, sc->imask); 2608 ath9k_hw_set_interrupts(sc->sc_ah, sc->imask);
2609 2609
2610 if (conf->type == NL80211_IFTYPE_AP || 2610 if (vif->type == NL80211_IFTYPE_AP ||
2611 conf->type == NL80211_IFTYPE_ADHOC || 2611 vif->type == NL80211_IFTYPE_ADHOC ||
2612 conf->type == NL80211_IFTYPE_MONITOR) 2612 vif->type == NL80211_IFTYPE_MONITOR)
2613 ath_start_ani(common); 2613 ath_start_ani(common);
2614 2614
2615out: 2615out:
@@ -2618,12 +2618,12 @@ out:
2618} 2618}
2619 2619
2620static void ath9k_remove_interface(struct ieee80211_hw *hw, 2620static void ath9k_remove_interface(struct ieee80211_hw *hw,
2621 struct ieee80211_if_init_conf *conf) 2621 struct ieee80211_vif *vif)
2622{ 2622{
2623 struct ath_wiphy *aphy = hw->priv; 2623 struct ath_wiphy *aphy = hw->priv;
2624 struct ath_softc *sc = aphy->sc; 2624 struct ath_softc *sc = aphy->sc;
2625 struct ath_common *common = ath9k_hw_common(sc->sc_ah); 2625 struct ath_common *common = ath9k_hw_common(sc->sc_ah);
2626 struct ath_vif *avp = (void *)conf->vif->drv_priv; 2626 struct ath_vif *avp = (void *)vif->drv_priv;
2627 int i; 2627 int i;
2628 2628
2629 ath_print(common, ATH_DBG_CONFIG, "Detach Interface\n"); 2629 ath_print(common, ATH_DBG_CONFIG, "Detach Interface\n");
@@ -2644,7 +2644,7 @@ static void ath9k_remove_interface(struct ieee80211_hw *hw,
2644 sc->sc_flags &= ~SC_OP_BEACONS; 2644 sc->sc_flags &= ~SC_OP_BEACONS;
2645 2645
2646 for (i = 0; i < ARRAY_SIZE(sc->beacon.bslot); i++) { 2646 for (i = 0; i < ARRAY_SIZE(sc->beacon.bslot); i++) {
2647 if (sc->beacon.bslot[i] == conf->vif) { 2647 if (sc->beacon.bslot[i] == vif) {
2648 printk(KERN_DEBUG "%s: vif had allocated beacon " 2648 printk(KERN_DEBUG "%s: vif had allocated beacon "
2649 "slot\n", __func__); 2649 "slot\n", __func__);
2650 sc->beacon.bslot[i] = NULL; 2650 sc->beacon.bslot[i] = NULL;
diff --git a/drivers/net/wireless/b43/main.c b/drivers/net/wireless/b43/main.c
index b0b5ce950008..6634a77fc766 100644
--- a/drivers/net/wireless/b43/main.c
+++ b/drivers/net/wireless/b43/main.c
@@ -4391,7 +4391,7 @@ err_busdown:
4391} 4391}
4392 4392
4393static int b43_op_add_interface(struct ieee80211_hw *hw, 4393static int b43_op_add_interface(struct ieee80211_hw *hw,
4394 struct ieee80211_if_init_conf *conf) 4394 struct ieee80211_vif *vif)
4395{ 4395{
4396 struct b43_wl *wl = hw_to_b43_wl(hw); 4396 struct b43_wl *wl = hw_to_b43_wl(hw);
4397 struct b43_wldev *dev; 4397 struct b43_wldev *dev;
@@ -4399,24 +4399,24 @@ static int b43_op_add_interface(struct ieee80211_hw *hw,
4399 4399
4400 /* TODO: allow WDS/AP devices to coexist */ 4400 /* TODO: allow WDS/AP devices to coexist */
4401 4401
4402 if (conf->type != NL80211_IFTYPE_AP && 4402 if (vif->type != NL80211_IFTYPE_AP &&
4403 conf->type != NL80211_IFTYPE_MESH_POINT && 4403 vif->type != NL80211_IFTYPE_MESH_POINT &&
4404 conf->type != NL80211_IFTYPE_STATION && 4404 vif->type != NL80211_IFTYPE_STATION &&
4405 conf->type != NL80211_IFTYPE_WDS && 4405 vif->type != NL80211_IFTYPE_WDS &&
4406 conf->type != NL80211_IFTYPE_ADHOC) 4406 vif->type != NL80211_IFTYPE_ADHOC)
4407 return -EOPNOTSUPP; 4407 return -EOPNOTSUPP;
4408 4408
4409 mutex_lock(&wl->mutex); 4409 mutex_lock(&wl->mutex);
4410 if (wl->operating) 4410 if (wl->operating)
4411 goto out_mutex_unlock; 4411 goto out_mutex_unlock;
4412 4412
4413 b43dbg(wl, "Adding Interface type %d\n", conf->type); 4413 b43dbg(wl, "Adding Interface type %d\n", vif->type);
4414 4414
4415 dev = wl->current_dev; 4415 dev = wl->current_dev;
4416 wl->operating = 1; 4416 wl->operating = 1;
4417 wl->vif = conf->vif; 4417 wl->vif = vif;
4418 wl->if_type = conf->type; 4418 wl->if_type = vif->type;
4419 memcpy(wl->mac_addr, conf->mac_addr, ETH_ALEN); 4419 memcpy(wl->mac_addr, vif->addr, ETH_ALEN);
4420 4420
4421 b43_adjust_opmode(dev); 4421 b43_adjust_opmode(dev);
4422 b43_set_pretbtt(dev); 4422 b43_set_pretbtt(dev);
@@ -4431,17 +4431,17 @@ static int b43_op_add_interface(struct ieee80211_hw *hw,
4431} 4431}
4432 4432
4433static void b43_op_remove_interface(struct ieee80211_hw *hw, 4433static void b43_op_remove_interface(struct ieee80211_hw *hw,
4434 struct ieee80211_if_init_conf *conf) 4434 struct ieee80211_vif *vif)
4435{ 4435{
4436 struct b43_wl *wl = hw_to_b43_wl(hw); 4436 struct b43_wl *wl = hw_to_b43_wl(hw);
4437 struct b43_wldev *dev = wl->current_dev; 4437 struct b43_wldev *dev = wl->current_dev;
4438 4438
4439 b43dbg(wl, "Removing Interface type %d\n", conf->type); 4439 b43dbg(wl, "Removing Interface type %d\n", vif->type);
4440 4440
4441 mutex_lock(&wl->mutex); 4441 mutex_lock(&wl->mutex);
4442 4442
4443 B43_WARN_ON(!wl->operating); 4443 B43_WARN_ON(!wl->operating);
4444 B43_WARN_ON(wl->vif != conf->vif); 4444 B43_WARN_ON(wl->vif != vif);
4445 wl->vif = NULL; 4445 wl->vif = NULL;
4446 4446
4447 wl->operating = 0; 4447 wl->operating = 0;
diff --git a/drivers/net/wireless/b43legacy/main.c b/drivers/net/wireless/b43legacy/main.c
index ab6a18c2e9d9..494017e4fcc9 100644
--- a/drivers/net/wireless/b43legacy/main.c
+++ b/drivers/net/wireless/b43legacy/main.c
@@ -3361,7 +3361,7 @@ err_kfree_lo_control:
3361} 3361}
3362 3362
3363static int b43legacy_op_add_interface(struct ieee80211_hw *hw, 3363static int b43legacy_op_add_interface(struct ieee80211_hw *hw,
3364 struct ieee80211_if_init_conf *conf) 3364 struct ieee80211_vif *vif)
3365{ 3365{
3366 struct b43legacy_wl *wl = hw_to_b43legacy_wl(hw); 3366 struct b43legacy_wl *wl = hw_to_b43legacy_wl(hw);
3367 struct b43legacy_wldev *dev; 3367 struct b43legacy_wldev *dev;
@@ -3370,23 +3370,23 @@ static int b43legacy_op_add_interface(struct ieee80211_hw *hw,
3370 3370
3371 /* TODO: allow WDS/AP devices to coexist */ 3371 /* TODO: allow WDS/AP devices to coexist */
3372 3372
3373 if (conf->type != NL80211_IFTYPE_AP && 3373 if (vif->type != NL80211_IFTYPE_AP &&
3374 conf->type != NL80211_IFTYPE_STATION && 3374 vif->type != NL80211_IFTYPE_STATION &&
3375 conf->type != NL80211_IFTYPE_WDS && 3375 vif->type != NL80211_IFTYPE_WDS &&
3376 conf->type != NL80211_IFTYPE_ADHOC) 3376 vif->type != NL80211_IFTYPE_ADHOC)
3377 return -EOPNOTSUPP; 3377 return -EOPNOTSUPP;
3378 3378
3379 mutex_lock(&wl->mutex); 3379 mutex_lock(&wl->mutex);
3380 if (wl->operating) 3380 if (wl->operating)
3381 goto out_mutex_unlock; 3381 goto out_mutex_unlock;
3382 3382
3383 b43legacydbg(wl, "Adding Interface type %d\n", conf->type); 3383 b43legacydbg(wl, "Adding Interface type %d\n", vif->type);
3384 3384
3385 dev = wl->current_dev; 3385 dev = wl->current_dev;
3386 wl->operating = 1; 3386 wl->operating = 1;
3387 wl->vif = conf->vif; 3387 wl->vif = vif;
3388 wl->if_type = conf->type; 3388 wl->if_type = vif->type;
3389 memcpy(wl->mac_addr, conf->mac_addr, ETH_ALEN); 3389 memcpy(wl->mac_addr, vif->addr, ETH_ALEN);
3390 3390
3391 spin_lock_irqsave(&wl->irq_lock, flags); 3391 spin_lock_irqsave(&wl->irq_lock, flags);
3392 b43legacy_adjust_opmode(dev); 3392 b43legacy_adjust_opmode(dev);
@@ -3403,18 +3403,18 @@ static int b43legacy_op_add_interface(struct ieee80211_hw *hw,
3403} 3403}
3404 3404
3405static void b43legacy_op_remove_interface(struct ieee80211_hw *hw, 3405static void b43legacy_op_remove_interface(struct ieee80211_hw *hw,
3406 struct ieee80211_if_init_conf *conf) 3406 struct ieee80211_vif *vif)
3407{ 3407{
3408 struct b43legacy_wl *wl = hw_to_b43legacy_wl(hw); 3408 struct b43legacy_wl *wl = hw_to_b43legacy_wl(hw);
3409 struct b43legacy_wldev *dev = wl->current_dev; 3409 struct b43legacy_wldev *dev = wl->current_dev;
3410 unsigned long flags; 3410 unsigned long flags;
3411 3411
3412 b43legacydbg(wl, "Removing Interface type %d\n", conf->type); 3412 b43legacydbg(wl, "Removing Interface type %d\n", vif->type);
3413 3413
3414 mutex_lock(&wl->mutex); 3414 mutex_lock(&wl->mutex);
3415 3415
3416 B43legacy_WARN_ON(!wl->operating); 3416 B43legacy_WARN_ON(!wl->operating);
3417 B43legacy_WARN_ON(wl->vif != conf->vif); 3417 B43legacy_WARN_ON(wl->vif != vif);
3418 wl->vif = NULL; 3418 wl->vif = NULL;
3419 3419
3420 wl->operating = 0; 3420 wl->operating = 0;
diff --git a/drivers/net/wireless/iwlwifi/iwl-core.c b/drivers/net/wireless/iwlwifi/iwl-core.c
index e3b96b48b7fe..14f482960d7f 100644
--- a/drivers/net/wireless/iwlwifi/iwl-core.c
+++ b/drivers/net/wireless/iwlwifi/iwl-core.c
@@ -2584,12 +2584,12 @@ int iwl_set_mode(struct iwl_priv *priv, int mode)
2584EXPORT_SYMBOL(iwl_set_mode); 2584EXPORT_SYMBOL(iwl_set_mode);
2585 2585
2586int iwl_mac_add_interface(struct ieee80211_hw *hw, 2586int iwl_mac_add_interface(struct ieee80211_hw *hw,
2587 struct ieee80211_if_init_conf *conf) 2587 struct ieee80211_vif *vif)
2588{ 2588{
2589 struct iwl_priv *priv = hw->priv; 2589 struct iwl_priv *priv = hw->priv;
2590 unsigned long flags; 2590 unsigned long flags;
2591 2591
2592 IWL_DEBUG_MAC80211(priv, "enter: type %d\n", conf->type); 2592 IWL_DEBUG_MAC80211(priv, "enter: type %d\n", vif->type);
2593 2593
2594 if (priv->vif) { 2594 if (priv->vif) {
2595 IWL_DEBUG_MAC80211(priv, "leave - vif != NULL\n"); 2595 IWL_DEBUG_MAC80211(priv, "leave - vif != NULL\n");
@@ -2597,19 +2597,19 @@ int iwl_mac_add_interface(struct ieee80211_hw *hw,
2597 } 2597 }
2598 2598
2599 spin_lock_irqsave(&priv->lock, flags); 2599 spin_lock_irqsave(&priv->lock, flags);
2600 priv->vif = conf->vif; 2600 priv->vif = vif;
2601 priv->iw_mode = conf->type; 2601 priv->iw_mode = vif->type;
2602 2602
2603 spin_unlock_irqrestore(&priv->lock, flags); 2603 spin_unlock_irqrestore(&priv->lock, flags);
2604 2604
2605 mutex_lock(&priv->mutex); 2605 mutex_lock(&priv->mutex);
2606 2606
2607 if (conf->mac_addr) { 2607 if (vif->addr) {
2608 IWL_DEBUG_MAC80211(priv, "Set %pM\n", conf->mac_addr); 2608 IWL_DEBUG_MAC80211(priv, "Set %pM\n", vif->addr);
2609 memcpy(priv->mac_addr, conf->mac_addr, ETH_ALEN); 2609 memcpy(priv->mac_addr, vif->addr, ETH_ALEN);
2610 } 2610 }
2611 2611
2612 if (iwl_set_mode(priv, conf->type) == -EAGAIN) 2612 if (iwl_set_mode(priv, vif->type) == -EAGAIN)
2613 /* we are not ready, will run again when ready */ 2613 /* we are not ready, will run again when ready */
2614 set_bit(STATUS_MODE_PENDING, &priv->status); 2614 set_bit(STATUS_MODE_PENDING, &priv->status);
2615 2615
@@ -2621,7 +2621,7 @@ int iwl_mac_add_interface(struct ieee80211_hw *hw,
2621EXPORT_SYMBOL(iwl_mac_add_interface); 2621EXPORT_SYMBOL(iwl_mac_add_interface);
2622 2622
2623void iwl_mac_remove_interface(struct ieee80211_hw *hw, 2623void iwl_mac_remove_interface(struct ieee80211_hw *hw,
2624 struct ieee80211_if_init_conf *conf) 2624 struct ieee80211_vif *vif)
2625{ 2625{
2626 struct iwl_priv *priv = hw->priv; 2626 struct iwl_priv *priv = hw->priv;
2627 2627
@@ -2634,7 +2634,7 @@ void iwl_mac_remove_interface(struct ieee80211_hw *hw,
2634 priv->staging_rxon.filter_flags &= ~RXON_FILTER_ASSOC_MSK; 2634 priv->staging_rxon.filter_flags &= ~RXON_FILTER_ASSOC_MSK;
2635 iwlcore_commit_rxon(priv); 2635 iwlcore_commit_rxon(priv);
2636 } 2636 }
2637 if (priv->vif == conf->vif) { 2637 if (priv->vif == vif) {
2638 priv->vif = NULL; 2638 priv->vif = NULL;
2639 memset(priv->bssid, 0, ETH_ALEN); 2639 memset(priv->bssid, 0, ETH_ALEN);
2640 } 2640 }
diff --git a/drivers/net/wireless/iwlwifi/iwl-core.h b/drivers/net/wireless/iwlwifi/iwl-core.h
index f7acbb32900a..1728f961dcba 100644
--- a/drivers/net/wireless/iwlwifi/iwl-core.h
+++ b/drivers/net/wireless/iwlwifi/iwl-core.h
@@ -332,9 +332,9 @@ int iwl_mac_beacon_update(struct ieee80211_hw *hw, struct sk_buff *skb);
332int iwl_commit_rxon(struct iwl_priv *priv); 332int iwl_commit_rxon(struct iwl_priv *priv);
333int iwl_set_mode(struct iwl_priv *priv, int mode); 333int iwl_set_mode(struct iwl_priv *priv, int mode);
334int iwl_mac_add_interface(struct ieee80211_hw *hw, 334int iwl_mac_add_interface(struct ieee80211_hw *hw,
335 struct ieee80211_if_init_conf *conf); 335 struct ieee80211_vif *vif);
336void iwl_mac_remove_interface(struct ieee80211_hw *hw, 336void iwl_mac_remove_interface(struct ieee80211_hw *hw,
337 struct ieee80211_if_init_conf *conf); 337 struct ieee80211_vif *vif);
338int iwl_mac_config(struct ieee80211_hw *hw, u32 changed); 338int iwl_mac_config(struct ieee80211_hw *hw, u32 changed);
339void iwl_config_ap(struct iwl_priv *priv); 339void iwl_config_ap(struct iwl_priv *priv);
340int iwl_mac_get_tx_stats(struct ieee80211_hw *hw, 340int iwl_mac_get_tx_stats(struct ieee80211_hw *hw,
diff --git a/drivers/net/wireless/libertas_tf/main.c b/drivers/net/wireless/libertas_tf/main.c
index 019431d2f8a9..15a367680f59 100644
--- a/drivers/net/wireless/libertas_tf/main.c
+++ b/drivers/net/wireless/libertas_tf/main.c
@@ -318,14 +318,14 @@ static void lbtf_op_stop(struct ieee80211_hw *hw)
318} 318}
319 319
320static int lbtf_op_add_interface(struct ieee80211_hw *hw, 320static int lbtf_op_add_interface(struct ieee80211_hw *hw,
321 struct ieee80211_if_init_conf *conf) 321 struct ieee80211_vif *vif)
322{ 322{
323 struct lbtf_private *priv = hw->priv; 323 struct lbtf_private *priv = hw->priv;
324 if (priv->vif != NULL) 324 if (priv->vif != NULL)
325 return -EOPNOTSUPP; 325 return -EOPNOTSUPP;
326 326
327 priv->vif = conf->vif; 327 priv->vif = vif;
328 switch (conf->type) { 328 switch (vif->type) {
329 case NL80211_IFTYPE_MESH_POINT: 329 case NL80211_IFTYPE_MESH_POINT:
330 case NL80211_IFTYPE_AP: 330 case NL80211_IFTYPE_AP:
331 lbtf_set_mode(priv, LBTF_AP_MODE); 331 lbtf_set_mode(priv, LBTF_AP_MODE);
@@ -337,12 +337,12 @@ static int lbtf_op_add_interface(struct ieee80211_hw *hw,
337 priv->vif = NULL; 337 priv->vif = NULL;
338 return -EOPNOTSUPP; 338 return -EOPNOTSUPP;
339 } 339 }
340 lbtf_set_mac_address(priv, (u8 *) conf->mac_addr); 340 lbtf_set_mac_address(priv, (u8 *) vif->addr);
341 return 0; 341 return 0;
342} 342}
343 343
344static void lbtf_op_remove_interface(struct ieee80211_hw *hw, 344static void lbtf_op_remove_interface(struct ieee80211_hw *hw,
345 struct ieee80211_if_init_conf *conf) 345 struct ieee80211_vif *vif)
346{ 346{
347 struct lbtf_private *priv = hw->priv; 347 struct lbtf_private *priv = hw->priv;
348 348
diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c
index 4dee69a38c1d..84df3fcf37b3 100644
--- a/drivers/net/wireless/mac80211_hwsim.c
+++ b/drivers/net/wireless/mac80211_hwsim.c
@@ -584,24 +584,24 @@ static void mac80211_hwsim_stop(struct ieee80211_hw *hw)
584 584
585 585
586static int mac80211_hwsim_add_interface(struct ieee80211_hw *hw, 586static int mac80211_hwsim_add_interface(struct ieee80211_hw *hw,
587 struct ieee80211_if_init_conf *conf) 587 struct ieee80211_vif *vif)
588{ 588{
589 printk(KERN_DEBUG "%s:%s (type=%d mac_addr=%pM)\n", 589 printk(KERN_DEBUG "%s:%s (type=%d mac_addr=%pM)\n",
590 wiphy_name(hw->wiphy), __func__, conf->type, 590 wiphy_name(hw->wiphy), __func__, vif->type,
591 conf->mac_addr); 591 vif->addr);
592 hwsim_set_magic(conf->vif); 592 hwsim_set_magic(vif);
593 return 0; 593 return 0;
594} 594}
595 595
596 596
597static void mac80211_hwsim_remove_interface( 597static void mac80211_hwsim_remove_interface(
598 struct ieee80211_hw *hw, struct ieee80211_if_init_conf *conf) 598 struct ieee80211_hw *hw, struct ieee80211_vif *vif)
599{ 599{
600 printk(KERN_DEBUG "%s:%s (type=%d mac_addr=%pM)\n", 600 printk(KERN_DEBUG "%s:%s (type=%d mac_addr=%pM)\n",
601 wiphy_name(hw->wiphy), __func__, conf->type, 601 wiphy_name(hw->wiphy), __func__, vif->type,
602 conf->mac_addr); 602 vif->addr);
603 hwsim_check_magic(conf->vif); 603 hwsim_check_magic(vif);
604 hwsim_clear_magic(conf->vif); 604 hwsim_clear_magic(vif);
605} 605}
606 606
607 607
diff --git a/drivers/net/wireless/mwl8k.c b/drivers/net/wireless/mwl8k.c
index 97a95decf9a8..c1c6ecd0c5b3 100644
--- a/drivers/net/wireless/mwl8k.c
+++ b/drivers/net/wireless/mwl8k.c
@@ -2835,7 +2835,7 @@ static void mwl8k_stop(struct ieee80211_hw *hw)
2835} 2835}
2836 2836
2837static int mwl8k_add_interface(struct ieee80211_hw *hw, 2837static int mwl8k_add_interface(struct ieee80211_hw *hw,
2838 struct ieee80211_if_init_conf *conf) 2838 struct ieee80211_vif *vif)
2839{ 2839{
2840 struct mwl8k_priv *priv = hw->priv; 2840 struct mwl8k_priv *priv = hw->priv;
2841 struct mwl8k_vif *mwl8k_vif; 2841 struct mwl8k_vif *mwl8k_vif;
@@ -2849,7 +2849,7 @@ static int mwl8k_add_interface(struct ieee80211_hw *hw,
2849 /* 2849 /*
2850 * We only support managed interfaces for now. 2850 * We only support managed interfaces for now.
2851 */ 2851 */
2852 if (conf->type != NL80211_IFTYPE_STATION) 2852 if (vif->type != NL80211_IFTYPE_STATION)
2853 return -EINVAL; 2853 return -EINVAL;
2854 2854
2855 /* 2855 /*
@@ -2865,24 +2865,24 @@ static int mwl8k_add_interface(struct ieee80211_hw *hw,
2865 } 2865 }
2866 2866
2867 /* Clean out driver private area */ 2867 /* Clean out driver private area */
2868 mwl8k_vif = MWL8K_VIF(conf->vif); 2868 mwl8k_vif = MWL8K_VIF(vif);
2869 memset(mwl8k_vif, 0, sizeof(*mwl8k_vif)); 2869 memset(mwl8k_vif, 0, sizeof(*mwl8k_vif));
2870 2870
2871 /* Set and save the mac address */ 2871 /* Set and save the mac address */
2872 mwl8k_cmd_set_mac_addr(hw, conf->mac_addr); 2872 mwl8k_cmd_set_mac_addr(hw, vif->addr);
2873 memcpy(mwl8k_vif->mac_addr, conf->mac_addr, ETH_ALEN); 2873 memcpy(mwl8k_vif->mac_addr, vif->addr, ETH_ALEN);
2874 2874
2875 /* Set Initial sequence number to zero */ 2875 /* Set Initial sequence number to zero */
2876 mwl8k_vif->seqno = 0; 2876 mwl8k_vif->seqno = 0;
2877 2877
2878 priv->vif = conf->vif; 2878 priv->vif = vif;
2879 priv->current_channel = NULL; 2879 priv->current_channel = NULL;
2880 2880
2881 return 0; 2881 return 0;
2882} 2882}
2883 2883
2884static void mwl8k_remove_interface(struct ieee80211_hw *hw, 2884static void mwl8k_remove_interface(struct ieee80211_hw *hw,
2885 struct ieee80211_if_init_conf *conf) 2885 struct ieee80211_vif *vif)
2886{ 2886{
2887 struct mwl8k_priv *priv = hw->priv; 2887 struct mwl8k_priv *priv = hw->priv;
2888 2888
diff --git a/drivers/net/wireless/p54/main.c b/drivers/net/wireless/p54/main.c
index 18012dbfb45d..26428e4c9c60 100644
--- a/drivers/net/wireless/p54/main.c
+++ b/drivers/net/wireless/p54/main.c
@@ -216,7 +216,7 @@ static void p54_stop(struct ieee80211_hw *dev)
216} 216}
217 217
218static int p54_add_interface(struct ieee80211_hw *dev, 218static int p54_add_interface(struct ieee80211_hw *dev,
219 struct ieee80211_if_init_conf *conf) 219 struct ieee80211_vif *vif)
220{ 220{
221 struct p54_common *priv = dev->priv; 221 struct p54_common *priv = dev->priv;
222 222
@@ -226,28 +226,28 @@ static int p54_add_interface(struct ieee80211_hw *dev,
226 return -EOPNOTSUPP; 226 return -EOPNOTSUPP;
227 } 227 }
228 228
229 priv->vif = conf->vif; 229 priv->vif = vif;
230 230
231 switch (conf->type) { 231 switch (vif->type) {
232 case NL80211_IFTYPE_STATION: 232 case NL80211_IFTYPE_STATION:
233 case NL80211_IFTYPE_ADHOC: 233 case NL80211_IFTYPE_ADHOC:
234 case NL80211_IFTYPE_AP: 234 case NL80211_IFTYPE_AP:
235 case NL80211_IFTYPE_MESH_POINT: 235 case NL80211_IFTYPE_MESH_POINT:
236 priv->mode = conf->type; 236 priv->mode = vif->type;
237 break; 237 break;
238 default: 238 default:
239 mutex_unlock(&priv->conf_mutex); 239 mutex_unlock(&priv->conf_mutex);
240 return -EOPNOTSUPP; 240 return -EOPNOTSUPP;
241 } 241 }
242 242
243 memcpy(priv->mac_addr, conf->mac_addr, ETH_ALEN); 243 memcpy(priv->mac_addr, vif->addr, ETH_ALEN);
244 p54_setup_mac(priv); 244 p54_setup_mac(priv);
245 mutex_unlock(&priv->conf_mutex); 245 mutex_unlock(&priv->conf_mutex);
246 return 0; 246 return 0;
247} 247}
248 248
249static void p54_remove_interface(struct ieee80211_hw *dev, 249static void p54_remove_interface(struct ieee80211_hw *dev,
250 struct ieee80211_if_init_conf *conf) 250 struct ieee80211_vif *vif)
251{ 251{
252 struct p54_common *priv = dev->priv; 252 struct p54_common *priv = dev->priv;
253 253
diff --git a/drivers/net/wireless/rt2x00/rt2x00.h b/drivers/net/wireless/rt2x00/rt2x00.h
index a664a999b2b0..b4c6e0a6d7e0 100644
--- a/drivers/net/wireless/rt2x00/rt2x00.h
+++ b/drivers/net/wireless/rt2x00/rt2x00.h
@@ -1019,9 +1019,9 @@ int rt2x00mac_tx(struct ieee80211_hw *hw, struct sk_buff *skb);
1019int rt2x00mac_start(struct ieee80211_hw *hw); 1019int rt2x00mac_start(struct ieee80211_hw *hw);
1020void rt2x00mac_stop(struct ieee80211_hw *hw); 1020void rt2x00mac_stop(struct ieee80211_hw *hw);
1021int rt2x00mac_add_interface(struct ieee80211_hw *hw, 1021int rt2x00mac_add_interface(struct ieee80211_hw *hw,
1022 struct ieee80211_if_init_conf *conf); 1022 struct ieee80211_vif *vif);
1023void rt2x00mac_remove_interface(struct ieee80211_hw *hw, 1023void rt2x00mac_remove_interface(struct ieee80211_hw *hw,
1024 struct ieee80211_if_init_conf *conf); 1024 struct ieee80211_vif *vif);
1025int rt2x00mac_config(struct ieee80211_hw *hw, u32 changed); 1025int rt2x00mac_config(struct ieee80211_hw *hw, u32 changed);
1026void rt2x00mac_configure_filter(struct ieee80211_hw *hw, 1026void rt2x00mac_configure_filter(struct ieee80211_hw *hw,
1027 unsigned int changed_flags, 1027 unsigned int changed_flags,
diff --git a/drivers/net/wireless/rt2x00/rt2x00mac.c b/drivers/net/wireless/rt2x00/rt2x00mac.c
index de549c244ed8..00f1f939f1bb 100644
--- a/drivers/net/wireless/rt2x00/rt2x00mac.c
+++ b/drivers/net/wireless/rt2x00/rt2x00mac.c
@@ -187,10 +187,10 @@ void rt2x00mac_stop(struct ieee80211_hw *hw)
187EXPORT_SYMBOL_GPL(rt2x00mac_stop); 187EXPORT_SYMBOL_GPL(rt2x00mac_stop);
188 188
189int rt2x00mac_add_interface(struct ieee80211_hw *hw, 189int rt2x00mac_add_interface(struct ieee80211_hw *hw,
190 struct ieee80211_if_init_conf *conf) 190 struct ieee80211_vif *vif)
191{ 191{
192 struct rt2x00_dev *rt2x00dev = hw->priv; 192 struct rt2x00_dev *rt2x00dev = hw->priv;
193 struct rt2x00_intf *intf = vif_to_intf(conf->vif); 193 struct rt2x00_intf *intf = vif_to_intf(vif);
194 struct data_queue *queue = rt2x00queue_get_queue(rt2x00dev, QID_BEACON); 194 struct data_queue *queue = rt2x00queue_get_queue(rt2x00dev, QID_BEACON);
195 struct queue_entry *entry = NULL; 195 struct queue_entry *entry = NULL;
196 unsigned int i; 196 unsigned int i;
@@ -203,7 +203,7 @@ int rt2x00mac_add_interface(struct ieee80211_hw *hw,
203 !test_bit(DEVICE_STATE_STARTED, &rt2x00dev->flags)) 203 !test_bit(DEVICE_STATE_STARTED, &rt2x00dev->flags))
204 return -ENODEV; 204 return -ENODEV;
205 205
206 switch (conf->type) { 206 switch (vif->type) {
207 case NL80211_IFTYPE_AP: 207 case NL80211_IFTYPE_AP:
208 /* 208 /*
209 * We don't support mixed combinations of 209 * We don't support mixed combinations of
@@ -263,7 +263,7 @@ int rt2x00mac_add_interface(struct ieee80211_hw *hw,
263 * increase interface count and start initialization. 263 * increase interface count and start initialization.
264 */ 264 */
265 265
266 if (conf->type == NL80211_IFTYPE_AP) 266 if (vif->type == NL80211_IFTYPE_AP)
267 rt2x00dev->intf_ap_count++; 267 rt2x00dev->intf_ap_count++;
268 else 268 else
269 rt2x00dev->intf_sta_count++; 269 rt2x00dev->intf_sta_count++;
@@ -273,16 +273,16 @@ int rt2x00mac_add_interface(struct ieee80211_hw *hw,
273 mutex_init(&intf->beacon_skb_mutex); 273 mutex_init(&intf->beacon_skb_mutex);
274 intf->beacon = entry; 274 intf->beacon = entry;
275 275
276 if (conf->type == NL80211_IFTYPE_AP) 276 if (vif->type == NL80211_IFTYPE_AP)
277 memcpy(&intf->bssid, conf->mac_addr, ETH_ALEN); 277 memcpy(&intf->bssid, vif->addr, ETH_ALEN);
278 memcpy(&intf->mac, conf->mac_addr, ETH_ALEN); 278 memcpy(&intf->mac, vif->addr, ETH_ALEN);
279 279
280 /* 280 /*
281 * The MAC adddress must be configured after the device 281 * The MAC adddress must be configured after the device
282 * has been initialized. Otherwise the device can reset 282 * has been initialized. Otherwise the device can reset
283 * the MAC registers. 283 * the MAC registers.
284 */ 284 */
285 rt2x00lib_config_intf(rt2x00dev, intf, conf->type, intf->mac, NULL); 285 rt2x00lib_config_intf(rt2x00dev, intf, vif->type, intf->mac, NULL);
286 286
287 /* 287 /*
288 * Some filters depend on the current working mode. We can force 288 * Some filters depend on the current working mode. We can force
@@ -296,10 +296,10 @@ int rt2x00mac_add_interface(struct ieee80211_hw *hw,
296EXPORT_SYMBOL_GPL(rt2x00mac_add_interface); 296EXPORT_SYMBOL_GPL(rt2x00mac_add_interface);
297 297
298void rt2x00mac_remove_interface(struct ieee80211_hw *hw, 298void rt2x00mac_remove_interface(struct ieee80211_hw *hw,
299 struct ieee80211_if_init_conf *conf) 299 struct ieee80211_vif *vif)
300{ 300{
301 struct rt2x00_dev *rt2x00dev = hw->priv; 301 struct rt2x00_dev *rt2x00dev = hw->priv;
302 struct rt2x00_intf *intf = vif_to_intf(conf->vif); 302 struct rt2x00_intf *intf = vif_to_intf(vif);
303 303
304 /* 304 /*
305 * Don't allow interfaces to be remove while 305 * Don't allow interfaces to be remove while
@@ -307,11 +307,11 @@ void rt2x00mac_remove_interface(struct ieee80211_hw *hw,
307 * no interface is present. 307 * no interface is present.
308 */ 308 */
309 if (!test_bit(DEVICE_STATE_PRESENT, &rt2x00dev->flags) || 309 if (!test_bit(DEVICE_STATE_PRESENT, &rt2x00dev->flags) ||
310 (conf->type == NL80211_IFTYPE_AP && !rt2x00dev->intf_ap_count) || 310 (vif->type == NL80211_IFTYPE_AP && !rt2x00dev->intf_ap_count) ||
311 (conf->type != NL80211_IFTYPE_AP && !rt2x00dev->intf_sta_count)) 311 (vif->type != NL80211_IFTYPE_AP && !rt2x00dev->intf_sta_count))
312 return; 312 return;
313 313
314 if (conf->type == NL80211_IFTYPE_AP) 314 if (vif->type == NL80211_IFTYPE_AP)
315 rt2x00dev->intf_ap_count--; 315 rt2x00dev->intf_ap_count--;
316 else 316 else
317 rt2x00dev->intf_sta_count--; 317 rt2x00dev->intf_sta_count--;
diff --git a/drivers/net/wireless/rtl818x/rtl8180_dev.c b/drivers/net/wireless/rtl818x/rtl8180_dev.c
index f01f1ef9e3be..5a2b7199f5d5 100644
--- a/drivers/net/wireless/rtl818x/rtl8180_dev.c
+++ b/drivers/net/wireless/rtl818x/rtl8180_dev.c
@@ -652,7 +652,7 @@ static void rtl8180_stop(struct ieee80211_hw *dev)
652} 652}
653 653
654static int rtl8180_add_interface(struct ieee80211_hw *dev, 654static int rtl8180_add_interface(struct ieee80211_hw *dev,
655 struct ieee80211_if_init_conf *conf) 655 struct ieee80211_vif *vif)
656{ 656{
657 struct rtl8180_priv *priv = dev->priv; 657 struct rtl8180_priv *priv = dev->priv;
658 658
@@ -662,27 +662,27 @@ static int rtl8180_add_interface(struct ieee80211_hw *dev,
662 if (priv->vif) 662 if (priv->vif)
663 return -EBUSY; 663 return -EBUSY;
664 664
665 switch (conf->type) { 665 switch (vif->type) {
666 case NL80211_IFTYPE_STATION: 666 case NL80211_IFTYPE_STATION:
667 break; 667 break;
668 default: 668 default:
669 return -EOPNOTSUPP; 669 return -EOPNOTSUPP;
670 } 670 }
671 671
672 priv->vif = conf->vif; 672 priv->vif = vif;
673 673
674 rtl818x_iowrite8(priv, &priv->map->EEPROM_CMD, RTL818X_EEPROM_CMD_CONFIG); 674 rtl818x_iowrite8(priv, &priv->map->EEPROM_CMD, RTL818X_EEPROM_CMD_CONFIG);
675 rtl818x_iowrite32(priv, (__le32 __iomem *)&priv->map->MAC[0], 675 rtl818x_iowrite32(priv, (__le32 __iomem *)&priv->map->MAC[0],
676 le32_to_cpu(*(__le32 *)conf->mac_addr)); 676 le32_to_cpu(*(__le32 *)vif->addr));
677 rtl818x_iowrite16(priv, (__le16 __iomem *)&priv->map->MAC[4], 677 rtl818x_iowrite16(priv, (__le16 __iomem *)&priv->map->MAC[4],
678 le16_to_cpu(*(__le16 *)(conf->mac_addr + 4))); 678 le16_to_cpu(*(__le16 *)(vif->addr + 4)));
679 rtl818x_iowrite8(priv, &priv->map->EEPROM_CMD, RTL818X_EEPROM_CMD_NORMAL); 679 rtl818x_iowrite8(priv, &priv->map->EEPROM_CMD, RTL818X_EEPROM_CMD_NORMAL);
680 680
681 return 0; 681 return 0;
682} 682}
683 683
684static void rtl8180_remove_interface(struct ieee80211_hw *dev, 684static void rtl8180_remove_interface(struct ieee80211_hw *dev,
685 struct ieee80211_if_init_conf *conf) 685 struct ieee80211_vif *vif)
686{ 686{
687 struct rtl8180_priv *priv = dev->priv; 687 struct rtl8180_priv *priv = dev->priv;
688 priv->vif = NULL; 688 priv->vif = NULL;
diff --git a/drivers/net/wireless/rtl818x/rtl8187_dev.c b/drivers/net/wireless/rtl818x/rtl8187_dev.c
index 1cb0eff46223..f336c63053c1 100644
--- a/drivers/net/wireless/rtl818x/rtl8187_dev.c
+++ b/drivers/net/wireless/rtl818x/rtl8187_dev.c
@@ -1018,7 +1018,7 @@ static void rtl8187_stop(struct ieee80211_hw *dev)
1018} 1018}
1019 1019
1020static int rtl8187_add_interface(struct ieee80211_hw *dev, 1020static int rtl8187_add_interface(struct ieee80211_hw *dev,
1021 struct ieee80211_if_init_conf *conf) 1021 struct ieee80211_vif *vif)
1022{ 1022{
1023 struct rtl8187_priv *priv = dev->priv; 1023 struct rtl8187_priv *priv = dev->priv;
1024 int i; 1024 int i;
@@ -1028,7 +1028,7 @@ static int rtl8187_add_interface(struct ieee80211_hw *dev,
1028 if (priv->vif) 1028 if (priv->vif)
1029 goto exit; 1029 goto exit;
1030 1030
1031 switch (conf->type) { 1031 switch (vif->type) {
1032 case NL80211_IFTYPE_STATION: 1032 case NL80211_IFTYPE_STATION:
1033 break; 1033 break;
1034 default: 1034 default:
@@ -1036,12 +1036,12 @@ static int rtl8187_add_interface(struct ieee80211_hw *dev,
1036 } 1036 }
1037 1037
1038 ret = 0; 1038 ret = 0;
1039 priv->vif = conf->vif; 1039 priv->vif = vif;
1040 1040
1041 rtl818x_iowrite8(priv, &priv->map->EEPROM_CMD, RTL818X_EEPROM_CMD_CONFIG); 1041 rtl818x_iowrite8(priv, &priv->map->EEPROM_CMD, RTL818X_EEPROM_CMD_CONFIG);
1042 for (i = 0; i < ETH_ALEN; i++) 1042 for (i = 0; i < ETH_ALEN; i++)
1043 rtl818x_iowrite8(priv, &priv->map->MAC[i], 1043 rtl818x_iowrite8(priv, &priv->map->MAC[i],
1044 ((u8 *)conf->mac_addr)[i]); 1044 ((u8 *)vif->addr)[i]);
1045 rtl818x_iowrite8(priv, &priv->map->EEPROM_CMD, RTL818X_EEPROM_CMD_NORMAL); 1045 rtl818x_iowrite8(priv, &priv->map->EEPROM_CMD, RTL818X_EEPROM_CMD_NORMAL);
1046 1046
1047exit: 1047exit:
@@ -1050,7 +1050,7 @@ exit:
1050} 1050}
1051 1051
1052static void rtl8187_remove_interface(struct ieee80211_hw *dev, 1052static void rtl8187_remove_interface(struct ieee80211_hw *dev,
1053 struct ieee80211_if_init_conf *conf) 1053 struct ieee80211_vif *vif)
1054{ 1054{
1055 struct rtl8187_priv *priv = dev->priv; 1055 struct rtl8187_priv *priv = dev->priv;
1056 mutex_lock(&priv->conf_mutex); 1056 mutex_lock(&priv->conf_mutex);
diff --git a/drivers/net/wireless/wl12xx/wl1251_main.c b/drivers/net/wireless/wl12xx/wl1251_main.c
index 6aeffbe9e401..4e373f3dbc43 100644
--- a/drivers/net/wireless/wl12xx/wl1251_main.c
+++ b/drivers/net/wireless/wl12xx/wl1251_main.c
@@ -511,13 +511,13 @@ static void wl1251_op_stop(struct ieee80211_hw *hw)
511} 511}
512 512
513static int wl1251_op_add_interface(struct ieee80211_hw *hw, 513static int wl1251_op_add_interface(struct ieee80211_hw *hw,
514 struct ieee80211_if_init_conf *conf) 514 struct ieee80211_vif *vif)
515{ 515{
516 struct wl1251 *wl = hw->priv; 516 struct wl1251 *wl = hw->priv;
517 int ret = 0; 517 int ret = 0;
518 518
519 wl1251_debug(DEBUG_MAC80211, "mac80211 add interface type %d mac %pM", 519 wl1251_debug(DEBUG_MAC80211, "mac80211 add interface type %d mac %pM",
520 conf->type, conf->mac_addr); 520 vif->type, vif->addr);
521 521
522 mutex_lock(&wl->mutex); 522 mutex_lock(&wl->mutex);
523 if (wl->vif) { 523 if (wl->vif) {
@@ -525,9 +525,9 @@ static int wl1251_op_add_interface(struct ieee80211_hw *hw,
525 goto out; 525 goto out;
526 } 526 }
527 527
528 wl->vif = conf->vif; 528 wl->vif = vif;
529 529
530 switch (conf->type) { 530 switch (vif->type) {
531 case NL80211_IFTYPE_STATION: 531 case NL80211_IFTYPE_STATION:
532 wl->bss_type = BSS_TYPE_STA_BSS; 532 wl->bss_type = BSS_TYPE_STA_BSS;
533 break; 533 break;
@@ -539,8 +539,8 @@ static int wl1251_op_add_interface(struct ieee80211_hw *hw,
539 goto out; 539 goto out;
540 } 540 }
541 541
542 if (memcmp(wl->mac_addr, conf->mac_addr, ETH_ALEN)) { 542 if (memcmp(wl->mac_addr, vif->addr, ETH_ALEN)) {
543 memcpy(wl->mac_addr, conf->mac_addr, ETH_ALEN); 543 memcpy(wl->mac_addr, vif->addr, ETH_ALEN);
544 SET_IEEE80211_PERM_ADDR(wl->hw, wl->mac_addr); 544 SET_IEEE80211_PERM_ADDR(wl->hw, wl->mac_addr);
545 ret = wl1251_acx_station_id(wl); 545 ret = wl1251_acx_station_id(wl);
546 if (ret < 0) 546 if (ret < 0)
@@ -553,7 +553,7 @@ out:
553} 553}
554 554
555static void wl1251_op_remove_interface(struct ieee80211_hw *hw, 555static void wl1251_op_remove_interface(struct ieee80211_hw *hw,
556 struct ieee80211_if_init_conf *conf) 556 struct ieee80211_vif *vif)
557{ 557{
558 struct wl1251 *wl = hw->priv; 558 struct wl1251 *wl = hw->priv;
559 559
diff --git a/drivers/net/wireless/wl12xx/wl1271_main.c b/drivers/net/wireless/wl12xx/wl1271_main.c
index 4a997381a8d0..e4867b895c43 100644
--- a/drivers/net/wireless/wl12xx/wl1271_main.c
+++ b/drivers/net/wireless/wl12xx/wl1271_main.c
@@ -1039,13 +1039,13 @@ static void wl1271_op_stop(struct ieee80211_hw *hw)
1039} 1039}
1040 1040
1041static int wl1271_op_add_interface(struct ieee80211_hw *hw, 1041static int wl1271_op_add_interface(struct ieee80211_hw *hw,
1042 struct ieee80211_if_init_conf *conf) 1042 struct ieee80211_vif *vif)
1043{ 1043{
1044 struct wl1271 *wl = hw->priv; 1044 struct wl1271 *wl = hw->priv;
1045 int ret = 0; 1045 int ret = 0;
1046 1046
1047 wl1271_debug(DEBUG_MAC80211, "mac80211 add interface type %d mac %pM", 1047 wl1271_debug(DEBUG_MAC80211, "mac80211 add interface type %d mac %pM",
1048 conf->type, conf->mac_addr); 1048 vif->type, vif->addr);
1049 1049
1050 mutex_lock(&wl->mutex); 1050 mutex_lock(&wl->mutex);
1051 if (wl->vif) { 1051 if (wl->vif) {
@@ -1053,9 +1053,9 @@ static int wl1271_op_add_interface(struct ieee80211_hw *hw,
1053 goto out; 1053 goto out;
1054 } 1054 }
1055 1055
1056 wl->vif = conf->vif; 1056 wl->vif = vif;
1057 1057
1058 switch (conf->type) { 1058 switch (vif->type) {
1059 case NL80211_IFTYPE_STATION: 1059 case NL80211_IFTYPE_STATION:
1060 wl->bss_type = BSS_TYPE_STA_BSS; 1060 wl->bss_type = BSS_TYPE_STA_BSS;
1061 break; 1061 break;
@@ -1075,7 +1075,7 @@ out:
1075} 1075}
1076 1076
1077static void wl1271_op_remove_interface(struct ieee80211_hw *hw, 1077static void wl1271_op_remove_interface(struct ieee80211_hw *hw,
1078 struct ieee80211_if_init_conf *conf) 1078 struct ieee80211_vif *vif)
1079{ 1079{
1080 struct wl1271 *wl = hw->priv; 1080 struct wl1271 *wl = hw->priv;
1081 1081
diff --git a/drivers/net/wireless/zd1211rw/zd_mac.c b/drivers/net/wireless/zd1211rw/zd_mac.c
index 8a243732c519..c4f41d0016c5 100644
--- a/drivers/net/wireless/zd1211rw/zd_mac.c
+++ b/drivers/net/wireless/zd1211rw/zd_mac.c
@@ -872,7 +872,7 @@ int zd_mac_rx(struct ieee80211_hw *hw, const u8 *buffer, unsigned int length)
872} 872}
873 873
874static int zd_op_add_interface(struct ieee80211_hw *hw, 874static int zd_op_add_interface(struct ieee80211_hw *hw,
875 struct ieee80211_if_init_conf *conf) 875 struct ieee80211_vif *vif)
876{ 876{
877 struct zd_mac *mac = zd_hw_mac(hw); 877 struct zd_mac *mac = zd_hw_mac(hw);
878 878
@@ -880,22 +880,22 @@ static int zd_op_add_interface(struct ieee80211_hw *hw,
880 if (mac->type != NL80211_IFTYPE_UNSPECIFIED) 880 if (mac->type != NL80211_IFTYPE_UNSPECIFIED)
881 return -EOPNOTSUPP; 881 return -EOPNOTSUPP;
882 882
883 switch (conf->type) { 883 switch (vif->type) {
884 case NL80211_IFTYPE_MONITOR: 884 case NL80211_IFTYPE_MONITOR:
885 case NL80211_IFTYPE_MESH_POINT: 885 case NL80211_IFTYPE_MESH_POINT:
886 case NL80211_IFTYPE_STATION: 886 case NL80211_IFTYPE_STATION:
887 case NL80211_IFTYPE_ADHOC: 887 case NL80211_IFTYPE_ADHOC:
888 mac->type = conf->type; 888 mac->type = vif->type;
889 break; 889 break;
890 default: 890 default:
891 return -EOPNOTSUPP; 891 return -EOPNOTSUPP;
892 } 892 }
893 893
894 return zd_write_mac_addr(&mac->chip, conf->mac_addr); 894 return zd_write_mac_addr(&mac->chip, vif->addr);
895} 895}
896 896
897static void zd_op_remove_interface(struct ieee80211_hw *hw, 897static void zd_op_remove_interface(struct ieee80211_hw *hw,
898 struct ieee80211_if_init_conf *conf) 898 struct ieee80211_vif *vif)
899{ 899{
900 struct zd_mac *mac = zd_hw_mac(hw); 900 struct zd_mac *mac = zd_hw_mac(hw);
901 mac->type = NL80211_IFTYPE_UNSPECIFIED; 901 mac->type = NL80211_IFTYPE_UNSPECIFIED;