Retried frames need to be inserted in the head of the list, not the tail.

This is an unfortunate byproduct of how the routine is used - it's called
with the head frame on the queue, but if the frame is failed, it's inserted
into the tail of the queue.

Because of this, the sequence numbers would get all shuffled around and
the BAW would be bumped past this sequence number, that's now at the
end of the software queue.  Then, whenever it's time for that frame
to be transmitted, it'll be immediately outside of the BAW and TX will
stall until the BAW catches up.

It can also result in all kinds of weird duplicate BAW frames, leading
to hilarious panics.

PR:		kern/166190
This commit is contained in:
adrian 2012-06-11 07:15:48 +00:00
parent ddabbbd18b
commit 3559a073df

View File

@ -2309,7 +2309,7 @@ ath_tx_xmit_aggr(struct ath_softc *sc, struct ath_node *an, struct ath_buf *bf)
/* paused? queue */
if (tid->paused) {
ATH_TXQ_INSERT_TAIL(tid, bf, bf_list);
ATH_TXQ_INSERT_HEAD(tid, bf, bf_list);
/* XXX don't sched - we're paused! */
return;
}