mac80211: propagate STBC / LDPC flags to radiotap
This capabilities weren't propagated to the radiotap header. We don't set here the VHT_KNOWN / MCS_HAVE flag because not all the low level drivers will know how to properly flag the frames, hence the low level driver will be in charge of setting IEEE80211_RADIOTAP_MCS_HAVE_FEC, IEEE80211_RADIOTAP_MCS_HAVE_STBC and / or IEEE80211_RADIOTAP_VHT_KNOWN_STBC according to its capabilities. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:

committed by
Johannes Berg

parent
1b8d242adb
commit
63c361f511
@@ -279,6 +279,8 @@ ieee80211_add_rx_radiotap_header(struct ieee80211_local *local,
|
||||
*pos |= IEEE80211_RADIOTAP_MCS_BW_40;
|
||||
if (status->flag & RX_FLAG_HT_GF)
|
||||
*pos |= IEEE80211_RADIOTAP_MCS_FMT_GF;
|
||||
if (status->flag & RX_FLAG_LDPC)
|
||||
*pos |= IEEE80211_RADIOTAP_MCS_FEC_LDPC;
|
||||
stbc = (status->flag & RX_FLAG_STBC_MASK) >> RX_FLAG_STBC_SHIFT;
|
||||
*pos |= stbc << IEEE80211_RADIOTAP_MCS_STBC_SHIFT;
|
||||
pos++;
|
||||
@@ -328,6 +330,9 @@ ieee80211_add_rx_radiotap_header(struct ieee80211_local *local,
|
||||
/* flags */
|
||||
if (status->flag & RX_FLAG_SHORT_GI)
|
||||
*pos |= IEEE80211_RADIOTAP_VHT_FLAG_SGI;
|
||||
/* in VHT, STBC is binary */
|
||||
if (status->flag & RX_FLAG_STBC_MASK)
|
||||
*pos |= IEEE80211_RADIOTAP_VHT_FLAG_STBC;
|
||||
pos++;
|
||||
/* bandwidth */
|
||||
if (status->vht_flag & RX_VHT_FLAG_80MHZ)
|
||||
@@ -344,6 +349,8 @@ ieee80211_add_rx_radiotap_header(struct ieee80211_local *local,
|
||||
*pos = (status->rate_idx << 4) | status->vht_nss;
|
||||
pos += 4;
|
||||
/* coding field */
|
||||
if (status->flag & RX_FLAG_LDPC)
|
||||
*pos |= IEEE80211_RADIOTAP_CODING_LDPC_USER0;
|
||||
pos++;
|
||||
/* group ID */
|
||||
pos++;
|
||||
|
Reference in New Issue
Block a user