Skip to content

Commit c434b2b

Browse files
committed
wifi: cfg80211: fix assoc response warning on failed links
The warning here shouldn't be done before we even set the bss field (or should've used the input data). Move the assignment before the warning to fix it. We noticed this now because of Wen's bugfix, where the bug fixed there had previously hidden this other bug. Fixes: 53ad07e ("wifi: cfg80211: support reporting failed links") Signed-off-by: Johannes Berg <[email protected]>
1 parent 3e3929e commit c434b2b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

net/wireless/mlme.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,10 +43,11 @@ void cfg80211_rx_assoc_resp(struct net_device *dev,
4343

4444
for (link_id = 0; link_id < ARRAY_SIZE(data->links); link_id++) {
4545
cr.links[link_id].status = data->links[link_id].status;
46+
cr.links[link_id].bss = data->links[link_id].bss;
47+
4648
WARN_ON_ONCE(cr.links[link_id].status != WLAN_STATUS_SUCCESS &&
4749
(!cr.ap_mld_addr || !cr.links[link_id].bss));
4850

49-
cr.links[link_id].bss = data->links[link_id].bss;
5051
if (!cr.links[link_id].bss)
5152
continue;
5253
cr.links[link_id].bssid = data->links[link_id].bss->bssid;

0 commit comments

Comments
 (0)