mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-04 05:58:57 +00:00
Do a read-after-write to ensure the interrupt register update is flushed
to the hardware. The QCA HAL has a comment noting that if this isn't done, modifications to AR_IMR_S2 before AR_IMR is flushed may produce spurious interrupts. Obtained from: QCA
This commit is contained in:
parent
9febee763b
commit
552c550628
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=265029
@ -337,6 +337,9 @@ ar5416SetInterrupts(struct ath_hal *ah, HAL_INT ints)
|
||||
/* Write the new IMR and store off our SW copy. */
|
||||
HALDEBUG(ah, HAL_DEBUG_INTERRUPT, "%s: new IMR 0x%x\n", __func__, mask);
|
||||
OS_REG_WRITE(ah, AR_IMR, mask);
|
||||
/* Flush write */
|
||||
(void) OS_REG_READ(ah, AR_IMR);
|
||||
|
||||
mask = OS_REG_READ(ah, AR_IMR_S2) & ~(AR_IMR_S2_TIM |
|
||||
AR_IMR_S2_DTIM |
|
||||
AR_IMR_S2_DTIMSYNC |
|
||||
|
Loading…
Reference in New Issue
Block a user