mac80211: propagate HE operation info into bss_conf
Upon a successful assoc a station shall store the content of the HE operation element inside bss_conf so that the driver can setup the hardware accordingly. Signed-off-by: Shashidhar Lakkavalli <slakkavalli@datto.com> Signed-off-by: John Crispin <john@phrozen.org> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> Link: https://lore.kernel.org/r/20190729102342.8659-2-john@phrozen.org [use struct copy] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
parent
90d4962cfc
commit
697f6c507c
|
@ -600,6 +600,7 @@ struct ieee80211_ftm_responder_params {
|
||||||
* nontransmitted BSSIDs
|
* nontransmitted BSSIDs
|
||||||
* @profile_periodicity: the least number of beacon frames need to be received
|
* @profile_periodicity: the least number of beacon frames need to be received
|
||||||
* in order to discover all the nontransmitted BSSIDs in the set.
|
* in order to discover all the nontransmitted BSSIDs in the set.
|
||||||
|
* @he_operation: HE operation information of the AP we are connected to
|
||||||
*/
|
*/
|
||||||
struct ieee80211_bss_conf {
|
struct ieee80211_bss_conf {
|
||||||
const u8 *bssid;
|
const u8 *bssid;
|
||||||
|
@ -661,6 +662,7 @@ struct ieee80211_bss_conf {
|
||||||
u8 bssid_indicator;
|
u8 bssid_indicator;
|
||||||
bool ema_ap;
|
bool ema_ap;
|
||||||
u8 profile_periodicity;
|
u8 profile_periodicity;
|
||||||
|
struct ieee80211_he_operation he_operation;
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -50,3 +50,18 @@ ieee80211_he_cap_ie_to_sta_he_cap(struct ieee80211_sub_if_data *sdata,
|
||||||
|
|
||||||
he_cap->has_he = true;
|
he_cap->has_he = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
ieee80211_he_op_ie_to_bss_conf(struct ieee80211_vif *vif,
|
||||||
|
const struct ieee80211_he_operation *he_op_ie_elem)
|
||||||
|
{
|
||||||
|
struct ieee80211_he_operation *he_operation =
|
||||||
|
&vif->bss_conf.he_operation;
|
||||||
|
|
||||||
|
if (!he_op_ie_elem) {
|
||||||
|
memset(he_operation, 0, sizeof(*he_operation));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
vif->bss_conf.he_operation = *he_op_ie_elem;
|
||||||
|
}
|
||||||
|
|
|
@ -1873,6 +1873,10 @@ ieee80211_he_cap_ie_to_sta_he_cap(struct ieee80211_sub_if_data *sdata,
|
||||||
const u8 *he_cap_ie, u8 he_cap_len,
|
const u8 *he_cap_ie, u8 he_cap_len,
|
||||||
struct sta_info *sta);
|
struct sta_info *sta);
|
||||||
|
|
||||||
|
void
|
||||||
|
ieee80211_he_op_ie_to_bss_conf(struct ieee80211_vif *vif,
|
||||||
|
const struct ieee80211_he_operation *he_op_ie_elem);
|
||||||
|
|
||||||
/* Spectrum management */
|
/* Spectrum management */
|
||||||
void ieee80211_process_measurement_req(struct ieee80211_sub_if_data *sdata,
|
void ieee80211_process_measurement_req(struct ieee80211_sub_if_data *sdata,
|
||||||
struct ieee80211_mgmt *mgmt,
|
struct ieee80211_mgmt *mgmt,
|
||||||
|
|
|
@ -3381,6 +3381,7 @@ static bool ieee80211_assoc_success(struct ieee80211_sub_if_data *sdata,
|
||||||
if (elems.uora_element)
|
if (elems.uora_element)
|
||||||
bss_conf->uora_ocw_range = elems.uora_element[0];
|
bss_conf->uora_ocw_range = elems.uora_element[0];
|
||||||
|
|
||||||
|
ieee80211_he_op_ie_to_bss_conf(&sdata->vif, elems.he_operation);
|
||||||
/* TODO: OPEN: what happens if BSS color disable is set? */
|
/* TODO: OPEN: what happens if BSS color disable is set? */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue