1
0
mirror of https://github.com/openbsd/src.git synced 2026-06-19 07:43:34 +02:00

Fix use of wrong tailq pointers in qwx.

Fortunately, this was a non-issue on devices with single radios and
there are no multi-radio devices known to us so far.

With help from kevlo@ who spotted a case I had missed.
This commit is contained in:
stsp
2026-05-31 13:20:20 +00:00
parent 76d412ec20
commit 5406c2792a
+6 -6
View File
@@ -1,4 +1,4 @@
/* $OpenBSD: qwx.c,v 1.119 2026/05/29 09:52:10 stsp Exp $ */
/* $OpenBSD: qwx.c,v 1.120 2026/05/31 13:20:20 stsp Exp $ */
/*
* Copyright 2023 Stefan Sperling <stsp@openbsd.org>
@@ -16811,8 +16811,8 @@ qwx_dp_rx_process_wbm_err(struct qwx_softc *sc, int purge)
if (purge) {
for (i = 0; i < sc->num_radios; i++) {
while ((msdu = TAILQ_FIRST(msdu_list))) {
TAILQ_REMOVE(msdu_list, msdu, entry);
while ((msdu = TAILQ_FIRST(&msdu_list[i]))) {
TAILQ_REMOVE(&msdu_list[i], msdu, entry);
m_freem(msdu->m);
msdu->m = NULL;
}
@@ -16831,8 +16831,8 @@ qwx_dp_rx_process_wbm_err(struct qwx_softc *sc, int purge)
}
for (i = 0; i < sc->num_radios; i++) {
while ((msdu = TAILQ_FIRST(msdu_list))) {
TAILQ_REMOVE(msdu_list, msdu, entry);
while ((msdu = TAILQ_FIRST(&msdu_list[i]))) {
TAILQ_REMOVE(&msdu_list[i], msdu, entry);
if (test_bit(ATH11K_CAC_RUNNING, sc->sc_flags)) {
m_freem(msdu->m);
msdu->m = NULL;
@@ -17633,7 +17633,7 @@ try_again:
if (purge) {
while ((msdu = TAILQ_FIRST(&msdu_list[i]))) {
TAILQ_REMOVE(msdu_list, msdu, entry);
TAILQ_REMOVE(&msdu_list[i], msdu, entry);
m_freem(msdu->m);
msdu->m = NULL;
}