diff options
Diffstat (limited to 'init')
| -rw-r--r-- | init/Kconfig | 45 | ||||
| -rw-r--r-- | init/do_mounts.c | 4 | ||||
| -rw-r--r-- | init/do_mounts_rd.c | 2 | ||||
| -rw-r--r-- | init/initramfs.c | 3 | ||||
| -rw-r--r-- | init/main.c | 27 |
5 files changed, 48 insertions, 33 deletions
diff --git a/init/Kconfig b/init/Kconfig index d10a994c40f5..765018c24cf9 100644 --- a/init/Kconfig +++ b/init/Kconfig | |||
| @@ -273,6 +273,16 @@ config FHANDLE | |||
| 273 | get renamed. Enables open_by_handle_at(2) and name_to_handle_at(2) | 273 | get renamed. Enables open_by_handle_at(2) and name_to_handle_at(2) |
| 274 | syscalls. | 274 | syscalls. |
| 275 | 275 | ||
| 276 | config USELIB | ||
| 277 | bool "uselib syscall" | ||
| 278 | default y | ||
| 279 | help | ||
| 280 | This option enables the uselib syscall, a system call used in the | ||
| 281 | dynamic linker from libc5 and earlier. glibc does not use this | ||
| 282 | system call. If you intend to run programs built on libc5 or | ||
| 283 | earlier, you may need to enable this syscall. Current systems | ||
| 284 | running glibc can safely disable this. | ||
| 285 | |||
| 276 | config AUDIT | 286 | config AUDIT |
| 277 | bool "Auditing support" | 287 | bool "Auditing support" |
| 278 | depends on NET | 288 | depends on NET |
| @@ -535,7 +545,7 @@ config CONTEXT_TRACKING_FORCE | |||
| 535 | dynticks subsystem by forcing the context tracking on all | 545 | dynticks subsystem by forcing the context tracking on all |
| 536 | CPUs in the system. | 546 | CPUs in the system. |
| 537 | 547 | ||
| 538 | Say Y only if you're working on the developpement of an | 548 | Say Y only if you're working on the development of an |
| 539 | architecture backend for the context tracking. | 549 | architecture backend for the context tracking. |
| 540 | 550 | ||
| 541 | Say N otherwise, this option brings an overhead that you | 551 | Say N otherwise, this option brings an overhead that you |
| @@ -857,7 +867,7 @@ config NUMA_BALANCING | |||
| 857 | 867 | ||
| 858 | menuconfig CGROUPS | 868 | menuconfig CGROUPS |
| 859 | boolean "Control Group support" | 869 | boolean "Control Group support" |
| 860 | depends on EVENTFD | 870 | select KERNFS |
| 861 | help | 871 | help |
| 862 | This option adds support for grouping sets of processes together, for | 872 | This option adds support for grouping sets of processes together, for |
| 863 | use with process control subsystems such as Cpusets, CFS, memory | 873 | use with process control subsystems such as Cpusets, CFS, memory |
| @@ -924,6 +934,7 @@ config MEMCG | |||
| 924 | bool "Memory Resource Controller for Control Groups" | 934 | bool "Memory Resource Controller for Control Groups" |
| 925 | depends on RESOURCE_COUNTERS | 935 | depends on RESOURCE_COUNTERS |
| 926 | select MM_OWNER | 936 | select MM_OWNER |
| 937 | select EVENTFD | ||
| 927 | help | 938 | help |
| 928 | Provides a memory resource controller that manages both anonymous | 939 | Provides a memory resource controller that manages both anonymous |
| 929 | memory and page cache. (See Documentation/cgroups/memory.txt) | 940 | memory and page cache. (See Documentation/cgroups/memory.txt) |
| @@ -1119,8 +1130,6 @@ config IPC_NS | |||
| 1119 | 1130 | ||
| 1120 | config USER_NS | 1131 | config USER_NS |
| 1121 | bool "User namespace" | 1132 | bool "User namespace" |
| 1122 | select UIDGID_STRICT_TYPE_CHECKS | ||
| 1123 | |||
| 1124 | default n | 1133 | default n |
| 1125 | help | 1134 | help |
| 1126 | This allows containers, i.e. vservers, to use user namespaces | 1135 | This allows containers, i.e. vservers, to use user namespaces |
| @@ -1152,18 +1161,8 @@ config NET_NS | |||
| 1152 | 1161 | ||
| 1153 | endif # NAMESPACES | 1162 | endif # NAMESPACES |
| 1154 | 1163 | ||
| 1155 | config UIDGID_STRICT_TYPE_CHECKS | ||
| 1156 | bool "Require conversions between uid/gids and their internal representation" | ||
| 1157 | default n | ||
| 1158 | help | ||
| 1159 | While the nececessary conversions are being added to all subsystems this option allows | ||
| 1160 | the code to continue to build for unconverted subsystems. | ||
| 1161 | |||
| 1162 | Say Y here if you want the strict type checking enabled | ||
| 1163 | |||
| 1164 | config SCHED_AUTOGROUP | 1164 | config SCHED_AUTOGROUP |
| 1165 | bool "Automatic process group scheduling" | 1165 | bool "Automatic process group scheduling" |
| 1166 | select EVENTFD | ||
| 1167 | select CGROUPS | 1166 | select CGROUPS |
| 1168 | select CGROUP_SCHED | 1167 | select CGROUP_SCHED |
| 1169 | select FAIR_GROUP_SCHED | 1168 | select FAIR_GROUP_SCHED |
| @@ -1305,6 +1304,16 @@ config UID16 | |||
| 1305 | help | 1304 | help |
| 1306 | This enables the legacy 16-bit UID syscall wrappers. | 1305 | This enables the legacy 16-bit UID syscall wrappers. |
| 1307 | 1306 | ||
| 1307 | config SYSFS_SYSCALL | ||
| 1308 | bool "Sysfs syscall support" if EXPERT | ||
| 1309 | default y | ||
| 1310 | ---help--- | ||
| 1311 | sys_sysfs is an obsolete system call no longer supported in libc. | ||
| 1312 | Note that disabling this option is more secure but might break | ||
| 1313 | compatibility with some systems. | ||
| 1314 | |||
| 1315 | If unsure say Y here. | ||
| 1316 | |||
| 1308 | config SYSCTL_SYSCALL | 1317 | config SYSCTL_SYSCALL |
| 1309 | bool "Sysctl syscall support" if EXPERT | 1318 | bool "Sysctl syscall support" if EXPERT |
| 1310 | depends on PROC_SYSCTL | 1319 | depends on PROC_SYSCTL |
| @@ -1402,6 +1411,13 @@ config FUTEX | |||
| 1402 | support for "fast userspace mutexes". The resulting kernel may not | 1411 | support for "fast userspace mutexes". The resulting kernel may not |
| 1403 | run glibc-based applications correctly. | 1412 | run glibc-based applications correctly. |
| 1404 | 1413 | ||
| 1414 | config HAVE_FUTEX_CMPXCHG | ||
| 1415 | bool | ||
| 1416 | help | ||
| 1417 | Architectures should select this if futex_atomic_cmpxchg_inatomic() | ||
| 1418 | is implemented and always working. This removes a couple of runtime | ||
| 1419 | checks. | ||
| 1420 | |||
| 1405 | config EPOLL | 1421 | config EPOLL |
| 1406 | bool "Enable eventpoll support" if EXPERT | 1422 | bool "Enable eventpoll support" if EXPERT |
| 1407 | default y | 1423 | default y |
| @@ -1470,6 +1486,7 @@ config PCI_QUIRKS | |||
| 1470 | 1486 | ||
| 1471 | config EMBEDDED | 1487 | config EMBEDDED |
| 1472 | bool "Embedded system" | 1488 | bool "Embedded system" |
| 1489 | option allnoconfig_y | ||
| 1473 | select EXPERT | 1490 | select EXPERT |
| 1474 | help | 1491 | help |
| 1475 | This option should be enabled if compiling the kernel for | 1492 | This option should be enabled if compiling the kernel for |
diff --git a/init/do_mounts.c b/init/do_mounts.c index 8e5addc45874..82f22885c87e 100644 --- a/init/do_mounts.c +++ b/init/do_mounts.c | |||
| @@ -102,13 +102,13 @@ no_match: | |||
| 102 | 102 | ||
| 103 | /** | 103 | /** |
| 104 | * devt_from_partuuid - looks up the dev_t of a partition by its UUID | 104 | * devt_from_partuuid - looks up the dev_t of a partition by its UUID |
| 105 | * @uuid: char array containing ascii UUID | 105 | * @uuid_str: char array containing ascii UUID |
| 106 | * | 106 | * |
| 107 | * The function will return the first partition which contains a matching | 107 | * The function will return the first partition which contains a matching |
| 108 | * UUID value in its partition_meta_info struct. This does not search | 108 | * UUID value in its partition_meta_info struct. This does not search |
| 109 | * by filesystem UUIDs. | 109 | * by filesystem UUIDs. |
| 110 | * | 110 | * |
| 111 | * If @uuid is followed by a "/PARTNROFF=%d", then the number will be | 111 | * If @uuid_str is followed by a "/PARTNROFF=%d", then the number will be |
| 112 | * extracted and used as an offset from the partition identified by the UUID. | 112 | * extracted and used as an offset from the partition identified by the UUID. |
| 113 | * | 113 | * |
| 114 | * Returns the matching dev_t on success or 0 on failure. | 114 | * Returns the matching dev_t on success or 0 on failure. |
diff --git a/init/do_mounts_rd.c b/init/do_mounts_rd.c index 7c098ac9068a..a8227022e3a0 100644 --- a/init/do_mounts_rd.c +++ b/init/do_mounts_rd.c | |||
| @@ -13,7 +13,7 @@ | |||
| 13 | #include <linux/minix_fs.h> | 13 | #include <linux/minix_fs.h> |
| 14 | #include <linux/ext2_fs.h> | 14 | #include <linux/ext2_fs.h> |
| 15 | #include <linux/romfs_fs.h> | 15 | #include <linux/romfs_fs.h> |
| 16 | #include <linux/cramfs_fs.h> | 16 | #include <uapi/linux/cramfs_fs.h> |
| 17 | #include <linux/initrd.h> | 17 | #include <linux/initrd.h> |
| 18 | #include <linux/string.h> | 18 | #include <linux/string.h> |
| 19 | #include <linux/slab.h> | 19 | #include <linux/slab.h> |
diff --git a/init/initramfs.c b/init/initramfs.c index a67ef9dbda9d..a8497fab1c3d 100644 --- a/init/initramfs.c +++ b/init/initramfs.c | |||
| @@ -455,6 +455,7 @@ static char * __init unpack_to_rootfs(char *buf, unsigned len) | |||
| 455 | } | 455 | } |
| 456 | this_header = 0; | 456 | this_header = 0; |
| 457 | decompress = decompress_method(buf, len, &compress_name); | 457 | decompress = decompress_method(buf, len, &compress_name); |
| 458 | pr_debug("Detected %s compressed data\n", compress_name); | ||
| 458 | if (decompress) { | 459 | if (decompress) { |
| 459 | res = decompress(buf, len, NULL, flush_buffer, NULL, | 460 | res = decompress(buf, len, NULL, flush_buffer, NULL, |
| 460 | &my_inptr, error); | 461 | &my_inptr, error); |
| @@ -583,7 +584,7 @@ static int __init populate_rootfs(void) | |||
| 583 | { | 584 | { |
| 584 | char *err = unpack_to_rootfs(__initramfs_start, __initramfs_size); | 585 | char *err = unpack_to_rootfs(__initramfs_start, __initramfs_size); |
| 585 | if (err) | 586 | if (err) |
| 586 | panic(err); /* Failed to decompress INTERNAL initramfs */ | 587 | panic("%s", err); /* Failed to decompress INTERNAL initramfs */ |
| 587 | if (initrd_start) { | 588 | if (initrd_start) { |
| 588 | #ifdef CONFIG_BLK_DEV_RAM | 589 | #ifdef CONFIG_BLK_DEV_RAM |
| 589 | int fd; | 590 | int fd; |
diff --git a/init/main.c b/init/main.c index febc511e078a..9c7fd4c9249f 100644 --- a/init/main.c +++ b/init/main.c | |||
| @@ -92,17 +92,11 @@ static int kernel_init(void *); | |||
| 92 | 92 | ||
| 93 | extern void init_IRQ(void); | 93 | extern void init_IRQ(void); |
| 94 | extern void fork_init(unsigned long); | 94 | extern void fork_init(unsigned long); |
| 95 | extern void mca_init(void); | ||
| 96 | extern void sbus_init(void); | ||
| 97 | extern void radix_tree_init(void); | 95 | extern void radix_tree_init(void); |
| 98 | #ifndef CONFIG_DEBUG_RODATA | 96 | #ifndef CONFIG_DEBUG_RODATA |
| 99 | static inline void mark_rodata_ro(void) { } | 97 | static inline void mark_rodata_ro(void) { } |
| 100 | #endif | 98 | #endif |
| 101 | 99 | ||
| 102 | #ifdef CONFIG_TC | ||
| 103 | extern void tc_init(void); | ||
| 104 | #endif | ||
| 105 | |||
| 106 | /* | 100 | /* |
| 107 | * Debug helper: via this flag we know that we are in 'early bootup code' | 101 | * Debug helper: via this flag we know that we are in 'early bootup code' |
| 108 | * where only the boot processor is running with IRQ disabled. This means | 102 | * where only the boot processor is running with IRQ disabled. This means |
| @@ -282,7 +276,7 @@ static int __init unknown_bootoption(char *param, char *val, const char *unused) | |||
| 282 | unsigned int i; | 276 | unsigned int i; |
| 283 | for (i = 0; envp_init[i]; i++) { | 277 | for (i = 0; envp_init[i]; i++) { |
| 284 | if (i == MAX_INIT_ENVS) { | 278 | if (i == MAX_INIT_ENVS) { |
| 285 | panic_later = "Too many boot env vars at `%s'"; | 279 | panic_later = "env"; |
| 286 | panic_param = param; | 280 | panic_param = param; |
| 287 | } | 281 | } |
| 288 | if (!strncmp(param, envp_init[i], val - param)) | 282 | if (!strncmp(param, envp_init[i], val - param)) |
| @@ -294,7 +288,7 @@ static int __init unknown_bootoption(char *param, char *val, const char *unused) | |||
| 294 | unsigned int i; | 288 | unsigned int i; |
| 295 | for (i = 0; argv_init[i]; i++) { | 289 | for (i = 0; argv_init[i]; i++) { |
| 296 | if (i == MAX_INIT_ARGS) { | 290 | if (i == MAX_INIT_ARGS) { |
| 297 | panic_later = "Too many boot init vars at `%s'"; | 291 | panic_later = "init"; |
| 298 | panic_param = param; | 292 | panic_param = param; |
| 299 | } | 293 | } |
| 300 | } | 294 | } |
| @@ -355,9 +349,11 @@ static inline void smp_prepare_cpus(unsigned int maxcpus) { } | |||
| 355 | */ | 349 | */ |
| 356 | static void __init setup_command_line(char *command_line) | 350 | static void __init setup_command_line(char *command_line) |
| 357 | { | 351 | { |
| 358 | saved_command_line = alloc_bootmem(strlen (boot_command_line)+1); | 352 | saved_command_line = |
| 359 | initcall_command_line = alloc_bootmem(strlen (boot_command_line)+1); | 353 | memblock_virt_alloc(strlen(boot_command_line) + 1, 0); |
| 360 | static_command_line = alloc_bootmem(strlen (command_line)+1); | 354 | initcall_command_line = |
| 355 | memblock_virt_alloc(strlen(boot_command_line) + 1, 0); | ||
| 356 | static_command_line = memblock_virt_alloc(strlen(command_line) + 1, 0); | ||
| 361 | strcpy (saved_command_line, boot_command_line); | 357 | strcpy (saved_command_line, boot_command_line); |
| 362 | strcpy (static_command_line, command_line); | 358 | strcpy (static_command_line, command_line); |
| 363 | } | 359 | } |
| @@ -476,7 +472,7 @@ static void __init mm_init(void) | |||
| 476 | mem_init(); | 472 | mem_init(); |
| 477 | kmem_cache_init(); | 473 | kmem_cache_init(); |
| 478 | percpu_init_late(); | 474 | percpu_init_late(); |
| 479 | pgtable_cache_init(); | 475 | pgtable_init(); |
| 480 | vmalloc_init(); | 476 | vmalloc_init(); |
| 481 | } | 477 | } |
| 482 | 478 | ||
| @@ -584,7 +580,8 @@ asmlinkage void __init start_kernel(void) | |||
| 584 | */ | 580 | */ |
| 585 | console_init(); | 581 | console_init(); |
| 586 | if (panic_later) | 582 | if (panic_later) |
| 587 | panic(panic_later, panic_param); | 583 | panic("Too many boot %s vars at `%s'", panic_later, |
| 584 | panic_param); | ||
| 588 | 585 | ||
| 589 | lockdep_info(); | 586 | lockdep_info(); |
| 590 | 587 | ||
| @@ -615,6 +612,7 @@ asmlinkage void __init start_kernel(void) | |||
| 615 | calibrate_delay(); | 612 | calibrate_delay(); |
| 616 | pidmap_init(); | 613 | pidmap_init(); |
| 617 | anon_vma_init(); | 614 | anon_vma_init(); |
| 615 | acpi_early_init(); | ||
| 618 | #ifdef CONFIG_X86 | 616 | #ifdef CONFIG_X86 |
| 619 | if (efi_enabled(EFI_RUNTIME_SERVICES)) | 617 | if (efi_enabled(EFI_RUNTIME_SERVICES)) |
| 620 | efi_enter_virtual_mode(); | 618 | efi_enter_virtual_mode(); |
| @@ -641,7 +639,6 @@ asmlinkage void __init start_kernel(void) | |||
| 641 | 639 | ||
| 642 | check_bugs(); | 640 | check_bugs(); |
| 643 | 641 | ||
| 644 | acpi_early_init(); /* before LAPIC and SMP init */ | ||
| 645 | sfi_init_late(); | 642 | sfi_init_late(); |
| 646 | 643 | ||
| 647 | if (efi_enabled(EFI_RUNTIME_SERVICES)) { | 644 | if (efi_enabled(EFI_RUNTIME_SERVICES)) { |
| @@ -815,7 +812,7 @@ void __init load_default_modules(void) | |||
| 815 | static int run_init_process(const char *init_filename) | 812 | static int run_init_process(const char *init_filename) |
| 816 | { | 813 | { |
| 817 | argv_init[0] = init_filename; | 814 | argv_init[0] = init_filename; |
| 818 | return do_execve(init_filename, | 815 | return do_execve(getname_kernel(init_filename), |
| 819 | (const char __user *const __user *)argv_init, | 816 | (const char __user *const __user *)argv_init, |
| 820 | (const char __user *const __user *)envp_init); | 817 | (const char __user *const __user *)envp_init); |
| 821 | } | 818 | } |
