carl9170: fix bad rssi reading
Fix rssi calculation error which was introduced in otus to ar9170 porting. Signed-off-by: Hiroaki KAWAI <hiroaki.kawai@gmail.com> Acked-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
This commit is contained in:
parent
76ea6fdbeb
commit
c452d944be
@ -453,7 +453,7 @@ static void carl9170_rx_phy_status(struct ar9170 *ar,
|
||||
/* post-process RSSI */
|
||||
for (i = 0; i < 7; i++)
|
||||
if (phy->rssi[i] & 0x80)
|
||||
phy->rssi[i] = ((phy->rssi[i] & 0x7f) + 1) & 0x7f;
|
||||
phy->rssi[i] = ((~phy->rssi[i] & 0x7f) + 1) & 0x7f;
|
||||
|
||||
/* TODO: we could do something with phy_errors */
|
||||
status->signal = ar->noise[0] + phy->rssi_combined;
|
||||
|
Loading…
Reference in New Issue
Block a user