]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ath9k_hw: fix calibration issues on chainmask that don't include chain 0
authorFelix Fietkau <nbd@openwrt.org>
Sun, 20 Jan 2013 20:55:20 +0000 (21:55 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 3 Mar 2013 22:06:43 +0000 (06:06 +0800)
commit 4a8f199508d79ff8a7d1e22f47b912baaf225336 upstream.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: CAI Qian <caiqian@redhat.com>
Reviewed-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/wireless/ath/ath9k/ar9003_calib.c
drivers/net/wireless/ath/ath9k/ar9003_phy.c
drivers/net/wireless/ath/ath9k/hw.h

index 63089cc1fafd6366d4209d33e1de28c5b4bd3bb0..9284bca6e16ebcff76a46cf2582f302fcf4d9aab 100644 (file)
@@ -938,6 +938,8 @@ static bool ar9003_hw_init_cal(struct ath_hw *ah,
                                          AR_PHY_CL_TAB_1,
                                          AR_PHY_CL_TAB_2 };
 
+       ar9003_hw_set_chain_masks(ah, ah->caps.rx_chainmask, ah->caps.tx_chainmask);
+
        if (rtt) {
                if (!ar9003_hw_rtt_restore(ah, chan))
                        run_rtt_cal = true;
index 600aca9fe6b1707cd292538cb3988ea43ac02df1..f86ee0c7f314c977f9bdb5f921d98039b575cb09 100644 (file)
@@ -543,7 +543,7 @@ static void ar9003_hw_init_bb(struct ath_hw *ah,
        udelay(synthDelay + BASE_ACTIVATE_DELAY);
 }
 
-static void ar9003_hw_set_chain_masks(struct ath_hw *ah, u8 rx, u8 tx)
+void ar9003_hw_set_chain_masks(struct ath_hw *ah, u8 rx, u8 tx)
 {
        switch (rx) {
        case 0x5:
index f8e1fbbbfc5e60a70bf0f18a120d6f03e5b52248..d5c5dca3d3675cca2870c941dad048a4c90f7eb8 100644 (file)
@@ -1014,6 +1014,7 @@ int ar9003_paprd_setup_gain_table(struct ath_hw *ah, int chain);
 int ar9003_paprd_init_table(struct ath_hw *ah);
 bool ar9003_paprd_is_done(struct ath_hw *ah);
 void ar9003_hw_set_paprd_txdesc(struct ath_hw *ah, void *ds, u8 chains);
+void ar9003_hw_set_chain_masks(struct ath_hw *ah, u8 rx, u8 tx);
 
 /* Hardware family op attach helpers */
 void ar5008_hw_attach_phy_ops(struct ath_hw *ah);