diff options
author | Felix Fietkau <nbd@openwrt.org> | 2012-03-14 11:40:27 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2012-03-15 13:45:04 -0400 |
commit | aebc0a88ddf514ef2b3cdba0b3f14883b8b0e339 (patch) | |
tree | 116324893f9376e0fdd6e3a7174563d706698ef7 | |
parent | 239c795d6ba9ada0811cdb4f87304552de29e81b (diff) |
ath9k_hw: clean up ath9k_hw_setuprxdesc
The ATH9K_HW_CAP_AUTOSLEEP check is bogus, the rx status area needs to be
cleared on all non-EDMA PCI/AHB based chipsets anyway.
Limit the memset to the rx status area to improve performance.
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | drivers/net/wireless/ath/ath9k/ar9002_mac.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/net/wireless/ath/ath9k/ar9002_mac.c b/drivers/net/wireless/ath/ath9k/ar9002_mac.c index 7b6417b5212e..aa2abaf31cba 100644 --- a/drivers/net/wireless/ath/ath9k/ar9002_mac.c +++ b/drivers/net/wireless/ath/ath9k/ar9002_mac.c | |||
@@ -347,15 +347,12 @@ void ath9k_hw_setuprxdesc(struct ath_hw *ah, struct ath_desc *ds, | |||
347 | u32 size, u32 flags) | 347 | u32 size, u32 flags) |
348 | { | 348 | { |
349 | struct ar5416_desc *ads = AR5416DESC(ds); | 349 | struct ar5416_desc *ads = AR5416DESC(ds); |
350 | struct ath9k_hw_capabilities *pCap = &ah->caps; | ||
351 | 350 | ||
352 | ads->ds_ctl1 = size & AR_BufLen; | 351 | ads->ds_ctl1 = size & AR_BufLen; |
353 | if (flags & ATH9K_RXDESC_INTREQ) | 352 | if (flags & ATH9K_RXDESC_INTREQ) |
354 | ads->ds_ctl1 |= AR_RxIntrReq; | 353 | ads->ds_ctl1 |= AR_RxIntrReq; |
355 | 354 | ||
356 | ads->ds_rxstatus8 &= ~AR_RxDone; | 355 | memset(&ads->u.rx, 0, sizeof(ads->u.rx)); |
357 | if (!(pCap->hw_caps & ATH9K_HW_CAP_AUTOSLEEP)) | ||
358 | memset(&(ads->u), 0, sizeof(ads->u)); | ||
359 | } | 356 | } |
360 | EXPORT_SYMBOL(ath9k_hw_setuprxdesc); | 357 | EXPORT_SYMBOL(ath9k_hw_setuprxdesc); |
361 | 358 | ||