diff options
author | Tomas Winkler <tomas.winkler@intel.com> | 2008-05-29 04:35:08 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2008-06-03 15:00:24 -0400 |
commit | a332f8d618a7bdb0096c7b21555120a1822cedec (patch) | |
tree | 4535d0e93f742c324d77314f961090b3cf71a24d /drivers/net/wireless/iwlwifi/iwl-dev.h | |
parent | 001caff0da8784989ef208af0f39d55ea07dfef5 (diff) |
iwlwifi: move tx response common handlers to iwlcore
This pach moves common tx response handlers to the header files
and iwl-tx.c.
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-dev.h')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-dev.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-dev.h b/drivers/net/wireless/iwlwifi/iwl-dev.h index 291c1ec9b0de..934331304703 100644 --- a/drivers/net/wireless/iwlwifi/iwl-dev.h +++ b/drivers/net/wireless/iwlwifi/iwl-dev.h | |||
@@ -1242,6 +1242,36 @@ static inline void iwl_txq_ctx_deactivate(struct iwl_priv *priv, int txq_id) | |||
1242 | clear_bit(txq_id, &priv->txq_ctx_active_msk); | 1242 | clear_bit(txq_id, &priv->txq_ctx_active_msk); |
1243 | } | 1243 | } |
1244 | 1244 | ||
1245 | #ifdef CONFIG_IWLWIF_DEBUG | ||
1246 | const char *iwl_get_tx_fail_reason(u32 status); | ||
1247 | #else | ||
1248 | static inline const char *iwl_get_tx_fail_reason(u32 status) { return ""; } | ||
1249 | #endif | ||
1250 | |||
1251 | |||
1252 | #ifdef CONFIG_IWL4965_HT | ||
1253 | static inline int iwl_get_ra_sta_id(struct iwl_priv *priv, | ||
1254 | struct ieee80211_hdr *hdr) | ||
1255 | { | ||
1256 | if (priv->iw_mode == IEEE80211_IF_TYPE_STA) { | ||
1257 | return IWL_AP_ID; | ||
1258 | } else { | ||
1259 | u8 *da = ieee80211_get_DA(hdr); | ||
1260 | return iwl_find_station(priv, da); | ||
1261 | } | ||
1262 | } | ||
1263 | |||
1264 | static inline struct ieee80211_hdr *iwl_tx_queue_get_hdr(struct iwl_priv *priv, | ||
1265 | int txq_id, int idx) | ||
1266 | { | ||
1267 | if (priv->txq[txq_id].txb[idx].skb[0]) | ||
1268 | return (struct ieee80211_hdr *)priv->txq[txq_id]. | ||
1269 | txb[idx].skb[0]->data; | ||
1270 | return NULL; | ||
1271 | } | ||
1272 | #endif | ||
1273 | |||
1274 | |||
1245 | static inline int iwl_is_associated(struct iwl_priv *priv) | 1275 | static inline int iwl_is_associated(struct iwl_priv *priv) |
1246 | { | 1276 | { |
1247 | return (priv->active_rxon.filter_flags & RXON_FILTER_ASSOC_MSK) ? 1 : 0; | 1277 | return (priv->active_rxon.filter_flags & RXON_FILTER_ASSOC_MSK) ? 1 : 0; |