1 Index: madwifi-ng-r2420-20070602/ath/if_ath.c
2 ===================================================================
3 --- madwifi-ng-r2420-20070602.orig/ath/if_ath.c 2007-06-04 13:21:58.427094400 +0200
4 +++ madwifi-ng-r2420-20070602/ath/if_ath.c 2007-06-04 13:21:58.684055336 +0200
6 /* NB: use this lock to protect an->an_ff_txbuf in athff_can_aggregate()
9 - ATH_TXQ_LOCK_IRQ(txq);
10 + ATH_TXQ_LOCK_BH(txq);
11 if (athff_can_aggregate(sc, eh, an, skb, vap->iv_fragthreshold, &ff_flush)) {
12 if (an->an_tx_ffbuf[skb->priority]) { /* i.e., frame on the staging queue */
13 bf = an->an_tx_ffbuf[skb->priority];
15 /* get (and remove) the frame from staging queue */
16 TAILQ_REMOVE(&txq->axq_stageq, bf, bf_stagelist);
17 an->an_tx_ffbuf[skb->priority] = NULL;
18 + ATH_TXQ_UNLOCK_BH(txq);
21 * chain skbs and add FF magic
24 ATH_HARDSTART_GET_TX_BUF_WITH_LOCK;
26 - ATH_TXQ_UNLOCK_IRQ_EARLY(txq);
27 + ATH_TXQ_UNLOCK_BH(txq);
30 DPRINTF(sc, ATH_DEBUG_XMIT | ATH_DEBUG_FF,
32 an->an_tx_ffbuf[skb->priority] = bf;
34 TAILQ_INSERT_HEAD(&txq->axq_stageq, bf, bf_stagelist);
36 - ATH_TXQ_UNLOCK_IRQ_EARLY(txq);
37 + ATH_TXQ_UNLOCK_BH(txq);
41 @@ -2649,12 +2649,12 @@
43 ATH_HARDSTART_GET_TX_BUF_WITH_LOCK;
45 - ATH_TXQ_UNLOCK_IRQ_EARLY(txq);
46 + ATH_TXQ_UNLOCK_BH(txq);
49 + ATH_TXQ_UNLOCK_BH(txq);
52 - ATH_TXQ_UNLOCK_IRQ(txq);
56 Index: madwifi-ng-r2420-20070602/ath/if_athvar.h
57 ===================================================================
58 --- madwifi-ng-r2420-20070602.orig/ath/if_athvar.h 2007-06-04 13:21:58.428094248 +0200
59 +++ madwifi-ng-r2420-20070602/ath/if_athvar.h 2007-06-04 13:21:58.684055336 +0200
61 #define ATH_TXQ_INTR_PERIOD 5 /* axq_intrcnt period for intr gen */
62 #define ATH_TXQ_LOCK_INIT(_tq) spin_lock_init(&(_tq)->axq_lock)
63 #define ATH_TXQ_LOCK_DESTROY(_tq)
64 +#define ATH_TXQ_LOCK_BH(_tq) spin_lock_bh(&(_tq)->axq_lock);
65 +#define ATH_TXQ_UNLOCK_BH(_tq) spin_unlock_bh(&(_tq)->axq_lock);
66 #define ATH_TXQ_LOCK_IRQ(_tq) do { \
67 unsigned long __axq_lockflags; \
68 spin_lock_irqsave(&(_tq)->axq_lock, __axq_lockflags);