aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rt2x00
diff options
context:
space:
mode:
authorIvo van Doorn <ivdoorn@gmail.com>2010-10-11 09:37:25 -0400
committerJohn W. Linville <linville@tuxdriver.com>2010-10-11 15:04:25 -0400
commitfa69560f317d961c56e29dea788b346d2b34fb87 (patch)
treef3102311d1a38906ebaf4a7df988b91a2f38cab3 /drivers/net/wireless/rt2x00
parenta9325199edb093a5c7311a25d15da20ee984e80b (diff)
rt2x00: Simplify Queue function arguments
A lot of functions accept a struct rt2x00_dev combined with either a struct queue_entry or struct data_queue argument. This can be simplified by only passing on the queue/entry argument. In cases where rt2x00_dev and a sk_buff are send together, we can send the queue_entry instead. rt2x00usb_alloc_urb and rt2x00usb_free_urb have a bit of vague naming. Instead they allocate all the data which belongs to a rt2x00 data queue entry. Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com> Acked-by: Helmut Schaa <helmut.schaa@googlemail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rt2x00')
-rw-r--r--drivers/net/wireless/rt2x00/rt2400pci.c2
-rw-r--r--drivers/net/wireless/rt2x00/rt2500pci.c2
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00.h13
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00dev.c10
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00lib.h11
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00pci.c2
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00queue.c49
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00usb.c18
8 files changed, 50 insertions, 57 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2400pci.c b/drivers/net/wireless/rt2x00/rt2400pci.c
index 4b88909275a..095cb6982d7 100644
--- a/drivers/net/wireless/rt2x00/rt2400pci.c
+++ b/drivers/net/wireless/rt2x00/rt2400pci.c
@@ -1104,7 +1104,7 @@ static void rt2400pci_write_beacon(struct queue_entry *entry,
1104 rt2x00_set_field32(&reg, CSR14_BEACON_GEN, 0); 1104 rt2x00_set_field32(&reg, CSR14_BEACON_GEN, 0);
1105 rt2x00pci_register_write(rt2x00dev, CSR14, reg); 1105 rt2x00pci_register_write(rt2x00dev, CSR14, reg);
1106 1106
1107 rt2x00queue_map_txskb(rt2x00dev, entry->skb); 1107 rt2x00queue_map_txskb(entry);
1108 1108
1109 /* 1109 /*
1110 * Write the TX descriptor for the beacon. 1110 * Write the TX descriptor for the beacon.
diff --git a/drivers/net/wireless/rt2x00/rt2500pci.c b/drivers/net/wireless/rt2x00/rt2500pci.c
index 46ef692e404..7d85bf9bd25 100644
--- a/drivers/net/wireless/rt2x00/rt2500pci.c
+++ b/drivers/net/wireless/rt2x00/rt2500pci.c
@@ -1258,7 +1258,7 @@ static void rt2500pci_write_beacon(struct queue_entry *entry,
1258 rt2x00_set_field32(&reg, CSR14_BEACON_GEN, 0); 1258 rt2x00_set_field32(&reg, CSR14_BEACON_GEN, 0);
1259 rt2x00pci_register_write(rt2x00dev, CSR14, reg); 1259 rt2x00pci_register_write(rt2x00dev, CSR14, reg);
1260 1260
1261 rt2x00queue_map_txskb(rt2x00dev, entry->skb); 1261 rt2x00queue_map_txskb(entry);
1262 1262
1263 /* 1263 /*
1264 * Write the TX descriptor for the beacon. 1264 * Write the TX descriptor for the beacon.
diff --git a/drivers/net/wireless/rt2x00/rt2x00.h b/drivers/net/wireless/rt2x00/rt2x00.h
index 75ac6624bf9..2322c84adc1 100644
--- a/drivers/net/wireless/rt2x00/rt2x00.h
+++ b/drivers/net/wireless/rt2x00/rt2x00.h
@@ -1036,17 +1036,15 @@ static inline bool rt2x00_is_soc(struct rt2x00_dev *rt2x00dev)
1036 1036
1037/** 1037/**
1038 * rt2x00queue_map_txskb - Map a skb into DMA for TX purposes. 1038 * rt2x00queue_map_txskb - Map a skb into DMA for TX purposes.
1039 * @rt2x00dev: Pointer to &struct rt2x00_dev. 1039 * @entry: Pointer to &struct queue_entry
1040 * @skb: The skb to map.
1041 */ 1040 */
1042void rt2x00queue_map_txskb(struct rt2x00_dev *rt2x00dev, struct sk_buff *skb); 1041void rt2x00queue_map_txskb(struct queue_entry *entry);
1043 1042
1044/** 1043/**
1045 * rt2x00queue_unmap_skb - Unmap a skb from DMA. 1044 * rt2x00queue_unmap_skb - Unmap a skb from DMA.
1046 * @rt2x00dev: Pointer to &struct rt2x00_dev. 1045 * @entry: Pointer to &struct queue_entry
1047 * @skb: The skb to unmap.
1048 */ 1046 */
1049void rt2x00queue_unmap_skb(struct rt2x00_dev *rt2x00dev, struct sk_buff *skb); 1047void rt2x00queue_unmap_skb(struct queue_entry *entry);
1050 1048
1051/** 1049/**
1052 * rt2x00queue_get_queue - Convert queue index to queue pointer 1050 * rt2x00queue_get_queue - Convert queue index to queue pointer
@@ -1093,8 +1091,7 @@ void rt2x00lib_dmadone(struct queue_entry *entry);
1093void rt2x00lib_txdone(struct queue_entry *entry, 1091void rt2x00lib_txdone(struct queue_entry *entry,
1094 struct txdone_entry_desc *txdesc); 1092 struct txdone_entry_desc *txdesc);
1095void rt2x00lib_txdone_noinfo(struct queue_entry *entry, u32 status); 1093void rt2x00lib_txdone_noinfo(struct queue_entry *entry, u32 status);
1096void rt2x00lib_rxdone(struct rt2x00_dev *rt2x00dev, 1094void rt2x00lib_rxdone(struct queue_entry *entry);
1097 struct queue_entry *entry);
1098 1095
1099/* 1096/*
1100 * mac80211 handlers. 1097 * mac80211 handlers.
diff --git a/drivers/net/wireless/rt2x00/rt2x00dev.c b/drivers/net/wireless/rt2x00/rt2x00dev.c
index 6f442b02b83..9b745faef0e 100644
--- a/drivers/net/wireless/rt2x00/rt2x00dev.c
+++ b/drivers/net/wireless/rt2x00/rt2x00dev.c
@@ -273,7 +273,7 @@ void rt2x00lib_txdone(struct queue_entry *entry,
273 /* 273 /*
274 * Unmap the skb. 274 * Unmap the skb.
275 */ 275 */
276 rt2x00queue_unmap_skb(rt2x00dev, entry->skb); 276 rt2x00queue_unmap_skb(entry);
277 277
278 /* 278 /*
279 * Remove the extra tx headroom from the skb. 279 * Remove the extra tx headroom from the skb.
@@ -465,9 +465,9 @@ static int rt2x00lib_rxdone_read_signal(struct rt2x00_dev *rt2x00dev,
465 return 0; 465 return 0;
466} 466}
467 467
468void rt2x00lib_rxdone(struct rt2x00_dev *rt2x00dev, 468void rt2x00lib_rxdone(struct queue_entry *entry)
469 struct queue_entry *entry)
470{ 469{
470 struct rt2x00_dev *rt2x00dev = entry->queue->rt2x00dev;
471 struct rxdone_entry_desc rxdesc; 471 struct rxdone_entry_desc rxdesc;
472 struct sk_buff *skb; 472 struct sk_buff *skb;
473 struct ieee80211_rx_status *rx_status; 473 struct ieee80211_rx_status *rx_status;
@@ -481,14 +481,14 @@ void rt2x00lib_rxdone(struct rt2x00_dev *rt2x00dev,
481 * Allocate a new sk_buffer. If no new buffer available, drop the 481 * Allocate a new sk_buffer. If no new buffer available, drop the
482 * received frame and reuse the existing buffer. 482 * received frame and reuse the existing buffer.
483 */ 483 */
484 skb = rt2x00queue_alloc_rxskb(rt2x00dev, entry); 484 skb = rt2x00queue_alloc_rxskb(entry);
485 if (!skb) 485 if (!skb)
486 return; 486 return;
487 487
488 /* 488 /*
489 * Unmap the skb. 489 * Unmap the skb.
490 */ 490 */
491 rt2x00queue_unmap_skb(rt2x00dev, entry->skb); 491 rt2x00queue_unmap_skb(entry);
492 492
493 /* 493 /*
494 * Extract the RXD details. 494 * Extract the RXD details.
diff --git a/drivers/net/wireless/rt2x00/rt2x00lib.h b/drivers/net/wireless/rt2x00/rt2x00lib.h
index 70c85ac2e53..619da23b7b5 100644
--- a/drivers/net/wireless/rt2x00/rt2x00lib.h
+++ b/drivers/net/wireless/rt2x00/rt2x00lib.h
@@ -100,18 +100,15 @@ void rt2x00lib_config(struct rt2x00_dev *rt2x00dev,
100 100
101/** 101/**
102 * rt2x00queue_alloc_rxskb - allocate a skb for RX purposes. 102 * rt2x00queue_alloc_rxskb - allocate a skb for RX purposes.
103 * @rt2x00dev: Pointer to &struct rt2x00_dev. 103 * @entry: The entry for which the skb will be applicable.
104 * @queue: The queue for which the skb will be applicable.
105 */ 104 */
106struct sk_buff *rt2x00queue_alloc_rxskb(struct rt2x00_dev *rt2x00dev, 105struct sk_buff *rt2x00queue_alloc_rxskb(struct queue_entry *entry);
107 struct queue_entry *entry);
108 106
109/** 107/**
110 * rt2x00queue_free_skb - free a skb 108 * rt2x00queue_free_skb - free a skb
111 * @rt2x00dev: Pointer to &struct rt2x00_dev. 109 * @entry: The entry for which the skb will be applicable.
112 * @skb: The skb to free.
113 */ 110 */
114void rt2x00queue_free_skb(struct rt2x00_dev *rt2x00dev, struct sk_buff *skb); 111void rt2x00queue_free_skb(struct queue_entry *entry);
115 112
116/** 113/**
117 * rt2x00queue_align_frame - Align 802.11 frame to 4-byte boundary 114 * rt2x00queue_align_frame - Align 802.11 frame to 4-byte boundary
diff --git a/drivers/net/wireless/rt2x00/rt2x00pci.c b/drivers/net/wireless/rt2x00/rt2x00pci.c
index 63c2cc408e1..2449d785cf8 100644
--- a/drivers/net/wireless/rt2x00/rt2x00pci.c
+++ b/drivers/net/wireless/rt2x00/rt2x00pci.c
@@ -84,7 +84,7 @@ void rt2x00pci_rxdone(struct rt2x00_dev *rt2x00dev)
84 /* 84 /*
85 * Send the frame to rt2x00lib for further processing. 85 * Send the frame to rt2x00lib for further processing.
86 */ 86 */
87 rt2x00lib_rxdone(rt2x00dev, entry); 87 rt2x00lib_rxdone(entry);
88 } 88 }
89} 89}
90EXPORT_SYMBOL_GPL(rt2x00pci_rxdone); 90EXPORT_SYMBOL_GPL(rt2x00pci_rxdone);
diff --git a/drivers/net/wireless/rt2x00/rt2x00queue.c b/drivers/net/wireless/rt2x00/rt2x00queue.c
index 83630f16dc6..7e30144c5cf 100644
--- a/drivers/net/wireless/rt2x00/rt2x00queue.c
+++ b/drivers/net/wireless/rt2x00/rt2x00queue.c
@@ -33,9 +33,9 @@
33#include "rt2x00.h" 33#include "rt2x00.h"
34#include "rt2x00lib.h" 34#include "rt2x00lib.h"
35 35
36struct sk_buff *rt2x00queue_alloc_rxskb(struct rt2x00_dev *rt2x00dev, 36struct sk_buff *rt2x00queue_alloc_rxskb(struct queue_entry *entry)
37 struct queue_entry *entry)
38{ 37{
38 struct rt2x00_dev *rt2x00dev = entry->queue->rt2x00dev;
39 struct sk_buff *skb; 39 struct sk_buff *skb;
40 struct skb_frame_desc *skbdesc; 40 struct skb_frame_desc *skbdesc;
41 unsigned int frame_size; 41 unsigned int frame_size;
@@ -97,39 +97,42 @@ struct sk_buff *rt2x00queue_alloc_rxskb(struct rt2x00_dev *rt2x00dev,
97 return skb; 97 return skb;
98} 98}
99 99
100void rt2x00queue_map_txskb(struct rt2x00_dev *rt2x00dev, struct sk_buff *skb) 100void rt2x00queue_map_txskb(struct queue_entry *entry)
101{ 101{
102 struct skb_frame_desc *skbdesc = get_skb_frame_desc(skb); 102 struct device *dev = entry->queue->rt2x00dev->dev;
103 struct skb_frame_desc *skbdesc = get_skb_frame_desc(entry->skb);
103 104
104 skbdesc->skb_dma = 105 skbdesc->skb_dma =
105 dma_map_single(rt2x00dev->dev, skb->data, skb->len, DMA_TO_DEVICE); 106 dma_map_single(dev, entry->skb->data, entry->skb->len, DMA_TO_DEVICE);
106 skbdesc->flags |= SKBDESC_DMA_MAPPED_TX; 107 skbdesc->flags |= SKBDESC_DMA_MAPPED_TX;
107} 108}
108EXPORT_SYMBOL_GPL(rt2x00queue_map_txskb); 109EXPORT_SYMBOL_GPL(rt2x00queue_map_txskb);
109 110
110void rt2x00queue_unmap_skb(struct rt2x00_dev *rt2x00dev, struct sk_buff *skb) 111void rt2x00queue_unmap_skb(struct queue_entry *entry)
111{ 112{
112 struct skb_frame_desc *skbdesc = get_skb_frame_desc(skb); 113 struct device *dev = entry->queue->rt2x00dev->dev;
114 struct skb_frame_desc *skbdesc = get_skb_frame_desc(entry->skb);
113 115
114 if (skbdesc->flags & SKBDESC_DMA_MAPPED_RX) { 116 if (skbdesc->flags & SKBDESC_DMA_MAPPED_RX) {
115 dma_unmap_single(rt2x00dev->dev, skbdesc->skb_dma, skb->len, 117 dma_unmap_single(dev, skbdesc->skb_dma, entry->skb->len,
116 DMA_FROM_DEVICE); 118 DMA_FROM_DEVICE);
117 skbdesc->flags &= ~SKBDESC_DMA_MAPPED_RX; 119 skbdesc->flags &= ~SKBDESC_DMA_MAPPED_RX;
118 } else if (skbdesc->flags & SKBDESC_DMA_MAPPED_TX) { 120 } else if (skbdesc->flags & SKBDESC_DMA_MAPPED_TX) {
119 dma_unmap_single(rt2x00dev->dev, skbdesc->skb_dma, skb->len, 121 dma_unmap_single(dev, skbdesc->skb_dma, entry->skb->len,
120 DMA_TO_DEVICE); 122 DMA_TO_DEVICE);
121 skbdesc->flags &= ~SKBDESC_DMA_MAPPED_TX; 123 skbdesc->flags &= ~SKBDESC_DMA_MAPPED_TX;
122 } 124 }
123} 125}
124EXPORT_SYMBOL_GPL(rt2x00queue_unmap_skb); 126EXPORT_SYMBOL_GPL(rt2x00queue_unmap_skb);
125 127
126void rt2x00queue_free_skb(struct rt2x00_dev *rt2x00dev, struct sk_buff *skb) 128void rt2x00queue_free_skb(struct queue_entry *entry)
127{ 129{
128 if (!skb) 130 if (!entry->skb)
129 return; 131 return;
130 132
131 rt2x00queue_unmap_skb(rt2x00dev, skb); 133 rt2x00queue_unmap_skb(entry);
132 dev_kfree_skb_any(skb); 134 dev_kfree_skb_any(entry->skb);
135 entry->skb = NULL;
133} 136}
134 137
135void rt2x00queue_align_frame(struct sk_buff *skb) 138void rt2x00queue_align_frame(struct sk_buff *skb)
@@ -438,7 +441,7 @@ static int rt2x00queue_write_tx_data(struct queue_entry *entry,
438 * Map the skb to DMA. 441 * Map the skb to DMA.
439 */ 442 */
440 if (test_bit(DRIVER_REQUIRE_DMA, &rt2x00dev->flags)) 443 if (test_bit(DRIVER_REQUIRE_DMA, &rt2x00dev->flags))
441 rt2x00queue_map_txskb(rt2x00dev, entry->skb); 444 rt2x00queue_map_txskb(entry);
442 445
443 return 0; 446 return 0;
444} 447}
@@ -585,8 +588,7 @@ int rt2x00queue_update_beacon(struct rt2x00_dev *rt2x00dev,
585 /* 588 /*
586 * Clean up the beacon skb. 589 * Clean up the beacon skb.
587 */ 590 */
588 rt2x00queue_free_skb(rt2x00dev, intf->beacon->skb); 591 rt2x00queue_free_skb(intf->beacon);
589 intf->beacon->skb = NULL;
590 592
591 if (!enable_beacon) { 593 if (!enable_beacon) {
592 rt2x00dev->ops->lib->kill_tx_queue(intf->beacon->queue); 594 rt2x00dev->ops->lib->kill_tx_queue(intf->beacon->queue);
@@ -827,8 +829,7 @@ static int rt2x00queue_alloc_entries(struct data_queue *queue,
827 return 0; 829 return 0;
828} 830}
829 831
830static void rt2x00queue_free_skbs(struct rt2x00_dev *rt2x00dev, 832static void rt2x00queue_free_skbs(struct data_queue *queue)
831 struct data_queue *queue)
832{ 833{
833 unsigned int i; 834 unsigned int i;
834 835
@@ -836,19 +837,17 @@ static void rt2x00queue_free_skbs(struct rt2x00_dev *rt2x00dev,
836 return; 837 return;
837 838
838 for (i = 0; i < queue->limit; i++) { 839 for (i = 0; i < queue->limit; i++) {
839 if (queue->entries[i].skb) 840 rt2x00queue_free_skb(&queue->entries[i]);
840 rt2x00queue_free_skb(rt2x00dev, queue->entries[i].skb);
841 } 841 }
842} 842}
843 843
844static int rt2x00queue_alloc_rxskbs(struct rt2x00_dev *rt2x00dev, 844static int rt2x00queue_alloc_rxskbs(struct data_queue *queue)
845 struct data_queue *queue)
846{ 845{
847 unsigned int i; 846 unsigned int i;
848 struct sk_buff *skb; 847 struct sk_buff *skb;
849 848
850 for (i = 0; i < queue->limit; i++) { 849 for (i = 0; i < queue->limit; i++) {
851 skb = rt2x00queue_alloc_rxskb(rt2x00dev, &queue->entries[i]); 850 skb = rt2x00queue_alloc_rxskb(&queue->entries[i]);
852 if (!skb) 851 if (!skb)
853 return -ENOMEM; 852 return -ENOMEM;
854 queue->entries[i].skb = skb; 853 queue->entries[i].skb = skb;
@@ -883,7 +882,7 @@ int rt2x00queue_initialize(struct rt2x00_dev *rt2x00dev)
883 goto exit; 882 goto exit;
884 } 883 }
885 884
886 status = rt2x00queue_alloc_rxskbs(rt2x00dev, rt2x00dev->rx); 885 status = rt2x00queue_alloc_rxskbs(rt2x00dev->rx);
887 if (status) 886 if (status)
888 goto exit; 887 goto exit;
889 888
@@ -901,7 +900,7 @@ void rt2x00queue_uninitialize(struct rt2x00_dev *rt2x00dev)
901{ 900{
902 struct data_queue *queue; 901 struct data_queue *queue;
903 902
904 rt2x00queue_free_skbs(rt2x00dev, rt2x00dev->rx); 903 rt2x00queue_free_skbs(rt2x00dev->rx);
905 904
906 queue_for_each(rt2x00dev, queue) { 905 queue_for_each(rt2x00dev, queue) {
907 kfree(queue->entries); 906 kfree(queue->entries);
diff --git a/drivers/net/wireless/rt2x00/rt2x00usb.c b/drivers/net/wireless/rt2x00/rt2x00usb.c
index 4c5ae3d4562..451d637377a 100644
--- a/drivers/net/wireless/rt2x00/rt2x00usb.c
+++ b/drivers/net/wireless/rt2x00/rt2x00usb.c
@@ -398,7 +398,7 @@ static void rt2x00usb_work_rxdone(struct work_struct *work)
398 /* 398 /*
399 * Send the frame to rt2x00lib for further processing. 399 * Send the frame to rt2x00lib for further processing.
400 */ 400 */
401 rt2x00lib_rxdone(rt2x00dev, entry); 401 rt2x00lib_rxdone(entry);
402 } 402 }
403} 403}
404 404
@@ -542,9 +542,9 @@ static int rt2x00usb_find_endpoints(struct rt2x00_dev *rt2x00dev)
542 return 0; 542 return 0;
543} 543}
544 544
545static int rt2x00usb_alloc_urb(struct rt2x00_dev *rt2x00dev, 545static int rt2x00usb_alloc_entries(struct data_queue *queue)
546 struct data_queue *queue)
547{ 546{
547 struct rt2x00_dev *rt2x00dev = queue->rt2x00dev;
548 struct queue_entry_priv_usb *entry_priv; 548 struct queue_entry_priv_usb *entry_priv;
549 struct queue_entry_priv_usb_bcn *bcn_priv; 549 struct queue_entry_priv_usb_bcn *bcn_priv;
550 unsigned int i; 550 unsigned int i;
@@ -561,7 +561,7 @@ static int rt2x00usb_alloc_urb(struct rt2x00_dev *rt2x00dev,
561 * no guardian byte was required for the beacon, 561 * no guardian byte was required for the beacon,
562 * then we are done. 562 * then we are done.
563 */ 563 */
564 if (rt2x00dev->bcn != queue || 564 if (queue->qid != QID_BEACON ||
565 !test_bit(DRIVER_REQUIRE_BEACON_GUARD, &rt2x00dev->flags)) 565 !test_bit(DRIVER_REQUIRE_BEACON_GUARD, &rt2x00dev->flags))
566 return 0; 566 return 0;
567 567
@@ -575,9 +575,9 @@ static int rt2x00usb_alloc_urb(struct rt2x00_dev *rt2x00dev,
575 return 0; 575 return 0;
576} 576}
577 577
578static void rt2x00usb_free_urb(struct rt2x00_dev *rt2x00dev, 578static void rt2x00usb_free_entries(struct data_queue *queue)
579 struct data_queue *queue)
580{ 579{
580 struct rt2x00_dev *rt2x00dev = queue->rt2x00dev;
581 struct queue_entry_priv_usb *entry_priv; 581 struct queue_entry_priv_usb *entry_priv;
582 struct queue_entry_priv_usb_bcn *bcn_priv; 582 struct queue_entry_priv_usb_bcn *bcn_priv;
583 unsigned int i; 583 unsigned int i;
@@ -596,7 +596,7 @@ static void rt2x00usb_free_urb(struct rt2x00_dev *rt2x00dev,
596 * no guardian byte was required for the beacon, 596 * no guardian byte was required for the beacon,
597 * then we are done. 597 * then we are done.
598 */ 598 */
599 if (rt2x00dev->bcn != queue || 599 if (queue->qid != QID_BEACON ||
600 !test_bit(DRIVER_REQUIRE_BEACON_GUARD, &rt2x00dev->flags)) 600 !test_bit(DRIVER_REQUIRE_BEACON_GUARD, &rt2x00dev->flags))
601 return; 601 return;
602 602
@@ -623,7 +623,7 @@ int rt2x00usb_initialize(struct rt2x00_dev *rt2x00dev)
623 * Allocate DMA 623 * Allocate DMA
624 */ 624 */
625 queue_for_each(rt2x00dev, queue) { 625 queue_for_each(rt2x00dev, queue) {
626 status = rt2x00usb_alloc_urb(rt2x00dev, queue); 626 status = rt2x00usb_alloc_entries(queue);
627 if (status) 627 if (status)
628 goto exit; 628 goto exit;
629 } 629 }
@@ -642,7 +642,7 @@ void rt2x00usb_uninitialize(struct rt2x00_dev *rt2x00dev)
642 struct data_queue *queue; 642 struct data_queue *queue;
643 643
644 queue_for_each(rt2x00dev, queue) 644 queue_for_each(rt2x00dev, queue)
645 rt2x00usb_free_urb(rt2x00dev, queue); 645 rt2x00usb_free_entries(queue);
646} 646}
647EXPORT_SYMBOL_GPL(rt2x00usb_uninitialize); 647EXPORT_SYMBOL_GPL(rt2x00usb_uninitialize);
648 648