summaryrefslogtreecommitdiff
path: root/init/noinitramfs.c
diff options
context:
space:
mode:
authorNamhyung Kim <namhyung@gmail.com>2010-10-26 14:22:42 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2010-10-26 16:52:15 -0700
commit562f5e638de4ef451226552fe8dd7847bacea24e (patch)
tree69a0ac78c9eca823a297c4b8e0810a5b1d4e3ee8 /init/noinitramfs.c
parentf0cfec11180973e4f4b2b6909623e47eaaf7ecfe (diff)
downloadkernel-mfld-blackbay-562f5e638de4ef451226552fe8dd7847bacea24e.tar.gz
kernel-mfld-blackbay-562f5e638de4ef451226552fe8dd7847bacea24e.tar.bz2
kernel-mfld-blackbay-562f5e638de4ef451226552fe8dd7847bacea24e.zip
init: mark __user address space on string literals
When calling syscall service routines in kernel, some of arguments should be user pointers but were missing __user markup on string literals. Add it. Removes some sparse warnings. Signed-off-by: Namhyung Kim <namhyung@gmail.com> Cc: Phillip Lougher <phillip@lougher.demon.co.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'init/noinitramfs.c')
-rw-r--r--init/noinitramfs.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/init/noinitramfs.c b/init/noinitramfs.c
index f4c1a3a1b8c..267739d8517 100644
--- a/init/noinitramfs.c
+++ b/init/noinitramfs.c
@@ -29,17 +29,17 @@ static int __init default_rootfs(void)
{
int err;
- err = sys_mkdir("/dev", 0755);
+ err = sys_mkdir((const char __user __force *) "/dev", 0755);
if (err < 0)
goto out;
- err = sys_mknod((const char __user *) "/dev/console",
+ err = sys_mknod((const char __user __force *) "/dev/console",
S_IFCHR | S_IRUSR | S_IWUSR,
new_encode_dev(MKDEV(5, 1)));
if (err < 0)
goto out;
- err = sys_mkdir("/root", 0700);
+ err = sys_mkdir((const char __user __force *) "/root", 0700);
if (err < 0)
goto out;