From ea5d4c8c813775dca16b064b490cba2ac5f27009 Mon Sep 17 00:00:00 2001
From: Rediet
Date: Fri, 15 Jan 2021 19:13:13 +0100
Subject: [PATCH] wifi: Remove HT Greenfield support
---
CHANGES.html | 1 +
RELEASE_NOTES | 1 +
examples/wireless/wifi-mixed-network.cc | 218 +++---------------
src/wifi/doc/source/wifi-user.rst | 4 -
.../examples/wifi-test-interference-helper.cc | 4 -
src/wifi/helper/wifi-helper.cc | 4 -
src/wifi/model/aarf-wifi-manager.cc | 4 +-
src/wifi/model/aarfcd-wifi-manager.cc | 4 +-
src/wifi/model/amrr-wifi-manager.cc | 4 +-
src/wifi/model/ap-wifi-mac.cc | 18 +-
src/wifi/model/ap-wifi-mac.h | 6 -
src/wifi/model/aparf-wifi-manager.cc | 4 +-
src/wifi/model/arf-wifi-manager.cc | 4 +-
src/wifi/model/cara-wifi-manager.cc | 4 +-
src/wifi/model/constant-rate-wifi-manager.cc | 4 +-
src/wifi/model/ht-capabilities.cc | 13 --
src/wifi/model/ht-capabilities.h | 12 -
src/wifi/model/ht-configuration.cc | 19 --
src/wifi/model/ht-configuration.h | 15 --
src/wifi/model/ht-operation.cc | 2 +-
src/wifi/model/ht-phy.cc | 16 +-
src/wifi/model/ht-phy.h | 4 +-
src/wifi/model/ideal-wifi-manager.cc | 4 +-
src/wifi/model/minstrel-ht-wifi-manager.cc | 4 +-
src/wifi/model/minstrel-wifi-manager.cc | 4 +-
src/wifi/model/onoe-wifi-manager.cc | 4 +-
src/wifi/model/parf-wifi-manager.cc | 4 +-
src/wifi/model/regular-wifi-mac.cc | 4 +-
src/wifi/model/rraa-wifi-manager.cc | 4 +-
src/wifi/model/rrpaa-wifi-manager.cc | 4 +-
src/wifi/model/sta-wifi-mac.cc | 18 --
src/wifi/model/wifi-phy-common.h | 3 -
src/wifi/model/wifi-remote-station-manager.cc | 72 +-----
src/wifi/model/wifi-remote-station-manager.h | 46 ----
src/wifi/model/wifi-utils.cc | 38 ++-
src/wifi/model/wifi-utils.h | 3 +-
src/wifi/test/tx-duration-test.cc | 40 +---
37 files changed, 87 insertions(+), 530 deletions(-)
diff --git a/CHANGES.html b/CHANGES.html
index 9631581b3..02b1fe515 100644
--- a/CHANGES.html
+++ b/CHANGES.html
@@ -68,6 +68,7 @@ us a note on ns-developers mailing list.
- The default TCP congestion control has been changed from NewReno to CUBIC.
- The 802.11a-like PHY configuration known as Holland has been removed from the wifi module. It was added in the 2005 timeframe for Wi-Fi rate control research but hasn't been used for quite some time.
+- Support for Greenfield mode (aka HT_GF) has been dropped from wifi.
diff --git a/RELEASE_NOTES b/RELEASE_NOTES
index fdc204eb9..4a7310d71 100644
--- a/RELEASE_NOTES
+++ b/RELEASE_NOTES
@@ -28,6 +28,7 @@ New user-visible features
-------------------------
- (sixlowpan) Added support for stateful (i.e., context-based) RFC6282 compression.
- (wifi) Holland PHY configuration has been removed from the model
+- (wifi) HT Greenfield (HT_GF) preamble support has been removed from the model
Bugs fixed
----------
diff --git a/examples/wireless/wifi-mixed-network.cc b/examples/wireless/wifi-mixed-network.cc
index 767d18199..498843931 100644
--- a/examples/wireless/wifi-mixed-network.cc
+++ b/examples/wireless/wifi-mixed-network.cc
@@ -45,9 +45,7 @@
// - whether short PPDU format is supported by the 802.11b station;
// - whether short slot time is supported by both the 802.11g station and the AP.
//
-// The example then compares HT only and mixed HT/non-HT cases with various configurations depending on the following parameters:
-// - whether HT GF is supported by the AP;
-// - whether HT GF is supported by all HT stations;
+// The example then compares HT only and mixed HT/non-HT cases.
//
// The output results show that the presence of an 802.11b station strongly affects 802.11g performance.
// Protection mechanisms ensure that the NAV value of 802.11b stations is set correctly in case of 802.11g transmissions.
@@ -56,8 +54,6 @@
// mechanism for access points). Since short slot time is disabled once an 802.11b station enters the network, benefits from
// short slot time are only observed in a g only configuration.
//
-// HT and mixed-HT results show that HT GF permits to slightly increase performance when all HT stations support GF mode
-//
// The user can also select the payload size and can choose either an UDP or a TCP connection.
// Example: ./waf --run "wifi-mixed-network --isUdp=1"
@@ -73,15 +69,12 @@ struct Parameters
bool enableShortSlotTime;
bool enableShortPhyPreamble;
WifiStandard apType;
- bool apSupportsGreenfield;
uint32_t nWifiB;
bool bHasTraffic;
uint32_t nWifiG;
bool gHasTraffic;
- uint32_t nWifiNNonGreenfield;
- bool nNonGreenfieldHasTraffic;
- uint32_t nWifiNGreenfield;
- bool nGreenfieldHasTraffic;
+ uint32_t nWifiN;
+ bool nHasTraffic;
bool isUdp;
uint32_t payloadSize;
double simulationTime;
@@ -117,15 +110,12 @@ Experiment::Run (Parameters params)
<< "\n\t enableShortSlotTime=" << params.enableShortSlotTime
<< "\n\t enableShortPhyPreamble=" << params.enableShortPhyPreamble
<< "\n\t apType=" << apTypeString
- << "\n\t apSupportsGreenfield=" << params.apSupportsGreenfield
<< "\n\t nWifiB=" << params.nWifiB
<< "\n\t bHasTraffic=" << params.bHasTraffic
<< "\n\t nWifiG=" << params.nWifiG
<< "\n\t gHasTraffic=" << params.gHasTraffic
- << "\n\t nWifiNNonGreenfield=" << params.nWifiNNonGreenfield
- << "\n\t nNonGreenfieldHasTraffic=" << params.nNonGreenfieldHasTraffic
- << "\n\t nWifiNGreenfield=" << params.nWifiNGreenfield
- << "\n\t nGreenfieldHasTraffic=" << params.nGreenfieldHasTraffic
+ << "\n\t nWifiN=" << params.nWifiN
+ << "\n\t nHasTraffic=" << params.nHasTraffic
<< std::endl;
Config::SetDefault ("ns3::WifiRemoteStationManager::ErpProtectionMode", StringValue (params.erpProtectionMode));
@@ -133,8 +123,7 @@ Experiment::Run (Parameters params)
double throughput = 0;
uint32_t nWifiB = params.nWifiB;
uint32_t nWifiG = params.nWifiG;
- uint32_t nWifiNNGF = params.nWifiNNonGreenfield;
- uint32_t nWifiNGF = params.nWifiNGreenfield;
+ uint32_t nWifiN = params.nWifiN;
double simulationTime = params.simulationTime;
uint32_t payloadSize = params.payloadSize;
@@ -142,10 +131,8 @@ Experiment::Run (Parameters params)
wifiBStaNodes.Create (nWifiB);
NodeContainer wifiGStaNodes;
wifiGStaNodes.Create (nWifiG);
- NodeContainer wifiNNGFStaNodes;
- wifiNNGFStaNodes.Create (nWifiNNGF);
- NodeContainer wifiNGFStaNodes;
- wifiNGFStaNodes.Create (nWifiNGF);
+ NodeContainer wifiNStaNodes;
+ wifiNStaNodes.Create (nWifiN);
NodeContainer wifiApNode;
wifiApNode.Create (1);
@@ -182,13 +169,12 @@ Experiment::Run (Parameters params)
// 802.11b/g/n STA
wifi.SetStandard (WIFI_STANDARD_80211n_2_4GHZ);
- NetDeviceContainer nNGFStaDevice, nGFStaDevice;
+ NetDeviceContainer nStaDevice;
mac.SetType ("ns3::StaWifiMac",
"Ssid", SsidValue (ssid),
"BE_BlockAckThreshold", UintegerValue (2),
"ShortSlotTimeSupported", BooleanValue (params.enableShortSlotTime));
- nNGFStaDevice = wifi.Install (phy, mac, wifiNNGFStaNodes);
- nGFStaDevice = wifi.Install (phy, mac, wifiNGFStaNodes);
+ nStaDevice = wifi.Install (phy, mac, wifiNStaNodes);
// AP
NetDeviceContainer apDevice;
@@ -206,31 +192,16 @@ Experiment::Run (Parameters params)
{
Ptr dev = wifiApNode.Get (0)->GetDevice (0);
Ptr wifi_dev = DynamicCast (dev);
- Ptr htConfiguration = wifi_dev->GetHtConfiguration ();
- htConfiguration->SetGreenfieldSupported (params.apSupportsGreenfield);
Ptr wifi_mac = wifi_dev->GetMac ();
PointerValue ptr;
wifi_mac->GetAttribute ("BE_Txop", ptr);
Ptr edca = ptr.Get ();
edca->SetTxopLimit (MicroSeconds (3008));
}
- if (nWifiNNGF > 0)
+ if (nWifiN > 0)
{
- Ptr dev = wifiNNGFStaNodes.Get (0)->GetDevice (0);
+ Ptr dev = wifiNStaNodes.Get (0)->GetDevice (0);
Ptr wifi_dev = DynamicCast (dev);
- Ptr htConfiguration = wifi_dev->GetHtConfiguration ();
- Ptr wifi_mac = wifi_dev->GetMac ();
- PointerValue ptr;
- wifi_mac->GetAttribute ("BE_Txop", ptr);
- Ptr edca = ptr.Get ();
- edca->SetTxopLimit (MicroSeconds (3008));
- }
- if (nWifiNGF > 0)
- {
- Ptr dev = wifiNGFStaNodes.Get (0)->GetDevice (0);
- Ptr wifi_dev = DynamicCast (dev);
- Ptr htConfiguration = wifi_dev->GetHtConfiguration ();
- htConfiguration->SetGreenfieldSupported (true);
Ptr wifi_mac = wifi_dev->GetMac ();
PointerValue ptr;
wifi_mac->GetAttribute ("BE_Txop", ptr);
@@ -253,11 +224,7 @@ Experiment::Run (Parameters params)
{
positionAlloc->Add (Vector (0.0, 5.0, 0.0));
}
- for (uint32_t i = 0; i < nWifiNNGF; i++)
- {
- positionAlloc->Add (Vector (0.0, 0.0, 5.0));
- }
- for (uint32_t i = 0; i < nWifiNGF; i++)
+ for (uint32_t i = 0; i < nWifiN; i++)
{
positionAlloc->Add (Vector (0.0, 0.0, 5.0));
}
@@ -267,16 +234,14 @@ Experiment::Run (Parameters params)
mobility.Install (wifiApNode);
mobility.Install (wifiBStaNodes);
mobility.Install (wifiGStaNodes);
- mobility.Install (wifiNNGFStaNodes);
- mobility.Install (wifiNGFStaNodes);
+ mobility.Install (wifiNStaNodes);
// Internet stack
InternetStackHelper stack;
stack.Install (wifiApNode);
stack.Install (wifiBStaNodes);
stack.Install (wifiGStaNodes);
- stack.Install (wifiNNGFStaNodes);
- stack.Install (wifiNGFStaNodes);
+ stack.Install (wifiNStaNodes);
Ipv4AddressHelper address;
address.SetBase ("192.168.1.0", "255.255.255.0");
@@ -284,10 +249,8 @@ Experiment::Run (Parameters params)
bStaInterface = address.Assign (bStaDevice);
Ipv4InterfaceContainer gStaInterface;
gStaInterface = address.Assign (gStaDevice);
- Ipv4InterfaceContainer nNGFStaInterface;
- nNGFStaInterface = address.Assign (nNGFStaDevice);
- Ipv4InterfaceContainer nGFStaInterface;
- nGFStaInterface = address.Assign (nGFStaDevice);
+ Ipv4InterfaceContainer nStaInterface;
+ nStaInterface = address.Assign (nStaDevice);
Ipv4InterfaceContainer ApInterface;
ApInterface = address.Assign (apDevice);
@@ -314,13 +277,9 @@ Experiment::Run (Parameters params)
{
clientApps.Add (client.Install (wifiGStaNodes));
}
- if (params.nNonGreenfieldHasTraffic)
+ if (params.nHasTraffic)
{
- clientApps.Add (client.Install (wifiNNGFStaNodes));
- }
- if (params.nGreenfieldHasTraffic)
- {
- clientApps.Add (client.Install (wifiNGFStaNodes));
+ clientApps.Add (client.Install (wifiNStaNodes));
}
clientApps.Start (Seconds (1.0));
clientApps.Stop (Seconds (simulationTime + 1));
@@ -359,13 +318,9 @@ Experiment::Run (Parameters params)
{
clientApps.Add (onoff.Install (wifiGStaNodes));
}
- if (params.nNonGreenfieldHasTraffic)
+ if (params.nHasTraffic)
{
- clientApps.Add (onoff.Install (wifiNNGFStaNodes));
- }
- if (params.nGreenfieldHasTraffic)
- {
- clientApps.Add (onoff.Install (wifiNGFStaNodes));
+ clientApps.Add (onoff.Install (wifiNStaNodes));
}
clientApps.Start (Seconds (1.0));
clientApps.Stop (Seconds (simulationTime + 1));
@@ -389,15 +344,12 @@ int main (int argc, char *argv[])
params.enableShortSlotTime = false;
params.enableShortPhyPreamble = false;
params.apType = WIFI_STANDARD_80211g;
- params.apSupportsGreenfield = false;
params.nWifiB = 0;
params.bHasTraffic = false;
params.nWifiG = 1;
params.gHasTraffic = true;
- params.nWifiNNonGreenfield = 0;
- params.nNonGreenfieldHasTraffic = false;
- params.nWifiNGreenfield = 0;
- params.nGreenfieldHasTraffic = false;
+ params.nWifiN = 0;
+ params.nHasTraffic = false;
params.isUdp = true;
params.payloadSize = 1472; //bytes
params.simulationTime = 10; //seconds
@@ -516,130 +468,17 @@ int main (int argc, char *argv[])
}
std::cout << "Throughput: " << throughput << " Mbit/s \n" << std::endl;
- params.testName = "HT GF not supported";
- params.enableErpProtection = false;
- params.enableShortSlotTime = false;
- params.enableShortPhyPreamble = false;
- params.apType = WIFI_STANDARD_80211n_2_4GHZ;
- params.apSupportsGreenfield = false;
- params.nWifiB = 0;
- params.bHasTraffic = false;
- params.nWifiG = 0;
- params.gHasTraffic = false;
- params.nWifiNNonGreenfield = 1;
- params.nNonGreenfieldHasTraffic = true;
- params.nWifiNGreenfield = 0;
- params.nGreenfieldHasTraffic = false;
- throughput = experiment.Run (params);
- if (verifyResults && (throughput < 43 || throughput > 44))
- {
- NS_LOG_ERROR ("Obtained throughput " << throughput << " is not in the expected boundaries!");
- exit (1);
- }
- std::cout << "Throughput: " << throughput << " Mbit/s \n" << std::endl;
-
- params.testName = "HT only with GF used";
- params.enableErpProtection = false;
- params.enableShortSlotTime = false;
- params.enableShortPhyPreamble = false;
- params.apType = WIFI_STANDARD_80211n_2_4GHZ;
- params.apSupportsGreenfield = true;
- params.nWifiB = 0;
- params.bHasTraffic = false;
- params.nWifiG = 0;
- params.gHasTraffic = false;
- params.nWifiNNonGreenfield = 0;
- params.nNonGreenfieldHasTraffic = false;
- params.nWifiNGreenfield = 1;
- params.nGreenfieldHasTraffic = true;
- throughput = experiment.Run (params);
- if (verifyResults && (throughput < 44 || throughput > 45))
- {
- NS_LOG_ERROR ("Obtained throughput " << throughput << " is not in the expected boundaries!");
- exit (1);
- }
- std::cout << "Throughput: " << throughput << " Mbit/s \n" << std::endl;
-
- params.testName = "HT only with GF allowed but disabled by protection";
- params.enableErpProtection = false;
- params.enableShortSlotTime = false;
- params.enableShortPhyPreamble = false;
- params.apType = WIFI_STANDARD_80211n_2_4GHZ;
- params.apSupportsGreenfield = true;
- params.nWifiB = 0;
- params.bHasTraffic = false;
- params.nWifiG = 0;
- params.gHasTraffic = false;
- params.nWifiNNonGreenfield = 1;
- params.nNonGreenfieldHasTraffic = false;
- params.nWifiNGreenfield = 1;
- params.nGreenfieldHasTraffic = true;
- throughput = experiment.Run (params);
- if (verifyResults && (throughput < 43 || throughput > 44))
- {
- NS_LOG_ERROR ("Obtained throughput " << throughput << " is not in the expected boundaries!");
- exit (1);
- }
- std::cout << "Throughput: " << throughput << " Mbit/s \n" << std::endl;
-
- params.testName = "HT only with GF not supported by the receiver";
- params.enableErpProtection = false;
- params.enableShortSlotTime = false;
- params.enableShortPhyPreamble = false;
- params.apType = WIFI_STANDARD_80211n_2_4GHZ;
- params.apSupportsGreenfield = false;
- params.nWifiB = 0;
- params.bHasTraffic = false;
- params.nWifiG = 0;
- params.gHasTraffic = false;
- params.nWifiNNonGreenfield = 0;
- params.nNonGreenfieldHasTraffic = false;
- params.nWifiNGreenfield = 1;
- params.nGreenfieldHasTraffic = true;
- throughput = experiment.Run (params);
- if (verifyResults && (throughput < 43 || throughput > 44))
- {
- NS_LOG_ERROR ("Obtained throughput " << throughput << " is not in the expected boundaries!");
- exit (1);
- }
- std::cout << "Throughput: " << throughput << " Mbit/s \n" << std::endl;
-
- params.testName = "Mixed HT/non-HT with GF enabled";
- params.enableErpProtection = false;
- params.enableShortSlotTime = false;
- params.enableShortPhyPreamble = false;
- params.apType = WIFI_STANDARD_80211n_2_4GHZ;
- params.apSupportsGreenfield = true;
- params.nWifiB = 0;
- params.bHasTraffic = false;
- params.nWifiG = 1;
- params.gHasTraffic = false;
- params.nWifiNNonGreenfield = 0;
- params.nNonGreenfieldHasTraffic = false;
- params.nWifiNGreenfield = 1;
- params.nGreenfieldHasTraffic = true;
- throughput = experiment.Run (params);
- if (verifyResults && (throughput < 44 || throughput > 45))
- {
- NS_LOG_ERROR ("Obtained throughput " << throughput << " is not in the expected boundaries!");
- exit (1);
- }
- std::cout << "Throughput: " << throughput << " Mbit/s \n" << std::endl;
-
params.testName = "HT only";
params.enableErpProtection = false;
params.enableShortSlotTime = false;
params.enableShortPhyPreamble = false;
params.apType = WIFI_STANDARD_80211n_2_4GHZ;
- params.apSupportsGreenfield = false;
params.nWifiB = 0;
params.bHasTraffic = false;
params.nWifiG = 0;
params.gHasTraffic = false;
- params.nWifiNNonGreenfield = 1;
- params.nNonGreenfieldHasTraffic = true;
- params.nWifiNGreenfield = 0;
- params.nGreenfieldHasTraffic = false;
+ params.nWifiN = 1;
+ params.nHasTraffic = true;
throughput = experiment.Run (params);
if (verifyResults && (throughput < 44 || throughput > 45))
{
@@ -653,15 +492,12 @@ int main (int argc, char *argv[])
params.enableShortSlotTime = false;
params.enableShortPhyPreamble = false;
params.apType = WIFI_STANDARD_80211n_2_4GHZ;
- params.apSupportsGreenfield = false;
params.nWifiB = 0;
params.bHasTraffic = false;
params.nWifiG = 1;
params.gHasTraffic = false;
- params.nWifiNNonGreenfield = 1;
- params.nNonGreenfieldHasTraffic = true;
- params.nWifiNGreenfield = 0;
- params.nGreenfieldHasTraffic = false;
+ params.nWifiN = 1;
+ params.nHasTraffic = true;
throughput = experiment.Run (params);
if (verifyResults && (throughput < 44 || throughput > 45))
{
diff --git a/src/wifi/doc/source/wifi-user.rst b/src/wifi/doc/source/wifi-user.rst
index 3ff14aede..89bbe8ab6 100644
--- a/src/wifi/doc/source/wifi-user.rst
+++ b/src/wifi/doc/source/wifi-user.rst
@@ -789,10 +789,6 @@ The following line of code enables the support of a short guard interval for all
Config::Set ("/NodeList/*/DeviceList/*/$ns3::WifiNetDevice/HtConfiguration/ShortGuardIntervalSupported", BooleanValue (true));
-Furthermore, 802.11n provides an optional mode (Greenfield mode) to reduce preamble durations and which is only compatible with 802.11n devices. This mode is enabled as follows::
-
- htConfiguration->SetGreenfieldSupported (true);
-
VHT configuration
=================
diff --git a/src/wifi/examples/wifi-test-interference-helper.cc b/src/wifi/examples/wifi-test-interference-helper.cc
index e7f33fd53..66cdb8338 100644
--- a/src/wifi/examples/wifi-test-interference-helper.cc
+++ b/src/wifi/examples/wifi-test-interference-helper.cc
@@ -393,10 +393,6 @@ int main (int argc, char *argv[])
{
input.preamble = WIFI_PREAMBLE_HT_MF;
}
- else if (str_preamble == "WIFI_PREAMBLE_HT_GF" && (input.standard == WIFI_PHY_STANDARD_80211n))
- {
- input.preamble = WIFI_PREAMBLE_HT_GF;
- }
else if (str_preamble == "WIFI_PREAMBLE_VHT_SU" && input.standard == WIFI_PHY_STANDARD_80211ac)
{
input.preamble = WIFI_PREAMBLE_VHT_SU;
diff --git a/src/wifi/helper/wifi-helper.cc b/src/wifi/helper/wifi-helper.cc
index 62b52b114..a0bdb9147 100644
--- a/src/wifi/helper/wifi-helper.cc
+++ b/src/wifi/helper/wifi-helper.cc
@@ -386,10 +386,6 @@ WifiPhyHelper::GetRadiotapHeader (
}
mcsKnown |= RadiotapHeader::MCS_KNOWN_HT_FORMAT;
- if (preamble == WIFI_PREAMBLE_HT_GF)
- {
- mcsFlags |= RadiotapHeader::MCS_FLAGS_HT_GREENFIELD;
- }
mcsKnown |= RadiotapHeader::MCS_KNOWN_NESS;
if (txVector.GetNess () & 0x01) //bit 1
diff --git a/src/wifi/model/aarf-wifi-manager.cc b/src/wifi/model/aarf-wifi-manager.cc
index fb7f168ee..aecac84dc 100644
--- a/src/wifi/model/aarf-wifi-manager.cc
+++ b/src/wifi/model/aarf-wifi-manager.cc
@@ -262,7 +262,7 @@ AarfWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
NS_LOG_DEBUG ("New datarate: " << mode.GetDataRate (channelWidth));
m_currentRate = mode.GetDataRate (channelWidth);
}
- return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
}
WifiTxVector
@@ -287,7 +287,7 @@ AarfWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
{
mode = GetNonErpSupported (station, 0);
}
- rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
return rtsTxVector;
}
diff --git a/src/wifi/model/aarfcd-wifi-manager.cc b/src/wifi/model/aarfcd-wifi-manager.cc
index a857a58a8..8b14b93de 100644
--- a/src/wifi/model/aarfcd-wifi-manager.cc
+++ b/src/wifi/model/aarfcd-wifi-manager.cc
@@ -330,7 +330,7 @@ AarfcdWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
NS_LOG_DEBUG ("New datarate: " << mode.GetDataRate (channelWidth));
m_currentRate = mode.GetDataRate (channelWidth);
}
- return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
}
WifiTxVector
@@ -355,7 +355,7 @@ AarfcdWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
{
mode = GetNonErpSupported (station, 0);
}
- rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
return rtsTxVector;
}
diff --git a/src/wifi/model/amrr-wifi-manager.cc b/src/wifi/model/amrr-wifi-manager.cc
index f933eabd0..650866cc9 100644
--- a/src/wifi/model/amrr-wifi-manager.cc
+++ b/src/wifi/model/amrr-wifi-manager.cc
@@ -374,7 +374,7 @@ AmrrWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
NS_LOG_DEBUG ("New datarate: " << mode.GetDataRate (channelWidth));
m_currentRate = mode.GetDataRate (channelWidth);
}
- return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
}
WifiTxVector
@@ -398,7 +398,7 @@ AmrrWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
{
mode = GetNonErpSupported (station, 0);
}
- rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
return rtsTxVector;
}
diff --git a/src/wifi/model/ap-wifi-mac.cc b/src/wifi/model/ap-wifi-mac.cc
index 234d54923..95b867338 100644
--- a/src/wifi/model/ap-wifi-mac.cc
+++ b/src/wifi/model/ap-wifi-mac.cc
@@ -240,22 +240,6 @@ ApWifiMac::GetShortPreambleEnabled (void) const
return false;
}
-bool
-ApWifiMac::IsNonGfHtStasPresent (void) const
-{
- bool isNonGfHtStasPresent = false;
- for (std::map::const_iterator i = m_staList.begin (); i != m_staList.end (); i++)
- {
- if (!m_stationManager->GetGreenfieldSupported (i->second))
- {
- isNonGfHtStasPresent = true;
- break;
- }
- }
- m_stationManager->SetUseGreenfieldProtection (isNonGfHtStasPresent);
- return isNonGfHtStasPresent;
-}
-
uint16_t
ApWifiMac::GetVhtOperationalChannelWidth (void) const
{
@@ -531,7 +515,7 @@ ApWifiMac::GetHtOperation (void) const
operation.SetHtSupported (1);
operation.SetPrimaryChannel (m_phy->GetChannelNumber ());
operation.SetRifsMode (false);
- operation.SetNonGfHtStasPresent (IsNonGfHtStasPresent ());
+ operation.SetNonGfHtStasPresent (true);
if (m_phy->GetChannelWidth () > 20)
{
operation.SetSecondaryChannelOffset (1);
diff --git a/src/wifi/model/ap-wifi-mac.h b/src/wifi/model/ap-wifi-mac.h
index 3e5685aa1..8d566811f 100644
--- a/src/wifi/model/ap-wifi-mac.h
+++ b/src/wifi/model/ap-wifi-mac.h
@@ -90,12 +90,6 @@ public:
* \returns whether short preamble should be enabled or not in the BSS.
*/
bool GetShortPreambleEnabled (void) const;
- /**
- * Determine whether non-Greenfield HT stations are present or not.
- *
- * \returns whether non-Greenfield HT stations are present or not.
- */
- bool IsNonGfHtStasPresent (void) const;
/**
* Determine the VHT operational channel width (in MHz).
*
diff --git a/src/wifi/model/aparf-wifi-manager.cc b/src/wifi/model/aparf-wifi-manager.cc
index b86c6f8eb..04cf0861e 100644
--- a/src/wifi/model/aparf-wifi-manager.cc
+++ b/src/wifi/model/aparf-wifi-manager.cc
@@ -361,7 +361,7 @@ AparfWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
m_rateChange (prevRate, rate, station->m_state->m_address);
station->m_prevRateIndex = station->m_rateIndex;
}
- return WifiTxVector (mode, station->m_powerLevel, GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (st))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ return WifiTxVector (mode, station->m_powerLevel, GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
}
WifiTxVector
@@ -386,7 +386,7 @@ AparfWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
{
mode = GetNonErpSupported (station, 0);
}
- rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (st))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
return rtsTxVector;
}
diff --git a/src/wifi/model/arf-wifi-manager.cc b/src/wifi/model/arf-wifi-manager.cc
index db04a2422..ada28bfc5 100644
--- a/src/wifi/model/arf-wifi-manager.cc
+++ b/src/wifi/model/arf-wifi-manager.cc
@@ -239,7 +239,7 @@ ArfWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
NS_LOG_DEBUG ("New datarate: " << mode.GetDataRate (channelWidth));
m_currentRate = mode.GetDataRate (channelWidth);
}
- return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
}
WifiTxVector
@@ -264,7 +264,7 @@ ArfWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
{
mode = GetNonErpSupported (station, 0);
}
- rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
return rtsTxVector;
}
diff --git a/src/wifi/model/cara-wifi-manager.cc b/src/wifi/model/cara-wifi-manager.cc
index 8789b57ff..5fb32d3fd 100644
--- a/src/wifi/model/cara-wifi-manager.cc
+++ b/src/wifi/model/cara-wifi-manager.cc
@@ -212,7 +212,7 @@ CaraWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
NS_LOG_DEBUG ("New datarate: " << mode.GetDataRate (channelWidth));
m_currentRate = mode.GetDataRate (channelWidth);
}
- return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
}
WifiTxVector
@@ -237,7 +237,7 @@ CaraWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
{
mode = GetNonErpSupported (station, 0);
}
- rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
return rtsTxVector;
}
diff --git a/src/wifi/model/constant-rate-wifi-manager.cc b/src/wifi/model/constant-rate-wifi-manager.cc
index df9461768..d6d21ef08 100644
--- a/src/wifi/model/constant-rate-wifi-manager.cc
+++ b/src/wifi/model/constant-rate-wifi-manager.cc
@@ -123,14 +123,14 @@ ConstantRateWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
{
nss = 1 + (m_dataMode.GetMcsValue () / 8);
}
- return WifiTxVector (m_dataMode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (m_dataMode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (st))), ConvertGuardIntervalToNanoSeconds (m_dataMode, GetShortGuardIntervalSupported (st), NanoSeconds (GetGuardInterval (st))), GetNumberOfAntennas (), nss, 0, GetChannelWidthForTransmission (m_dataMode, GetChannelWidth (st)), GetAggregation (st));
+ return WifiTxVector (m_dataMode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (m_dataMode.GetModulationClass (), GetShortPreambleEnabled ()), ConvertGuardIntervalToNanoSeconds (m_dataMode, GetShortGuardIntervalSupported (st), NanoSeconds (GetGuardInterval (st))), GetNumberOfAntennas (), nss, 0, GetChannelWidthForTransmission (m_dataMode, GetChannelWidth (st)), GetAggregation (st));
}
WifiTxVector
ConstantRateWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
{
NS_LOG_FUNCTION (this << st);
- return WifiTxVector (m_ctlMode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (m_ctlMode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (st))), ConvertGuardIntervalToNanoSeconds (m_ctlMode, GetShortGuardIntervalSupported (st), NanoSeconds (GetGuardInterval (st))), 1, 1, 0, GetChannelWidthForTransmission (m_ctlMode, GetChannelWidth (st)), GetAggregation (st));
+ return WifiTxVector (m_ctlMode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (m_ctlMode.GetModulationClass (), GetShortPreambleEnabled ()), ConvertGuardIntervalToNanoSeconds (m_ctlMode, GetShortGuardIntervalSupported (st), NanoSeconds (GetGuardInterval (st))), 1, 1, 0, GetChannelWidthForTransmission (m_ctlMode, GetChannelWidth (st)), GetAggregation (st));
}
} //namespace ns3
diff --git a/src/wifi/model/ht-capabilities.cc b/src/wifi/model/ht-capabilities.cc
index 7c3e7ad9f..5d9a93f7d 100644
--- a/src/wifi/model/ht-capabilities.cc
+++ b/src/wifi/model/ht-capabilities.cc
@@ -116,12 +116,6 @@ HtCapabilities::SetSupportedChannelWidth (uint8_t supportedChannelWidth)
m_supportedChannelWidth = supportedChannelWidth;
}
-void
-HtCapabilities::SetGreenfield (uint8_t greenfield)
-{
- m_greenField = greenfield;
-}
-
void
HtCapabilities::SetShortGuardInterval20 (uint8_t shortGuardInterval)
{
@@ -210,12 +204,6 @@ HtCapabilities::GetSupportedChannelWidth (void) const
return m_supportedChannelWidth;
}
-uint8_t
-HtCapabilities::GetGreenfield (void) const
-{
- return m_greenField;
-}
-
uint8_t
HtCapabilities::GetShortGuardInterval20 (void) const
{
@@ -554,7 +542,6 @@ operator << (std::ostream &os, const HtCapabilities &htcapabilities)
{
os << bool (htcapabilities.GetLdpc ())
<< "|" << bool (htcapabilities.GetSupportedChannelWidth ())
- << "|" << bool (htcapabilities.GetGreenfield ())
<< "|" << bool (htcapabilities.GetShortGuardInterval20 ()) << "|";
for (uint8_t i = 0; i < MAX_SUPPORTED_MCS; i++)
{
diff --git a/src/wifi/model/ht-capabilities.h b/src/wifi/model/ht-capabilities.h
index 5907a2083..df8b9cd9e 100644
--- a/src/wifi/model/ht-capabilities.h
+++ b/src/wifi/model/ht-capabilities.h
@@ -113,12 +113,6 @@ public:
* \param supportedChannelWidth the supported channel width field
*/
void SetSupportedChannelWidth (uint8_t supportedChannelWidth);
- /**
- * Set the Greenfield field.
- *
- * \param greenfield the Greenfield field
- */
- void SetGreenfield (uint8_t greenfield);
/**
* Set the short guard interval 20 field.
*
@@ -243,12 +237,6 @@ public:
* \return the supported channel width
*/
uint8_t GetSupportedChannelWidth (void) const;
- /**
- * Return the Greenfield field.
- *
- * \return the Greenfield field
- */
- uint8_t GetGreenfield (void) const;
/**
* Return the short guard interval 20 value.
*
diff --git a/src/wifi/model/ht-configuration.cc b/src/wifi/model/ht-configuration.cc
index 98361c8ae..32a96e082 100644
--- a/src/wifi/model/ht-configuration.cc
+++ b/src/wifi/model/ht-configuration.cc
@@ -52,12 +52,6 @@ HtConfiguration::GetTypeId (void)
MakeBooleanAccessor (&HtConfiguration::GetShortGuardIntervalSupported,
&HtConfiguration::SetShortGuardIntervalSupported),
MakeBooleanChecker ())
- .AddAttribute ("GreenfieldSupported",
- "Whether or not Greenfield is supported.",
- BooleanValue (false),
- MakeBooleanAccessor (&HtConfiguration::GetGreenfieldSupported,
- &HtConfiguration::SetGreenfieldSupported),
- MakeBooleanChecker ())
.AddAttribute ("LdpcSupported",
"Whether or not LDPC coding is supported.",
BooleanValue (false),
@@ -81,19 +75,6 @@ HtConfiguration::GetShortGuardIntervalSupported (void) const
return m_sgiSupported;
}
-void
-HtConfiguration::SetGreenfieldSupported (bool enable)
-{
- NS_LOG_FUNCTION (this << enable);
- m_greenfieldSupported = enable;
-}
-
-bool
-HtConfiguration::GetGreenfieldSupported (void) const
-{
- return m_greenfieldSupported;
-}
-
void
HtConfiguration::SetLdpcSupported (bool enable)
{
diff --git a/src/wifi/model/ht-configuration.h b/src/wifi/model/ht-configuration.h
index e00b068d4..2496fb8af 100644
--- a/src/wifi/model/ht-configuration.h
+++ b/src/wifi/model/ht-configuration.h
@@ -59,20 +59,6 @@ public:
* false otherwise.
*/
bool GetShortGuardIntervalSupported (void) const;
- /**
- * Enable or disable Greenfield support.
- *
- * \param enable true if Greenfield is to be supported,
- * false otherwise
- */
- void SetGreenfieldSupported (bool enable);
- /**
- * \return whether the device supports Greenfield.
- *
- * \return true if Greenfield is supported,
- * false otherwise.
- */
- bool GetGreenfieldSupported (void) const;
/**
* Enable or disable LDPC support.
*
@@ -91,7 +77,6 @@ public:
private:
bool m_sgiSupported; ///< flag whether short guard interval is supported
- bool m_greenfieldSupported; ///< flag whether Greenfield is supported
bool m_ldpcSupported; ///< flag whether LDPC coding is supported
};
diff --git a/src/wifi/model/ht-operation.cc b/src/wifi/model/ht-operation.cc
index bd6c0c765..3a7a30fdd 100644
--- a/src/wifi/model/ht-operation.cc
+++ b/src/wifi/model/ht-operation.cc
@@ -29,7 +29,7 @@ HtOperation::HtOperation ()
m_rifsMode (0),
m_reservedInformationSubset1 (0),
m_htProtection (0),
- m_nonGfHtStasPresent (0),
+ m_nonGfHtStasPresent (1),
m_reservedInformationSubset2_1 (0),
m_obssNonHtStasPresent (0),
m_reservedInformationSubset2_2 (0),
diff --git a/src/wifi/model/ht-phy.cc b/src/wifi/model/ht-phy.cc
index 1c725e41d..7650512a3 100644
--- a/src/wifi/model/ht-phy.cc
+++ b/src/wifi/model/ht-phy.cc
@@ -41,10 +41,6 @@ const PhyEntity::PpduFormats HtPhy::m_htPpduFormats {
WIFI_PPDU_FIELD_NON_HT_HEADER, //L-SIG
WIFI_PPDU_FIELD_HT_SIG, //HT-SIG
WIFI_PPDU_FIELD_TRAINING, //HT-STF + HT-LTFs
- WIFI_PPDU_FIELD_DATA } },
- { WIFI_PREAMBLE_HT_GF, { WIFI_PPDU_FIELD_PREAMBLE, //HT-GF-STF + HT-LTF1
- WIFI_PPDU_FIELD_HT_SIG, //HT-SIG
- WIFI_PPDU_FIELD_TRAINING, //Additional HT-LTFs
WIFI_PPDU_FIELD_DATA } }
};
/* *NS_CHECK_STYLE_ON* */
@@ -242,7 +238,7 @@ HtPhy::GetDuration (WifiPpduField field, WifiTxVector txVector) const
Time
HtPhy::GetLSigDuration (WifiPreamble preamble) const
{
- return (preamble == WIFI_PREAMBLE_HT_GF) ? MicroSeconds (0) : MicroSeconds (4); //no L-SIG for HT-GF
+ return MicroSeconds (4);
}
Time
@@ -252,14 +248,7 @@ HtPhy::GetTrainingDuration (WifiTxVector txVector,
NS_ABORT_MSG_IF (nDataLtf == 0 || nDataLtf > 4 || nExtensionLtf > 4 || (nDataLtf + nExtensionLtf) > 5,
"Unsupported combination of data (" << +nDataLtf << ") and extension (" << +nExtensionLtf << ") LTFs numbers for HT"); //see IEEE 802.11-2016, section 19.3.9.4.6 "HT-LTF definition"
Time duration = MicroSeconds (4) * (nDataLtf + nExtensionLtf);
- if (txVector.GetPreambleType () == WIFI_PREAMBLE_HT_GF)
- {
- return MicroSeconds (4) * (nDataLtf - 1 + nExtensionLtf); //no HT-STF and first HT-LTF is already in preamble, see IEEE 802.11-2016, section 19.3.5.5 "HT-greenfield format LTF"
- }
- else //HT-MF
- {
- return MicroSeconds (4) * (1 /* HT-STF */ + nDataLtf + nExtensionLtf);
- }
+ return MicroSeconds (4) * (1 /* HT-STF */ + nDataLtf + nExtensionLtf);
}
Time
@@ -383,7 +372,6 @@ HtPhy::DoEndReceiveField (WifiPpduField field, Ptr event)
case WIFI_PPDU_FIELD_TRAINING:
return PhyFieldRxStatus (true); //always consider that training has been correctly received
case WIFI_PPDU_FIELD_NON_HT_HEADER:
- NS_ASSERT (event->GetTxVector ().GetPreambleType () != WIFI_PREAMBLE_HT_GF);
//no break so as to go to OfdmPhy for processing
default:
return OfdmPhy::DoEndReceiveField (field, event);
diff --git a/src/wifi/model/ht-phy.h b/src/wifi/model/ht-phy.h
index f0cdd2f64..d4e744cbe 100644
--- a/src/wifi/model/ht-phy.h
+++ b/src/wifi/model/ht-phy.h
@@ -42,8 +42,8 @@ namespace ns3 {
* \ingroup wifi
*
* HT PHY is based on OFDM PHY.
- * HT-Mixed and HT-Greenfield PPDU formats are
- * supported. Only HT MCSs up to 31 are supported.
+ * Only HT-Mixed is supported (support for HT-Greenfield has been removed).
+ * Only HT MCSs up to 31 are supported.
*
* Refer to IEEE 802.11-2016, clause 19.
*/
diff --git a/src/wifi/model/ideal-wifi-manager.cc b/src/wifi/model/ideal-wifi-manager.cc
index b0a5a766d..6ae61bd3a 100644
--- a/src/wifi/model/ideal-wifi-manager.cc
+++ b/src/wifi/model/ideal-wifi-manager.cc
@@ -530,7 +530,7 @@ IdealWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
NS_LOG_DEBUG ("New datarate: " << maxMode.GetDataRate (channelWidth, guardInterval, selectedNss));
m_currentRate = maxMode.GetDataRate (channelWidth, guardInterval, selectedNss);
}
- return WifiTxVector (maxMode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (maxMode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), guardInterval, GetNumberOfAntennas (), selectedNss, 0, GetChannelWidthForTransmission (maxMode, channelWidth), GetAggregation (station));
+ return WifiTxVector (maxMode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (maxMode.GetModulationClass (), GetShortPreambleEnabled ()), guardInterval, GetNumberOfAntennas (), selectedNss, 0, GetChannelWidthForTransmission (maxMode, channelWidth), GetAggregation (station));
}
WifiTxVector
@@ -560,7 +560,7 @@ IdealWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
maxMode = mode;
}
}
- return WifiTxVector (maxMode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (maxMode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, GetNumberOfAntennas (), nss, 0, GetChannelWidthForNonHtMode (maxMode), GetAggregation (station));
+ return WifiTxVector (maxMode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (maxMode.GetModulationClass (), GetShortPreambleEnabled ()), 800, GetNumberOfAntennas (), nss, 0, GetChannelWidthForNonHtMode (maxMode), GetAggregation (station));
}
double
diff --git a/src/wifi/model/minstrel-ht-wifi-manager.cc b/src/wifi/model/minstrel-ht-wifi-manager.cc
index e4b0e07c5..ff984f438 100644
--- a/src/wifi/model/minstrel-ht-wifi-manager.cc
+++ b/src/wifi/model/minstrel-ht-wifi-manager.cc
@@ -865,7 +865,7 @@ MinstrelHtWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
NS_LOG_DEBUG ("New datarate: " << dataRate);
m_currentRate = dataRate;
}
- return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), group.sgi ? 400 : 800, GetNumberOfAntennas (), group.streams, GetNess (station), GetChannelWidthForTransmission (mode, group.chWidth), GetAggregation (station) && !station->m_isSampling);
+ return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), group.sgi ? 400 : 800, GetNumberOfAntennas (), group.streams, GetNess (station), GetChannelWidthForTransmission (mode, group.chWidth), GetAggregation (station) && !station->m_isSampling);
}
}
@@ -939,7 +939,7 @@ MinstrelHtWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
NS_ASSERT (rateFound);
- return WifiTxVector (rtsRate, GetDefaultTxPowerLevel (), GetPreambleForTransmission (rtsRate.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))),
+ return WifiTxVector (rtsRate, GetDefaultTxPowerLevel (), GetPreambleForTransmission (rtsRate.GetModulationClass (), GetShortPreambleEnabled ()),
800, 1, 1, 0, GetChannelWidthForTransmission (rtsRate, GetChannelWidth (station)), GetAggregation (station));
}
}
diff --git a/src/wifi/model/minstrel-wifi-manager.cc b/src/wifi/model/minstrel-wifi-manager.cc
index c01af7369..8e4b4b31e 100644
--- a/src/wifi/model/minstrel-wifi-manager.cc
+++ b/src/wifi/model/minstrel-wifi-manager.cc
@@ -379,7 +379,7 @@ MinstrelWifiManager::GetDataTxVector (MinstrelWifiRemoteStation *station)
NS_LOG_DEBUG ("New datarate: " << mode.GetDataRate (channelWidth));
m_currentRate = mode.GetDataRate (channelWidth);
}
- return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
}
WifiTxVector
@@ -402,7 +402,7 @@ MinstrelWifiManager::GetRtsTxVector (MinstrelWifiRemoteStation *station)
{
mode = GetNonErpSupported (station, 0);
}
- rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
return rtsTxVector;
}
diff --git a/src/wifi/model/onoe-wifi-manager.cc b/src/wifi/model/onoe-wifi-manager.cc
index 27e8a37e4..8bc4def4b 100644
--- a/src/wifi/model/onoe-wifi-manager.cc
+++ b/src/wifi/model/onoe-wifi-manager.cc
@@ -336,7 +336,7 @@ OnoeWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
NS_LOG_DEBUG ("New datarate: " << mode.GetDataRate (channelWidth));
m_currentRate = mode.GetDataRate (channelWidth);
}
- return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (st))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
}
WifiTxVector
@@ -360,7 +360,7 @@ OnoeWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
{
mode = GetNonErpSupported (station, 0);
}
- rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (st))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
return rtsTxVector;
}
diff --git a/src/wifi/model/parf-wifi-manager.cc b/src/wifi/model/parf-wifi-manager.cc
index 3657a98cb..729d9dcf0 100644
--- a/src/wifi/model/parf-wifi-manager.cc
+++ b/src/wifi/model/parf-wifi-manager.cc
@@ -333,7 +333,7 @@ ParfWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
m_rateChange (prevRate, rate, station->m_state->m_address);
station->m_prevRateIndex = station->m_rateIndex;
}
- return WifiTxVector (mode, station->m_powerLevel, GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ return WifiTxVector (mode, station->m_powerLevel, GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
}
WifiTxVector
@@ -358,7 +358,7 @@ ParfWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
{
mode = GetNonErpSupported (station, 0);
}
- rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
return rtsTxVector;
}
diff --git a/src/wifi/model/regular-wifi-mac.cc b/src/wifi/model/regular-wifi-mac.cc
index ef1c4298c..9795ea43e 100644
--- a/src/wifi/model/regular-wifi-mac.cc
+++ b/src/wifi/model/regular-wifi-mac.cc
@@ -205,14 +205,12 @@ RegularWifiMac::GetHtCapabilities (void) const
if (GetHtSupported ())
{
Ptr htConfiguration = GetHtConfiguration ();
- bool greenfieldSupported = htConfiguration->GetGreenfieldSupported ();
bool sgiSupported = htConfiguration->GetShortGuardIntervalSupported ();
capabilities.SetHtSupported (1);
capabilities.SetLdpc (htConfiguration->GetLdpcSupported ());
capabilities.SetSupportedChannelWidth (m_phy->GetChannelWidth () >= 40);
capabilities.SetShortGuardInterval20 (sgiSupported);
capabilities.SetShortGuardInterval40 (m_phy->GetChannelWidth () >= 40 && sgiSupported);
- capabilities.SetGreenfield (greenfieldSupported);
// Set Maximum A-MSDU Length subfield
uint16_t maxAmsduSize = std::max ({m_voMaxAmsduSize, m_viMaxAmsduSize,
m_beMaxAmsduSize, m_bkMaxAmsduSize});
@@ -231,7 +229,7 @@ RegularWifiMac::GetHtCapabilities (void) const
// The maximum A-MPDU length in HT capabilities elements ranges from 2^13-1 to 2^16-1
capabilities.SetMaxAmpduLength (std::min (std::max (maxAmpduLength, 8191u), 65535u));
- capabilities.SetLSigProtectionSupport (!greenfieldSupported);
+ capabilities.SetLSigProtectionSupport (true);
uint64_t maxSupportedRate = 0; //in bit/s
for (const auto & mcs : m_phy->GetMcsList (WIFI_MOD_CLASS_HT))
{
diff --git a/src/wifi/model/rraa-wifi-manager.cc b/src/wifi/model/rraa-wifi-manager.cc
index f7489e5ad..e82c1537a 100644
--- a/src/wifi/model/rraa-wifi-manager.cc
+++ b/src/wifi/model/rraa-wifi-manager.cc
@@ -361,7 +361,7 @@ RraaWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
NS_LOG_DEBUG ("New datarate: " << mode.GetDataRate (channelWidth));
m_currentRate = mode.GetDataRate (channelWidth);
}
- return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ return WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
}
WifiTxVector
@@ -384,7 +384,7 @@ RraaWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
{
mode = GetNonErpSupported (station, 0);
}
- rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
return rtsTxVector;
}
diff --git a/src/wifi/model/rrpaa-wifi-manager.cc b/src/wifi/model/rrpaa-wifi-manager.cc
index 5dd26d76a..aa5680081 100644
--- a/src/wifi/model/rrpaa-wifi-manager.cc
+++ b/src/wifi/model/rrpaa-wifi-manager.cc
@@ -412,7 +412,7 @@ RrpaaWifiManager::DoGetDataTxVector (WifiRemoteStation *st)
m_powerChange (prevPower, power, station->m_state->m_address);
station->m_prevPowerLevel = station->m_powerLevel;
}
- return WifiTxVector (mode, station->m_powerLevel, GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ return WifiTxVector (mode, station->m_powerLevel, GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
}
WifiTxVector
RrpaaWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
@@ -434,7 +434,7 @@ RrpaaWifiManager::DoGetRtsTxVector (WifiRemoteStation *st)
{
mode = GetNonErpSupported (station, 0);
}
- rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (GetAddress (station))), 800, 1, 1, 0, channelWidth, GetAggregation (station));
+ rtsTxVector = WifiTxVector (mode, GetDefaultTxPowerLevel (), GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()), 800, 1, 1, 0, channelWidth, GetAggregation (station));
return rtsTxVector;
}
diff --git a/src/wifi/model/sta-wifi-mac.cc b/src/wifi/model/sta-wifi-mac.cc
index ed9ddf129..f0ee217a9 100644
--- a/src/wifi/model/sta-wifi-mac.cc
+++ b/src/wifi/model/sta-wifi-mac.cc
@@ -782,15 +782,6 @@ StaWifiMac::UpdateApInfoFromBeacon (MgtBeaconHeader beacon, Mac48Address apAddr,
else
{
m_stationManager->AddStationHtCapabilities (apAddr, htCapabilities);
- HtOperation htOperation = beacon.GetHtOperation ();
- if (htOperation.GetNonGfHtStasPresent ())
- {
- m_stationManager->SetUseGreenfieldProtection (true);
- }
- else
- {
- m_stationManager->SetUseGreenfieldProtection (false);
- }
}
}
if (GetVhtSupported ())
@@ -969,15 +960,6 @@ StaWifiMac::UpdateApInfoFromAssocResp (MgtAssocResponseHeader assocResp, Mac48Ad
else
{
m_stationManager->AddStationHtCapabilities (apAddr, htCapabilities);
- HtOperation htOperation = assocResp.GetHtOperation ();
- if (htOperation.GetNonGfHtStasPresent ())
- {
- m_stationManager->SetUseGreenfieldProtection (true);
- }
- else
- {
- m_stationManager->SetUseGreenfieldProtection (false);
- }
}
}
if (GetVhtSupported ())
diff --git a/src/wifi/model/wifi-phy-common.h b/src/wifi/model/wifi-phy-common.h
index b3dc1976e..2dc120339 100644
--- a/src/wifi/model/wifi-phy-common.h
+++ b/src/wifi/model/wifi-phy-common.h
@@ -47,7 +47,6 @@ enum WifiPreamble
WIFI_PREAMBLE_LONG,
WIFI_PREAMBLE_SHORT,
WIFI_PREAMBLE_HT_MF,
- WIFI_PREAMBLE_HT_GF,
WIFI_PREAMBLE_VHT_SU,
WIFI_PREAMBLE_VHT_MU,
WIFI_PREAMBLE_HE_SU,
@@ -73,8 +72,6 @@ inline std::ostream& operator<< (std::ostream &os, const WifiPreamble &preamble)
return (os << "SHORT");
case WIFI_PREAMBLE_HT_MF:
return (os << "HT_MF");
- case WIFI_PREAMBLE_HT_GF:
- return (os << "HT_GF");
case WIFI_PREAMBLE_VHT_SU:
return (os << "VHT_SU");
case WIFI_PREAMBLE_VHT_MU:
diff --git a/src/wifi/model/wifi-remote-station-manager.cc b/src/wifi/model/wifi-remote-station-manager.cc
index 1596dce61..94d24ed47 100644
--- a/src/wifi/model/wifi-remote-station-manager.cc
+++ b/src/wifi/model/wifi-remote-station-manager.cc
@@ -120,7 +120,6 @@ WifiRemoteStationManager::WifiRemoteStationManager ()
: m_pcfSupported (false),
m_useNonErpProtection (false),
m_useNonHtProtection (false),
- m_useGreenfieldProtection (false),
m_shortPreambleEnabled (false),
m_shortSlotTimeEnabled (false)
{
@@ -270,22 +269,6 @@ WifiRemoteStationManager::GetPcfSupported (void) const
return m_pcfSupported;
}
-bool
-WifiRemoteStationManager::GetGreenfieldSupported (void) const
-{
- if (GetHtSupported ())
- {
- Ptr device = DynamicCast (m_wifiPhy->GetDevice ());
- Ptr htConfiguration = device->GetHtConfiguration ();
- NS_ASSERT (htConfiguration); //If HT is supported, we should have a HT configuration attached
- if (htConfiguration->GetGreenfieldSupported ())
- {
- return true;
- }
- }
- return false;
-}
-
bool
WifiRemoteStationManager::GetLdpcSupported (void) const
{
@@ -512,7 +495,7 @@ WifiRemoteStationManager::GetDataTxVector (const WifiMacHeader &header)
WifiMode mode = GetNonUnicastMode ();
WifiTxVector v;
v.SetMode (mode);
- v.SetPreambleType (GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (address)));
+ v.SetPreambleType (GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()));
v.SetTxPowerLevel (m_defaultTxPowerLevel);
v.SetChannelWidth (GetChannelWidthForTransmission (mode, m_wifiPhy->GetChannelWidth ()));
v.SetGuardInterval (ConvertGuardIntervalToNanoSeconds (mode, DynamicCast (m_wifiPhy->GetDevice ())));
@@ -535,7 +518,7 @@ WifiRemoteStationManager::GetDataTxVector (const WifiMacHeader &header)
mgtMode = GetDefaultMode ();
}
txVector.SetMode (mgtMode);
- txVector.SetPreambleType (GetPreambleForTransmission (mgtMode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (address)));
+ txVector.SetPreambleType (GetPreambleForTransmission (mgtMode.GetModulationClass (), GetShortPreambleEnabled ()));
txVector.SetTxPowerLevel (m_defaultTxPowerLevel);
txVector.SetChannelWidth (GetChannelWidthForTransmission (mgtMode, m_wifiPhy->GetChannelWidth ()));
txVector.SetGuardInterval (ConvertGuardIntervalToNanoSeconds (mgtMode, DynamicCast (m_wifiPhy->GetDevice ())));
@@ -598,7 +581,7 @@ WifiRemoteStationManager::GetRtsTxVector (Mac48Address address)
WifiMode mode = GetNonUnicastMode ();
WifiTxVector v;
v.SetMode (mode);
- v.SetPreambleType (GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (address)));
+ v.SetPreambleType (GetPreambleForTransmission (mode.GetModulationClass (), GetShortPreambleEnabled ()));
v.SetTxPowerLevel (m_defaultTxPowerLevel);
v.SetChannelWidth (GetChannelWidthForTransmission (mode, m_wifiPhy->GetChannelWidth ()));
v.SetGuardInterval (ConvertGuardIntervalToNanoSeconds (mode, DynamicCast (m_wifiPhy->GetDevice ())));
@@ -617,7 +600,7 @@ WifiRemoteStationManager::GetCtsTxVector (Mac48Address to, WifiMode rtsTxMode) c
WifiMode ctsMode = GetControlAnswerMode (rtsTxMode);
WifiTxVector v;
v.SetMode (ctsMode);
- v.SetPreambleType (GetPreambleForTransmission (ctsMode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (to)));
+ v.SetPreambleType (GetPreambleForTransmission (ctsMode.GetModulationClass (), GetShortPreambleEnabled ()));
v.SetTxPowerLevel (GetDefaultTxPowerLevel ());
v.SetChannelWidth (GetChannelWidthForTransmission (ctsMode, m_wifiPhy->GetChannelWidth ()));
uint16_t ctsTxGuardInterval = ConvertGuardIntervalToNanoSeconds (ctsMode, DynamicCast (m_wifiPhy->GetDevice ()));
@@ -633,7 +616,7 @@ WifiRemoteStationManager::GetAckTxVector (Mac48Address to, WifiMode dataTxMode)
WifiMode ackMode = GetControlAnswerMode (dataTxMode);
WifiTxVector v;
v.SetMode (ackMode);
- v.SetPreambleType (GetPreambleForTransmission (ackMode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (to)));
+ v.SetPreambleType (GetPreambleForTransmission (ackMode.GetModulationClass (), GetShortPreambleEnabled ()));
v.SetTxPowerLevel (GetDefaultTxPowerLevel ());
v.SetChannelWidth (GetChannelWidthForTransmission (ackMode, m_wifiPhy->GetChannelWidth ()));
uint16_t ackTxGuardInterval = ConvertGuardIntervalToNanoSeconds (ackMode, DynamicCast (m_wifiPhy->GetDevice ()));
@@ -649,7 +632,7 @@ WifiRemoteStationManager::GetBlockAckTxVector (Mac48Address to, WifiMode dataTxM
WifiMode blockAckMode = GetControlAnswerMode (dataTxMode);
WifiTxVector v;
v.SetMode (blockAckMode);
- v.SetPreambleType (GetPreambleForTransmission (blockAckMode.GetModulationClass (), GetShortPreambleEnabled (), UseGreenfieldForDestination (to)));
+ v.SetPreambleType (GetPreambleForTransmission (blockAckMode.GetModulationClass (), GetShortPreambleEnabled ()));
v.SetTxPowerLevel (GetDefaultTxPowerLevel ());
v.SetChannelWidth (GetChannelWidthForTransmission (blockAckMode, m_wifiPhy->GetChannelWidth ()));
uint16_t blockAckTxGuardInterval = ConvertGuardIntervalToNanoSeconds (blockAckMode, DynamicCast (m_wifiPhy->GetDevice ()));
@@ -1038,19 +1021,6 @@ WifiRemoteStationManager::GetUseNonHtProtection (void) const
return m_useNonHtProtection;
}
-void
-WifiRemoteStationManager::SetUseGreenfieldProtection (bool enable)
-{
- NS_LOG_FUNCTION (this << enable);
- m_useGreenfieldProtection = enable;
-}
-
-bool
-WifiRemoteStationManager::GetUseGreenfieldProtection (void) const
-{
- return m_useGreenfieldProtection;
-}
-
bool
WifiRemoteStationManager::NeedRetransmission (Ptr mpdu)
{
@@ -1414,18 +1384,6 @@ WifiRemoteStationManager::GetStationHeCapabilities (Mac48Address from)
return LookupState (from)->m_heCapabilities;
}
-bool
-WifiRemoteStationManager::GetGreenfieldSupported (Mac48Address address) const
-{
- Ptr htCapabilities = LookupState (address)->m_htCapabilities;
-
- if (!htCapabilities)
- {
- return false;
- }
- return htCapabilities->GetGreenfield ();
-}
-
bool
WifiRemoteStationManager::GetLdpcSupported (Mac48Address address) const
{
@@ -1697,18 +1655,6 @@ WifiRemoteStationManager::GetGuardInterval (const WifiRemoteStation *station) co
return station->m_state->m_guardInterval;
}
-bool
-WifiRemoteStationManager::GetGreenfield (const WifiRemoteStation *station) const
-{
- Ptr htCapabilities = station->m_state->m_htCapabilities;
-
- if (!htCapabilities)
- {
- return false;
- }
- return htCapabilities->GetGreenfield ();
-}
-
bool
WifiRemoteStationManager::GetAggregation (const WifiRemoteStation *station) const
{
@@ -1868,12 +1814,6 @@ WifiRemoteStationManager::GetMaxNumberOfTransmitStreams (void) const
return m_wifiPhy->GetMaxSupportedTxSpatialStreams ();
}
-bool
-WifiRemoteStationManager::UseGreenfieldForDestination (Mac48Address dest) const
-{
- return (GetGreenfieldSupported () && GetGreenfieldSupported (dest) && !GetUseGreenfieldProtection ());
-}
-
bool
WifiRemoteStationManager::UseLdpcForDestination (Mac48Address dest) const
{
diff --git a/src/wifi/model/wifi-remote-station-manager.h b/src/wifi/model/wifi-remote-station-manager.h
index 4485d72b3..e83f6d714 100644
--- a/src/wifi/model/wifi-remote-station-manager.h
+++ b/src/wifi/model/wifi-remote-station-manager.h
@@ -267,12 +267,6 @@ public:
* \return true if PCF capability support is enabled, false otherwise
*/
bool GetPcfSupported (void) const;
- /**
- * Return whether the device has HT Greenfield support enabled.
- *
- * \return true if HT Grenfield support is enabled, false otherwise
- */
- bool GetGreenfieldSupported (void) const;
/**
* Return whether the device has LDPC support enabled.
*
@@ -317,19 +311,6 @@ public:
* false otherwise
*/
bool GetUseNonHtProtection (void) const;
- /**
- * Enable or disable protection for stations that do not support HT Greenfield format.
- *
- * \param enable enable or disable protection for stations that do not support HT Greenfield format
- */
- void SetUseGreenfieldProtection (bool enable);
- /**
- * Return whether protection for stations that do not support HT Greenfield format is enabled.
- *
- * \return true if protection for stations that do not support HT Greenfield is enabled,
- * false otherwise
- */
- bool GetUseGreenfieldProtection (void) const;
/**
* Enable or disable short PHY preambles.
*
@@ -404,15 +385,6 @@ public:
* \return the basic mode at the given index
*/
WifiMode GetNonErpBasicMode (uint8_t i) const;
- /**
- * Return whether the station supports Greenfield or not.
- *
- * \param address the address of the station
- *
- * \return true if Greenfield is supported by the station,
- * false otherwise
- */
- bool GetGreenfieldSupported (Mac48Address address) const;
/**
* Return whether the station supports LDPC or not.
*
@@ -873,14 +845,6 @@ public:
* \return the maximum number of spatial streams supported by the PHY layer
*/
uint8_t GetMaxNumberOfTransmitStreams (void) const;
- /**
- * \returns whether HT greenfield should be used for a given destination address.
- *
- * \param dest the destination address
- *
- * \return whether HT greenfield should be used for a given destination address
- */
- bool UseGreenfieldForDestination (Mac48Address dest) const;
/**
* \returns whether LDPC should be used for a given destination address.
*
@@ -1054,15 +1018,6 @@ protected:
* false otherwise
*/
bool GetAggregation (const WifiRemoteStation *station) const;
- /**
- * Return whether the station supports Greenfield or not.
- *
- * \param station the station being queried
- *
- * \return true if Greenfield is supported by the station,
- * false otherwise
- */
- bool GetGreenfield (const WifiRemoteStation *station) const;
/**
* Return the number of supported streams the station has.
@@ -1307,7 +1262,6 @@ private:
WifiMode m_nonUnicastMode; //!< Transmission mode for non-unicast Data frames
bool m_useNonErpProtection; //!< flag if protection for non-ERP stations against ERP transmissions is enabled
bool m_useNonHtProtection; //!< flag if protection for non-HT stations against HT transmissions is enabled
- bool m_useGreenfieldProtection; //!< flag if protection for stations that do not support HT Greenfield format is enabled
bool m_shortPreambleEnabled; //!< flag if short PHY preamble is enabled
bool m_shortSlotTimeEnabled; //!< flag if short slot time is enabled
ProtectionMode m_erpProtectionMode; //!< Protection mode for ERP stations when non-ERP stations are detected
diff --git a/src/wifi/model/wifi-utils.cc b/src/wifi/model/wifi-utils.cc
index a418e1345..20157b3d5 100644
--- a/src/wifi/model/wifi-utils.cc
+++ b/src/wifi/model/wifi-utils.cc
@@ -113,7 +113,7 @@ GetChannelWidthForTransmission (WifiMode mode, uint16_t maxSupportedChannelWidth
}
WifiPreamble
-GetPreambleForTransmission (WifiModulationClass modulation, bool useShortPreamble, bool useGreenfield)
+GetPreambleForTransmission (WifiModulationClass modulation, bool useShortPreamble)
{
if (modulation == WIFI_MOD_CLASS_HE)
{
@@ -123,14 +123,9 @@ GetPreambleForTransmission (WifiModulationClass modulation, bool useShortPreambl
{
return WIFI_PREAMBLE_VHT_SU;
}
- else if (modulation == WIFI_MOD_CLASS_HT && useGreenfield)
- {
- //If protection for Greenfield is used we go for HT_MF preamble which is the default protection for GF format defined in the standard.
- return WIFI_PREAMBLE_HT_GF;
- }
else if (modulation == WIFI_MOD_CLASS_HT)
{
- return WIFI_PREAMBLE_HT_MF;
+ return WIFI_PREAMBLE_HT_MF; // HT_GF has been removed
}
else if (modulation == WIFI_MOD_CLASS_HR_DSSS && useShortPreamble) //ERP_DSSS is modeled through HR_DSSS (since same preamble and modulation)
{
@@ -245,21 +240,18 @@ GetPpduMaxTime (WifiPreamble preamble)
switch (preamble)
{
- case WIFI_PREAMBLE_HT_GF:
- duration = MicroSeconds (10000);
- break;
- case WIFI_PREAMBLE_HT_MF:
- case WIFI_PREAMBLE_VHT_SU:
- case WIFI_PREAMBLE_VHT_MU:
- case WIFI_PREAMBLE_HE_SU:
- case WIFI_PREAMBLE_HE_ER_SU:
- case WIFI_PREAMBLE_HE_MU:
- case WIFI_PREAMBLE_HE_TB:
- duration = MicroSeconds (5484);
- break;
- default:
- duration = MicroSeconds (0);
- break;
+ case WIFI_PREAMBLE_HT_MF:
+ case WIFI_PREAMBLE_VHT_SU:
+ case WIFI_PREAMBLE_VHT_MU:
+ case WIFI_PREAMBLE_HE_SU:
+ case WIFI_PREAMBLE_HE_ER_SU:
+ case WIFI_PREAMBLE_HE_MU:
+ case WIFI_PREAMBLE_HE_TB:
+ duration = MicroSeconds (5484);
+ break;
+ default:
+ duration = MicroSeconds (0);
+ break;
}
return duration;
}
@@ -267,7 +259,7 @@ GetPpduMaxTime (WifiPreamble preamble)
bool
IsHt (WifiPreamble preamble)
{
- return (preamble == WIFI_PREAMBLE_HT_MF || preamble == WIFI_PREAMBLE_HT_GF);
+ return (preamble == WIFI_PREAMBLE_HT_MF);
}
bool
diff --git a/src/wifi/model/wifi-utils.h b/src/wifi/model/wifi-utils.h
index d6a20ecde..869eb4ff7 100644
--- a/src/wifi/model/wifi-utils.h
+++ b/src/wifi/model/wifi-utils.h
@@ -89,11 +89,10 @@ uint16_t ConvertGuardIntervalToNanoSeconds (WifiMode mode, bool htShortGuardInte
*
* \param modulation the modulation selected for the transmission
* \param useShortPreamble whether short preamble should be used
- * \param useGreenfield whether HT Greenfield should be used
*
* \return the preamble to be used for the transmission
*/
-WifiPreamble GetPreambleForTransmission (WifiModulationClass modulation, bool useShortPreamble, bool useGreenfield);
+WifiPreamble GetPreambleForTransmission (WifiModulationClass modulation, bool useShortPreamble);
/**
* Return the channel width that corresponds to the selected mode (instead of
* letting the PHY's default channel width). This is especially useful when using
diff --git a/src/wifi/test/tx-duration-test.cc b/src/wifi/test/tx-duration-test.cc
index cdc051586..7e4ff2808 100644
--- a/src/wifi/test/tx-duration-test.cc
+++ b/src/wifi/test/tx-duration-test.cc
@@ -409,33 +409,18 @@ TxDurationTest::DoRun (void)
&& CheckTxDuration (1536, HtPhy::GetHtMcs7 (), 20, 800, WIFI_PREAMBLE_HT_MF, MicroSeconds (228))
&& CheckTxDuration (76, HtPhy::GetHtMcs7 (), 20, 800, WIFI_PREAMBLE_HT_MF, MicroSeconds (48))
&& CheckTxDuration (14, HtPhy::GetHtMcs7 (), 20, 800, WIFI_PREAMBLE_HT_MF, MicroSeconds (40))
- && CheckTxDuration (1536, HtPhy::GetHtMcs7 (), 20, 800, WIFI_PREAMBLE_HT_GF, MicroSeconds (216))
- && CheckTxDuration (76, HtPhy::GetHtMcs7 (), 20, 800, WIFI_PREAMBLE_HT_GF, MicroSeconds (36))
- && CheckTxDuration (14, HtPhy::GetHtMcs7 (), 20, 800, WIFI_PREAMBLE_HT_GF, MicroSeconds (28))
&& CheckTxDuration (1536, HtPhy::GetHtMcs0 (), 20, 400, WIFI_PREAMBLE_HT_MF, NanoSeconds (1742400))
&& CheckTxDuration (76, HtPhy::GetHtMcs0 (), 20, 400, WIFI_PREAMBLE_HT_MF, MicroSeconds (126))
&& CheckTxDuration (14, HtPhy::GetHtMcs0 (), 20, 400, WIFI_PREAMBLE_HT_MF, NanoSeconds (57600))
- && CheckTxDuration (1536,HtPhy::GetHtMcs0 (), 20, 400, WIFI_PREAMBLE_HT_GF, NanoSeconds (1730400))
- && CheckTxDuration (76, HtPhy::GetHtMcs0 (), 20, 400, WIFI_PREAMBLE_HT_GF, MicroSeconds (114))
- && CheckTxDuration (14, HtPhy::GetHtMcs0 (), 20, 400, WIFI_PREAMBLE_HT_GF, NanoSeconds (45600))
&& CheckTxDuration (1536, HtPhy::GetHtMcs6 (), 20, 400, WIFI_PREAMBLE_HT_MF, NanoSeconds (226800))
&& CheckTxDuration (76, HtPhy::GetHtMcs6 (), 20, 400, WIFI_PREAMBLE_HT_MF, NanoSeconds (46800))
&& CheckTxDuration (14, HtPhy::GetHtMcs6 (), 20, 400, WIFI_PREAMBLE_HT_MF, NanoSeconds (39600))
- && CheckTxDuration (1536, HtPhy::GetHtMcs6 (), 20, 400, WIFI_PREAMBLE_HT_GF, NanoSeconds (214800))
- && CheckTxDuration (76, HtPhy::GetHtMcs6 (), 20, 400, WIFI_PREAMBLE_HT_GF, NanoSeconds (34800))
- && CheckTxDuration (14, HtPhy::GetHtMcs6 (), 20, 400, WIFI_PREAMBLE_HT_GF, NanoSeconds (27600))
&& CheckTxDuration (1536, HtPhy::GetHtMcs7 (), 40, 800, WIFI_PREAMBLE_HT_MF, MicroSeconds (128))
&& CheckTxDuration (76, HtPhy::GetHtMcs7 (), 40, 800, WIFI_PREAMBLE_HT_MF, MicroSeconds (44))
&& CheckTxDuration (14, HtPhy::GetHtMcs7 (), 40, 800, WIFI_PREAMBLE_HT_MF, MicroSeconds (40))
- && CheckTxDuration (1536, HtPhy::GetHtMcs7 (), 40, 800, WIFI_PREAMBLE_HT_GF, MicroSeconds (116))
- && CheckTxDuration (76, HtPhy::GetHtMcs7 (), 40, 800, WIFI_PREAMBLE_HT_GF, MicroSeconds (32))
- && CheckTxDuration (14, HtPhy::GetHtMcs7 (), 40, 800, WIFI_PREAMBLE_HT_GF, MicroSeconds (28))
&& CheckTxDuration (1536, HtPhy::GetHtMcs7 (), 40, 400, WIFI_PREAMBLE_HT_MF, NanoSeconds (118800))
&& CheckTxDuration (76, HtPhy::GetHtMcs7 (), 40, 400, WIFI_PREAMBLE_HT_MF, NanoSeconds (43200))
- && CheckTxDuration (14, HtPhy::GetHtMcs7 (), 40, 400, WIFI_PREAMBLE_HT_MF, NanoSeconds (39600))
- && CheckTxDuration (1536, HtPhy::GetHtMcs7 (), 40, 400, WIFI_PREAMBLE_HT_GF, NanoSeconds (106800))
- && CheckTxDuration (76, HtPhy::GetHtMcs7 (), 40, 400, WIFI_PREAMBLE_HT_GF, NanoSeconds (31200))
- && CheckTxDuration (14, HtPhy::GetHtMcs7 (), 40, 400, WIFI_PREAMBLE_HT_GF, NanoSeconds (27600));
+ && CheckTxDuration (14, HtPhy::GetHtMcs7 (), 40, 400, WIFI_PREAMBLE_HT_MF, NanoSeconds (39600));
NS_TEST_EXPECT_MSG_EQ (retval, true, "an 802.11n duration failed");
@@ -869,29 +854,6 @@ PhyHeaderSectionsTest::DoRun (void)
htSigMode };
CheckPhyHeaderSections (phyEntity->GetPhyHeaderSections (txVector, ppduStart), sections);
- // -> HT-GF format for 1 SS and no ESS
- txVector.SetPreambleType (WIFI_PREAMBLE_HT_GF);
- txVector.SetNss (1);
- txVector.SetNess (0);
- sections = { { WIFI_PPDU_FIELD_PREAMBLE, { { ppduStart,
- ppduStart + MicroSeconds (16) },
- nonHtMode } },
- { WIFI_PPDU_FIELD_HT_SIG, { { ppduStart + MicroSeconds (16),
- ppduStart + MicroSeconds (24) },
- htSigMode } },
- { WIFI_PPDU_FIELD_TRAINING, { { ppduStart + MicroSeconds (24),
- ppduStart + MicroSeconds (24) }, // sole HT-LTF already in preamble
- htSigMode } } };
- CheckPhyHeaderSections (phyEntity->GetPhyHeaderSections (txVector, ppduStart), sections);
-
- // -> HT-GF format for 2 SS and 2 ESS
- txVector.SetNss (2);
- txVector.SetNess (2);
- sections[WIFI_PPDU_FIELD_TRAINING] = { { ppduStart + MicroSeconds (24),
- ppduStart + MicroSeconds (36) }, // 3 HT-LTFs (1 data, since 1 already in preamble, + 2 extension)
- htSigMode };
- CheckPhyHeaderSections (phyEntity->GetPhyHeaderSections (txVector, ppduStart), sections);
-
// ==================================================================================
// 11ac (VHT)