Skip to content

Commit a7035a8

Browse files
jhnikulaalexandrebelloni
authored andcommitted
i3c: mipi-i3c-hci: Clear INTR_STATUS unconditionally
Status fields in INTR_STATUS register are write 1 to clear so do it unconditionally and move clearing of them out of an if block. Suggested-by: Frank Li <[email protected]> Signed-off-by: Jarkko Nikula <[email protected]> Reviewed-by: Frank Li <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Alexandre Belloni <[email protected]>
1 parent 279c240 commit a7035a8

File tree

1 file changed

+2
-3
lines changed
  • drivers/i3c/master/mipi-i3c-hci

1 file changed

+2
-3
lines changed

drivers/i3c/master/mipi-i3c-hci/core.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -590,12 +590,11 @@ static irqreturn_t i3c_hci_irq_handler(int irq, void *dev_id)
590590
u32 val;
591591

592592
val = reg_read(INTR_STATUS);
593+
reg_write(INTR_STATUS, val);
593594
DBG("INTR_STATUS = %#x", val);
594595

595-
if (val) {
596-
reg_write(INTR_STATUS, val);
596+
if (val)
597597
result = IRQ_HANDLED;
598-
}
599598

600599
if (val & INTR_HC_RESET_CANCEL) {
601600
DBG("cancelled reset");

0 commit comments

Comments
 (0)