diff options
author | 2010-04-12 18:02:31 +0000 | |
---|---|---|
committer | 2010-04-12 18:02:31 +0000 | |
commit | 78f42b525ba4ca85f2b5e6280aa09b1424542620 (patch) | |
tree | 37696ac92c592642327346285b04dc4ad91bf894 | |
parent | Don't jump the queue if we have to wait on the client side because (diff) | |
download | wireguard-openbsd-78f42b525ba4ca85f2b5e6280aa09b1424542620.tar.xz wireguard-openbsd-78f42b525ba4ca85f2b5e6280aa09b1424542620.zip |
Make hardware generate 802.11 sequence numbers (except for unicast
QoS data frames) such that the same counter is used for beacons,
management frames and non-QoS data frames.
This will help clients that don't like jumps in sequence numbers,
like the FreeBSD duplicate detection code.
Found after an interesting discussion with Yao Zhao.
-rw-r--r-- | sys/dev/ic/rt2860.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/dev/ic/rt2860.c b/sys/dev/ic/rt2860.c index c1c2399feff..ab0a4e2a9c6 100644 --- a/sys/dev/ic/rt2860.c +++ b/sys/dev/ic/rt2860.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rt2860.c,v 1.50 2010/04/10 07:57:21 damien Exp $ */ +/* $OpenBSD: rt2860.c,v 1.51 2010/04/12 18:02:31 damien Exp $ */ /*- * Copyright (c) 2007-2010 Damien Bergamini <damien.bergamini@free.fr> @@ -1461,7 +1461,8 @@ rt2860_tx(struct rt2860_softc *sc, struct mbuf *m, struct ieee80211_node *ni) /* setup TX Wireless Information */ txwi = data->txwi; txwi->flags = 0; - txwi->xflags = 0; + /* let HW generate seq numbers for non-QoS frames */ + txwi->xflags = hasqos ? 0 : RT2860_TX_NSEQ; txwi->wcid = (type == IEEE80211_FC0_TYPE_DATA) ? RT2860_AID2WCID(ni->ni_associd) : 0xff; txwi->len = htole16(m->m_pkthdr.len); @@ -3708,6 +3709,7 @@ rt2860_setup_beacon(struct rt2860_softc *sc) txwi.phy |= htole16(RT2860_PHY_OFDM); txwi.txop = RT2860_TX_TXOP_HT; txwi.flags = RT2860_TX_TS; + txwi.xflags = RT2860_TX_NSEQ; RAL_WRITE_REGION_1(sc, RT2860_BCN_BASE(0), (uint8_t *)&txwi, sizeof txwi); |