]> www.infradead.org Git - users/dwmw2/linux.git/commit
wifi: mac80211: re-order assigning channel in activate links
authorAditya Kumar Singh <quic_adisi@quicinc.com>
Tue, 1 Oct 2024 08:50:34 +0000 (14:20 +0530)
committerJohannes Berg <johannes.berg@intel.com>
Wed, 23 Oct 2024 15:26:14 +0000 (17:26 +0200)
commit188a1bf894323bf3a90361676da8364c82ce6d32
treef4280da17f26d43ddb20a310b3785db319b6a84b
parent31cb94f71c1ba126b9c684c5882cbf5032d0d1bc
wifi: mac80211: re-order assigning channel in activate links

The current flow in _ieee80211_set_active_links() does not align with the
operational requirements of drivers that groups multiple hardware
under a single wiphy. These drivers (e.g ath12k) rely on channel
assignment to determine the appropriate hardware for each link. Without
this, the drivers cannot correctly establish the link interface.

Currently in _ieee80211_set_active_links(), after calling
drv_change_vif_links() on the driver, the state of all connected stations
is updated via drv_change_sta_links(). This is followed by handling keys
in the links, and finally, assigning the channel to the links.
Consequently, drv_change_sta_links() prompts drivers to create the station
entry at their level and within their firmware. However, since channels
have not yet been assigned to links at this stage, drivers have not
created the necessary link interface for establishing link stations,
leading to failures in activating the links.

Therefore, re-order the logic so that after drv_change_vif_links() and
removing the old links, channels are assigned to newly added links.
Following this, the flow proceeds to station handling.

Signed-off-by: Aditya Kumar Singh <quic_adisi@quicinc.com>
Link: https://patch.msgid.link/20241001085034.2745669-1-quic_adisi@quicinc.com
[Johannes: fix iwlwifi to deal with the changes]
Reviewed-by: Miriam Rachel Korenblit <miriam.rachel.korenblit@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/intel/iwlwifi/mvm/mld-mac80211.c
drivers/net/wireless/intel/iwlwifi/mvm/mld-sta.c
net/mac80211/link.c