[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240627124313.1811-2-wsa+renesas@sang-engineering.com>
Date: Thu, 27 Jun 2024 14:43:14 +0200
From: Wolfram Sang <wsa+renesas@...g-engineering.com>
To: linux-renesas-soc@...r.kernel.org
Cc: Wolfram Sang <wsa+renesas@...g-engineering.com>,
linux-i2c@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: [PATCH] i2c: add debug message for detected HostNotify alerts
Setting up HostNotify can be tricky. Support debugging by stating
whenever we received a HostNotify alert independent of the irq being
mapped. Especially useful with the in-kernel i2c testunit.
Signed-off-by: Wolfram Sang <wsa+renesas@...g-engineering.com>
---
drivers/i2c/i2c-core-base.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/i2c/i2c-core-base.c b/drivers/i2c/i2c-core-base.c
index db0d1ac82910..b94594e90a66 100644
--- a/drivers/i2c/i2c-core-base.c
+++ b/drivers/i2c/i2c-core-base.c
@@ -1468,6 +1468,8 @@ int i2c_handle_smbus_host_notify(struct i2c_adapter *adap, unsigned short addr)
if (!adap)
return -EINVAL;
+ dev_dbg(&adap->dev, "Detected HostNotify from address 0x%02x", addr);
+
irq = irq_find_mapping(adap->host_notify_domain, addr);
if (irq <= 0)
return -ENXIO;
--
2.43.0
Powered by blists - more mailing lists