Bug 910: Replace AccessClass with 802.11-style AcIndex
authorDean Armstrong <deanarm@gmail.com>
Thu, 03 Jun 2010 17:23:55 +0100
changeset 6331 eee2eab36748
parent 6330 af9c574246d5
child 6332 20aa2a218037
Bug 910: Replace AccessClass with 802.11-style AcIndex
src/devices/mesh/mesh-wifi-interface-mac.cc
src/devices/mesh/mesh-wifi-interface-mac.h
src/devices/wifi/edca-txop-n.cc
src/devices/wifi/edca-txop-n.h
src/devices/wifi/mac-low.cc
src/devices/wifi/mac-low.h
src/devices/wifi/qadhoc-wifi-mac.cc
src/devices/wifi/qadhoc-wifi-mac.h
src/devices/wifi/qap-wifi-mac.cc
src/devices/wifi/qap-wifi-mac.h
src/devices/wifi/qos-utils.cc
src/devices/wifi/qos-utils.h
src/devices/wifi/qsta-wifi-mac.cc
src/devices/wifi/qsta-wifi-mac.h
src/devices/wifi/wifi-mac.cc
src/devices/wifi/wifi-mac.h
src/devices/wifi/wifi.h
src/helper/qos-wifi-mac-helper.cc
src/helper/qos-wifi-mac-helper.h
--- a/src/devices/mesh/mesh-wifi-interface-mac.cc	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/mesh/mesh-wifi-interface-mac.cc	Thu Jun 03 17:23:55 2010 +0100
@@ -102,7 +102,10 @@
   m_beaconDca->SetMaxCw (0);
   m_beaconDca->SetAifsn (1);
   m_beaconDca->SetManager (m_dcfManager);
-  
+
+  // Construct the EDCAFs. The ordering is important - highest
+  // priority (see Table 9-1 in IEEE 802.11-2007) must be created
+  // first.
   SetQueue (AC_VO);
   SetQueue (AC_VI);
   SetQueue (AC_BE);
@@ -402,7 +405,7 @@
     }
   //Classify: application sets a tag, which is removed here
   // Get Qos tag:
-  AccessClass ac = AC_BE;
+  AcIndex ac = AC_BE;
   QosTag tag;
   if (packet->RemovePacketTag (tag))
     {
@@ -699,7 +702,7 @@
   m_stats = Statistics ();
 }
 void
-MeshWifiInterfaceMac::SetQueue (AccessClass ac)
+MeshWifiInterfaceMac::SetQueue (AcIndex ac)
 {
   if (m_queues.find (ac) != m_queues.end ())
     {
--- a/src/devices/mesh/mesh-wifi-interface-mac.h	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/mesh/mesh-wifi-interface-mac.h	Thu Jun 03 17:23:55 2010 +0100
@@ -159,7 +159,7 @@
   void ResetStats ();
   /// Enable/disable beacons
   void SetBeaconGeneration (bool enable);
-  void SetQueue (AccessClass ac);
+  void SetQueue (AcIndex ac);
   WifiPhyStandard GetPhyStandard () const;
   virtual void FinishConfigureStandard (enum WifiPhyStandard standard);
 private:
@@ -184,7 +184,7 @@
   void DoStart ();
 
 private:
-  typedef std::map<AccessClass, Ptr<DcaTxop> > Queues;
+  typedef std::map<AcIndex, Ptr<DcaTxop> > Queues;
   typedef std::vector<Ptr<MeshWifiInterfaceMacPlugin> > PluginList;
   ///\name Wifi MAC internals
   //\{
--- a/src/devices/wifi/edca-txop-n.cc	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/edca-txop-n.cc	Thu Jun 03 17:23:55 2010 +0100
@@ -771,7 +771,7 @@
 }
 
 void
-EdcaTxopN::SetAccessClass (enum AccessClass ac)
+EdcaTxopN::SetAccessCategory (enum AcIndex ac)
 {
   m_ac = ac;
 }
--- a/src/devices/wifi/edca-txop-n.h	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/edca-txop-n.h	Thu Jun 03 17:23:55 2010 +0100
@@ -137,7 +137,7 @@
   void NextFragment (void);
   Ptr<Packet> GetFragmentPacket (WifiMacHeader *hdr);
   
-  void SetAccessClass (enum AccessClass ac);
+  void SetAccessCategory (enum AcIndex ac);
   void Queue (Ptr<const Packet> packet, const WifiMacHeader &hdr);
   void SetMsduAggregator (Ptr<MsduAggregator> aggr);
   void PushFront (Ptr<const Packet> packet, const WifiMacHeader &hdr);
@@ -185,7 +185,7 @@
    */
   void VerifyBlockAck (void);
   
-  AccessClass m_ac;
+  AcIndex m_ac;
   class Dcf;
   class TransmissionListener;
   class BlockAckEventListener;
--- a/src/devices/wifi/mac-low.cc	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/mac-low.cc	Thu Jun 03 17:23:55 2010 +0100
@@ -829,7 +829,7 @@
              data MPDUs with the Ack Policy subfield set to Block Ack, it shall discard
              them and shall send a DELBA frame using the normal access 
              mechanisms. */
-          AccessClass ac = QosUtilsMapTidToAc (hdr.GetQosTid ());
+          AcIndex ac = QosUtilsMapTidToAc (hdr.GetQosTid ());
           m_edcaListeners[ac]->BlockAckInactivityTimeout (hdr.GetAddr2 (), hdr.GetQosTid ());
           return;
         }
@@ -1538,7 +1538,7 @@
       AgreementsI it = m_bAckAgreements.find (std::make_pair (originator, respHdr->GetTid ()));
       Time timeout = MicroSeconds (1024 * agreement.GetTimeout ());
  
-      AccessClass ac = QosUtilsMapTidToAc (agreement.GetTid ());
+      AcIndex ac = QosUtilsMapTidToAc (agreement.GetTid ());
       
       it->second.first.m_inactivityEvent = Simulator::Schedule (timeout,
                                                                 &MacLowBlockAckEventListener::BlockAckInactivityTimeout,
@@ -1846,8 +1846,8 @@
       agreement.m_inactivityEvent.Cancel ();
       Time timeout = MicroSeconds (1024 * agreement.GetTimeout ());
 
-      AccessClass ac = QosUtilsMapTidToAc (agreement.GetTid ());
-      //std::map<AccessClass, MacLowTransmissionListener*>::iterator it = m_edcaListeners.find (ac);
+      AcIndex ac = QosUtilsMapTidToAc (agreement.GetTid ());
+      //std::map<AcIndex, MacLowTransmissionListener*>::iterator it = m_edcaListeners.find (ac);
       //NS_ASSERT (it != m_edcaListeners.end ());
 
       agreement.m_inactivityEvent = Simulator::Schedule (timeout, 
@@ -1859,7 +1859,7 @@
 }
 
 void
-MacLow::RegisterBlockAckListenerForAc (enum AccessClass ac, MacLowBlockAckEventListener *listener)
+MacLow::RegisterBlockAckListenerForAc (enum AcIndex ac, MacLowBlockAckEventListener *listener)
 {
   m_edcaListeners.insert (std::make_pair (ac, listener));
 }
--- a/src/devices/wifi/mac-low.h	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/mac-low.h	Thu Jun 03 17:23:55 2010 +0100
@@ -479,7 +479,7 @@
    * The lifetime of the registered listener is typically equal to the lifetime of the queue
    * associated to this AC.
    */
-  void RegisterBlockAckListenerForAc (enum AccessClass ac, MacLowBlockAckEventListener *listener);
+  void RegisterBlockAckListenerForAc (enum AcIndex ac, MacLowBlockAckEventListener *listener);
 private:
   void CancelAllEvents (void);
   uint32_t GetAckSize (void) const;
@@ -631,7 +631,7 @@
 
   Agreements m_bAckAgreements;
   
-  typedef std::map<AccessClass, MacLowBlockAckEventListener*> QueueListeners;
+  typedef std::map<AcIndex, MacLowBlockAckEventListener*> QueueListeners;
   QueueListeners m_edcaListeners;
 };
 
--- a/src/devices/wifi/qadhoc-wifi-mac.cc	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/qadhoc-wifi-mac.cc	Thu Jun 03 17:23:55 2010 +0100
@@ -85,6 +85,9 @@
   m_dcfManager = new DcfManager ();
   m_dcfManager->SetupLowListener (m_low);
 
+  // Construct the EDCAFs. The ordering is important - highest
+  // priority (see Table 9-1 in IEEE 802.11-2007) must be created
+  // first.
   SetQueue (AC_VO);
   SetQueue (AC_VI);
   SetQueue (AC_BE);
@@ -278,7 +281,7 @@
   if (tid < 8)
     {
       hdr.SetQosTid (tid);
-      AccessClass ac = QosUtilsMapTidToAc (tid);
+      AcIndex ac = QosUtilsMapTidToAc (tid);
       m_queues[ac]->Queue (packet, hdr);
     }
   else
@@ -404,7 +407,7 @@
               else
                 {
                   /* We must notify correct queue tear down of agreement */
-                  AccessClass ac = QosUtilsMapTidToAc (delBaHdr.GetTid ());
+                  AcIndex ac = QosUtilsMapTidToAc (delBaHdr.GetTid ());
                   m_queues[ac]->GotDelBaFrame (&delBaHdr, hdr->GetAddr2 ());
                 }
             }
@@ -458,14 +461,14 @@
 }
 
 void
-QadhocWifiMac::SetQueue (enum AccessClass ac)
+QadhocWifiMac::SetQueue (enum AcIndex ac)
 {
   Ptr<EdcaTxopN> edca = CreateObject<EdcaTxopN> ();
   edca->SetLow (m_low);
   edca->SetManager (m_dcfManager);
   edca->SetTypeOfStation (ADHOC_STA);
   edca->SetTxMiddle (m_txMiddle);
-  edca->SetAccessClass (ac);
+  edca->SetAccessCategory (ac);
   edca->CompleteConfig ();
   m_queues.insert (std::make_pair(ac, edca));
 }
--- a/src/devices/wifi/qadhoc-wifi-mac.h	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/qadhoc-wifi-mac.h	Thu Jun 03 17:23:55 2010 +0100
@@ -96,12 +96,12 @@
   */
   void DeaggregateAmsduAndForward (Ptr<Packet> aggregatedPacket, const WifiMacHeader *hdr);
 
-  typedef std::map<AccessClass, Ptr<EdcaTxopN> > Queues;
+  typedef std::map<AcIndex, Ptr<EdcaTxopN> > Queues;
   typedef std::list<std::pair<Ptr<Packet>, AmsduSubframeHeader> > DeaggregatedMsdus;
   typedef std::list<std::pair<Ptr<Packet>, AmsduSubframeHeader> >::const_iterator DeaggregatedMsdusCI;
 
   virtual void FinishConfigureStandard (enum WifiPhyStandard standard);
-  void SetQueue (enum AccessClass ac);
+  void SetQueue (enum AcIndex ac);
   Ptr<EdcaTxopN> GetVOQueue (void) const;
   Ptr<EdcaTxopN> GetVIQueue (void) const;
   Ptr<EdcaTxopN> GetBEQueue (void) const;
--- a/src/devices/wifi/qap-wifi-mac.cc	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/qap-wifi-mac.cc	Thu Jun 03 17:23:55 2010 +0100
@@ -106,6 +106,9 @@
   m_beaconDca->SetLow (m_low);
   m_beaconDca->SetManager (m_dcfManager);
 
+  // Construct the EDCAFs. The ordering is important - highest
+  // priority (see Table 9-1 in IEEE 802.11-2007) must be created
+  // first.
   SetQueue (AC_VO);
   SetQueue (AC_VI);
   SetQueue (AC_BE);
@@ -399,7 +402,7 @@
   if (tid < 8)
     {
       hdr.SetQosTid (tid);
-      AccessClass ac = QosUtilsMapTidToAc (tid);
+      AcIndex ac = QosUtilsMapTidToAc (tid);
       m_queues[ac]->Queue (packet, hdr);
     }
   else
@@ -435,7 +438,7 @@
   hdr.SetDsFrom ();
   hdr.SetDsNotTo ();
 
-  AccessClass ac = QosUtilsMapTidToAc (oldHdr->GetQosTid ());
+  AcIndex ac = QosUtilsMapTidToAc (oldHdr->GetQosTid ());
   m_queues[ac]->Queue (packet, hdr);
 }
 
@@ -737,7 +740,7 @@
                   else
                     {
                       /* We must notify correct queue tear down of agreement */
-                      AccessClass ac = QosUtilsMapTidToAc (delBaHdr.GetTid ());
+                      AcIndex ac = QosUtilsMapTidToAc (delBaHdr.GetTid ());
                       m_queues[ac]->GotDelBaFrame (&delBaHdr, hdr->GetAddr2 ());
                     }
                 }
@@ -803,7 +806,7 @@
 }
 
 void
-QapWifiMac::SetQueue (enum AccessClass ac)
+QapWifiMac::SetQueue (enum AcIndex ac)
 {
   Ptr<EdcaTxopN> edca = CreateObject<EdcaTxopN> ();
   edca->SetLow (m_low);
@@ -812,7 +815,7 @@
   edca->SetTxMiddle (m_txMiddle);
   edca->SetTxOkCallback (MakeCallback (&QapWifiMac::TxOk, this));
   edca->SetTxFailedCallback (MakeCallback (&QapWifiMac::TxFailed, this));
-  edca->SetAccessClass (ac);
+  edca->SetAccessCategory (ac);
   edca->CompleteConfig ();
   m_queues.insert (std::make_pair(ac, edca));
 }
--- a/src/devices/wifi/qap-wifi-mac.h	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/qap-wifi-mac.h	Thu Jun 03 17:23:55 2010 +0100
@@ -92,7 +92,7 @@
   void StartBeaconing (void);
 
 private:
-  typedef std::map<AccessClass, Ptr<EdcaTxopN> > Queues;
+  typedef std::map<AcIndex, Ptr<EdcaTxopN> > Queues;
   typedef std::list<std::pair<Ptr<Packet>, AmsduSubframeHeader> > DeaggregatedMsdus;
   typedef std::list<std::pair<Ptr<Packet>, AmsduSubframeHeader> >::const_iterator DeaggregatedMsdusCI;
   
@@ -122,7 +122,7 @@
   Ptr<EdcaTxopN> GetVIQueue (void) const;
   Ptr<EdcaTxopN> GetBEQueue (void) const;
   Ptr<EdcaTxopN> GetBKQueue (void) const;
-  void SetQueue (enum AccessClass ac);
+  void SetQueue (enum AcIndex ac);
 
   virtual void FinishConfigureStandard (enum WifiPhyStandard standard);
 
--- a/src/devices/wifi/qos-utils.cc	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/qos-utils.cc	Thu Jun 03 17:23:55 2010 +0100
@@ -23,7 +23,7 @@
 
 namespace ns3 {
 
-AccessClass
+AcIndex
 QosUtilsMapTidToAc (uint8_t tid)
 {
   switch (tid) {
--- a/src/devices/wifi/qos-utils.h	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/qos-utils.h	Thu Jun 03 17:23:55 2010 +0100
@@ -26,11 +26,21 @@
 
 namespace ns3 {
 
-enum AccessClass {
-  AC_VO = 0,
-  AC_VI = 1,
-  AC_BE = 2,
-  AC_BK = 3,
+/* This enumeration defines the Access Categories as an enumeration
+ * with values corresponding to the AC index (ACI) values specified in
+ * Table 7-36 of IEEE 802.11-2007.
+ */
+enum AcIndex {
+  /** Best Effort */
+  AC_BE = 0,
+  /** Background */
+  AC_BK = 1,
+  /** Video */
+  AC_VI = 2,
+  /** Voice */
+  AC_VO = 3,
+
+  /** Total number of ACs */
   AC_BE_NQOS = 4,
   AC_UNDEF
 };
@@ -38,7 +48,7 @@
 /* Maps TID (Traffic ID) to Access classes.
  * For more details see table 9-1 of IEEE802.11 standard.
  */
-AccessClass QosUtilsMapTidToAc (uint8_t tid);
+AcIndex QosUtilsMapTidToAc (uint8_t tid);
 
 /* If a qos tag is attached to the packet, returns a value < 8.
    A value >= 8 is returned otherwise.
--- a/src/devices/wifi/qsta-wifi-mac.cc	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/qsta-wifi-mac.cc	Thu Jun 03 17:23:55 2010 +0100
@@ -109,6 +109,9 @@
   m_dcfManager = new DcfManager ();
   m_dcfManager->SetupLowListener (m_low);
 
+  // Construct the EDCAFs. The ordering is important - highest
+  // priority (see Table 9-1 in IEEE 802.11-2007) must be created
+  // first.
   SetQueue (AC_VO);
   SetQueue (AC_VI);
   SetQueue (AC_BE);
@@ -546,7 +549,7 @@
   if (tid < 8)
     {
       hdr.SetQosTid (tid);
-      AccessClass ac = QosUtilsMapTidToAc (tid);
+      AcIndex ac = QosUtilsMapTidToAc (tid);
       m_queues[ac]->Queue (packet, hdr);
     }
   else
@@ -730,7 +733,7 @@
           else
             {
               /* We must notify correct queue tear down of agreement */
-              AccessClass ac = QosUtilsMapTidToAc (delBaHdr.GetTid ());
+              AcIndex ac = QosUtilsMapTidToAc (delBaHdr.GetTid ());
               m_queues[ac]->GotDelBaFrame (&delBaHdr, hdr->GetAddr2 ());
             }
         }
@@ -785,14 +788,14 @@
 }
 
 void
-QstaWifiMac::SetQueue (enum AccessClass ac)
+QstaWifiMac::SetQueue (enum AcIndex ac)
 {
   Ptr<EdcaTxopN> edca = CreateObject<EdcaTxopN> ();
   edca->SetLow (m_low);
   edca->SetManager (m_dcfManager);
   edca->SetTypeOfStation (STA);
   edca->SetTxMiddle (m_txMiddle);
-  edca->SetAccessClass (ac);
+  edca->SetAccessCategory (ac);
   edca->CompleteConfig ();
   m_queues.insert (std::make_pair(ac, edca));
 }
--- a/src/devices/wifi/qsta-wifi-mac.h	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/qsta-wifi-mac.h	Thu Jun 03 17:23:55 2010 +0100
@@ -121,13 +121,13 @@
   QstaWifiMac &operator = (const QstaWifiMac &);
   QstaWifiMac (const QstaWifiMac &);
   virtual void FinishConfigureStandard (enum WifiPhyStandard standard);
-  void SetQueue (enum AccessClass ac);
+  void SetQueue (enum AcIndex ac);
   Ptr<EdcaTxopN> GetVOQueue (void) const;
   Ptr<EdcaTxopN> GetVIQueue (void) const;
   Ptr<EdcaTxopN> GetBEQueue (void) const;
   Ptr<EdcaTxopN> GetBKQueue (void) const;
 
-  typedef std::map<AccessClass, Ptr<EdcaTxopN> > Queues;
+  typedef std::map<AcIndex, Ptr<EdcaTxopN> > Queues;
   typedef std::list<std::pair<Ptr<Packet>, AmsduSubframeHeader> > DeaggregatedMsdus;
   typedef std::list<std::pair<Ptr<Packet>, AmsduSubframeHeader> >::const_iterator DeaggregatedMsdusCI;
     
--- a/src/devices/wifi/wifi-mac.cc	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/wifi-mac.cc	Thu Jun 03 17:23:55 2010 +0100
@@ -356,7 +356,7 @@
 }
 
 void
-WifiMac::ConfigureDcf (Ptr<Dcf> dcf, uint32_t cwmin, uint32_t cwmax, enum AccessClass ac)
+WifiMac::ConfigureDcf (Ptr<Dcf> dcf, uint32_t cwmin, uint32_t cwmax, enum AcIndex ac)
 {
   /* see IEE802.11 section 7.3.2.29 */
   switch (ac) {
@@ -392,7 +392,7 @@
 }
 
 void
-WifiMac::ConfigureCCHDcf (Ptr<Dcf> dcf, uint32_t cwmin, uint32_t cwmax, enum AccessClass ac)
+WifiMac::ConfigureCCHDcf (Ptr<Dcf> dcf, uint32_t cwmin, uint32_t cwmax, enum AcIndex ac)
 {
   /* see IEEE 1609.4-2006 section 6.3.1, Table 1 */
   switch (ac) {
--- a/src/devices/wifi/wifi-mac.h	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/wifi-mac.h	Thu Jun 03 17:23:55 2010 +0100
@@ -218,8 +218,8 @@
   void ConfigureStandard (enum WifiPhyStandard standard);
 
 protected:
-  void ConfigureDcf (Ptr<Dcf> dcf, uint32_t cwmin, uint32_t cwmax, enum AccessClass ac);
-  void ConfigureCCHDcf (Ptr<Dcf> dcf, uint32_t cwmin, uint32_t cwmax, enum AccessClass ac);
+  void ConfigureDcf (Ptr<Dcf> dcf, uint32_t cwmin, uint32_t cwmax, enum AcIndex ac);
+  void ConfigureCCHDcf (Ptr<Dcf> dcf, uint32_t cwmin, uint32_t cwmax, enum AcIndex ac);
 private:
   static Time GetDefaultMaxPropagationDelay (void);
   static Time GetDefaultSlot (void);
--- a/src/devices/wifi/wifi.h	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/devices/wifi/wifi.h	Thu Jun 03 17:23:55 2010 +0100
@@ -44,7 +44,7 @@
  *     belonging to AC_BE access class. 
  *     How TIDs are mapped to access classes are shown in the table below. 
  *   
- *     TID-AccessClass mapping:
+ *     TID-AcIndex mapping:
  *     
  *      <table border=1>
  *      <tr>
--- a/src/helper/qos-wifi-mac-helper.cc	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/helper/qos-wifi-mac-helper.cc	Thu Jun 03 17:23:55 2010 +0100
@@ -64,13 +64,13 @@
 }
 
 void
-QosWifiMacHelper::SetMsduAggregatorForAc (AccessClass accessClass, std::string type,
+QosWifiMacHelper::SetMsduAggregatorForAc (AcIndex ac, std::string type,
                                           std::string n0, const AttributeValue &v0,
                                           std::string n1, const AttributeValue &v1,
                                           std::string n2, const AttributeValue &v2,
                                           std::string n3, const AttributeValue &v3)
 {
-  std::map<AccessClass, ObjectFactory>::iterator it = m_aggregators.find (accessClass);
+  std::map<AcIndex, ObjectFactory>::iterator it = m_aggregators.find (ac);
   if (it != m_aggregators.end ())
     {
       it->second.SetTypeId (type);
@@ -87,26 +87,26 @@
       factory.Set (n1, v1);
       factory.Set (n2, v2);
       factory.Set (n3, v3);
-      m_aggregators.insert (std::make_pair (accessClass, factory));
+      m_aggregators.insert (std::make_pair (ac, factory));
     }
 }
 
 void
-QosWifiMacHelper::SetBlockAckThresholdForAc (enum AccessClass accessClass, uint8_t threshold)
+QosWifiMacHelper::SetBlockAckThresholdForAc (enum AcIndex ac, uint8_t threshold)
 {
-  m_bAckThresholds[accessClass] = threshold;
+  m_bAckThresholds[ac] = threshold;
 }
 
 void
-QosWifiMacHelper::SetBlockAckInactivityTimeoutForAc (enum AccessClass accessClass, uint16_t timeout)
+QosWifiMacHelper::SetBlockAckInactivityTimeoutForAc (enum AcIndex ac, uint16_t timeout)
 {
-  m_bAckInactivityTimeouts[accessClass] = timeout;
+  m_bAckInactivityTimeouts[ac] = timeout;
 }
 
 void
-QosWifiMacHelper::Setup (Ptr<WifiMac> mac, enum AccessClass ac, std::string dcaAttrName) const
+QosWifiMacHelper::Setup (Ptr<WifiMac> mac, enum AcIndex ac, std::string dcaAttrName) const
 {
-  std::map<AccessClass, ObjectFactory>::const_iterator it = m_aggregators.find (ac);
+  std::map<AcIndex, ObjectFactory>::const_iterator it = m_aggregators.find (ac);
   PointerValue ptr;
   mac->GetAttribute (dcaAttrName, ptr);
   Ptr<EdcaTxopN> edca = ptr.Get<EdcaTxopN> ();
--- a/src/helper/qos-wifi-mac-helper.h	Thu Jun 03 13:34:09 2010 +0200
+++ b/src/helper/qos-wifi-mac-helper.h	Thu Jun 03 17:23:55 2010 +0100
@@ -87,7 +87,7 @@
   /**
    * Set the class, type and attributes for the Msdu aggregator
    *
-   * \param accessClass access class for which we are setting aggregator. Possibilities
+   * \param ac access category for which we are setting aggregator. Possibilities
    *  are: AC_BK, AC_BE, AC_VI, AC_VO.
    * \param type the type of ns3::MsduAggregator to create.
    * \param n0 the name of the attribute to set
@@ -102,7 +102,7 @@
    * All the attributes specified in this method should exist
    * in the requested aggregator.
    */
-  void SetMsduAggregatorForAc (AccessClass accessClass, std::string type,
+  void SetMsduAggregatorForAc (AcIndex ac, std::string type,
                                std::string n0 = "", const AttributeValue &v0 = EmptyAttributeValue (),
                                std::string n1 = "", const AttributeValue &v1 = EmptyAttributeValue (),
                                std::string n2 = "", const AttributeValue &v2 = EmptyAttributeValue (),
@@ -112,11 +112,11 @@
    * If number of packets in the respective queue reaches this value block ack mechanism
    * is used.
    *
-   * \param accessClass access class for which we are setting block ack threshold. Possibilities
+   * \param ac access category for which we are setting block ack threshold. Possibilities
    * are: AC_BK, AC_BE, AC_VI, AC_VO.
    * \param threshold the threshold (number of packets)
    */
-  void SetBlockAckThresholdForAc (enum AccessClass accessClass, uint8_t threshold);
+  void SetBlockAckThresholdForAc (enum AcIndex ac, uint8_t threshold);
   /**
    * Sets value of block ack inactivity timeout for a specific access class. <i>timeout</i>
    * represents number of blocks of 1024 microseconds. When this timer expires the relative
@@ -124,11 +124,11 @@
    * that a block ack request or a MPDU with ack policy BLOCK ACK is received.
    * Timer is reset in a originator station every time that a block ack frame is received.
    * 
-   * \param accessClass access class for which we are setting block ack threshold. Possibilities
+   * \param ac access category for which we are setting block ack threshold. Possibilities
    * are: AC_BK, AC_BE, AC_VI, AC_VO.
    * \param timeout number of block of 1024 microseconds.
    */
-  void SetBlockAckInactivityTimeoutForAc (enum AccessClass accessClass, uint16_t timeout);
+  void SetBlockAckInactivityTimeoutForAc (enum AcIndex ac, uint16_t timeout);
 private:
   /**
    * \internal
@@ -137,17 +137,17 @@
    * This method implements the pure virtual method defined in \ref ns3::WifiMacHelper.
    */
   virtual Ptr<WifiMac> Create (void) const;
-  void Setup (Ptr<WifiMac> mac, enum AccessClass ac, std::string dcaAttrName) const;
+  void Setup (Ptr<WifiMac> mac, enum AcIndex ac, std::string dcaAttrName) const;
 
 
   ObjectFactory m_mac;
-  std::map<AccessClass, ObjectFactory> m_aggregators;
+  std::map<AcIndex, ObjectFactory> m_aggregators;
   /* 
-   * Next maps contain, for every access class, the values for block ack threshold and
-   * block ack inactivity timeout.
+   * Next maps contain, for every access category, the values for
+   * block ack threshold and block ack inactivity timeout.
    */
-  std::map<AccessClass, uint8_t> m_bAckThresholds;
-  std::map<AccessClass, uint16_t> m_bAckInactivityTimeouts;
+  std::map<AcIndex, uint8_t> m_bAckThresholds;
+  std::map<AcIndex, uint16_t> m_bAckInactivityTimeouts;
 };
 
 } //namespace ns3