Commit 6fda135c authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

Revert "printk: return -EINVAL if the message len is bigger than the buf size"

This reverts commit b56a39ac.

A better patch from Jan will follow this to resolve the issue.
Acked-by: default avatarKay Sievers <kay@vrfy.org>
Cc: Fengguang Wu <wfg@linux.intel.com>
Cc: Yuanhan Liu <yuanhan.liu@linux.intel.com>
Cc: Jan Beulich <JBeulich@suse.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 4661e356
......@@ -880,9 +880,7 @@ static int syslog_print(char __user *buf, int size)
syslog_seq++;
raw_spin_unlock_irq(&logbuf_lock);
if (len > size)
len = -EINVAL;
else if (len > 0 && copy_to_user(buf, text, len))
if (len > 0 && copy_to_user(buf, text, len))
len = -EFAULT;
kfree(text);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment