diff options
author | H. Peter Anvin <hpa@zytor.com> | 2010-05-08 23:59:58 +0200 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2010-05-08 23:59:58 +0200 |
commit | d7be0ce6afb1df60bc786f57410407ceae92b994 (patch) | |
tree | 5e91acfc12c833531ad3320f274e0cd96a129973 /drivers/s390/char/sclp_async.c | |
parent | x86: Clean up the hypervisor layer (diff) | |
parent | Linux 2.6.34-rc6 (diff) | |
download | linux-d7be0ce6afb1df60bc786f57410407ceae92b994.tar.xz linux-d7be0ce6afb1df60bc786f57410407ceae92b994.zip |
Merge commit 'v2.6.34-rc6' into x86/cpu
Diffstat (limited to 'drivers/s390/char/sclp_async.c')
-rw-r--r-- | drivers/s390/char/sclp_async.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/s390/char/sclp_async.c b/drivers/s390/char/sclp_async.c index f449c696e503..7ad30e72f868 100644 --- a/drivers/s390/char/sclp_async.c +++ b/drivers/s390/char/sclp_async.c @@ -11,6 +11,7 @@ #include <linux/device.h> #include <linux/stat.h> #include <linux/string.h> +#include <linux/slab.h> #include <linux/ctype.h> #include <linux/kmod.h> #include <linux/err.h> @@ -84,7 +85,7 @@ static int proc_handler_callhome(struct ctl_table *ctl, int write, rc = copy_from_user(buf, buffer, sizeof(buf)); if (rc != 0) return -EFAULT; - buf[len - 1] = '\0'; + buf[sizeof(buf) - 1] = '\0'; if (strict_strtoul(buf, 0, &val) != 0) return -EINVAL; if (val != 0 && val != 1) |