[net80211] add STBC capability flags to iv_flags_ht.
This is in preparation for exposing configuring STBC flags up to ifconfig so STBC TX/RX can be configured at runtime. * Set the FHT_STBC flags for TX/RX if the HT capabilitiex exist * Clear the RX STBC HT capability flag when creating a HTCAP IE, so we only announce it if it's configured in the FHT flags. Tested: * AR9331 (carambola2), AP/STA modes
This commit is contained in:
parent
1729922f65
commit
5706199db6
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=298604
@ -293,6 +293,11 @@ ieee80211_ht_vattach(struct ieee80211vap *vap)
|
||||
vap->iv_flags_ht |= IEEE80211_FHT_AMSDU_RX;
|
||||
if (vap->iv_htcaps & IEEE80211_HTC_AMSDU)
|
||||
vap->iv_flags_ht |= IEEE80211_FHT_AMSDU_TX;
|
||||
|
||||
if (vap->iv_htcaps & IEEE80211_HTCAP_TXSTBC)
|
||||
vap->iv_flags_ht |= IEEE80211_FHT_STBC_TX;
|
||||
if (vap->iv_htcaps & IEEE80211_HTCAP_RXSTBC)
|
||||
vap->iv_flags_ht |= IEEE80211_FHT_STBC_RX;
|
||||
}
|
||||
/* NB: disable default legacy WDS, too many issues right now */
|
||||
if (vap->iv_flags_ext & IEEE80211_FEXT_WDSLEGACY)
|
||||
@ -2778,6 +2783,13 @@ ieee80211_add_htcap_body(uint8_t *frm, struct ieee80211_node *ni)
|
||||
if ((vap->iv_flags_ht & IEEE80211_FHT_SHORTGI40) == 0 ||
|
||||
(caps & IEEE80211_HTCAP_CHWIDTH40) == 0)
|
||||
caps &= ~IEEE80211_HTCAP_SHORTGI40;
|
||||
|
||||
/* adjust STBC based on receive capabilities */
|
||||
if ((vap->iv_flags_ht & IEEE80211_FHT_STBC_RX) == 0)
|
||||
caps &= ~IEEE80211_HTCAP_RXSTBC;
|
||||
|
||||
/* XXX TODO: adjust LDPC based on receive capabilities */
|
||||
|
||||
ADDSHORT(frm, caps);
|
||||
|
||||
/* HT parameters */
|
||||
|
Loading…
Reference in New Issue
Block a user