ieee80211_output.c (232480) | ieee80211_output.c (234324) |
---|---|
1/*- 2 * Copyright (c) 2001 Atsushi Onoe 3 * Copyright (c) 2002-2009 Sam Leffler, Errno Consulting 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 11 unchanged lines hidden (view full) --- 20 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25 */ 26 27#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2001 Atsushi Onoe 3 * Copyright (c) 2002-2009 Sam Leffler, Errno Consulting 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 11 unchanged lines hidden (view full) --- 20 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25 */ 26 27#include <sys/cdefs.h> |
28__FBSDID("$FreeBSD: head/sys/net80211/ieee80211_output.c 232480 2012-03-04 05:52:26Z adrian $"); | 28__FBSDID("$FreeBSD: head/sys/net80211/ieee80211_output.c 234324 2012-04-15 20:29:39Z adrian $"); |
29 30#include "opt_inet.h" 31#include "opt_inet6.h" 32#include "opt_wlan.h" 33 34#include <sys/param.h> 35#include <sys/systm.h> 36#include <sys/mbuf.h> --- 281 unchanged lines hidden (view full) --- 318 * it might be collected by the driver and held/retransmit. 319 * The default ic_ampdu_enable routine handles staggering 320 * ADDBA requests in case the receiver NAK's us or we are 321 * otherwise unable to establish a BA stream. 322 */ 323 if ((ni->ni_flags & IEEE80211_NODE_AMPDU_TX) && 324 (vap->iv_flags_ht & IEEE80211_FHT_AMPDU_TX) && 325 (m->m_flags & M_EAPOL) == 0) { | 29 30#include "opt_inet.h" 31#include "opt_inet6.h" 32#include "opt_wlan.h" 33 34#include <sys/param.h> 35#include <sys/systm.h> 36#include <sys/mbuf.h> --- 281 unchanged lines hidden (view full) --- 318 * it might be collected by the driver and held/retransmit. 319 * The default ic_ampdu_enable routine handles staggering 320 * ADDBA requests in case the receiver NAK's us or we are 321 * otherwise unable to establish a BA stream. 322 */ 323 if ((ni->ni_flags & IEEE80211_NODE_AMPDU_TX) && 324 (vap->iv_flags_ht & IEEE80211_FHT_AMPDU_TX) && 325 (m->m_flags & M_EAPOL) == 0) { |
326 const int ac = M_WME_GETAC(m); 327 struct ieee80211_tx_ampdu *tap = &ni->ni_tx_ampdu[ac]; | 326 int tid = WME_AC_TO_TID(M_WME_GETAC(m)); 327 struct ieee80211_tx_ampdu *tap = &ni->ni_tx_ampdu[tid]; |
328 329 ieee80211_txampdu_count_packet(tap); 330 if (IEEE80211_AMPDU_RUNNING(tap)) { 331 /* 332 * Operational, mark frame for aggregation. 333 * 334 * XXX do tx aggregation here 335 */ --- 248 unchanged lines hidden (view full) --- 584 if (vap->iv_opmode == IEEE80211_M_MBSS) 585 IEEE80211_ADDR_COPY(wh->i_addr3, sa); 586 else 587#endif 588 IEEE80211_ADDR_COPY(wh->i_addr3, bssid); 589 } 590 *(uint16_t *)&wh->i_dur[0] = 0; 591 | 328 329 ieee80211_txampdu_count_packet(tap); 330 if (IEEE80211_AMPDU_RUNNING(tap)) { 331 /* 332 * Operational, mark frame for aggregation. 333 * 334 * XXX do tx aggregation here 335 */ --- 248 unchanged lines hidden (view full) --- 584 if (vap->iv_opmode == IEEE80211_M_MBSS) 585 IEEE80211_ADDR_COPY(wh->i_addr3, sa); 586 else 587#endif 588 IEEE80211_ADDR_COPY(wh->i_addr3, bssid); 589 } 590 *(uint16_t *)&wh->i_dur[0] = 0; 591 |
592 tap = &ni->ni_tx_ampdu[TID_TO_WME_AC(tid)]; | 592 tap = &ni->ni_tx_ampdu[tid]; |
593 if (tid != IEEE80211_NONQOS_TID && IEEE80211_AMPDU_RUNNING(tap)) 594 m->m_flags |= M_AMPDU_MPDU; 595 else { 596 seqno = ni->ni_txseqs[tid]++; 597 *(uint16_t *)&wh->i_seq[0] = 598 htole16(seqno << IEEE80211_SEQ_SEQ_SHIFT); 599 M_SEQNO_SET(m, seqno); 600 } --- 2537 unchanged lines hidden --- | 593 if (tid != IEEE80211_NONQOS_TID && IEEE80211_AMPDU_RUNNING(tap)) 594 m->m_flags |= M_AMPDU_MPDU; 595 else { 596 seqno = ni->ni_txseqs[tid]++; 597 *(uint16_t *)&wh->i_seq[0] = 598 htole16(seqno << IEEE80211_SEQ_SEQ_SHIFT); 599 M_SEQNO_SET(m, seqno); 600 } --- 2537 unchanged lines hidden --- |