From: Jarkko Nikula Date: Wed, 9 Apr 2025 14:04:01 +0000 (+0300) Subject: i3c: mipi-i3c-hci: Move unexpected INTR_STATUS print before IO handler X-Git-Tag: v6.16-rc1~87^2~6 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=bd916806632d1a22a10a30d5ab7cce549791a563;p=thirdparty%2Flinux.git i3c: mipi-i3c-hci: Move unexpected INTR_STATUS print before IO handler Move "unexpected INTR_STATUS" error print before calling the IO handler as it is more consistent that way. Otherwise it may be confusing if generic interrupt related prints are mixed with IO handler prints. Since this error print is more indication of missing code rather than runtime error downgrade it to dev_warn_once(). Reviewed-by: Frank Li Signed-off-by: Jarkko Nikula Link: https://lore.kernel.org/r/20250409140401.299251-5-jarkko.nikula@linux.intel.com Signed-off-by: Alexandre Belloni --- diff --git a/drivers/i3c/master/mipi-i3c-hci/core.c b/drivers/i3c/master/mipi-i3c-hci/core.c index 0bb74173ca940..bc45386945408 100644 --- a/drivers/i3c/master/mipi-i3c-hci/core.c +++ b/drivers/i3c/master/mipi-i3c-hci/core.c @@ -606,12 +606,13 @@ static irqreturn_t i3c_hci_irq_handler(int irq, void *dev_id) val &= ~INTR_HC_INTERNAL_ERR; } + if (val) + dev_warn_once(&hci->master.dev, + "unexpected INTR_STATUS %#x\n", val); + if (hci->io->irq_handler(hci)) result = IRQ_HANDLED; - if (val) - dev_err(&hci->master.dev, "unexpected INTR_STATUS %#x\n", val); - return result; }