diff options
author | Ingo Molnar <mingo@elte.hu> | 2011-08-04 09:09:27 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2011-08-04 09:09:27 +0200 |
commit | d7619fe39d9769b4d4545cc511c891deea18ae08 (patch) | |
tree | 0a902533414001075b2245825e145cc2e35ce985 /kernel/trace/trace_stack.c | |
parent | 9ea71503a8ed9184d2d0b8ccc4d269d05f7940ae (diff) | |
parent | ed8f37370d83e695c0a4fa5d5fc7a83ecb947526 (diff) |
Merge branch 'linus' into core/urgent
Diffstat (limited to 'kernel/trace/trace_stack.c')
-rw-r--r-- | kernel/trace/trace_stack.c | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/kernel/trace/trace_stack.c b/kernel/trace/trace_stack.c index b0b53b8e4c25..77575b386d97 100644 --- a/kernel/trace/trace_stack.c +++ b/kernel/trace/trace_stack.c @@ -156,20 +156,11 @@ stack_max_size_write(struct file *filp, const char __user *ubuf, { long *ptr = filp->private_data; unsigned long val, flags; - char buf[64]; int ret; int cpu; - if (count >= sizeof(buf)) - return -EINVAL; - - if (copy_from_user(&buf, ubuf, count)) - return -EFAULT; - - buf[count] = 0; - - ret = strict_strtoul(buf, 10, &val); - if (ret < 0) + ret = kstrtoul_from_user(ubuf, count, 10, &val); + if (ret) return ret; local_irq_save(flags); |