ath9k: Fix symbol overlap window for half/quarter channels
PATCH 1/1 ath9k: Fix symbol overlap window for half/quarter channels
Since commit cd6cfd7311a385144a2f9c74f692ae2df3ae033f "ath9k: do not set half/quarter channel flags in AR_PHY_MODE" the condition "rfMode & (AR_PHY_MODE_QUARTER | AR_PHY_MODE_HALF)" would never evaluate to true.
Fix this by using the available IS_CHAN_HALF_RATE and IS_CHAN_QUARTER_RATE marcros instead.
---
Just stumbled over that piece of code while looking into TX99, so this is only compile-tested.
Felix, can you please confirm if this is correct or if removing the whole block would be better?
Thanks,
Helmut
drivers/net/wireless/ath/ath9k/ar9003_phy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/wireless/ath/ath9k/ar9003_phy.c +1 -1
@@ -1010,7 +1010,7 @@ static void ar9003_hw_set_rfmode(struct ath_hw *ah,if (IS_CHAN_A_FAST_CLOCK (ah, chan)) rfMode |= (AR_PHY_MODE_DYNAMIC |AR_PHY_MODE_DYN_CCK_DISABLE ); -if (rfMode & (AR_PHY_MODE_QUARTER |AR_PHY_MODE_HALF )) +if (IS_CHAN_HALF_RATE (chan) ||IS_CHAN_QUARTER_RATE (chan))REG_RMW_FIELD (ah,AR_PHY_FRAME_CTL ,AR_PHY_FRAME_CTL_CF_OVERLAP_WINDOW ,3 );
Signature · 1 line
2.8.1
PATCH 1/1 ath9k: Fix symbol overlap window for half/quarter channels
Quoted 8 lines · Helmut Schaa
Since commit
cd6cfd7311a385144a2f9c74f692ae2df3ae033f"ath9k: do not set half/quarter channel flags inAR_PHY_MODE" the condition "rfMode & (AR_PHY_MODE_QUARTER|AR_PHY_MODE_HALF)" would never evaluate to true.Fix this by using the available
IS_CHAN_HALF_RATEandIS_CHAN_QUARTER_RATEmarcros instead.
Quoted 8 lines
Signed-off-by Helmut Schaa <[email protected]>Cc Felix Fietkau <[email protected]>---
Just stumbled over that piece of code while looking into TX99, so this is only compile-tested.Felix, can you please confirm if this is correct or if removing the whole block would be better?
This patch looks good to me.
Kalle Valo
AppliedPATCH 1/1 ath9k: Fix symbol overlap window for half/quarter channels
In reply to Helmut SchaaQuoted 10 lines · Helmut Schaa
Since commit
cd6cfd7311a385144a2f9c74f692ae2df3ae033f"ath9k: do not set half/quarter channel flags inAR_PHY_MODE" the condition "rfMode & (AR_PHY_MODE_QUARTER|AR_PHY_MODE_HALF)" would never evaluate to true.Fix this by using the available
IS_CHAN_HALF_RATEandIS_CHAN_QUARTER_RATEmarcros instead.Signed-off-by Helmut Schaa <[email protected]>Cc Felix Fietkau <[email protected]>
Thanks, applied to ath.git.
Signature · 1 line
Kalle Valo