]> git.karo-electronics.de Git - linux-beck.git/commitdiff
ath9k_hw: do not apply the 2.4 ghz ack timeout workaround to cts
authorFelix Fietkau <nbd@openwrt.org>
Sat, 27 Aug 2011 23:52:10 +0000 (01:52 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 13 Sep 2011 19:42:29 +0000 (15:42 -0400)
It is only used to workaround interoperability issues related to longer
delays in receiving the block ack, so it is not necessary to apply it
to the CTS exchange.
Should improve throughput slightly, especially when there are lots
of retransmissions.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/hw.c

index 3a16ba256ef9456785692eb3607441c36222d199..468ac4b17dfb51f92bd6b50070614ae4ebf6bfbe 100644 (file)
@@ -960,7 +960,7 @@ void ath9k_hw_init_global_settings(struct ath_hw *ah)
        struct ath_common *common = ath9k_hw_common(ah);
        struct ieee80211_conf *conf = &common->hw->conf;
        const struct ath9k_channel *chan = ah->curchan;
-       int acktimeout;
+       int acktimeout, ctstimeout;
        int slottime;
        int sifstime;
        int rx_lat = 0, tx_lat = 0, eifs = 0;
@@ -1017,6 +1017,7 @@ void ath9k_hw_init_global_settings(struct ath_hw *ah)
 
        /* As defined by IEEE 802.11-2007 17.3.8.6 */
        acktimeout = slottime + sifstime + 3 * ah->coverage_class;
+       ctstimeout = acktimeout;
 
        /*
         * Workaround for early ACK timeouts, add an offset to match the
@@ -1031,7 +1032,7 @@ void ath9k_hw_init_global_settings(struct ath_hw *ah)
        ath9k_hw_set_sifs_time(ah, sifstime);
        ath9k_hw_setslottime(ah, slottime);
        ath9k_hw_set_ack_timeout(ah, acktimeout);
-       ath9k_hw_set_cts_timeout(ah, acktimeout);
+       ath9k_hw_set_cts_timeout(ah, ctstimeout);
        if (ah->globaltxtimeout != (u32) -1)
                ath9k_hw_set_global_txtimeout(ah, ah->globaltxtimeout);