From e8fe7336849e469978c9bbcc435903595912c4d3 Mon Sep 17 00:00:00 2001 From: Rajkumar Manoharan Date: Fri, 5 Aug 2011 18:59:41 +0530 Subject: ath9k: Use atomic reference count for interrupt ops Let us enable/disable interrupts based on reference count. By doing this we can ensure that interrupts are never be enabled in the middle of tasklet processing. Instead of addressing corner cases like "ath9k: avoid enabling interrupts while processing rx", this approach handles it in generic manner. Signed-off-by: Rajkumar Manoharan Signed-off-by: John W. Linville --- drivers/net/wireless/ath/ath9k/init.c | 1 + 1 file changed, 1 insertion(+) (limited to 'drivers/net/wireless/ath/ath9k/init.c') diff --git a/drivers/net/wireless/ath/ath9k/init.c b/drivers/net/wireless/ath/ath9k/init.c index d99f188..db38a58 100644 --- a/drivers/net/wireless/ath/ath9k/init.c +++ b/drivers/net/wireless/ath/ath9k/init.c @@ -566,6 +566,7 @@ static int ath9k_init_softc(u16 devid, struct ath_softc *sc, ah->reg_ops.read = ath9k_ioread32; ah->reg_ops.write = ath9k_iowrite32; ah->reg_ops.rmw = ath9k_reg_rmw; + atomic_set(&ah->intr_ref_cnt, -1); sc->sc_ah = ah; if (!pdata) { -- cgit v1.1