From b4ef172776f03155391f47c1ffc00f784edf03d2 Mon Sep 17 00:00:00 2001 From: Stefano Avallone Date: Tue, 19 Sep 2023 18:19:20 +0200 Subject: [PATCH] wifi: Generate backoff if needed when receiving AssocResp --- src/wifi/model/sta-wifi-mac.cc | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/wifi/model/sta-wifi-mac.cc b/src/wifi/model/sta-wifi-mac.cc index c77a46e3f..7cc5371fc 100644 --- a/src/wifi/model/sta-wifi-mac.cc +++ b/src/wifi/model/sta-wifi-mac.cc @@ -1450,7 +1450,17 @@ StaWifiMac::ReceiveAssocResp(Ptr mpdu, uint8_t linkId) { if (GetStaLink(link).bssid) { - StartAccessIfNeeded(id); + if (const auto txop = GetTxop()) + { + txop->StartAccessAfterEvent(id, false, true); + } + for (const auto [acIndex, ac] : wifiAcList) + { + if (const auto edca = GetQosTxop(acIndex)) + { + edca->StartAccessAfterEvent(id, false, true); + } + } } }