aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl-sta.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2010-04-28 11:44:51 -0400
committerReinette Chatre <reinette.chatre@intel.com>2010-05-10 18:08:52 -0400
commitc0222df86e55576ef879795b5a158c46e6653f07 (patch)
tree87a2c5b717617ef75fa90aa72ef6f2a42ac1d3d1 /drivers/net/wireless/iwlwifi/iwl-sta.c
parent6e0b9cac681bf9b633397d2d5270e5ab31ca04db (diff)
iwlwifi: pass address to iwl_remove_station
We'll need that function for IBSS station management, so pass it the address, which is the only thing it uses from the station struct. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-sta.c')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-sta.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-sta.c b/drivers/net/wireless/iwlwifi/iwl-sta.c
index 5c6b3262baf9..354eb13a8515 100644
--- a/drivers/net/wireless/iwlwifi/iwl-sta.c
+++ b/drivers/net/wireless/iwlwifi/iwl-sta.c
@@ -596,7 +596,7 @@ static int iwl_send_remove_station(struct iwl_priv *priv,
596/** 596/**
597 * iwl_remove_station - Remove driver's knowledge of station. 597 * iwl_remove_station - Remove driver's knowledge of station.
598 */ 598 */
599static int iwl_remove_station(struct iwl_priv *priv, struct ieee80211_sta *sta) 599static int iwl_remove_station(struct iwl_priv *priv, const u8 *addr)
600{ 600{
601 int sta_id = IWL_INVALID_STATION; 601 int sta_id = IWL_INVALID_STATION;
602 int i, ret = -EINVAL; 602 int i, ret = -EINVAL;
@@ -607,7 +607,7 @@ static int iwl_remove_station(struct iwl_priv *priv, struct ieee80211_sta *sta)
607 if (!iwl_is_ready(priv)) { 607 if (!iwl_is_ready(priv)) {
608 IWL_DEBUG_INFO(priv, 608 IWL_DEBUG_INFO(priv,
609 "Unable to remove station %pM, device not ready.\n", 609 "Unable to remove station %pM, device not ready.\n",
610 sta->addr); 610 addr);
611 /* 611 /*
612 * It is typical for stations to be removed when we are 612 * It is typical for stations to be removed when we are
613 * going down. Return success since device will be down 613 * going down. Return success since device will be down
@@ -624,7 +624,7 @@ static int iwl_remove_station(struct iwl_priv *priv, struct ieee80211_sta *sta)
624 for (i = IWL_STA_ID; i < priv->hw_params.max_stations; i++) 624 for (i = IWL_STA_ID; i < priv->hw_params.max_stations; i++)
625 if (priv->stations[i].used && 625 if (priv->stations[i].used &&
626 !compare_ether_addr(priv->stations[i].sta.sta.addr, 626 !compare_ether_addr(priv->stations[i].sta.sta.addr,
627 sta->addr)) { 627 addr)) {
628 sta_id = i; 628 sta_id = i;
629 break; 629 break;
630 } 630 }
@@ -633,17 +633,17 @@ static int iwl_remove_station(struct iwl_priv *priv, struct ieee80211_sta *sta)
633 goto out; 633 goto out;
634 634
635 IWL_DEBUG_ASSOC(priv, "Removing STA from driver:%d %pM\n", 635 IWL_DEBUG_ASSOC(priv, "Removing STA from driver:%d %pM\n",
636 sta_id, sta->addr); 636 sta_id, addr);
637 637
638 if (!(priv->stations[sta_id].used & IWL_STA_DRIVER_ACTIVE)) { 638 if (!(priv->stations[sta_id].used & IWL_STA_DRIVER_ACTIVE)) {
639 IWL_DEBUG_INFO(priv, "Removing %pM but non DRIVER active\n", 639 IWL_DEBUG_INFO(priv, "Removing %pM but non DRIVER active\n",
640 sta->addr); 640 addr);
641 goto out; 641 goto out;
642 } 642 }
643 643
644 if (!(priv->stations[sta_id].used & IWL_STA_UCODE_ACTIVE)) { 644 if (!(priv->stations[sta_id].used & IWL_STA_UCODE_ACTIVE)) {
645 IWL_DEBUG_INFO(priv, "Removing %pM but non UCODE active\n", 645 IWL_DEBUG_INFO(priv, "Removing %pM but non UCODE active\n",
646 sta->addr); 646 addr);
647 goto out; 647 goto out;
648 } 648 }
649 649
@@ -1450,7 +1450,7 @@ int iwl_mac_sta_remove(struct ieee80211_hw *hw,
1450 struct iwl_priv *priv = hw->priv; 1450 struct iwl_priv *priv = hw->priv;
1451 IWL_DEBUG_INFO(priv, "received request to remove station %pM\n", 1451 IWL_DEBUG_INFO(priv, "received request to remove station %pM\n",
1452 sta->addr); 1452 sta->addr);
1453 ret = iwl_remove_station(priv, sta); 1453 ret = iwl_remove_station(priv, sta->addr);
1454 if (ret) 1454 if (ret)
1455 IWL_ERR(priv, "Error removing station %pM\n", 1455 IWL_ERR(priv, "Error removing station %pM\n",
1456 sta->addr); 1456 sta->addr);