Wi-Fi Multimedia (WMM)

advertisement
Tecnologie e Protocolli per Internet II
l
Wi-Fi QoS: Wi-Fi Multimedia (WMM)
Andrea Detti
Tecnologie e Protocolli per Internet II
Filename: wmm.docx
Pag 1 of 11
Tecnologie e Protocolli per Internet II
1
l
OVERVIEW
The Wi-Fi Multimedia, which acronym is WMM, is a Wi-Fi alliance (http://wi-fi.org/) certification
program for Wi-Fi cards that support QoS.
The QoS feature is achieved by enhancing the IEEE 802.11 MAC layer with the amendment IEEE
802.11e. The functionality IEEE 802.11e makes possible to differentiate data traffic on the wireless
interface, both in terms of delay/jitter and throughput. The IEEE 802.11e defines several
mechanisms of channel access; anyway, the commercial WMM adapters mostly implement the
Enhanced Distributed Channel Access (EDCA), that is the minimum implementation requirement to
succeed the WMM certification.
The Enhanced Distributed Channel Access (EDCA) extend the legacy Distributed Coordination
Function (DCF). For this reason, we prefer to shortly review the DCF in order to better understand
the capabilities of EDCA. We assume the absence of RTS/CTS mechanisms, which practically is
never used.
The DCF channel access algorithm is reported in Figure 1, while Figure 2 reports the time
semantic. When there is a packet to transmit, the MAC layer monitors the channel and if the
channel is free for DIFS seconds (50 s), the packet is transmitted. If the channel is not free, a
back off period is started and at the end of the back off interval, the packet will be transmitted. The
backoff counter is not continuously decreased but it is decreased only when the channel is
considered idle. It is important to observe that a STA considers the channel idle only when the
channel itself is continuously free for DIFS seconds. In this way, the free SIFS (10 s) period
between the MAC frame and the related MAC ACK is not detected by a STA which always
consider the channel as busy and never attempt to transmit between MAC frame and MAC ACK.
The value of the back off counter is a random variable uniformly distributed between 0 and the
Contention Window (CW). The contention window is a value that in absence of collision (i.e., no
loss of MAC ACK) is equal to a value named CWmin, while during a collision period its value is
doubled for each consecutive collision, up to CWmax. The time unit of CW is the slot (20 s) and
the default value of the PHY 802.11b are CWmin=31 and CWmax=1023 (the CWmin value for
PHY 802.11a is instead CWmin=15). Moreover, the values of CWmin/max must be always a power
of 2 minus 1, e.g. 31=2^5-1.
When all interfaces continuously have packets to transmit (i.e., there is saturation), the adoption of
DCF assures that wireless stations (STA) have the same opportunity of getting the channel to
transfer a packet. This involves that all STA obtains the same throughput in terms of packet per
seconds (that does not necessary involve the same throughput in terms of bit per second) and
none traffic differentiation is possible.
Filename: wmm.docx
Pag 2 of 11
Tecnologie e Protocolli per Internet II
l
Figure 3 sketches the average time evolution of packets transmissions when there are two greedy
STAs that access the radio medium and collision are negligible. In the figure each transmission
phase (DIFS+MAC_FRAME_TX+SIFS+MAC_ACK_TX) is represented as occurring in a time
instant. We see that, neglecting the times spent in transmission phases, each STA transfers a
packets every CWmin/2 seconds; CWmin/2 is indeed the average Contention Window in absence
of collision.
Figure 1 - DCF flow chart
Filename: wmm.docx
Pag 3 of 11
Tecnologie e Protocolli per Internet II
l
Figure 2 - DCF time semantics.
Figure 3
Packets transferred on the wireless interface when there are two greedy STAs
operating in DCF (blue: STA n.1; red: STA n.2); each transmission phases is condensed in a
time instant
Figure 4
Packets transferred on the wireless interface when there are two greedy STAs
operating in DCF (blue: STA n.1; red: STA n.2) with different CWmin; each transmission
phases is condensed in a time instant
Starting from Figure 3 the rationale behind the EDCA is drawn in Figure 4: if the two STAs have
different CWmin then their average number of packets transferred in the unit time differs as well.
For instance, if CWmin(2) of the STA n.2 is the half of the one of STA n.1 (CWmin (1)), then the
STA n.2 will get two times the throughput (pkt/sec) of STA n.1. As instance, in Figure 4 number of
s is two times the blue one.
This said, in the following we details the EDCA functionality implemented in a WMM device.
Filename: wmm.docx
Pag 4 of 11
Tecnologie e Protocolli per Internet II
Figure 5
l
EDCA functionality in a WMM device
As we can see from Figure 5, the EDCA MAC subsystem of a device has four queues. Each queue
serves one of the four access class (AC): BacKground (BK), BestEffort (BE), Video (VI), Voice
(VO). The packet classification is mostly done on the base of IP TOS field, but it can also be done
on the basis of 802.1d tags. The mapping between IP TOS and access class is reported in Table
1.
Table 1 Default IP TOS and Access Class mapping
IP TOS value
AC
0
BE
8
BK
160
VI
48
VO
Each queue is served by an independent channel access function (EDCAF), which time semantics
is reported in Figure 6. Each module operates according to the DCF principles and it is
characterized by a specific value of CWmin and CWmax. In doing so, by regulating the CW values
it is possible to differentiate the throughput (pkt/sec) obtained by the four classes. We observe that
the independency of the EDCAFs modules makes possible internal virtual packet collisions among
access classes of the same STA. These collisions are handled by an internal collision resolution
module, which discards the colliding packets, as it occurs
STAs.
Filename: wmm.docx
Pag 5 of 11
Tecnologie e Protocolli per Internet II
l
With respect to the legacy DCF, EDCAF introduces two additional parameters that are TXOP and
AIFS.
Figure 6 - EDCAF time semantics.
The TXOP (transmission opportunity) is the time interval grant to a STA that has acquired the
channel. During this time interval the STA can transfer packets (also more than one) without the
need of perform again a channel contention (i.e., subsequent transmissions are spaced of a SIFS
period). TXOP is often a measured in microseconds and the value zero means that the grant on
the channel is only for a single packet, after that the channel contention must be done again (as in
classical DCF).
Figure 7
Packets transferred on the wireless interface when there are two greedy STAs
operating in DCF (blue: STA n.1; red: STA n.2) with different CWmin and TXOP of STA n.2.
makes possible the transmission of two frames; each transmission phases is condensed in
a time instant
Figure 7 sketches the average time evolution of packets transmissions when there are two greedy
STAs that access the radio medium and collision are negligible. As it occurs in Figure 4, STA n.2
has a CWmin that is the half of the one of STA n.1, but in this case, STA n.2 has also the
advantage of having a TXOP such large as to make possible the transmission of two frames each
Filename: wmm.docx
Pag 6 of 11
Tecnologie e Protocolli per Internet II
l
time the STA gets the channel. In doing so, we can see that with respect to the Figure 4, in Figure
7 the STA n.2 has doubled its throughput (pkt/sec).
The AIFS in EDCAF has the same role of DIFS in DCF. A value of AIFS equal to x means a time
interval equal to SIDS+x*slot_time (thus, a DIFS time is equal to AIFS=2). The impact of AIFS on
traffic differentiation is a bit complex to explain. We observe that a STA considers the channel as
idle if it has sensed a continuous free channel for AIFS seconds. Consequently, a smaller AIFS
allows to more often consider the channel as idle and to decrease backoff counter, until
transmission. This differentiation effects is not relevant when the traffic is low, but when there are
many greedy STAs, then the AIFS differentiation yields a valuable impact on performance; indeed,
the free periods between MAC frames are shorter and only the EDCAF with small AIFS may sense
the channel idle and decrement their backoff counter.
Let us now comment the rationale in configuring CWmin, TXOP and AIFS. A reduction of CWmin
decreases the mean time spent in waiting the transmission opportunity, thus it involves a reduction
of the latency and an increase of the throughput (pkt/sec). An increase of TXOP involves an
increase of the throughput (pkt/sec) and a further reduction of latency for bursty traffic (e.g. MPEG
video); indeed, a burst of data may be transferred within a single channel access. Finally, AIFS is
used to give a traffic priority that increase with the level of saturation of the interface, hence small
AIFS should be given to the premium traffic.
The default parameter configuration of EDCA is reported in Table 2. For the 802.11b PHY,
aCWmin=31 and aCWmax=1023. For 802.11g/a PHY, aCWmin=15 and aCWmax=1023
Table 2 Default values of EDCA parameters
As far as the WMM configuration in a BSS (Wi-Fi with AP) is concerned, it is worth to note that the
AP may overrule the default parameters by distributing a new parameter set on the beacon frame.
In a IBSS (i.e., STA in ad-hoc mode) the default values are used, although each STA may change
Filename: wmm.docx
Pag 7 of 11
Tecnologie e Protocolli per Internet II
l
them locally without any global agreement. Anyway, we observe that in ad-hoc mode many off-theshelf adapters do not support WMM (unless driver is hacked).
The AC_BK traffic is the lower traffic priority and its AIFS is very large; consequently, in case of
strong congestion this traffic class is practically starved.
The AC_BE traffic class is quite similar to the only one supported by DCF, with the difference that
instead of DIFS=50
s, that class has to wait a AIFS=70 s. When there are on AC_BE and
AC_BK and when there is a small number of STAs, the BE_AC perform a bit better than AC_BK;
whereas, when there are a lot of contending STAs, the smaller AIFS make starved the BK_AC.
Video (AC_VI) and Voice (AC_VO) are the premium classes. Their small value of CWmin allows
these classes to get the most of available bandwidth. Moreover, the small value of AIFS involves
that in case of strong distributed saturation these two classes are the only one that do not starve.
We observe that AC_VO has a CWmin that is the half of the CWmin of AV_VO but on the contrary,
the TXOP of AC_VI is two times the one of AC_VO, thus balancing the CWmin difference. The
rationale behind this choice is the fact that voice requires a lower delay (smaller CWmin) and the
traffic is no so much bursty (smaller TXOP); on the contrary, video support a bit better delay/jitter
(greater CWmin) but its traffic may be more bursty (larger TXOP)
Filename: wmm.docx
Pag 8 of 11
Tecnologie e Protocolli per Internet II
2
l
POISSON TRAFFIC TESTBED
To give an idea of traffic differentiation performed by WMM, we set-up a small test-bed formed by
two STAs, operating in ad-hoc mode 802.11b (see Figure 8). On the STA n.1 (192.168.96.1), we
setup four Poisson/UDP1 greedy (i.e., 10 Mbps) sources, each source belongs to a different
Access Class: source 1 is AC_BK, source 2 is AC_BE, source 3 is AC_VI and source 4 is AC_VO.
On the STA n.2 (192.168.96.2), we setup the relevant receivers. The test runs for 120 seconds and
the i-th source starts at (i-1)*30 s and stops at the end of test. The OS is Linux, Kernel 2.6.22,
Kubuntu 7.10 distribution. Previous Kernels seems to not support WMM. The Wi-Fi adapters are
Linksys/Cisco WPC55AG, which has an Atheros chipset AR5212/AR5213 (rev 01). The Linux
driver is madwifi-ng (http://madwifi.org) release r3456. This driver does not natively support WMM
in ad-hoc mode, thus we opportunely hacked it to enable WMM in ad-hoc mode.
Figure 8
Wireless test-bed architecture
Figure 9 reports the useful data rate (goodput) obtained by the four traffic streams, while Figure 10
report the relevant delays. We see how when an higher priority source begins to transmit the
goodput of the lower priority sources significantly decreases and delay significantly increases.
Moreover, the Video and Voice access classes practically get the most of available bandwidth and
have very lower delay than the other classes2.
1
With the term Poisson source, we means a source that emits packets with an interarrival times distributed in an expneg form and constant packet payload size of 1460 bytes.
2
The aggressiveness of AC_VI and AC_VO may be further exacerbated in presence of more STAs, as AIFS difference
have a greater impact.
Filename: wmm.docx
Pag 9 of 11
Tecnologie e Protocolli per Internet II
Figure 9
Figure 10
l
Goodput with Wi-Fi WMM
Delay with Wi-Fi WMM
Finally, we qualitatively generalize the obtained results to the case of more transmitting STAs. The
goodput reported in Figure 9
transmitting STAs and it is not the goodput of a single transmitting STA; moreover, within the same
access class, different transmitting STAs fairly share the available bandwidth. As far as the delays
Filename: wmm.docx
Pag 10 of 11
Tecnologie e Protocolli per Internet II
l
reported in Figure 10, a dual reasoning may be done: as instance, in case of two transmitting
STAs, each STA will get the half of the bandwidth reported in Figure 9, then experiences more or
less two times the delays reported in Figure 10.
Filename: wmm.docx
Pag 11 of 11
Download