From: "Luis R. Rodriguez" <lrodriguez@atheros.com>
To: <linville@tuxdriver.com>, <linville@tuxdriver.com>
Cc: <linux-wireless@vger.kernel.org>, <ath9k-devel@lists.ath9k.org>,
<jouni.malinen@atheros.com>,
"Luis R. Rodriguez" <lrodriguez@atheros.com>,
<linux-wireless@vger.kernel.org>, <ath9k-devel@lists.ath9k.org>
Subject: [PATCH 11/12] ath9k: Add initial link quality reporting
Date: Sat, 2 Aug 2008 16:49:03 -0700 [thread overview]
Message-ID: <1217720944-23234-12-git-send-email-lrodriguez@atheros.com> (raw)
In-Reply-To: <1217720944-23234-11-git-send-email-lrodriguez@atheros.com>
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
---
drivers/net/wireless/ath9k/main.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/drivers/net/wireless/ath9k/main.c b/drivers/net/wireless/ath9k/main.c
index effcce9..7222a42 100644
--- a/drivers/net/wireless/ath9k/main.c
+++ b/drivers/net/wireless/ath9k/main.c
@@ -282,10 +282,11 @@ static void ath9k_rx_prepare(struct ath_softc *sc,
rx_status->mactime = status->tsf;
rx_status->band = curchan->band;
rx_status->freq = curchan->center_freq;
- rx_status->signal = (status->rssi * 64) / 100;
rx_status->noise = ATH_DEFAULT_NOISE_FLOOR;
+ rx_status->signal = rx_status->noise + status->rssi;
rx_status->rate_idx = ath_rate2idx(sc, (status->rateKbps / 100));
rx_status->antenna = status->antenna;
+ rx_status->qual = status->rssi * 100 / 64;
if (status->flags & ATH_RX_MIC_ERROR)
rx_status->flag |= RX_FLAG_MMIC_ERROR;
@@ -1402,6 +1403,9 @@ static int ath_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
goto bad2;
}
+ hw->flags = IEEE80211_HW_SIGNAL_DBM |
+ IEEE80211_HW_NOISE_DBM;
+
SET_IEEE80211_DEV(hw, &pdev->dev);
pci_set_drvdata(pdev, hw);
--
1.5.6.rc2.15.g457bb.dirty
next prev parent reply other threads:[~2008-08-02 23:49 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-02 23:48 [PATCH 00/12] ath9k: more cleanups for 2.6.27 Luis R. Rodriguez
[not found] ` <1217720944-23234-2-git-send-email-lrodriguez@atheros.com>
2008-08-02 23:48 ` [PATCH 02/12] ath9k: Update rate control after association Luis R. Rodriguez
2008-08-02 23:48 ` [PATCH 03/12] ath9k: Channel cleanup Luis R. Rodriguez
2008-08-02 23:48 ` [PATCH 04/12] ath9k: Fix channel registration Luis R. Rodriguez
2008-08-02 23:48 ` [PATCH 05/12] ath9k: Consolidate channel list Luis R. Rodriguez
2008-08-02 23:48 ` [PATCH 06/12] ath9k: Pass channel mode when setting a channel Luis R. Rodriguez
2008-08-02 23:48 ` [PATCH 07/12] ath9k: Channel structure cleanup Luis R. Rodriguez
2008-08-02 23:49 ` [PATCH 08/12] ath9k: We don't have a HAL anymore :) Luis R. Rodriguez
[not found] ` <1217720944-23234-10-git-send-email-lrodriguez@atheros.com>
2008-08-02 23:49 ` [PATCH 10/12] ath9k: Port to new skb->cb mac80211 changes Luis R. Rodriguez
2008-08-02 23:49 ` Luis R. Rodriguez [this message]
2008-08-02 23:49 ` [PATCH 12/12] ath9k: Use u8/u16/u32 Luis R. Rodriguez
2008-08-03 0:18 ` [PATCH 00/12] ath9k: more cleanups for 2.6.27 Luis R. Rodriguez
2008-08-03 9:18 ` Johannes Berg
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=1217720944-23234-12-git-send-email-lrodriguez@atheros.com \
--to=lrodriguez@atheros.com \
--cc=ath9k-devel@lists.ath9k.org \
--cc=jouni.malinen@atheros.com \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
/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