developer | 66e89bc | 2024-04-23 14:50:01 +0800 | [diff] [blame] | 1 | From 8c4eb9b740a9f2ae57e048edbbc4aad1d62734f2 Mon Sep 17 00:00:00 2001 |
| 2 | From: Michael-CY Lee <michael-cy.lee@mediatek.com> |
| 3 | Date: Tue, 27 Feb 2024 15:04:35 +0800 |
| 4 | Subject: [PATCH 094/104] mtk: hostapd: AP MLD: specify link id for unicast |
| 5 | DEAUTH |
| 6 | |
| 7 | When deauthenticating the STA, hostapd should specifies the setup link |
| 8 | of the target STA so that the TX status of the DEAUTH can be forwarded |
| 9 | to the correct link (BSS). |
| 10 | |
| 11 | (The original gerrit somehow disappears, so I commit it again) |
| 12 | (https://gerrit.mediatek.inc/c/gateway/WiFi7/mac80211/hostapd/+/8715613) |
| 13 | |
developer | 66e89bc | 2024-04-23 14:50:01 +0800 | [diff] [blame] | 14 | Signed-off-by: Michael-CY Lee <michael-cy.lee@mediatek.com> |
developer | 66e89bc | 2024-04-23 14:50:01 +0800 | [diff] [blame] | 15 | --- |
| 16 | src/ap/ap_drv_ops.c | 6 +++++- |
| 17 | 1 file changed, 5 insertions(+), 1 deletion(-) |
| 18 | |
| 19 | diff --git a/src/ap/ap_drv_ops.c b/src/ap/ap_drv_ops.c |
| 20 | index 9357ce7b6..2c535f24a 100644 |
| 21 | --- a/src/ap/ap_drv_ops.c |
| 22 | +++ b/src/ap/ap_drv_ops.c |
| 23 | @@ -867,7 +867,11 @@ int hostapd_drv_sta_deauth(struct hostapd_data *hapd, |
| 24 | if (hapd->conf->mld_ap) { |
| 25 | struct sta_info *sta = ap_get_sta(hapd, addr); |
| 26 | |
| 27 | - link_id = hapd->mld_link_id; |
| 28 | + if (sta) |
| 29 | + link_id = sta->mld_assoc_link_id; |
| 30 | + else |
| 31 | + link_id = hapd->mld_link_id; |
| 32 | + |
| 33 | if (ap_sta_is_mld(hapd, sta)) |
| 34 | own_addr = hapd->mld->mld_addr; |
| 35 | } |
| 36 | -- |
| 37 | 2.39.2 |
| 38 | |