X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=init%2Fdo_mounts_rd.c;h=fe9acb0ae4808bd663187d802960d788f73276c1;hb=ce1addf6e46177b549851118fca59427b1b9dd6c;hp=bf3ef667bf3669d4332fbaa5fdd65784823c0f54;hpb=541e448096530e327668a7645b437373b31842ad;p=firefly-linux-kernel-4.4.55.git diff --git a/init/do_mounts_rd.c b/init/do_mounts_rd.c index bf3ef667bf36..fe9acb0ae480 100644 --- a/init/do_mounts_rd.c +++ b/init/do_mounts_rd.c @@ -64,7 +64,7 @@ identify_ramdisk_image(int fd, int start_block, decompress_fn *decompressor) buf = kmalloc(size, GFP_KERNEL); if (!buf) - return -1; + return -ENOMEM; minixsb = (struct minix_super_block *) buf; ext2sb = (struct ext2_super_block *) buf; @@ -168,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; @@ -267,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; }