]> bbs.cooldavid.org Git - net-next-2.6.git/commit - drivers/net/wireless/rt2x00/rt2800.h
rt2x00: Convert AGC value from descriptor to RSSI (dBm)
authorIvo van Doorn <ivdoorn@gmail.com>
Sun, 11 Jul 2010 10:23:50 +0000 (12:23 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 12 Jul 2010 20:05:33 +0000 (16:05 -0400)
commit748619220651a33c260ed6c0a7648e69324edd74
tree70aac3f3abd9ea5826f2217f708836dfe6434980
parent5e846004914d2295e020edd48a828b653323f93e
rt2x00: Convert AGC value from descriptor to RSSI (dBm)

The RSSI values in the RXWI descriptor aren't true RSSI
values. Instead they are more like the AGC values similar
to rt61pci. And as such, it needs the same conversion
before it can be passed to rt2x00lib/mac80211.

This requires the struct queue_entry to be passed to
rt2800_process_rxwi rather then the skb structure which
is contained in the queue_entry. This is required to
obtain the lna_gain information from the rt2x00_dev structure.

This fixes connection problems when using wpa_supplicant
which would try to connect to the worst AP's rather then the
best ones.

Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/rt2x00/rt2800.h
drivers/net/wireless/rt2x00/rt2800lib.c
drivers/net/wireless/rt2x00/rt2800lib.h
drivers/net/wireless/rt2x00/rt2800pci.c
drivers/net/wireless/rt2x00/rt2800usb.c