aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rt2x00/rt2x00queue.h
diff options
context:
space:
mode:
authorIvo van Doorn <ivdoorn@gmail.com>2009-04-26 10:09:32 -0400
committerJohn W. Linville <linville@tuxdriver.com>2009-05-06 15:14:50 -0400
commit35f00cfcc06bb85e0659f9847400518008d78145 (patch)
treedccebd4dd7cde975d857d1fb3f28dd1e467fa72f /drivers/net/wireless/rt2x00/rt2x00queue.h
parent9f1661718c7fcf82e25c6aed20b729ee372d9d65 (diff)
rt2x00: Implement support for 802.11n
Extend rt2x00lib capabilities to support 802.11n, it still lacks aggregation support, but that can be added in the future. 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/rt2x00queue.h')
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00queue.h39
1 files changed, 30 insertions, 9 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00queue.h b/drivers/net/wireless/rt2x00/rt2x00queue.h
index 13e0ece176a1..b5e06347c8a7 100644
--- a/drivers/net/wireless/rt2x00/rt2x00queue.h
+++ b/drivers/net/wireless/rt2x00/rt2x00queue.h
@@ -35,9 +35,12 @@
35 * for USB devices this restriction does not apply, but the value of 35 * for USB devices this restriction does not apply, but the value of
36 * 2432 makes sense since it is big enough to contain the maximum fragment 36 * 2432 makes sense since it is big enough to contain the maximum fragment
37 * size according to the ieee802.11 specs. 37 * size according to the ieee802.11 specs.
38 * The aggregation size depends on support from the driver, but should
39 * be something around 3840 bytes.
38 */ 40 */
39#define DATA_FRAME_SIZE 2432 41#define DATA_FRAME_SIZE 2432
40#define MGMT_FRAME_SIZE 256 42#define MGMT_FRAME_SIZE 256
43#define AGGREGATION_SIZE 3840
41 44
42/** 45/**
43 * DOC: Number of entries per queue 46 * DOC: Number of entries per queue
@@ -148,18 +151,20 @@ static inline struct skb_frame_desc* get_skb_frame_desc(struct sk_buff *skb)
148 * 151 *
149 * @RXDONE_SIGNAL_PLCP: Signal field contains the plcp value. 152 * @RXDONE_SIGNAL_PLCP: Signal field contains the plcp value.
150 * @RXDONE_SIGNAL_BITRATE: Signal field contains the bitrate value. 153 * @RXDONE_SIGNAL_BITRATE: Signal field contains the bitrate value.
154 * @RXDONE_SIGNAL_MCS: Signal field contains the mcs value.
151 * @RXDONE_MY_BSS: Does this frame originate from device's BSS. 155 * @RXDONE_MY_BSS: Does this frame originate from device's BSS.
152 * @RXDONE_CRYPTO_IV: Driver provided IV/EIV data. 156 * @RXDONE_CRYPTO_IV: Driver provided IV/EIV data.
153 * @RXDONE_CRYPTO_ICV: Driver provided ICV data. 157 * @RXDONE_CRYPTO_ICV: Driver provided ICV data.
154 * @RXDONE_L2PAD: 802.11 payload has been padded to 4-byte boundary. 158 * @RXDONE_L2PAD: 802.11 payload has been padded to 4-byte boundary.
155 */ 159 */
156enum rxdone_entry_desc_flags { 160enum rxdone_entry_desc_flags {
157 RXDONE_SIGNAL_PLCP = 1 << 0, 161 RXDONE_SIGNAL_PLCP = BIT(0),
158 RXDONE_SIGNAL_BITRATE = 1 << 1, 162 RXDONE_SIGNAL_BITRATE = BIT(1),
159 RXDONE_MY_BSS = 1 << 2, 163 RXDONE_SIGNAL_MCS = BIT(2),
160 RXDONE_CRYPTO_IV = 1 << 3, 164 RXDONE_MY_BSS = BIT(3),
161 RXDONE_CRYPTO_ICV = 1 << 4, 165 RXDONE_CRYPTO_IV = BIT(4),
162 RXDONE_L2PAD = 1 << 5, 166 RXDONE_CRYPTO_ICV = BIT(5),
167 RXDONE_L2PAD = BIT(6),
163}; 168};
164 169
165/** 170/**
@@ -168,7 +173,7 @@ enum rxdone_entry_desc_flags {
168 * from &rxdone_entry_desc to a signal value type. 173 * from &rxdone_entry_desc to a signal value type.
169 */ 174 */
170#define RXDONE_SIGNAL_MASK \ 175#define RXDONE_SIGNAL_MASK \
171 ( RXDONE_SIGNAL_PLCP | RXDONE_SIGNAL_BITRATE ) 176 ( RXDONE_SIGNAL_PLCP | RXDONE_SIGNAL_BITRATE | RXDONE_SIGNAL_MCS )
172 177
173/** 178/**
174 * struct rxdone_entry_desc: RX Entry descriptor 179 * struct rxdone_entry_desc: RX Entry descriptor
@@ -182,6 +187,7 @@ enum rxdone_entry_desc_flags {
182 * @size: Data size of the received frame. 187 * @size: Data size of the received frame.
183 * @flags: MAC80211 receive flags (See &enum mac80211_rx_flags). 188 * @flags: MAC80211 receive flags (See &enum mac80211_rx_flags).
184 * @dev_flags: Ralink receive flags (See &enum rxdone_entry_desc_flags). 189 * @dev_flags: Ralink receive flags (See &enum rxdone_entry_desc_flags).
190 * @rate_mode: Rate mode (See @enum rate_modulation).
185 * @cipher: Cipher type used during decryption. 191 * @cipher: Cipher type used during decryption.
186 * @cipher_status: Decryption status. 192 * @cipher_status: Decryption status.
187 * @iv: IV/EIV data used during decryption. 193 * @iv: IV/EIV data used during decryption.
@@ -195,6 +201,7 @@ struct rxdone_entry_desc {
195 int size; 201 int size;
196 int flags; 202 int flags;
197 int dev_flags; 203 int dev_flags;
204 u16 rate_mode;
198 u8 cipher; 205 u8 cipher;
199 u8 cipher_status; 206 u8 cipher_status;
200 207
@@ -248,6 +255,9 @@ struct txdone_entry_desc {
248 * @ENTRY_TXD_ENCRYPT_PAIRWISE: Use pairwise key table (instead of shared). 255 * @ENTRY_TXD_ENCRYPT_PAIRWISE: Use pairwise key table (instead of shared).
249 * @ENTRY_TXD_ENCRYPT_IV: Generate IV/EIV in hardware. 256 * @ENTRY_TXD_ENCRYPT_IV: Generate IV/EIV in hardware.
250 * @ENTRY_TXD_ENCRYPT_MMIC: Generate MIC in hardware. 257 * @ENTRY_TXD_ENCRYPT_MMIC: Generate MIC in hardware.
258 * @ENTRY_TXD_HT_AMPDU: This frame is part of an AMPDU.
259 * @ENTRY_TXD_HT_BW_40: Use 40MHz Bandwidth.
260 * @ENTRY_TXD_HT_SHORT_GI: Use short GI.
251 */ 261 */
252enum txentry_desc_flags { 262enum txentry_desc_flags {
253 ENTRY_TXD_RTS_FRAME, 263 ENTRY_TXD_RTS_FRAME,
@@ -263,6 +273,9 @@ enum txentry_desc_flags {
263 ENTRY_TXD_ENCRYPT_PAIRWISE, 273 ENTRY_TXD_ENCRYPT_PAIRWISE,
264 ENTRY_TXD_ENCRYPT_IV, 274 ENTRY_TXD_ENCRYPT_IV,
265 ENTRY_TXD_ENCRYPT_MMIC, 275 ENTRY_TXD_ENCRYPT_MMIC,
276 ENTRY_TXD_HT_AMPDU,
277 ENTRY_TXD_HT_BW_40,
278 ENTRY_TXD_HT_SHORT_GI,
266}; 279};
267 280
268/** 281/**
@@ -278,7 +291,11 @@ enum txentry_desc_flags {
278 * @length_low: PLCP length low word. 291 * @length_low: PLCP length low word.
279 * @signal: PLCP signal. 292 * @signal: PLCP signal.
280 * @service: PLCP service. 293 * @service: PLCP service.
294 * @msc: MCS.
295 * @stbc: STBC.
296 * @ba_size: BA size.
281 * @rate_mode: Rate mode (See @enum rate_modulation). 297 * @rate_mode: Rate mode (See @enum rate_modulation).
298 * @mpdu_density: MDPU density.
282 * @retry_limit: Max number of retries. 299 * @retry_limit: Max number of retries.
283 * @aifs: AIFS value. 300 * @aifs: AIFS value.
284 * @ifs: IFS value. 301 * @ifs: IFS value.
@@ -302,7 +319,11 @@ struct txentry_desc {
302 u16 signal; 319 u16 signal;
303 u16 service; 320 u16 service;
304 321
322 u16 mcs;
323 u16 stbc;
324 u16 ba_size;
305 u16 rate_mode; 325 u16 rate_mode;
326 u16 mpdu_density;
306 327
307 short retry_limit; 328 short retry_limit;
308 short aifs; 329 short aifs;