[PATCH v2 4/8] spi: stm32-ospi: Simplify SMIE interrupt test
Patrice Chotard
patrice.chotard at foss.st.com
Sun Dec 7 23:29:11 PST 2025
SR_SMF status bit can only be set if CR_SMIE was previously set,
keep status bit check only.
Signed-off-by: Patrice Chotard <patrice.chotard at foss.st.com>
---
drivers/spi/spi-stm32-ospi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/spi/spi-stm32-ospi.c b/drivers/spi/spi-stm32-ospi.c
index 06632cdd1630..c36df8d3f5cb 100644
--- a/drivers/spi/spi-stm32-ospi.c
+++ b/drivers/spi/spi-stm32-ospi.c
@@ -279,7 +279,7 @@ static irqreturn_t stm32_ospi_irq(int irq, void *dev_id)
cr = readl_relaxed(regs_base + OSPI_CR);
sr = readl_relaxed(regs_base + OSPI_SR);
- if (cr & CR_SMIE && sr & SR_SMF) {
+ if (sr & SR_SMF) {
/* disable irq */
cr &= ~CR_SMIE;
writel_relaxed(cr, regs_base + OSPI_CR);
--
2.43.0
More information about the linux-arm-kernel
mailing list