Skip to contentSkip to conversation

ath9k correct interrupts ?

RFC In review Stanislaw Gruszka 2 participants 2 messages Feb 18, 2011 Qualcomm Atheros ATH9K wireless driver

lore
Share & tools
lore
#0 lore raw

RFC 1/1 ath9k correct interrupts ?

I'm not sure if that patch is correct or not. It possibly fix change from commit 4df3071ebd92ef7115b409da64d0eb405d24a631 "ath9k_hw: optimize interrupt mask changes" that looks suspicious for me. But from other hand this patch could be totally wrong. Felix?

drivers/net/wireless/ath/ath9k/mac.c +3 -2
index 180170d..2915b11 100644
@@ -885,7 +885,7 @@ void ath9k_hw_set_interrupts(struct ath_hw *ah, enum ath9k_int ints)
 	struct ath_common *common = ath9k_hw_common(ah);
 
 	if (!(ints & ATH9K_INT_GLOBAL))
-		ath9k_hw_enable_interrupts(ah);
+		ath9k_hw_disable_interrupts(ah);
 
 	ath_dbg(common, ATH_DBG_INTERRUPT, "0x%x => 0x%x\n", omask, ints);
 
@@ -963,7 +963,8 @@ void ath9k_hw_set_interrupts(struct ath_hw *ah, enum ath9k_int ints)
 			REG_CLR_BIT(ah, AR_IMR_S5, AR_IMR_S5_TIM_TIMER);
 	}
 
-	ath9k_hw_enable_interrupts(ah);
+	if (ints & ATH9K_INT_GLOBAL)
+		ath9k_hw_enable_interrupts(ah);
 
 	return;
 }
#1 lore raw
Quoted 5 lines · Stanislaw Gruszka

I'm not sure if that patch is correct or not. It possibly fix change from commit 4df3071ebd92ef7115b409da64d0eb405d24a631 "ath9k_hw: optimize interrupt mask changes" that looks suspicious for me. But from other hand this patch could be totally wrong. Felix?

Looks good to me

- Felix