Skip to contentSkip to conversation

spi: pl022: Don't touch unspecified bits in interrupt mask

PATCH Applied Alexander Sverdlin 2 participants 2 messages Feb 27, 2015 – Mar 6, 2015 1 message not in the archive

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 2/4 spi: pl022: Don't touch unspecified bits in interrupt mask

spi: pl022: Don't touch unspecified bits in interrupt mask

PL022 Programmers model explicitely states "do not modify undefined register bits". Correct the "all enable" interrupt mask so that it only enables defined ones.

---
 drivers/spi/spi-pl022.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)
drivers/spi/spi-pl022.c +6 -1
index f68cbf6..0566657 100644
@@ -278,7 +278,12 @@
  */
 #define DEFAULT_SSP_REG_IMSC  0x0UL
 #define DISABLE_ALL_INTERRUPTS DEFAULT_SSP_REG_IMSC
-#define ENABLE_ALL_INTERRUPTS (~DEFAULT_SSP_REG_IMSC)
+#define ENABLE_ALL_INTERRUPTS ( \
+	SSP_IMSC_MASK_RORIM | \
+	SSP_IMSC_MASK_RTIM | \
+	SSP_IMSC_MASK_RXIM | \
+	SSP_IMSC_MASK_TXIM \
+)
 
 #define CLEAR_ALL_INTERRUPTS  0x3
 

--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

Applied
#2 lore raw
In reply to a message not in the archive
Quoted 5 lines · Alexander Sverdlin

spi: pl022: Don't touch unspecified bits in interrupt mask

PL022 Programmers model explicitely states "do not modify undefined register bits". Correct the "all enable" interrupt mask so that it only enables defined ones.

Applied, thanks.