aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rt2x00/rt2x00queue.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2x00queue.h')
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00queue.h40
1 files changed, 26 insertions, 14 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00queue.h b/drivers/net/wireless/rt2x00/rt2x00queue.h
index 7027c9f47d3..29fe2652555 100644
--- a/drivers/net/wireless/rt2x00/rt2x00queue.h
+++ b/drivers/net/wireless/rt2x00/rt2x00queue.h
@@ -54,6 +54,17 @@
54 54
55/** 55/**
56 * enum data_queue_qid: Queue identification 56 * enum data_queue_qid: Queue identification
57 *
58 * @QID_AC_BE: AC BE queue
59 * @QID_AC_BK: AC BK queue
60 * @QID_AC_VI: AC VI queue
61 * @QID_AC_VO: AC VO queue
62 * @QID_HCCA: HCCA queue
63 * @QID_MGMT: MGMT queue (prio queue)
64 * @QID_RX: RX queue
65 * @QID_OTHER: None of the above (don't use, only present for completeness)
66 * @QID_BEACON: Beacon queue (value unspecified, don't send it to device)
67 * @QID_ATIM: Atim queue (value unspeficied, don't send it to device)
57 */ 68 */
58enum data_queue_qid { 69enum data_queue_qid {
59 QID_AC_BE = 0, 70 QID_AC_BE = 0,
@@ -64,22 +75,25 @@ enum data_queue_qid {
64 QID_MGMT = 13, 75 QID_MGMT = 13,
65 QID_RX = 14, 76 QID_RX = 14,
66 QID_OTHER = 15, 77 QID_OTHER = 15,
78 QID_BEACON,
79 QID_ATIM,
67}; 80};
68 81
69/** 82/**
70 * enum rt2x00_bcn_queue: Beacon queue index 83 * mac80211_queue_to_qid - Convert mac80211 queue to rt2x00 qid
71 * 84 * @queue: mac80211 queue.
72 * Start counting with a high offset, this because this enumeration
73 * supplements &enum ieee80211_tx_queue and we should prevent value
74 * conflicts.
75 *
76 * @RT2X00_BCN_QUEUE_BEACON: Beacon queue
77 * @RT2X00_BCN_QUEUE_ATIM: Atim queue (sends frame after beacon)
78 */ 85 */
79enum rt2x00_bcn_queue { 86static inline enum data_queue_qid mac80211_queue_to_qid(unsigned int queue)
80 RT2X00_BCN_QUEUE_BEACON = 100, 87{
81 RT2X00_BCN_QUEUE_ATIM = 101, 88 /* Regular TX queues are mapped directly */
82}; 89 if (queue < NUM_TX_DATA_QUEUES)
90 return queue;
91 else if (queue == IEEE80211_TX_QUEUE_BEACON)
92 return QID_BEACON;
93 else if (queue == IEEE80211_TX_QUEUE_AFTER_BEACON)
94 return QID_ATIM;
95 return QID_OTHER;
96}
83 97
84/** 98/**
85 * enum skb_frame_desc_flags: Flags for &struct skb_frame_desc 99 * enum skb_frame_desc_flags: Flags for &struct skb_frame_desc
@@ -105,7 +119,6 @@ enum skb_frame_desc_flags {
105 * of the scope of the skb->data pointer. 119 * of the scope of the skb->data pointer.
106 * @data_len: Length of the frame data. 120 * @data_len: Length of the frame data.
107 * @desc_len: Length of the frame descriptor. 121 * @desc_len: Length of the frame descriptor.
108
109 * @entry: The entry to which this sk buffer belongs. 122 * @entry: The entry to which this sk buffer belongs.
110 */ 123 */
111struct skb_frame_desc { 124struct skb_frame_desc {
@@ -240,7 +253,6 @@ struct txentry_desc {
240 * encryption or decryption. The entry should only be touched after 253 * encryption or decryption. The entry should only be touched after
241 * the device has signaled it is done with it. 254 * the device has signaled it is done with it.
242 */ 255 */
243
244enum queue_entry_flags { 256enum queue_entry_flags {
245 ENTRY_BCN_ASSIGNED, 257 ENTRY_BCN_ASSIGNED,
246 ENTRY_OWNER_DEVICE_DATA, 258 ENTRY_OWNER_DEVICE_DATA,