diff options
| author | Dedy Lansky <qca_dlansky@qca.qualcomm.com> | 2017-08-21 22:58:54 +0300 |
|---|---|---|
| committer | Maya Erez <merez@codeaurora.org> | 2017-08-21 22:59:19 +0300 |
| commit | ba2101fc30b4302badba0790f7e6d4222f15a46b (patch) | |
| tree | 5ab5dba245c920045e7bbef6d2ff100c7ff0bde2 /drivers/net/wireless/ath/wil6210/wmi.c | |
| parent | 468ba7b8f93d584586a0b31aaeadb890ce60068b (diff) | |
wil6210: support FW RSSI reporting
New FW supports reporting RSSI signal in dBm.
Report RSSI to kernel in case FW has this capability.
Change-Id: I85fdae2e92a38cfb7ab9a5f97dcf363add51b959
Signed-off-by: Dedy Lansky <qca_dlansky@qca.qualcomm.com>
Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Git-commit: 30868f5d4413759ba82c0703290f2483402fea39
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git
Signed-off-by: Maya Erez <merez@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/ath/wil6210/wmi.c')
| -rw-r--r-- | drivers/net/wireless/ath/wil6210/wmi.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/net/wireless/ath/wil6210/wmi.c b/drivers/net/wireless/ath/wil6210/wmi.c index fba0d6a79ae2..61f629c94bbb 100644 --- a/drivers/net/wireless/ath/wil6210/wmi.c +++ b/drivers/net/wireless/ath/wil6210/wmi.c @@ -382,12 +382,15 @@ static void wmi_evt_rx_mgmt(struct wil6210_priv *wil, int id, void *d, int len) ch_no = data->info.channel + 1; freq = ieee80211_channel_to_frequency(ch_no, IEEE80211_BAND_60GHZ); channel = ieee80211_get_channel(wiphy, freq); - signal = data->info.sqi; + if (test_bit(WMI_FW_CAPABILITY_RSSI_REPORTING, wil->fw_capabilities)) + signal = 100 * data->info.rssi; + else + signal = data->info.sqi; d_status = le16_to_cpu(data->info.status); fc = rx_mgmt_frame->frame_control; - wil_dbg_wmi(wil, "MGMT Rx: channel %d MCS %d SNR %d SQI %d%%\n", - data->info.channel, data->info.mcs, data->info.snr, + wil_dbg_wmi(wil, "MGMT Rx: channel %d MCS %d RSSI %d SQI %d%%\n", + data->info.channel, data->info.mcs, data->info.rssi, data->info.sqi); wil_dbg_wmi(wil, "status 0x%04x len %d fc 0x%04x\n", d_status, d_len, le16_to_cpu(fc)); |
