aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rt2x00/rt2x00dev.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2x00dev.c')
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00dev.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00dev.c b/drivers/net/wireless/rt2x00/rt2x00dev.c
index acf4d67ba43d..f52e92512f90 100644
--- a/drivers/net/wireless/rt2x00/rt2x00dev.c
+++ b/drivers/net/wireless/rt2x00/rt2x00dev.c
@@ -580,19 +580,28 @@ void rt2x00lib_rxdone(struct queue_entry *entry,
580 for (i = 0; i < sband->n_bitrates; i++) { 580 for (i = 0; i < sband->n_bitrates; i++) {
581 rate = rt2x00_get_rate(sband->bitrates[i].hw_value); 581 rate = rt2x00_get_rate(sband->bitrates[i].hw_value);
582 582
583 if ((rxdesc->signal_plcp && rate->plcp == rxdesc->signal) || 583 if (((rxdesc->dev_flags & RXDONE_SIGNAL_PLCP) &&
584 (!rxdesc->signal_plcp && rate->bitrate == rxdesc->signal)) { 584 (rate->plcp == rxdesc->signal)) ||
585 (!(rxdesc->dev_flags & RXDONE_SIGNAL_PLCP) &&
586 (rate->bitrate == rxdesc->signal))) {
585 idx = i; 587 idx = i;
586 break; 588 break;
587 } 589 }
588 } 590 }
589 591
592 if (idx < 0) {
593 WARNING(rt2x00dev, "Frame received with unrecognized signal,"
594 "signal=0x%.2x, plcp=%d.\n", rxdesc->signal,
595 !!(rxdesc->dev_flags & RXDONE_SIGNAL_PLCP));
596 idx = 0;
597 }
598
590 /* 599 /*
591 * Only update link status if this is a beacon frame carrying our bssid. 600 * Only update link status if this is a beacon frame carrying our bssid.
592 */ 601 */
593 hdr = (struct ieee80211_hdr *)entry->skb->data; 602 hdr = (struct ieee80211_hdr *)entry->skb->data;
594 fc = le16_to_cpu(hdr->frame_control); 603 fc = le16_to_cpu(hdr->frame_control);
595 if (is_beacon(fc) && rxdesc->my_bss) 604 if (is_beacon(fc) && (rxdesc->dev_flags & RXDONE_MY_BSS))
596 rt2x00lib_update_link_stats(&rt2x00dev->link, rxdesc->rssi); 605 rt2x00lib_update_link_stats(&rt2x00dev->link, rxdesc->rssi);
597 606
598 rt2x00dev->link.qual.rx_success++; 607 rt2x00dev->link.qual.rx_success++;