diff options
author | Johannes Berg | 2010-04-30 20:30:45 +0200 |
---|---|---|
committer | Reinette Chatre | 2010-05-11 00:09:05 +0200 |
commit | 2a87c26bbe9587baeb9e56d3ce0b4971bd777643 (patch) | |
tree | 1c04fc0eebe00cf3ffe6219f3b6d195f3cfae05a /drivers/net/wireless/iwlwifi/iwl-agn-tx.c | |
parent | iwlwifi: add iwl_sta_id() (diff) | |
download | kernel-qcow2-linux-2a87c26bbe9587baeb9e56d3ce0b4971bd777643.tar.gz kernel-qcow2-linux-2a87c26bbe9587baeb9e56d3ce0b4971bd777643.tar.xz kernel-qcow2-linux-2a87c26bbe9587baeb9e56d3ce0b4971bd777643.zip |
iwlwifi: use iwl_find_station less
Since we now store the station ID in each station
struct, many places need not look at the station
table any more since they can just pull the station
ID out of the struct. Remove iwl_get_sta_id() and
use iwl_sta_id() instead as appropriate.
This reduces the amount of code needed to find the
right station significantly, and works since
mac80211 passes the station only after it has been
fully initialised, ie. even if TX races with
station addition it will only be passed to TX once
the addition is complete.
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-agn-tx.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn-tx.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-tx.c b/drivers/net/wireless/iwlwifi/iwl-agn-tx.c index 6a306e849584..89c85d1043ba 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-tx.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn-tx.c @@ -566,11 +566,11 @@ int iwlagn_tx_skb(struct iwl_priv *priv, struct sk_buff *skb) hdr_len = ieee80211_hdrlen(fc); - /* Find (or create) index into station table for destination station */ - if (info->flags & IEEE80211_TX_CTL_INJECTED) + /* Find index into station table for destination station */ + if (!info->control.sta) sta_id = priv->hw_params.bcast_sta_id; else - sta_id = iwl_get_sta_id(priv, hdr); + sta_id = iwl_sta_id(info->control.sta); if (sta_id == IWL_INVALID_STATION) { IWL_DEBUG_DROP(priv, "Dropping - INVALID STATION: %pM\n", hdr->addr1); |