diff options
Diffstat (limited to 'drivers/net/wireless/b43/xmit.c')
-rw-r--r-- | drivers/net/wireless/b43/xmit.c | 27 |
1 files changed, 19 insertions, 8 deletions
diff --git a/drivers/net/wireless/b43/xmit.c b/drivers/net/wireless/b43/xmit.c index 0bd6f8a348a..3307ba1856b 100644 --- a/drivers/net/wireless/b43/xmit.c +++ b/drivers/net/wireless/b43/xmit.c | |||
@@ -531,21 +531,32 @@ void b43_rx(struct b43_wldev *dev, struct sk_buff *skb, const void *_rxhdr) | |||
531 | switch (chanstat & B43_RX_CHAN_PHYTYPE) { | 531 | switch (chanstat & B43_RX_CHAN_PHYTYPE) { |
532 | case B43_PHYTYPE_A: | 532 | case B43_PHYTYPE_A: |
533 | status.phymode = MODE_IEEE80211A; | 533 | status.phymode = MODE_IEEE80211A; |
534 | status.freq = chanid; | 534 | B43_WARN_ON(1); |
535 | status.channel = b43_freq_to_channel_a(chanid); | 535 | /* FIXME: We don't really know which value the "chanid" contains. |
536 | break; | 536 | * So the following assignment might be wrong. */ |
537 | case B43_PHYTYPE_B: | 537 | status.channel = chanid; |
538 | status.phymode = MODE_IEEE80211B; | 538 | status.freq = b43_channel_to_freq_5ghz(status.channel); |
539 | status.freq = chanid + 2400; | ||
540 | status.channel = b43_freq_to_channel_bg(chanid + 2400); | ||
541 | break; | 539 | break; |
542 | case B43_PHYTYPE_G: | 540 | case B43_PHYTYPE_G: |
543 | status.phymode = MODE_IEEE80211G; | 541 | status.phymode = MODE_IEEE80211G; |
542 | /* chanid is the radio channel cookie value as used | ||
543 | * to tune the radio. */ | ||
544 | status.freq = chanid + 2400; | 544 | status.freq = chanid + 2400; |
545 | status.channel = b43_freq_to_channel_bg(chanid + 2400); | 545 | status.channel = b43_freq_to_channel_2ghz(status.freq); |
546 | break; | ||
547 | case B43_PHYTYPE_N: | ||
548 | status.phymode = 0xDEAD /*FIXME MODE_IEEE80211N*/; | ||
549 | /* chanid is the SHM channel cookie. Which is the plain | ||
550 | * channel number in b43. */ | ||
551 | status.channel = chanid; | ||
552 | if (chanstat & B43_RX_CHAN_5GHZ) | ||
553 | status.freq = b43_freq_to_channel_5ghz(status.freq); | ||
554 | else | ||
555 | status.freq = b43_freq_to_channel_2ghz(status.freq); | ||
546 | break; | 556 | break; |
547 | default: | 557 | default: |
548 | B43_WARN_ON(1); | 558 | B43_WARN_ON(1); |
559 | goto drop; | ||
549 | } | 560 | } |
550 | 561 | ||
551 | dev->stats.last_rx = jiffies; | 562 | dev->stats.last_rx = jiffies; |