aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rt2x00/rt2x00dev.c
diff options
context:
space:
mode:
authorIvo van Doorn <ivdoorn@gmail.com>2008-06-16 13:56:54 -0400
committerJohn W. Linville <linville@tuxdriver.com>2008-06-26 16:49:16 -0400
commitd74f5ba473b915e5d4ea1ed391984bb62d9de8b1 (patch)
tree93e1a847c61b053096657b132034c7df86a13bfa /drivers/net/wireless/rt2x00/rt2x00dev.c
parentc4da004857056e6ee034c4110ccdcba659077b7e (diff)
rt2x00: Cleanup symbol exports
With a bit of code moving to rt2x00lib within the TX and RX paths we can now remove a lot of EXPORT_SYMBOL_GPL() statements. This cleans up the interface between rt2x00lib and the drivers and has the additional benefit that rt2x00pci and rt2x00usb are trimmed down in size as well since they have less to do. Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2x00dev.c')
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00dev.c29
1 files changed, 29 insertions, 0 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00dev.c b/drivers/net/wireless/rt2x00/rt2x00dev.c
index 99b14ba99d9..2a63a7b911b 100644
--- a/drivers/net/wireless/rt2x00/rt2x00dev.c
+++ b/drivers/net/wireless/rt2x00/rt2x00dev.c
@@ -504,6 +504,12 @@ void rt2x00lib_txdone(struct queue_entry *entry,
504{ 504{
505 struct rt2x00_dev *rt2x00dev = entry->queue->rt2x00dev; 505 struct rt2x00_dev *rt2x00dev = entry->queue->rt2x00dev;
506 struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(entry->skb); 506 struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(entry->skb);
507 enum data_queue_qid qid = skb_get_queue_mapping(entry->skb);
508
509 /*
510 * Unmap the skb.
511 */
512 rt2x00queue_unmap_skb(rt2x00dev, entry->skb);
507 513
508 /* 514 /*
509 * Send frame to debugfs immediately, after this call is completed 515 * Send frame to debugfs immediately, after this call is completed
@@ -552,7 +558,25 @@ void rt2x00lib_txdone(struct queue_entry *entry,
552 ieee80211_tx_status_irqsafe(rt2x00dev->hw, entry->skb); 558 ieee80211_tx_status_irqsafe(rt2x00dev->hw, entry->skb);
553 else 559 else
554 dev_kfree_skb_irq(entry->skb); 560 dev_kfree_skb_irq(entry->skb);
561
562 /*
563 * Make this entry available for reuse.
564 */
555 entry->skb = NULL; 565 entry->skb = NULL;
566 entry->flags = 0;
567
568 rt2x00dev->ops->lib->init_txentry(rt2x00dev, entry);
569
570 __clear_bit(ENTRY_OWNER_DEVICE_DATA, &entry->flags);
571 rt2x00queue_index_inc(entry->queue, Q_INDEX_DONE);
572
573 /*
574 * If the data queue was below the threshold before the txdone
575 * handler we must make sure the packet queue in the mac80211 stack
576 * is reenabled when the txdone handler has finished.
577 */
578 if (!rt2x00queue_threshold(entry->queue))
579 ieee80211_wake_queue(rt2x00dev->hw, qid);
556} 580}
557EXPORT_SYMBOL_GPL(rt2x00lib_txdone); 581EXPORT_SYMBOL_GPL(rt2x00lib_txdone);
558 582
@@ -657,6 +681,11 @@ void rt2x00lib_rxdone(struct rt2x00_dev *rt2x00dev,
657 * Replace the skb with the freshly allocated one. 681 * Replace the skb with the freshly allocated one.
658 */ 682 */
659 entry->skb = skb; 683 entry->skb = skb;
684 entry->flags = 0;
685
686 rt2x00dev->ops->lib->init_rxentry(rt2x00dev, entry);
687
688 rt2x00queue_index_inc(entry->queue, Q_INDEX);
660} 689}
661EXPORT_SYMBOL_GPL(rt2x00lib_rxdone); 690EXPORT_SYMBOL_GPL(rt2x00lib_rxdone);
662 691