ath9k: add missing locking around ath9k_hw_proc_mib_event
authorFelix Fietkau <nbd@openwrt.org>
Tue, 12 Oct 2010 14:08:03 +0000 (16:08 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 15 Oct 2010 19:48:44 +0000 (15:48 -0400)
ath9k_hw_proc_mib_event updates the cycle counters, so it common->cc_lock
must be acquired.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/main.c

index 74ff51d..2c7f28e 100644 (file)
@@ -779,7 +779,9 @@ irqreturn_t ath_isr(int irq, void *dev)
                 * it will clear whatever condition caused
                 * the interrupt.
                 */
+               spin_lock(&common->cc_lock);
                ath9k_hw_proc_mib_event(ah);
+               spin_unlock(&common->cc_lock);
                ath9k_hw_set_interrupts(ah, ah->imask);
        }