[PATCH 2/7] kmsg: no need to limit the return value of printk
From: Alan Jenkins
Date: Wed Oct 07 2009 - 04:42:53 EST
Prefixes added by printk() are no longer included in the count of
characters which it returns.
Signed-off-by: Alan Jenkins <alan-jenkins@xxxxxxxxxxxxxx>
---
drivers/char/mem.c | 3 ---
1 files changed, 0 insertions(+), 3 deletions(-)
diff --git a/drivers/char/mem.c b/drivers/char/mem.c
index a074fce..8599f65 100644
--- a/drivers/char/mem.c
+++ b/drivers/char/mem.c
@@ -852,9 +852,6 @@ static ssize_t kmsg_write(struct file * file, const char __user * buf,
if (!copy_from_user(tmp, buf, count)) {
tmp[count] = 0;
ret = printk("%s", tmp);
- if (ret > count)
- /* printk can add a prefix */
- ret = count;
}
kfree(tmp);
return ret;
--
1.6.3.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/