ath9k: write buffer related optimisation in ar5008_hw_set_channel_regs
authorOleksij Rempel <linux@rempel-privat.de>
Sun, 22 Mar 2015 18:29:55 +0000 (19:29 +0100)
committerKalle Valo <kvalo@codeaurora.org>
Mon, 30 Mar 2015 08:31:33 +0000 (11:31 +0300)
Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/ath/ath9k/ar5008_phy.c

index f273427fdd29ff93a3406d582928499ae22398c7..6c23d279525f5dfa8671342b3c30b25163b6e0ba 100644 (file)
@@ -681,12 +681,13 @@ static void ar5008_hw_set_channel_regs(struct ath_hw *ah,
                        phymode |= AR_PHY_FC_DYN2040_PRI_CH;
 
        }
+       ENABLE_REGWRITE_BUFFER(ah);
        REG_WRITE(ah, AR_PHY_TURBO, phymode);
 
+       /* This function do only REG_WRITE, so
+        * we can include it to REGWRITE_BUFFER. */
        ath9k_hw_set11nmac2040(ah, chan);
 
-       ENABLE_REGWRITE_BUFFER(ah);
-
        REG_WRITE(ah, AR_GTXTO, 25 << AR_GTXTO_TIMEOUT_LIMIT_S);
        REG_WRITE(ah, AR_CST, 0xF << AR_CST_TIMEOUT_LIMIT_S);