blob: e8adbc04097888814f2f121476c630004db8397f [file] [log] [blame]
From ec1fdb73853632e9a9003f8c59620d1e12f6d2d0 Mon Sep 17 00:00:00 2001
From: Sriram R <quic_srirrama@quicinc.com>
Date: Thu, 28 Mar 2024 23:46:35 +0530
Subject: [PATCH 005/104] hostapd: MLO: handle auth/assoc on link address
Modify authentication and association frames to be always sent with link
address as A1 and A3 for ease of Tx status handling.
Signed-off-by: Sriram R <quic_srirrama@quicinc.com>
Signed-off-by: Aditya Kumar Singh <quic_adisi@quicinc.com>
---
src/ap/ieee802_11.c | 25 ++-----------------------
1 file changed, 2 insertions(+), 23 deletions(-)
diff --git a/src/ap/ieee802_11.c b/src/ap/ieee802_11.c
index 5a3132de4..b20300bab 100644
--- a/src/ap/ieee802_11.c
+++ b/src/ap/ieee802_11.c
@@ -416,14 +416,7 @@ static int send_auth_reply(struct hostapd_data *hapd, struct sta_info *sta,
struct wpabuf *ml_resp = NULL;
#ifdef CONFIG_IEEE80211BE
- /*
- * Once a non-AP MLD is added to the driver, the addressing should use
- * the MLD MAC address. Thus, use the MLD address instead of translating
- * the addresses.
- */
if (ap_sta_is_mld(hapd, sta)) {
- sa = hapd->mld->mld_addr;
-
ml_resp = hostapd_ml_auth_resp(hapd);
if (!ml_resp)
return -1;
@@ -444,7 +437,7 @@ static int send_auth_reply(struct hostapd_data *hapd, struct sta_info *sta,
WLAN_FC_STYPE_AUTH);
os_memcpy(reply->da, dst, ETH_ALEN);
os_memcpy(reply->sa, sa, ETH_ALEN);
- os_memcpy(reply->bssid, bssid, ETH_ALEN);
+ os_memcpy(reply->bssid, sa, ETH_ALEN);
reply->u.auth.auth_alg = host_to_le16(auth_alg);
reply->u.auth.auth_transaction = host_to_le16(auth_transaction);
@@ -3265,14 +3258,9 @@ static void handle_auth(struct hostapd_data *hapd,
bssid = mgmt->bssid;
#ifdef CONFIG_IEEE80211BE
- /*
- * Once a non-AP MLD is added to the driver, the addressing should use
- * the MLD MAC address. It is the responsibility of the driver to
- * handle the translations.
- */
if (ap_sta_is_mld(hapd, sta)) {
dst = sta->addr;
- bssid = hapd->mld->mld_addr;
+ bssid = hapd->own_addr;
}
#endif /* CONFIG_IEEE80211BE */
@@ -4823,15 +4811,6 @@ static u16 send_assoc_resp(struct hostapd_data *hapd, struct sta_info *sta,
(reassoc ? WLAN_FC_STYPE_REASSOC_RESP :
WLAN_FC_STYPE_ASSOC_RESP));
-#ifdef CONFIG_IEEE80211BE
- /*
- * Once a non-AP MLD is added to the driver, the addressing should use
- * MLD MAC address.
- */
- if (ap_sta_is_mld(hapd, sta) && allow_mld_addr_trans)
- sa = hapd->mld->mld_addr;
-#endif /* CONFIG_IEEE80211BE */
-
os_memcpy(reply->da, addr, ETH_ALEN);
os_memcpy(reply->sa, sa, ETH_ALEN);
os_memcpy(reply->bssid, sa, ETH_ALEN);
--
2.39.2