Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 79335
b: refs/heads/master
c: 851b3e5
h: refs/heads/master
i:
  79333: 2c3f8a9
  79331: 9f61f2a
  79327: 5a7b0e3
v: v3
  • Loading branch information
Al Viro authored and David S. Miller committed Jan 28, 2008
1 parent 2cb7616 commit 0a0414e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 977b143c13e685081625704ac356b741d71c6a73
refs/heads/master: 851b3e5e3de0feea7bfee634f99a940648de58c8
9 changes: 6 additions & 3 deletions trunk/drivers/net/wireless/airo.c
Original file line number Diff line number Diff line change
Expand Up @@ -7239,6 +7239,7 @@ static inline char *airo_translate_scan(struct net_device *dev,
char * current_val; /* For rates */
int i;
char * buf;
u16 dBm;

/* First entry *MUST* be the AP MAC address */
iwe.cmd = SIOCGIWAP;
Expand Down Expand Up @@ -7277,16 +7278,18 @@ static inline char *airo_translate_scan(struct net_device *dev,
iwe.u.freq.e = 1;
current_ev = iwe_stream_add_event(current_ev, end_buf, &iwe, IW_EV_FREQ_LEN);

dBm = le16_to_cpu(bss->dBm);

/* Add quality statistics */
iwe.cmd = IWEVQUAL;
if (ai->rssi) {
iwe.u.qual.level = 0x100 - bss->dBm;
iwe.u.qual.qual = airo_dbm_to_pct( ai->rssi, bss->dBm );
iwe.u.qual.level = 0x100 - dBm;
iwe.u.qual.qual = airo_dbm_to_pct(ai->rssi, dBm);
iwe.u.qual.updated = IW_QUAL_QUAL_UPDATED
| IW_QUAL_LEVEL_UPDATED
| IW_QUAL_DBM;
} else {
iwe.u.qual.level = (bss->dBm + 321) / 2;
iwe.u.qual.level = (dBm + 321) / 2;
iwe.u.qual.qual = 0;
iwe.u.qual.updated = IW_QUAL_QUAL_INVALID
| IW_QUAL_LEVEL_UPDATED
Expand Down

0 comments on commit 0a0414e

Please sign in to comment.