Incorrect signal levels reported using wpa_supplicant's driver_nl80211

Johannes Berg johannes
Tue Nov 3 00:06:55 PST 2009


On Mon, 2009-11-02 at 11:40 -0800, Dan Williams wrote:

> > 	--> dbm: used only if:
> > 		* valid and zero max_qual->level (but now set to -110....) 
> 
> IIRC non-zero max_qual->level was the indication that the driver wanted
> to use RSSI, not dBm.

Are you sure? Weird ... we've had it set at -110 practically forever in
mac80211-based drivers.

> Since the real "max" dBm is around 0 (ie, that's
> the highest signal strength you'll ever really see), max_qual->level
> meant the driver was reporting signal strength in dBm.  max_qual->level
> == -110 is kinda wrong, because that's the _minimum_ level, not the max.
> The noise floor is almost always around -100 dBm so setting
> max_qual->level is pretty useless.
> 
> This is *exactly* why 'qual' is there: so that the driver itself can
> figure out what the hell it's signal level is, and so that NM doesn't
> have to go around assuming stuff.
> 
> For WEXT reporting, mac80211 should really be constructing a 'qual'
> instead of leaving it 0.  Then we don't have ambiguities with dBm, RSSI,
> unspec, etc.

We do that -- I think the problem here is not the max_qual value but
that you're not getting a "qual" value since -Dnl80211 doesn't construct
that.

What effectively happens is that you're trying to discover device
capabilities based on wext, but then use the information provided by
nl80211, which while effectively the same information comes in a
different format. When using nl80211, you really should discover whether
the device uses dBm or RSSI values by the kind of attribute it gave you
in the scan result.

So IMHO the solution is to move all that "what kind of crap am I
getting" detection into driver_wext and only export the sanitised values
from wpa_supplicant.

johannes

PS: Please trim your quoting, it should be easy enough to kill
everything after your signature.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 801 bytes
Desc: This is a digitally signed message part
Url : http://lists.shmoo.com/pipermail/hostap/attachments/20091103/10e09776/attachment-0001.pgp 



More information about the Hostap mailing list