diff options
author | Felix Fietkau <nbd@openwrt.org> | 2012-04-19 15:18:22 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2012-04-23 15:35:30 -0400 |
commit | e88e486115a21c27389b666191b318988fbca07f (patch) | |
tree | 33478ad317d3a9c786d3d2f02bbbe2d0d13eced6 | |
parent | 0466e2547d05a9ae8d49afc67a3851d034a528f8 (diff) |
ath9k_hw: use standard SIFS time as reference for half/quarter channels
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/hw.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c index 72c5bcd4886d..a43934fb8138 100644 --- a/drivers/net/wireless/ath/ath9k/hw.c +++ b/drivers/net/wireless/ath/ath9k/hw.c | |||
@@ -1041,6 +1041,11 @@ void ath9k_hw_init_global_settings(struct ath_hw *ah) | |||
1041 | rx_lat = 37; | 1041 | rx_lat = 37; |
1042 | tx_lat = 54; | 1042 | tx_lat = 54; |
1043 | 1043 | ||
1044 | if (IS_CHAN_5GHZ(chan)) | ||
1045 | sifstime = 16; | ||
1046 | else | ||
1047 | sifstime = 10; | ||
1048 | |||
1044 | if (IS_CHAN_HALF_RATE(chan)) { | 1049 | if (IS_CHAN_HALF_RATE(chan)) { |
1045 | eifs = 175; | 1050 | eifs = 175; |
1046 | rx_lat *= 2; | 1051 | rx_lat *= 2; |
@@ -1048,8 +1053,8 @@ void ath9k_hw_init_global_settings(struct ath_hw *ah) | |||
1048 | if (IS_CHAN_A_FAST_CLOCK(ah, chan)) | 1053 | if (IS_CHAN_A_FAST_CLOCK(ah, chan)) |
1049 | tx_lat += 11; | 1054 | tx_lat += 11; |
1050 | 1055 | ||
1056 | sifstime *= 2; | ||
1051 | slottime = 13; | 1057 | slottime = 13; |
1052 | sifstime = 32; | ||
1053 | } else if (IS_CHAN_QUARTER_RATE(chan)) { | 1058 | } else if (IS_CHAN_QUARTER_RATE(chan)) { |
1054 | eifs = 340; | 1059 | eifs = 340; |
1055 | rx_lat = (rx_lat * 4) - 1; | 1060 | rx_lat = (rx_lat * 4) - 1; |
@@ -1057,8 +1062,8 @@ void ath9k_hw_init_global_settings(struct ath_hw *ah) | |||
1057 | if (IS_CHAN_A_FAST_CLOCK(ah, chan)) | 1062 | if (IS_CHAN_A_FAST_CLOCK(ah, chan)) |
1058 | tx_lat += 22; | 1063 | tx_lat += 22; |
1059 | 1064 | ||
1065 | sifstime *= 4; | ||
1060 | slottime = 21; | 1066 | slottime = 21; |
1061 | sifstime = 64; | ||
1062 | } else { | 1067 | } else { |
1063 | if (AR_SREV_9287(ah) && AR_SREV_9287_13_OR_LATER(ah)) { | 1068 | if (AR_SREV_9287(ah) && AR_SREV_9287_13_OR_LATER(ah)) { |
1064 | eifs = AR_D_GBL_IFS_EIFS_ASYNC_FIFO; | 1069 | eifs = AR_D_GBL_IFS_EIFS_ASYNC_FIFO; |
@@ -1072,10 +1077,6 @@ void ath9k_hw_init_global_settings(struct ath_hw *ah) | |||
1072 | tx_lat = MS(reg, AR_USEC_TX_LAT); | 1077 | tx_lat = MS(reg, AR_USEC_TX_LAT); |
1073 | 1078 | ||
1074 | slottime = ah->slottime; | 1079 | slottime = ah->slottime; |
1075 | if (IS_CHAN_5GHZ(chan)) | ||
1076 | sifstime = 16; | ||
1077 | else | ||
1078 | sifstime = 10; | ||
1079 | } | 1080 | } |
1080 | 1081 | ||
1081 | /* As defined by IEEE 802.11-2007 17.3.8.6 */ | 1082 | /* As defined by IEEE 802.11-2007 17.3.8.6 */ |