diff options
author | Christian Lamparter <chunkeey@web.de> | 2009-04-18 19:28:12 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-04-22 16:57:18 -0400 |
commit | cca84799dfe9f5201ae9c69eb8ed15fd26b72b37 (patch) | |
tree | 804e93427cf30be39eb650f22b90c367bcec9ab7 /drivers/net/wireless/ath/ar9170/hw.h | |
parent | e7ec86f54e519e8e86f1cf328db13263f3ef8bd4 (diff) |
ar9170: rework rxstream code
With this patch ar9170 is capable of receiving aggregated 802.11n frames
and sniffing on most networks without having a "debug message overhead".
(Includes phy initialization requested by
Johannes Berg <johannes@sipsolutions.net> -- JWL)
Signed-off-by: Christian Lamparter <chunkeey@web.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ar9170/hw.h')
-rw-r--r-- | drivers/net/wireless/ath/ar9170/hw.h | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/drivers/net/wireless/ath/ar9170/hw.h b/drivers/net/wireless/ath/ar9170/hw.h index 53e250a4278..95bf812d6fc 100644 --- a/drivers/net/wireless/ath/ar9170/hw.h +++ b/drivers/net/wireless/ath/ar9170/hw.h | |||
@@ -312,7 +312,7 @@ struct ar9170_rx_head { | |||
312 | u8 plcp[12]; | 312 | u8 plcp[12]; |
313 | } __packed; | 313 | } __packed; |
314 | 314 | ||
315 | struct ar9170_rx_tail { | 315 | struct ar9170_rx_phystatus { |
316 | union { | 316 | union { |
317 | struct { | 317 | struct { |
318 | u8 rssi_ant0, rssi_ant1, rssi_ant2, | 318 | u8 rssi_ant0, rssi_ant1, rssi_ant2, |
@@ -324,6 +324,9 @@ struct ar9170_rx_tail { | |||
324 | 324 | ||
325 | u8 evm_stream0[6], evm_stream1[6]; | 325 | u8 evm_stream0[6], evm_stream1[6]; |
326 | u8 phy_err; | 326 | u8 phy_err; |
327 | } __packed; | ||
328 | |||
329 | struct ar9170_rx_macstatus { | ||
327 | u8 SAidx, DAidx; | 330 | u8 SAidx, DAidx; |
328 | u8 error; | 331 | u8 error; |
329 | u8 status; | 332 | u8 status; |
@@ -339,7 +342,7 @@ struct ar9170_rx_tail { | |||
339 | 342 | ||
340 | #define AR9170_RX_ENC_SOFTWARE 0x8 | 343 | #define AR9170_RX_ENC_SOFTWARE 0x8 |
341 | 344 | ||
342 | static inline u8 ar9170_get_decrypt_type(struct ar9170_rx_tail *t) | 345 | static inline u8 ar9170_get_decrypt_type(struct ar9170_rx_macstatus *t) |
343 | { | 346 | { |
344 | return (t->SAidx & 0xc0) >> 4 | | 347 | return (t->SAidx & 0xc0) >> 4 | |
345 | (t->DAidx & 0xc0) >> 6; | 348 | (t->DAidx & 0xc0) >> 6; |
@@ -357,10 +360,9 @@ static inline u8 ar9170_get_decrypt_type(struct ar9170_rx_tail *t) | |||
357 | 360 | ||
358 | #define AR9170_RX_STATUS_MPDU_MASK 0x30 | 361 | #define AR9170_RX_STATUS_MPDU_MASK 0x30 |
359 | #define AR9170_RX_STATUS_MPDU_SINGLE 0x00 | 362 | #define AR9170_RX_STATUS_MPDU_SINGLE 0x00 |
360 | #define AR9170_RX_STATUS_MPDU_FIRST 0x10 | 363 | #define AR9170_RX_STATUS_MPDU_FIRST 0x20 |
361 | #define AR9170_RX_STATUS_MPDU_MIDDLE 0x20 | 364 | #define AR9170_RX_STATUS_MPDU_MIDDLE 0x30 |
362 | #define AR9170_RX_STATUS_MPDU_LAST 0x30 | 365 | #define AR9170_RX_STATUS_MPDU_LAST 0x10 |
363 | |||
364 | 366 | ||
365 | #define AR9170_RX_ERROR_RXTO 0x01 | 367 | #define AR9170_RX_ERROR_RXTO 0x01 |
366 | #define AR9170_RX_ERROR_OVERRUN 0x02 | 368 | #define AR9170_RX_ERROR_OVERRUN 0x02 |
@@ -369,6 +371,7 @@ static inline u8 ar9170_get_decrypt_type(struct ar9170_rx_tail *t) | |||
369 | #define AR9170_RX_ERROR_WRONG_RA 0x10 | 371 | #define AR9170_RX_ERROR_WRONG_RA 0x10 |
370 | #define AR9170_RX_ERROR_PLCP 0x20 | 372 | #define AR9170_RX_ERROR_PLCP 0x20 |
371 | #define AR9170_RX_ERROR_MMIC 0x40 | 373 | #define AR9170_RX_ERROR_MMIC 0x40 |
374 | #define AR9170_RX_ERROR_FATAL 0x80 | ||
372 | 375 | ||
373 | struct ar9170_cmd_tx_status { | 376 | struct ar9170_cmd_tx_status { |
374 | __le16 unkn; | 377 | __le16 unkn; |