From f0f3df6a93be22cc3535cc53f6834fee5585f734 Mon Sep 17 00:00:00 2001 From: Bard Liao Date: Wed, 10 Dec 2025 10:54:21 +0800 Subject: [PATCH] soundwire: lower the trace level to warning when the alert is ignored Command Ignored is a valid response of SoundWire. It could happen when an invalid interrupt occurs when the device is not attached. The driver will try to access the device and will get an Ignored response. It is harmless to ignore the unexpected interrupt. Lower the trace level to not scare users. Signed-off-by: Bard Liao --- drivers/soundwire/bus.c | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/drivers/soundwire/bus.c b/drivers/soundwire/bus.c index fb68738dfb9b84..9c20b4971fb698 100644 --- a/drivers/soundwire/bus.c +++ b/drivers/soundwire/bus.c @@ -1664,8 +1664,12 @@ static int sdw_handle_slave_alerts(struct sdw_slave *slave) /* Read Intstat 1, Intstat 2 and Intstat 3 registers */ ret = sdw_read_no_pm(slave, SDW_SCP_INT1); if (ret < 0) { - dev_err(&slave->dev, - "SDW_SCP_INT1 read failed:%d\n", ret); + if (ret == -ENODATA) + dev_warn(&slave->dev, + "SDW_SCP_INT1 read command was ignored\n"); + else + dev_err(&slave->dev, + "SDW_SCP_INT1 read failed:%d\n", ret); goto io_err; } buf = ret; @@ -1959,10 +1963,14 @@ int sdw_handle_slave_status(struct sdw_bus *bus, case SDW_SLAVE_ALERT: ret = sdw_handle_slave_alerts(slave); - if (ret < 0) - dev_err(&slave->dev, - "Slave %d alert handling failed: %d\n", - i, ret); + if (ret < 0) { + if (ret == -ENODATA) + dev_warn(&slave->dev, + "Slave %d alert is ignored\n", i); + else + dev_err(&slave->dev, + "Slave %d alert handling failed: %d\n", i, ret); + } break; case SDW_SLAVE_ATTACHED: