aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/wireless/iwlwifi/iwl-core.c
diff options
context:
space:
mode:
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>2008-06-30 17:23:03 +0800
committerJohn W. Linville <linville@tuxdriver.com>2008-06-30 17:37:38 -0400
commit24e5c40130c29bed0fbfbcc9c23613ae6ffc4c0a (patch)
tree0aa928342fc8fe0eb10e8ef8a40f0dd8e74ab6cf /drivers/net/wireless/iwlwifi/iwl-core.c
parentf236a2657794b6f10b582bf6ccfbca7bf0d5ec82 (diff)
iwlwifi: better station table maintenance
This patch makes the station table maintenance safer. Two flags are maintained: 1) if station is present in driver 2) if station is present in uCode This will allow us in the future to deal with more stations than the firmware allows. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-core.c')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-core.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-core.c b/drivers/net/wireless/iwlwifi/iwl-core.c
index eb74a40a62e..1c0670bc284 100644
--- a/drivers/net/wireless/iwlwifi/iwl-core.c
+++ b/drivers/net/wireless/iwlwifi/iwl-core.c
@@ -284,6 +284,10 @@ void iwlcore_clear_stations_table(struct iwl_priv *priv)
spin_lock_irqsave(&priv->sta_lock, flags);
priv->num_stations = 0;
+ if (iwl_is_alive(priv) &&
+ iwl_send_cmd_pdu_async(priv, REPLY_REMOVE_ALL_STA, 0, NULL, NULL))
+ IWL_ERROR("Couldn't clear the station table\n");
+
memset(priv->stations, 0, sizeof(priv->stations));
spin_unlock_irqrestore(&priv->sta_lock, flags);