zd1211rw: fix invalid signal values from device
authorJussi Kivilinna <jussi.kivilinna@mbnet.fi>
Mon, 20 Jun 2011 11:42:28 +0000 (14:42 +0300)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 22 Jun 2011 20:09:45 +0000 (16:09 -0400)
commit7a1d6564a15183cb5994656040966df09af8390f
treed9637c519b66007d6b98249c3477051fa4bba870
parent670dc2833d144375eac36ad74111495a825a9288
zd1211rw: fix invalid signal values from device

Driver uses IEEE80211_HW_SIGNAL_UNSPEC and so signal values reported to
mac80211 should be in range 0..100. Sometimes device return out of range
values. These out of range values can then trigger warning in
cfg80211_inform_bss_frame.

This patch adds checks to enforce range returned from driver to
mac80211 be in 0..100 range.

Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/zd1211rw/zd_def.h
drivers/net/wireless/zd1211rw/zd_mac.c