diff options
Diffstat (limited to 'init')
-rw-r--r-- | init/Kconfig | 11 | ||||
-rw-r--r-- | init/do_mounts.c | 14 | ||||
-rw-r--r-- | init/do_mounts_initrd.c | 10 | ||||
-rw-r--r-- | init/do_mounts_md.c | 12 | ||||
-rw-r--r-- | init/do_mounts_rd.c | 13 | ||||
-rw-r--r-- | init/initramfs.c | 16 |
6 files changed, 62 insertions, 14 deletions
diff --git a/init/Kconfig b/init/Kconfig index 1e004d057468..d07dcf9fc8a9 100644 --- a/init/Kconfig +++ b/init/Kconfig | |||
@@ -167,7 +167,7 @@ config KERNEL_BZIP2 | |||
167 | depends on HAVE_KERNEL_BZIP2 | 167 | depends on HAVE_KERNEL_BZIP2 |
168 | help | 168 | help |
169 | Its compression ratio and speed is intermediate. | 169 | Its compression ratio and speed is intermediate. |
170 | Decompression speed is slowest among the three. The kernel | 170 | Decompression speed is slowest among the choices. The kernel |
171 | size is about 10% smaller with bzip2, in comparison to gzip. | 171 | size is about 10% smaller with bzip2, in comparison to gzip. |
172 | Bzip2 uses a large amount of memory. For modern kernels you | 172 | Bzip2 uses a large amount of memory. For modern kernels you |
173 | will need at least 8MB RAM or more for booting. | 173 | will need at least 8MB RAM or more for booting. |
@@ -176,10 +176,9 @@ config KERNEL_LZMA | |||
176 | bool "LZMA" | 176 | bool "LZMA" |
177 | depends on HAVE_KERNEL_LZMA | 177 | depends on HAVE_KERNEL_LZMA |
178 | help | 178 | help |
179 | The most recent compression algorithm. | 179 | This compression algorithm's ratio is best. Decompression speed |
180 | Its ratio is best, decompression speed is between the other | 180 | is between gzip and bzip2. Compression is slowest. |
181 | two. Compression is slowest. The kernel size is about 33% | 181 | The kernel size is about 33% smaller with LZMA in comparison to gzip. |
182 | smaller with LZMA in comparison to gzip. | ||
183 | 182 | ||
184 | config KERNEL_XZ | 183 | config KERNEL_XZ |
185 | bool "XZ" | 184 | bool "XZ" |
@@ -200,7 +199,7 @@ config KERNEL_LZO | |||
200 | bool "LZO" | 199 | bool "LZO" |
201 | depends on HAVE_KERNEL_LZO | 200 | depends on HAVE_KERNEL_LZO |
202 | help | 201 | help |
203 | Its compression ratio is the poorest among the 4. The kernel | 202 | Its compression ratio is the poorest among the choices. The kernel |
204 | size is about 10% bigger than gzip; however its speed | 203 | size is about 10% bigger than gzip; however its speed |
205 | (both compression and decompression) is the fastest. | 204 | (both compression and decompression) is the fastest. |
206 | 205 | ||
diff --git a/init/do_mounts.c b/init/do_mounts.c index 42b0707c3481..d3f0aeed2d39 100644 --- a/init/do_mounts.c +++ b/init/do_mounts.c | |||
@@ -1,3 +1,13 @@ | |||
1 | /* | ||
2 | * Many of the syscalls used in this file expect some of the arguments | ||
3 | * to be __user pointers not __kernel pointers. To limit the sparse | ||
4 | * noise, turn off sparse checking for this file. | ||
5 | */ | ||
6 | #ifdef __CHECKER__ | ||
7 | #undef __CHECKER__ | ||
8 | #warning "Sparse checking disabled for this file" | ||
9 | #endif | ||
10 | |||
1 | #include <linux/module.h> | 11 | #include <linux/module.h> |
2 | #include <linux/sched.h> | 12 | #include <linux/sched.h> |
3 | #include <linux/ctype.h> | 13 | #include <linux/ctype.h> |
@@ -330,7 +340,7 @@ static int __init do_mount_root(char *name, char *fs, int flags, void *data) | |||
330 | if (err) | 340 | if (err) |
331 | return err; | 341 | return err; |
332 | 342 | ||
333 | sys_chdir((const char __user __force *)"/root"); | 343 | sys_chdir("/root"); |
334 | s = current->fs->pwd.dentry->d_sb; | 344 | s = current->fs->pwd.dentry->d_sb; |
335 | ROOT_DEV = s->s_dev; | 345 | ROOT_DEV = s->s_dev; |
336 | printk(KERN_INFO | 346 | printk(KERN_INFO |
@@ -556,5 +566,5 @@ void __init prepare_namespace(void) | |||
556 | out: | 566 | out: |
557 | devtmpfs_mount("dev"); | 567 | devtmpfs_mount("dev"); |
558 | sys_mount(".", "/", NULL, MS_MOVE, NULL); | 568 | sys_mount(".", "/", NULL, MS_MOVE, NULL); |
559 | sys_chroot((const char __user __force *)"."); | 569 | sys_chroot("."); |
560 | } | 570 | } |
diff --git a/init/do_mounts_initrd.c b/init/do_mounts_initrd.c index 9047330c73e9..135959a276be 100644 --- a/init/do_mounts_initrd.c +++ b/init/do_mounts_initrd.c | |||
@@ -1,3 +1,13 @@ | |||
1 | /* | ||
2 | * Many of the syscalls used in this file expect some of the arguments | ||
3 | * to be __user pointers not __kernel pointers. To limit the sparse | ||
4 | * noise, turn off sparse checking for this file. | ||
5 | */ | ||
6 | #ifdef __CHECKER__ | ||
7 | #undef __CHECKER__ | ||
8 | #warning "Sparse checking disabled for this file" | ||
9 | #endif | ||
10 | |||
1 | #include <linux/unistd.h> | 11 | #include <linux/unistd.h> |
2 | #include <linux/kernel.h> | 12 | #include <linux/kernel.h> |
3 | #include <linux/fs.h> | 13 | #include <linux/fs.h> |
diff --git a/init/do_mounts_md.c b/init/do_mounts_md.c index 32c4799b8c91..8cb6db54285b 100644 --- a/init/do_mounts_md.c +++ b/init/do_mounts_md.c | |||
@@ -1,3 +1,13 @@ | |||
1 | /* | ||
2 | * Many of the syscalls used in this file expect some of the arguments | ||
3 | * to be __user pointers not __kernel pointers. To limit the sparse | ||
4 | * noise, turn off sparse checking for this file. | ||
5 | */ | ||
6 | #ifdef __CHECKER__ | ||
7 | #undef __CHECKER__ | ||
8 | #warning "Sparse checking disabled for this file" | ||
9 | #endif | ||
10 | |||
1 | #include <linux/delay.h> | 11 | #include <linux/delay.h> |
2 | #include <linux/raid/md_u.h> | 12 | #include <linux/raid/md_u.h> |
3 | #include <linux/raid/md_p.h> | 13 | #include <linux/raid/md_p.h> |
@@ -283,7 +293,7 @@ static void __init autodetect_raid(void) | |||
283 | 293 | ||
284 | wait_for_device_probe(); | 294 | wait_for_device_probe(); |
285 | 295 | ||
286 | fd = sys_open((const char __user __force *) "/dev/md0", 0, 0); | 296 | fd = sys_open("/dev/md0", 0, 0); |
287 | if (fd >= 0) { | 297 | if (fd >= 0) { |
288 | sys_ioctl(fd, RAID_AUTORUN, raid_autopart); | 298 | sys_ioctl(fd, RAID_AUTORUN, raid_autopart); |
289 | sys_close(fd); | 299 | sys_close(fd); |
diff --git a/init/do_mounts_rd.c b/init/do_mounts_rd.c index 6212586df29a..6be2879cca66 100644 --- a/init/do_mounts_rd.c +++ b/init/do_mounts_rd.c | |||
@@ -1,3 +1,12 @@ | |||
1 | /* | ||
2 | * Many of the syscalls used in this file expect some of the arguments | ||
3 | * to be __user pointers not __kernel pointers. To limit the sparse | ||
4 | * noise, turn off sparse checking for this file. | ||
5 | */ | ||
6 | #ifdef __CHECKER__ | ||
7 | #undef __CHECKER__ | ||
8 | #warning "Sparse checking disabled for this file" | ||
9 | #endif | ||
1 | 10 | ||
2 | #include <linux/kernel.h> | 11 | #include <linux/kernel.h> |
3 | #include <linux/fs.h> | 12 | #include <linux/fs.h> |
@@ -181,7 +190,7 @@ int __init rd_load_image(char *from) | |||
181 | char rotator[4] = { '|' , '/' , '-' , '\\' }; | 190 | char rotator[4] = { '|' , '/' , '-' , '\\' }; |
182 | #endif | 191 | #endif |
183 | 192 | ||
184 | out_fd = sys_open((const char __user __force *) "/dev/ram", O_RDWR, 0); | 193 | out_fd = sys_open("/dev/ram", O_RDWR, 0); |
185 | if (out_fd < 0) | 194 | if (out_fd < 0) |
186 | goto out; | 195 | goto out; |
187 | 196 | ||
@@ -280,7 +289,7 @@ noclose_input: | |||
280 | sys_close(out_fd); | 289 | sys_close(out_fd); |
281 | out: | 290 | out: |
282 | kfree(buf); | 291 | kfree(buf); |
283 | sys_unlink((const char __user __force *) "/dev/ram"); | 292 | sys_unlink("/dev/ram"); |
284 | return res; | 293 | return res; |
285 | } | 294 | } |
286 | 295 | ||
diff --git a/init/initramfs.c b/init/initramfs.c index 8216c303b082..84c6bf111300 100644 --- a/init/initramfs.c +++ b/init/initramfs.c | |||
@@ -1,3 +1,13 @@ | |||
1 | /* | ||
2 | * Many of the syscalls used in this file expect some of the arguments | ||
3 | * to be __user pointers not __kernel pointers. To limit the sparse | ||
4 | * noise, turn off sparse checking for this file. | ||
5 | */ | ||
6 | #ifdef __CHECKER__ | ||
7 | #undef __CHECKER__ | ||
8 | #warning "Sparse checking disabled for this file" | ||
9 | #endif | ||
10 | |||
1 | #include <linux/init.h> | 11 | #include <linux/init.h> |
2 | #include <linux/fs.h> | 12 | #include <linux/fs.h> |
3 | #include <linux/slab.h> | 13 | #include <linux/slab.h> |
@@ -74,7 +84,7 @@ static void __init free_hash(void) | |||
74 | } | 84 | } |
75 | } | 85 | } |
76 | 86 | ||
77 | static long __init do_utime(char __user *filename, time_t mtime) | 87 | static long __init do_utime(char *filename, time_t mtime) |
78 | { | 88 | { |
79 | struct timespec t[2]; | 89 | struct timespec t[2]; |
80 | 90 | ||
@@ -529,7 +539,7 @@ static void __init clean_rootfs(void) | |||
529 | struct linux_dirent64 *dirp; | 539 | struct linux_dirent64 *dirp; |
530 | int num; | 540 | int num; |
531 | 541 | ||
532 | fd = sys_open((const char __user __force *) "/", O_RDONLY, 0); | 542 | fd = sys_open("/", O_RDONLY, 0); |
533 | WARN_ON(fd < 0); | 543 | WARN_ON(fd < 0); |
534 | if (fd < 0) | 544 | if (fd < 0) |
535 | return; | 545 | return; |
@@ -589,7 +599,7 @@ static int __init populate_rootfs(void) | |||
589 | } | 599 | } |
590 | printk(KERN_INFO "rootfs image is not initramfs (%s)" | 600 | printk(KERN_INFO "rootfs image is not initramfs (%s)" |
591 | "; looks like an initrd\n", err); | 601 | "; looks like an initrd\n", err); |
592 | fd = sys_open((const char __user __force *) "/initrd.image", | 602 | fd = sys_open("/initrd.image", |
593 | O_WRONLY|O_CREAT, 0700); | 603 | O_WRONLY|O_CREAT, 0700); |
594 | if (fd >= 0) { | 604 | if (fd >= 0) { |
595 | sys_write(fd, (char *)initrd_start, | 605 | sys_write(fd, (char *)initrd_start, |