diff --git a/sys/dev/rtwn/rtl8192c/r92c_tx.c b/sys/dev/rtwn/rtl8192c/r92c_tx.c --- a/sys/dev/rtwn/rtl8192c/r92c_tx.c +++ b/sys/dev/rtwn/rtl8192c/r92c_tx.c @@ -452,13 +452,10 @@ } else { uint16_t seqno; - /* TODO: seqno allocate through net80211? */ - /* TODO: what to do about QoS NULL frames? */ - if (m->m_flags & M_AMPDU_MPDU) { - seqno = ni->ni_txseqs[tid] % IEEE80211_SEQ_RANGE; - ni->ni_txseqs[tid]++; - } else - seqno = M_SEQNO_GET(m) % IEEE80211_SEQ_RANGE; + if (m->m_flags & M_AMPDU_MPDU) + ieee80211_output_seqno_assign(ni, -1, m); + + seqno = M_SEQNO_GET(m); /* Set sequence number. */ txd->txdseq = htole16(seqno); @@ -513,7 +510,7 @@ rtwn_r92c_tx_setup_hwseq(sc, txd); } else { /* Set sequence number. */ - txd->txdseq |= htole16(M_SEQNO_GET(m) % IEEE80211_SEQ_RANGE); + txd->txdseq |= htole16(M_SEQNO_GET(m)); } } diff --git a/sys/dev/rtwn/rtl8812a/r12a_tx.c b/sys/dev/rtwn/rtl8812a/r12a_tx.c --- a/sys/dev/rtwn/rtl8812a/r12a_tx.c +++ b/sys/dev/rtwn/rtl8812a/r12a_tx.c @@ -433,14 +433,9 @@ } else { uint16_t seqno; - /* TODO: seqno allocate through net80211? */ - /* TODO: what to do about QoS NULL frames? */ - if (m->m_flags & M_AMPDU_MPDU) { - seqno = ni->ni_txseqs[tid]; - ni->ni_txseqs[tid]++; - } else - seqno = M_SEQNO_GET(m) % IEEE80211_SEQ_RANGE; - + if (m->m_flags & M_AMPDU_MPDU) + ieee80211_output_seqno_assign(ni, -1, m); + seqno = M_SEQNO_GET(m); /* Set sequence number. */ txd->txdw9 |= htole32(SM(R12A_TXDW9_SEQ, seqno)); } @@ -495,8 +490,7 @@ txd->txdw3 |= htole32(SM(R12A_TXDW3_SEQ_SEL, uvp->id)); } else { /* Set sequence number. */ - txd->txdw9 |= htole32(SM(R12A_TXDW9_SEQ, - M_SEQNO_GET(m) % IEEE80211_SEQ_RANGE)); + txd->txdw9 |= htole32(SM(R12A_TXDW9_SEQ, M_SEQNO_GET(m))); } }