wifi: Basic Block Ack agreements are not supported

This commit is contained in:
Stefano Avallone
2024-05-19 10:56:04 +02:00
parent 5a29c3d1b5
commit 05cb5ea88d
3 changed files with 10 additions and 18 deletions

View File

@@ -99,11 +99,11 @@ BlockAckManager::GetAgreementAsRecipient(const Mac48Address& originator, uint8_t
void
BlockAckManager::CreateOriginatorAgreement(const MgtAddBaRequestHeader& reqHdr,
const Mac48Address& recipient,
bool htSupported)
const Mac48Address& recipient)
{
NS_LOG_FUNCTION(this << reqHdr << recipient << htSupported);
const uint8_t tid = reqHdr.GetTid();
NS_LOG_FUNCTION(this << reqHdr << recipient);
const auto tid = reqHdr.GetTid();
OriginatorBlockAckAgreement agreement(recipient, tid);
agreement.SetStartingSequence(reqHdr.GetStartingSequence());
/* For now we assume that originator doesn't use this field. Use of this field
@@ -111,7 +111,7 @@ BlockAckManager::CreateOriginatorAgreement(const MgtAddBaRequestHeader& reqHdr,
agreement.SetBufferSize(reqHdr.GetBufferSize());
agreement.SetTimeout(reqHdr.GetTimeout());
agreement.SetAmsduSupport(reqHdr.IsAmsduSupported());
agreement.SetHtSupported(htSupported);
agreement.SetHtSupported(true);
if (reqHdr.IsImmediateBlockAck())
{
agreement.SetImmediateBlockAck();
@@ -195,11 +195,10 @@ void
BlockAckManager::CreateRecipientAgreement(const MgtAddBaResponseHeader& respHdr,
const Mac48Address& originator,
uint16_t startingSeq,
bool htSupported,
Ptr<MacRxMiddle> rxMiddle)
{
NS_LOG_FUNCTION(this << respHdr << originator << startingSeq << htSupported << rxMiddle);
uint8_t tid = respHdr.GetTid();
NS_LOG_FUNCTION(this << respHdr << originator << startingSeq << rxMiddle);
const auto tid = respHdr.GetTid();
RecipientBlockAckAgreement agreement(originator,
respHdr.IsAmsduSupported(),
@@ -207,7 +206,8 @@ BlockAckManager::CreateRecipientAgreement(const MgtAddBaResponseHeader& respHdr,
respHdr.GetBufferSize(),
respHdr.GetTimeout(),
startingSeq,
htSupported);
true);
agreement.SetMacRxMiddle(rxMiddle);
if (respHdr.IsImmediateBlockAck())
{

View File

@@ -106,14 +106,12 @@ class BlockAckManager : public Object
/**
* \param reqHdr Relative Add block ack request (action frame).
* \param recipient Address of peer station involved in block ack mechanism.
* \param htSupported Whether both originator and recipient support HT
*
* Creates a new originator block ack agreement in pending state. When a ADDBA response
* with a successful status code is received, the relative agreement becomes established.
*/
void CreateOriginatorAgreement(const MgtAddBaRequestHeader& reqHdr,
const Mac48Address& recipient,
bool htSupported = true);
const Mac48Address& recipient);
/**
* \param recipient Address of peer station involved in block ack mechanism.
* \param tid traffic ID of transmitted packet.
@@ -140,7 +138,6 @@ class BlockAckManager : public Object
* mechanism.
* \param startingSeq Sequence number of the first MPDU of all
* packets for which block ack was negotiated.
* \param htSupported whether HT support is enabled
* \param rxMiddle the MAC RX Middle on this station
*
* This function is typically invoked only by ns3::WifiMac
@@ -153,7 +150,6 @@ class BlockAckManager : public Object
void CreateRecipientAgreement(const MgtAddBaResponseHeader& respHdr,
const Mac48Address& originator,
uint16_t startingSeq,
bool htSupported,
Ptr<MacRxMiddle> rxMiddle);
/**
* Destroy a recipient Block Ack agreement.

View File

@@ -256,13 +256,9 @@ HtFrameExchangeManager::SendAddBaResponse(const MgtAddBaRequestHeader* reqHdr,
{
originator = *originatorMld;
}
bool htSupported = m_mac->GetDevice()->GetHtConfiguration() &&
(GetWifiRemoteStationManager()->GetHtSupported(originator) ||
GetWifiRemoteStationManager()->GetStationHe6GhzCapabilities(originator));
GetBaManager(tid)->CreateRecipientAgreement(respHdr,
originator,
reqHdr->GetStartingSequence(),
htSupported,
m_rxMiddle);
auto agreement = GetBaManager(tid)->GetAgreementAsRecipient(originator, tid);