]> nv-tegra.nvidia Code Review - linux-2.6.git/blobdiff - init/do_mounts_rd.c
cgroups: make swap accounting default behavior configurable
[linux-2.6.git] / init / do_mounts_rd.c
index 91d0cfca507108303f4f12fb0fb67bde30644fc8..6e1ee6987c78dbca4cb3f01aaa031e4b3a42708f 100644 (file)
@@ -7,6 +7,7 @@
 #include <linux/cramfs_fs.h>
 #include <linux/initrd.h>
 #include <linux/string.h>
+#include <linux/slab.h>
 
 #include "do_mounts.h"
 #include "../fs/squashfs/squashfs_fs.h"
@@ -83,7 +84,8 @@ identify_ramdisk_image(int fd, int start_block, decompress_fn *decompressor)
                printk(KERN_NOTICE "RAMDISK: %s image found at block %d\n",
                       compress_name, start_block);
                if (!*decompressor)
-                       printk(KERN_CRIT "RAMDISK: %s decompressor not configured!\n",
+                       printk(KERN_EMERG
+                              "RAMDISK: %s decompressor not configured!\n",
                               compress_name);
                nblocks = 0;
                goto done;
@@ -166,7 +168,7 @@ int __init rd_load_image(char *from)
        char rotator[4] = { '|' , '/' , '-' , '\\' };
 #endif
 
-       out_fd = sys_open("/dev/ram", O_RDWR, 0);
+       out_fd = sys_open((const char __user __force *) "/dev/ram", O_RDWR, 0);
        if (out_fd < 0)
                goto out;
 
@@ -265,7 +267,7 @@ noclose_input:
        sys_close(out_fd);
 out:
        kfree(buf);
-       sys_unlink("/dev/ram");
+       sys_unlink((const char __user __force *) "/dev/ram");
        return res;
 }