aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorBill Moss <bmoss@clemson.edu>2006-02-14 19:50:18 -0500
committerJohn W. Linville <linville@tuxdriver.com>2006-03-17 15:08:02 -0500
commitb191608a451e75ed7f979cac268f5f423176feb3 (patch)
tree3f0037006a39d8c8507392bca15b326471fc76a2 /drivers
parent9d0be03aeeadcd59bd8f57219817e876a5e88e88 (diff)
[PATCH] ipw2200: Add signal level to iwlist scan output
This patch does two things. It uses the parameter IW_QUAL_DBM which is new in WE-19 to cause signal level and noise to be reported in dBm by the wireless tools. It also defines the signal level as an unsigned integer so that the signal level will be reported by iwlist iface scan. Signed-off-by: Bill Moss <bmoss@clemson.edu> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/wireless/ipw2200.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/net/wireless/ipw2200.c b/drivers/net/wireless/ipw2200.c
index b2bbdf982b01..c38d6a5fe9a3 100644
--- a/drivers/net/wireless/ipw2200.c
+++ b/drivers/net/wireless/ipw2200.c
@@ -7831,7 +7831,8 @@ static void ipw_rx(struct ipw_priv *priv)
7831 le16_to_cpu(pkt->u.frame.rssi_dbm) - 7831 le16_to_cpu(pkt->u.frame.rssi_dbm) -
7832 IPW_RSSI_TO_DBM, 7832 IPW_RSSI_TO_DBM,
7833 .signal = 7833 .signal =
7834 le16_to_cpu(pkt->u.frame.signal), 7834 le16_to_cpu(pkt->u.frame.rssi_dbm) -
7835 IPW_RSSI_TO_DBM + 0x100,
7835 .noise = 7836 .noise =
7836 le16_to_cpu(pkt->u.frame.noise), 7837 le16_to_cpu(pkt->u.frame.noise),
7837 .rate = pkt->u.frame.rate, 7838 .rate = pkt->u.frame.rate,
@@ -8358,7 +8359,7 @@ static int ipw_wx_get_range(struct net_device *dev,
8358 range->max_qual.qual = 100; 8359 range->max_qual.qual = 100;
8359 /* TODO: Find real max RSSI and stick here */ 8360 /* TODO: Find real max RSSI and stick here */
8360 range->max_qual.level = 0; 8361 range->max_qual.level = 0;
8361 range->max_qual.noise = priv->ieee->worst_rssi + 0x100; 8362 range->max_qual.noise = 0;
8362 range->max_qual.updated = 7; /* Updated all three */ 8363 range->max_qual.updated = 7; /* Updated all three */
8363 8364
8364 range->avg_qual.qual = 70; 8365 range->avg_qual.qual = 70;
@@ -9568,7 +9569,7 @@ static struct iw_statistics *ipw_get_wireless_stats(struct net_device *dev)
9568 wstats->qual.level = average_value(&priv->average_rssi); 9569 wstats->qual.level = average_value(&priv->average_rssi);
9569 wstats->qual.noise = average_value(&priv->average_noise); 9570 wstats->qual.noise = average_value(&priv->average_noise);
9570 wstats->qual.updated = IW_QUAL_QUAL_UPDATED | IW_QUAL_LEVEL_UPDATED | 9571 wstats->qual.updated = IW_QUAL_QUAL_UPDATED | IW_QUAL_LEVEL_UPDATED |
9571 IW_QUAL_NOISE_UPDATED; 9572 IW_QUAL_NOISE_UPDATED | IW_QUAL_DBM;
9572 9573
9573 wstats->miss.beacon = average_value(&priv->average_missed_beacons); 9574 wstats->miss.beacon = average_value(&priv->average_missed_beacons);
9574 wstats->discard.retries = priv->last_tx_failures; 9575 wstats->discard.retries = priv->last_tx_failures;