wifi: Limit TXOP bandwidth upon every transmission

This commit is contained in:
Stefano Avallone
2023-07-09 11:02:43 +02:00
committed by Stefano Avallone
parent 2e3dbaea4e
commit 61a6921a89
3 changed files with 4 additions and 0 deletions

View File

@@ -525,6 +525,7 @@ FrameExchangeManager::ForwardMpduDown(Ptr<WifiMpdu> mpdu, WifiTxVector& txVector
auto psdu = Create<WifiPsdu>(mpdu, false);
FinalizeMacHeader(psdu);
m_allowedWidth = std::min(m_allowedWidth, txVector.GetChannelWidth());
m_phy->Send(psdu, txVector);
}

View File

@@ -918,6 +918,8 @@ HeFrameExchangeManager::ForwardPsduMapDown(WifiConstPsduMap psduMap, WifiTxVecto
FinalizeMacHeader(psdu);
NotifyTxToEdca(psdu);
}
m_allowedWidth = std::min(m_allowedWidth, txVector.GetChannelWidth());
if (psduMap.size() > 1 || psduMap.begin()->second->IsAggregate() ||
psduMap.begin()->second->IsSingle())
{

View File

@@ -1131,6 +1131,7 @@ HtFrameExchangeManager::ForwardPsduDown(Ptr<const WifiPsdu> psdu, WifiTxVector&
NS_LOG_DEBUG("Transmitting a PSDU: " << *psdu << " TXVECTOR: " << txVector);
FinalizeMacHeader(psdu);
NotifyTxToEdca(psdu);
m_allowedWidth = std::min(m_allowedWidth, txVector.GetChannelWidth());
if (psdu->IsAggregate())
{