developer | 05f3b2b | 2024-08-19 19:17:34 +0800 | [diff] [blame^] | 1 | From 1e54da693f94da15372d3e397c362a20fb5b1af1 Mon Sep 17 00:00:00 2001 |
| 2 | From: Michael-CY Lee <michael-cy.lee@mediatek.com> |
| 3 | Date: Mon, 6 May 2024 18:14:35 +0800 |
| 4 | Subject: [PATCH 084/126] mtk: hostapd: prevent responding to mgmt while AP MLD |
| 5 | is initializing |
| 6 | |
| 7 | While AP MLD is initializing, it might include incomplete information |
| 8 | inside its response of mgmt. |
| 9 | Therefore this commit prevents responding to mgmt while AP MLD is initializing |
| 10 | |
| 11 | Signed-off-by: Michael-CY Lee <michael-cy.lee@mediatek.com> |
| 12 | --- |
| 13 | src/ap/ieee802_11.c | 7 +++++++ |
| 14 | 1 file changed, 7 insertions(+) |
| 15 | |
| 16 | diff --git a/src/ap/ieee802_11.c b/src/ap/ieee802_11.c |
| 17 | index 37a2c5ab8..1365bc822 100644 |
| 18 | --- a/src/ap/ieee802_11.c |
| 19 | +++ b/src/ap/ieee802_11.c |
| 20 | @@ -6305,6 +6305,13 @@ int ieee802_11_mgmt(struct hostapd_data *hapd, const u8 *buf, size_t len, |
| 21 | if (len < 24) |
| 22 | return 0; |
| 23 | |
| 24 | +#ifdef CONFIG_IEEE80211BE |
| 25 | + if (hapd->conf->mld_ap && !hapd->mld->started) { |
| 26 | + wpa_printf(MSG_DEBUG, "MGMT: Drop the frame - MLD not ready"); |
| 27 | + return 1; |
| 28 | + } |
| 29 | +#endif /* CONFIG_IEEE80211BE */ |
| 30 | + |
| 31 | if (fi && fi->freq) |
| 32 | freq = fi->freq; |
| 33 | else |
| 34 | -- |
| 35 | 2.18.0 |
| 36 | |