Currently nl80211 BSSs (struct i802_bss) flink->freq is initialized to
drv->first_bss->flink->freq in wpa_driver_nl80211_if_add(). In case of
single drv model, this results in frequency of the first BSS of the
first radio (say, on the 2.4 GHz band) being set to all the BSSs of the
drv though they can belong to different radios and thereby operating on
different frequencies.
wpa_driver_nl80211_send_mlme() uses bss->flink->freq to send Management
frames to the driver which fails as the driver complains that the TX
frequency doesn't match its operating frequency.
Currently in wpa_driver_nl80211_set_ap(), for ML BSS the above mentioned
default value is overridden whenever beacon is set. Fix this by
overriding link frequency also for non-ML BSSs.
Signed-off-by: Rameshkumar Sundaram <quic_ramess@quicinc.com>
nla_put(msg, NL80211_ATTR_SSID, params->ssid_len, params->ssid))
goto fail;
+ if (params->freq)
+ nl80211_link_set_freq(bss,
+ params->mld_ap ? params->mld_link_id :
+ NL80211_DRV_LINK_ID_NA,
+ params->freq->freq);
+
if (params->mld_ap) {
wpa_printf(MSG_DEBUG, "nl80211: link_id=%u",
params->mld_link_id);
if (nla_put_u8(msg, NL80211_ATTR_MLO_LINK_ID,
params->mld_link_id))
goto fail;
-
- if (params->freq)
- nl80211_link_set_freq(bss, params->mld_link_id,
- params->freq->freq);
}
if (params->proberesp && params->proberesp_len) {