From: Lorenzo Bianconi Date: Thu, 24 Feb 2022 11:55:00 +0000 (+0100) Subject: mac80211: update bssid_indicator in ieee80211_assign_beacon X-Git-Tag: v6.1-rc5~1746^2~44^2~24 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=dde78aa520155316f31fca1b0f4dfcb779151799;p=platform%2Fkernel%2Flinux-starfive.git mac80211: update bssid_indicator in ieee80211_assign_beacon Update bssid_indicator in ieee80211_bss_conf according to the number of bssid in the set. Signed-off-by: Lorenzo Bianconi Link: https://lore.kernel.org/r/f92317e002fca9933f05a445fcefb4f53291d601.1645702516.git.lorenzo@kernel.org Signed-off-by: Johannes Berg --- diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index 072eccb..ba75253 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c @@ -1071,6 +1071,9 @@ static int ieee80211_assign_beacon(struct ieee80211_sub_if_data *sdata, new->mbssid_ies = (void *)pos; pos += struct_size(new->mbssid_ies, elem, mbssid->cnt); ieee80211_copy_mbssid_beacon(pos, new->mbssid_ies, mbssid); + /* update bssid_indicator */ + sdata->vif.bss_conf.bssid_indicator = + ilog2(__roundup_pow_of_two(mbssid->cnt + 1)); } if (csa) {