summaryrefslogtreecommitdiff
path: root/kernel/trace/trace_stack.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2011-08-04 09:09:27 +0200
committerIngo Molnar <mingo@elte.hu>2011-08-04 09:09:27 +0200
commitd7619fe39d9769b4d4545cc511c891deea18ae08 (patch)
tree0a902533414001075b2245825e145cc2e35ce985 /kernel/trace/trace_stack.c
parent9ea71503a8ed9184d2d0b8ccc4d269d05f7940ae (diff)
parented8f37370d83e695c0a4fa5d5fc7a83ecb947526 (diff)
Merge branch 'linus' into core/urgent
Diffstat (limited to 'kernel/trace/trace_stack.c')
-rw-r--r--kernel/trace/trace_stack.c13
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);