* [PATCH 1/4] ath5k: Fix another faulty channel flag check
@ 2007-11-14 16:11 Nick Kossifidis
2007-11-15 17:59 ` Luis R. Rodriguez
0 siblings, 1 reply; 2+ messages in thread
From: Nick Kossifidis @ 2007-11-14 16:11 UTC (permalink / raw)
To: ath5k-devel, linux-wireless; +Cc: linville, jirislaby, mcgrof
*Fix another faulty channel flags check
Don't check channel->val against CHANNEL_A/B/G flags because they have common flags set
eg. doing AND between CHANNEL_A and CHANNEL_G always returns true because they have
CHANNEL_OFDM, same goes for CHANNEL_B and CHANNEL_G that have CHANNEL_2GHZ in common.
Instead check against CHANNEL_CCK/OFDM/2GHZ/5GHZ...
Changes-licensed-under: ISC
Signed-off-by: Nick Kossifidis <mickflemm@gmail.com>
---
diff --git a/drivers/net/wireless/ath5k/hw.c b/drivers/net/wireless/ath5k/hw.c
index f78ca6e..ead2d75 100644
--- a/drivers/net/wireless/ath5k/hw.c
+++ b/drivers/net/wireless/ath5k/hw.c
@@ -719,7 +719,7 @@ int ath5k_hw_reset(struct ath5k_hw *ah, enum ieee80211_if_types op_mode,
AR5K_SREV_RAD_5112A) {
ath5k_hw_reg_write(ah, AR5K_PHY_CCKTXCTL_WORLD,
AR5K_PHY_CCKTXCTL);
- if (channel->val & CHANNEL_A)
+ if (channel->val & CHANNEL_5GHZ)
data = 0xffb81020;
else
data = 0xffb80d20;
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 1/4] ath5k: Fix another faulty channel flag check
2007-11-14 16:11 [PATCH 1/4] ath5k: Fix another faulty channel flag check Nick Kossifidis
@ 2007-11-15 17:59 ` Luis R. Rodriguez
0 siblings, 0 replies; 2+ messages in thread
From: Luis R. Rodriguez @ 2007-11-15 17:59 UTC (permalink / raw)
To: ath5k-devel, linux-wireless, linville, jirislaby, mcgrof
On Nov 14, 2007 11:11 AM, Nick Kossifidis <mick@madwifi.org> wrote:
> *Fix another faulty channel flags check
>
> Don't check channel->val against CHANNEL_A/B/G flags because they have common flags set
> eg. doing AND between CHANNEL_A and CHANNEL_G always returns true because they have
> CHANNEL_OFDM, same goes for CHANNEL_B and CHANNEL_G that have CHANNEL_2GHZ in common.
>
> Instead check against CHANNEL_CCK/OFDM/2GHZ/5GHZ...
>
> Changes-licensed-under: ISC
> Signed-off-by: Nick Kossifidis <mickflemm@gmail.com>
Acked-by: Luis R. Rodriguez <mcgrof@winlab.rutgers.edu>
Luis
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2007-11-15 17:59 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-11-14 16:11 [PATCH 1/4] ath5k: Fix another faulty channel flag check Nick Kossifidis
2007-11-15 17:59 ` Luis R. Rodriguez
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).