summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZhao Li <enderaoelyther@gmail.com>2026-07-30 01:36:07 +0800
committerJohannes Berg <johannes.berg@intel.com>2026-08-02 18:15:41 +0200
commita28fcce6ee74be8a4526e6cfa16dc7786d62a784 (patch)
treea392ad2bc487b443faac3e47457ff3a449df512a
parentcc3e7fdbf7c0fe8a78195e53d322126546b6212b (diff)
downloadlinux-next-a28fcce6ee74be8a4526e6cfa16dc7786d62a784.tar.gz
linux-next-a28fcce6ee74be8a4526e6cfa16dc7786d62a784.zip
wifi: mac80211: send TWT teardown to peer after setup TX failure
When an AP's TWT Setup response is not acknowledged, ieee80211_s1g_tx_twt_setup_fail() asks the driver to tear down the local agreement and sends a TWT teardown action as the peer notification. It uses the response SA as the destination, but ieee80211_s1g_send_twt_setup() built that response with SA set to the AP's address. The teardown is therefore queued with DA, SA and BSSID all set to the AP address and never reaches the station. The in-tree driver callbacks update local hardware state and emit no action frame. The station receives no notification that mac80211 asked the driver to remove the agreement and can keep following the TWT schedule, leaving the peers' power-save state desynchronized. Address the teardown to the response DA, the station to which the failed response was sent. This also matches the station lookup the transmit status path already performs on the same frame. Fixes: f5a4c24e689f ("mac80211: introduce individual TWT support in AP mode") Assisted-by: Codex:gpt-5.6-sol Assisted-by: Kimi:K3 Signed-off-by: Zhao Li <enderaoelyther@gmail.com> Link: https://patch.msgid.link/20260729173607.13340-1-enderaoelyther@gmail.com Signed-off-by: Johannes Berg <johannes.berg@intel.com>
-rw-r--r--net/mac80211/s1g.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/mac80211/s1g.c b/net/mac80211/s1g.c
index 5af4a0c6c642..825fcf3f909b 100644
--- a/net/mac80211/s1g.c
+++ b/net/mac80211/s1g.c
@@ -143,7 +143,7 @@ ieee80211_s1g_tx_twt_setup_fail(struct ieee80211_sub_if_data *sdata,
drv_twt_teardown_request(sdata->local, sdata, &sta->sta, flowid);
- ieee80211_s1g_send_twt_teardown(sdata, mgmt->sa, sdata->vif.addr,
+ ieee80211_s1g_send_twt_teardown(sdata, mgmt->da, sdata->vif.addr,
flowid);
}