diff options
-rw-r--r-- | drivers/net/wireless/hostap/hostap_80211_rx.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/hostap/hostap_ap.c | 6 | ||||
-rw-r--r-- | drivers/net/wireless/hostap/hostap_ioctl.c | 9 |
3 files changed, 12 insertions, 6 deletions
diff --git a/drivers/net/wireless/hostap/hostap_80211_rx.c b/drivers/net/wireless/hostap/hostap_80211_rx.c index 42e61c68c325..ffac50899454 100644 --- a/drivers/net/wireless/hostap/hostap_80211_rx.c +++ b/drivers/net/wireless/hostap/hostap_80211_rx.c | |||
@@ -737,7 +737,8 @@ void hostap_80211_rx(struct net_device *dev, struct sk_buff *skb, | |||
737 | struct iw_quality wstats; | 737 | struct iw_quality wstats; |
738 | wstats.level = rx_stats->signal; | 738 | wstats.level = rx_stats->signal; |
739 | wstats.noise = rx_stats->noise; | 739 | wstats.noise = rx_stats->noise; |
740 | wstats.updated = 6; /* No qual value */ | 740 | wstats.updated = IW_QUAL_LEVEL_UPDATED | IW_QUAL_NOISE_UPDATED |
741 | | IW_QUAL_QUAL_INVALID | IW_QUAL_DBM; | ||
741 | /* Update spy records */ | 742 | /* Update spy records */ |
742 | wireless_spy_update(dev, hdr->addr2, &wstats); | 743 | wireless_spy_update(dev, hdr->addr2, &wstats); |
743 | } | 744 | } |
diff --git a/drivers/net/wireless/hostap/hostap_ap.c b/drivers/net/wireless/hostap/hostap_ap.c index 087d9269af34..9da94ab7f05f 100644 --- a/drivers/net/wireless/hostap/hostap_ap.c +++ b/drivers/net/wireless/hostap/hostap_ap.c | |||
@@ -2349,7 +2349,7 @@ static int prism2_ap_get_sta_qual(local_info_t *local, struct sockaddr addr[], | |||
2349 | qual[count].noise = HFA384X_LEVEL_TO_dBm(sta->last_rx_silence); | 2349 | qual[count].noise = HFA384X_LEVEL_TO_dBm(sta->last_rx_silence); |
2350 | qual[count].updated = sta->last_rx_updated; | 2350 | qual[count].updated = sta->last_rx_updated; |
2351 | 2351 | ||
2352 | sta->last_rx_updated = 0; | 2352 | sta->last_rx_updated = IW_QUAL_DBM; |
2353 | 2353 | ||
2354 | count++; | 2354 | count++; |
2355 | if (count >= buf_size) | 2355 | if (count >= buf_size) |
@@ -2467,7 +2467,7 @@ static int prism2_ap_translate_scan(struct net_device *dev, char *buffer) | |||
2467 | } | 2467 | } |
2468 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ | 2468 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ |
2469 | 2469 | ||
2470 | sta->last_rx_updated = 0; | 2470 | sta->last_rx_updated = IW_QUAL_DBM; |
2471 | 2471 | ||
2472 | /* To be continued, we should make good use of IWEVCUSTOM */ | 2472 | /* To be continued, we should make good use of IWEVCUSTOM */ |
2473 | } | 2473 | } |
@@ -3174,7 +3174,7 @@ int hostap_update_rx_stats(struct ap_data *ap, | |||
3174 | sta->last_rx_silence = rx_stats->noise; | 3174 | sta->last_rx_silence = rx_stats->noise; |
3175 | sta->last_rx_signal = rx_stats->signal; | 3175 | sta->last_rx_signal = rx_stats->signal; |
3176 | sta->last_rx_rate = rx_stats->rate; | 3176 | sta->last_rx_rate = rx_stats->rate; |
3177 | sta->last_rx_updated = 7; | 3177 | sta->last_rx_updated = IW_QUAL_ALL_UPDATED | IW_QUAL_DBM; |
3178 | if (rx_stats->rate == 10) | 3178 | if (rx_stats->rate == 10) |
3179 | sta->rx_count[0]++; | 3179 | sta->rx_count[0]++; |
3180 | else if (rx_stats->rate == 20) | 3180 | else if (rx_stats->rate == 20) |
diff --git a/drivers/net/wireless/hostap/hostap_ioctl.c b/drivers/net/wireless/hostap/hostap_ioctl.c index e720369a3515..dd9817261a3a 100644 --- a/drivers/net/wireless/hostap/hostap_ioctl.c +++ b/drivers/net/wireless/hostap/hostap_ioctl.c | |||
@@ -50,7 +50,8 @@ static struct iw_statistics *hostap_get_wireless_stats(struct net_device *dev) | |||
50 | #endif /* in_atomic */ | 50 | #endif /* in_atomic */ |
51 | 51 | ||
52 | if (update && prism2_update_comms_qual(dev) == 0) | 52 | if (update && prism2_update_comms_qual(dev) == 0) |
53 | wstats->qual.updated = 7; | 53 | wstats->qual.updated = IW_QUAL_ALL_UPDATED | |
54 | IW_QUAL_DBM; | ||
54 | 55 | ||
55 | wstats->qual.qual = local->comms_qual; | 56 | wstats->qual.qual = local->comms_qual; |
56 | wstats->qual.level = local->avg_signal; | 57 | wstats->qual.level = local->avg_signal; |
@@ -59,7 +60,7 @@ static struct iw_statistics *hostap_get_wireless_stats(struct net_device *dev) | |||
59 | wstats->qual.qual = 0; | 60 | wstats->qual.qual = 0; |
60 | wstats->qual.level = 0; | 61 | wstats->qual.level = 0; |
61 | wstats->qual.noise = 0; | 62 | wstats->qual.noise = 0; |
62 | wstats->qual.updated = 0; | 63 | wstats->qual.updated = IW_QUAL_ALL_INVALID; |
63 | } | 64 | } |
64 | 65 | ||
65 | return wstats; | 66 | return wstats; |
@@ -1894,6 +1895,10 @@ static char * __prism2_translate_scan(local_info_t *local, | |||
1894 | iwe.u.qual.noise = | 1895 | iwe.u.qual.noise = |
1895 | HFA384X_LEVEL_TO_dBm(le16_to_cpu(scan->anl)); | 1896 | HFA384X_LEVEL_TO_dBm(le16_to_cpu(scan->anl)); |
1896 | } | 1897 | } |
1898 | iwe.u.qual.updated = IW_QUAL_LEVEL_UPDATED | ||
1899 | | IW_QUAL_NOISE_UPDATED | ||
1900 | | IW_QUAL_QUAL_INVALID | ||
1901 | | IW_QUAL_DBM; | ||
1897 | iwe.len = IW_EV_QUAL_LEN; | 1902 | iwe.len = IW_EV_QUAL_LEN; |
1898 | current_ev = iwe_stream_add_event(current_ev, end_buf, &iwe, | 1903 | current_ev = iwe_stream_add_event(current_ev, end_buf, &iwe, |
1899 | IW_EV_QUAL_LEN); | 1904 | IW_EV_QUAL_LEN); |