aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath9k/htc_drv_txrx.c
diff options
context:
space:
mode:
authorSujith Manoharan <Sujith.Manoharan@atheros.com>2011-04-13 01:55:00 -0400
committerJohn W. Linville <linville@tuxdriver.com>2011-04-13 15:23:16 -0400
commit658ef04fd42a587b17a379ad9208023473442ddd (patch)
tree6924eb7847c62cce0ef4125ecb76aa448407535d /drivers/net/wireless/ath/ath9k/htc_drv_txrx.c
parentee3fa1bdadd998652083a7814af745f765a06a25 (diff)
ath9k_htc: Move TX specific stuff to a separate structure
Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/htc_drv_txrx.c')
-rw-r--r--drivers/net/wireless/ath/ath9k/htc_drv_txrx.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/drivers/net/wireless/ath/ath9k/htc_drv_txrx.c b/drivers/net/wireless/ath/ath9k/htc_drv_txrx.c
index ab55dff4721f..6f7987d7b6b0 100644
--- a/drivers/net/wireless/ath/ath9k/htc_drv_txrx.c
+++ b/drivers/net/wireless/ath/ath9k/htc_drv_txrx.c
@@ -239,10 +239,10 @@ static bool ath9k_htc_check_tx_aggr(struct ath9k_htc_priv *priv,
239{ 239{
240 bool ret = false; 240 bool ret = false;
241 241
242 spin_lock_bh(&priv->tx_lock); 242 spin_lock_bh(&priv->tx.tx_lock);
243 if ((tid < ATH9K_HTC_MAX_TID) && (ista->tid_state[tid] == AGGR_STOP)) 243 if ((tid < ATH9K_HTC_MAX_TID) && (ista->tid_state[tid] == AGGR_STOP))
244 ret = true; 244 ret = true;
245 spin_unlock_bh(&priv->tx_lock); 245 spin_unlock_bh(&priv->tx.tx_lock);
246 246
247 return ret; 247 return ret;
248} 248}
@@ -257,7 +257,7 @@ void ath9k_tx_tasklet(unsigned long data)
257 struct sk_buff *skb = NULL; 257 struct sk_buff *skb = NULL;
258 __le16 fc; 258 __le16 fc;
259 259
260 while ((skb = skb_dequeue(&priv->tx_queue)) != NULL) { 260 while ((skb = skb_dequeue(&priv->tx.tx_queue)) != NULL) {
261 261
262 hdr = (struct ieee80211_hdr *) skb->data; 262 hdr = (struct ieee80211_hdr *) skb->data;
263 fc = hdr->frame_control; 263 fc = hdr->frame_control;
@@ -292,9 +292,9 @@ void ath9k_tx_tasklet(unsigned long data)
292 292
293 if (ath9k_htc_check_tx_aggr(priv, ista, tid)) { 293 if (ath9k_htc_check_tx_aggr(priv, ista, tid)) {
294 ieee80211_start_tx_ba_session(sta, tid, 0); 294 ieee80211_start_tx_ba_session(sta, tid, 0);
295 spin_lock_bh(&priv->tx_lock); 295 spin_lock_bh(&priv->tx.tx_lock);
296 ista->tid_state[tid] = AGGR_PROGRESS; 296 ista->tid_state[tid] = AGGR_PROGRESS;
297 spin_unlock_bh(&priv->tx_lock); 297 spin_unlock_bh(&priv->tx.tx_lock);
298 } 298 }
299 } 299 }
300 } 300 }
@@ -307,16 +307,16 @@ void ath9k_tx_tasklet(unsigned long data)
307 } 307 }
308 308
309 /* Wake TX queues if needed */ 309 /* Wake TX queues if needed */
310 spin_lock_bh(&priv->tx_lock); 310 spin_lock_bh(&priv->tx.tx_lock);
311 if (priv->tx_queues_stop) { 311 if (priv->tx.tx_queues_stop) {
312 priv->tx_queues_stop = false; 312 priv->tx.tx_queues_stop = false;
313 spin_unlock_bh(&priv->tx_lock); 313 spin_unlock_bh(&priv->tx.tx_lock);
314 ath_dbg(ath9k_hw_common(priv->ah), ATH_DBG_XMIT, 314 ath_dbg(ath9k_hw_common(priv->ah), ATH_DBG_XMIT,
315 "Waking up TX queues\n"); 315 "Waking up TX queues\n");
316 ieee80211_wake_queues(priv->hw); 316 ieee80211_wake_queues(priv->hw);
317 return; 317 return;
318 } 318 }
319 spin_unlock_bh(&priv->tx_lock); 319 spin_unlock_bh(&priv->tx.tx_lock);
320} 320}
321 321
322void ath9k_htc_txep(void *drv_priv, struct sk_buff *skb, 322void ath9k_htc_txep(void *drv_priv, struct sk_buff *skb,
@@ -348,13 +348,13 @@ void ath9k_htc_txep(void *drv_priv, struct sk_buff *skb,
348 if (txok) 348 if (txok)
349 tx_info->flags |= IEEE80211_TX_STAT_ACK; 349 tx_info->flags |= IEEE80211_TX_STAT_ACK;
350 350
351 skb_queue_tail(&priv->tx_queue, skb); 351 skb_queue_tail(&priv->tx.tx_queue, skb);
352 tasklet_schedule(&priv->tx_tasklet); 352 tasklet_schedule(&priv->tx_tasklet);
353} 353}
354 354
355int ath9k_tx_init(struct ath9k_htc_priv *priv) 355int ath9k_tx_init(struct ath9k_htc_priv *priv)
356{ 356{
357 skb_queue_head_init(&priv->tx_queue); 357 skb_queue_head_init(&priv->tx.tx_queue);
358 return 0; 358 return 0;
359} 359}
360 360