wlcore: add antenna diversity reading comments

add comments to the antenna diversity reading

Signed-off-by: Guy Mishol <guym@ti.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
This commit is contained in:
Guy Mishol 2015-07-27 17:25:49 +03:00 committed by Kalle Valo
parent 6c63173211
commit 5d7e73ba2f
1 changed files with 6 additions and 0 deletions

View File

@ -74,6 +74,12 @@ static void wl1271_rx_status(struct wl1271 *wl,
if (desc->rate <= wl->hw_min_ht_rate) if (desc->rate <= wl->hw_min_ht_rate)
status->flag |= RX_FLAG_HT; status->flag |= RX_FLAG_HT;
/*
* Read the signal level and antenna diversity indication.
* The msb in the signal level is always set as it is a
* negative number.
* The antenna indication is the msb of the rssi.
*/
status->signal = ((desc->rssi & RSSI_LEVEL_BITMASK) | BIT(7)); status->signal = ((desc->rssi & RSSI_LEVEL_BITMASK) | BIT(7));
status->antenna = ((desc->rssi & ANT_DIVERSITY_BITMASK) >> 7); status->antenna = ((desc->rssi & ANT_DIVERSITY_BITMASK) >> 7);