From 7711eb0827fd2a82b4a4d35e4f47a798531ae95c Mon Sep 17 00:00:00 2001 From: Sascha Hauer Date: Mon, 5 Aug 2019 11:13:15 +0200 Subject: console: return number of characters written in fops_write struct cdev_operations write() callback is supposed to return the number of characters written. Do this instead of returning 0 for the console device files. Signed-off-by: Sascha Hauer --- common/console.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/console.c b/common/console.c index 406722a1da..ee17a508ba 100644 --- a/common/console.c +++ b/common/console.c @@ -300,7 +300,7 @@ static ssize_t fops_write(struct cdev* dev, const void* buf, size_t count, priv->puts(priv, buf); - return 0; + return count; } int console_register(struct console_device *newcdev) -- cgit v1.2.3