From: Hiroaki KAWAI <hiroaki.kawai@gmail.com>
To: linux-wireless@vger.kernel.org
Cc: Hiroaki KAWAI <hiroaki.kawai@gmail.com>
Subject: [PATCH] carl9170: fix bad rssi reading
Date: Thu, 10 Sep 2015 18:04:45 +0000 [thread overview]
Message-ID: <1441908285-606-1-git-send-email-hiroaki.kawai@gmail.com> (raw)
Fix rssi calculation error which was introduced in otus to ar9170
porting.
Signed-off-by: Hiroaki KAWAI <hiroaki.kawai@gmail.com>
---
drivers/net/wireless/ath/carl9170/rx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/ath/carl9170/rx.c b/drivers/net/wireless/ath/carl9170/rx.c
index 924135b..d66533c 100644
--- a/drivers/net/wireless/ath/carl9170/rx.c
+++ b/drivers/net/wireless/ath/carl9170/rx.c
@@ -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;
--
2.5.1
next reply other threads:[~2015-09-10 9:04 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-10 18:04 Hiroaki KAWAI [this message]
2015-09-10 13:07 ` [PATCH] carl9170: fix bad rssi reading Christian Lamparter
2015-09-10 16:43 ` Hiroaki Kawai
[not found] ` <CABD3darfGTc8gVgAo4j7S4M0uymoF2gy8ihLraN2qcXJFO9cWw@mail.gmail.com>
2015-09-10 16:56 ` Christian Lamparter
2015-09-29 7:38 ` Kalle Valo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1441908285-606-1-git-send-email-hiroaki.kawai@gmail.com \
--to=hiroaki.kawai@gmail.com \
--cc=linux-wireless@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).