Skip to contentSkip to conversation

mei: demote client disconnect warning on suspend to debug

char-misc-next Tomas Winkler 1 participant 1 message May 30, 2024

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

From: Alexander Usyskin <[email protected]>

Change level for the "not connected" client message in the write callback from error to debug.

The MEI driver currently disconnects all clients upon system suspend. This behavior is by design and user-space applications with open connections before the suspend are expected to handle errors upon resume, by reopening their handles, reconnecting,
and retrying their operations.

However, the current driver implementation logs an error message every time a write operation is attempted on a disconnected client. Since this is a normal and expected flow after system resume logging this as an error can be misleading.

---
 drivers/misc/mei/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/misc/mei/main.c +1 -1
index 79e6f3c1341febe0921b32dd..40c3fe26f76df0a5a7fe192e 100644
@@ -329,7 +329,7 @@ static ssize_t mei_write(struct file *file, const char __user *ubuf,
 	}
 
 	if (!mei_cl_is_connected(cl)) {
-		cl_err(dev, cl, "is not connected");
+		cl_dbg(dev, cl, "is not connected");
 		rets = -ENODEV;
 		goto out;
 	}
Signature · 1 line
2.45.0