aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/profile.c
diff options
context:
space:
mode:
authorHeiko Carstens <heiko.carstens@de.ibm.com>2006-12-06 23:36:37 -0500
committerLinus Torvalds <torvalds@woody.osdl.org>2006-12-07 11:39:33 -0500
commit064b022c7adb2d853378078a9dc141f8288d1c73 (patch)
tree67a8a2a05c0acd5eeee569317cf3cd87ff66cabb /kernel/profile.c
parent7116e994b47f3988389be4ceee67dac64b56e0d0 (diff)
[PATCH] profile: fix uaccess handling
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'kernel/profile.c')
-rw-r--r--kernel/profile.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/profile.c b/kernel/profile.c
index f940b462eec..15b012df4ff 100644
--- a/kernel/profile.c
+++ b/kernel/profile.c
@@ -442,7 +442,8 @@ read_profile(struct file *file, char __user *buf, size_t count, loff_t *ppos)
442 read = 0; 442 read = 0;
443 443
444 while (p < sizeof(unsigned int) && count > 0) { 444 while (p < sizeof(unsigned int) && count > 0) {
445 put_user(*((char *)(&sample_step)+p),buf); 445 if (put_user(*((char *)(&sample_step)+p),buf))
446 return -EFAULT;
446 buf++; p++; count--; read++; 447 buf++; p++; count--; read++;
447 } 448 }
448 pnt = (char *)prof_buffer + p - sizeof(atomic_t); 449 pnt = (char *)prof_buffer + p - sizeof(atomic_t);