diff options
Diffstat (limited to 'init')
-rw-r--r-- | init/Kconfig | 47 | ||||
-rw-r--r-- | init/calibrate.c | 2 | ||||
-rw-r--r-- | init/do_mounts.c | 3 | ||||
-rw-r--r-- | init/do_mounts.h | 1 | ||||
-rw-r--r-- | init/do_mounts_rd.c | 37 | ||||
-rw-r--r-- | init/initramfs.c | 22 | ||||
-rw-r--r-- | init/main.c | 44 | ||||
-rw-r--r-- | init/version.c | 3 |
8 files changed, 47 insertions, 112 deletions
diff --git a/init/Kconfig b/init/Kconfig index 6199d1120900..c11da38837e5 100644 --- a/init/Kconfig +++ b/init/Kconfig | |||
@@ -171,7 +171,7 @@ config BSD_PROCESS_ACCT_V3 | |||
171 | process and it's parent. Note that this file format is incompatible | 171 | process and it's parent. Note that this file format is incompatible |
172 | with previous v0/v1/v2 file formats, so you will need updated tools | 172 | with previous v0/v1/v2 file formats, so you will need updated tools |
173 | for processing it. A preliminary version of these tools is available | 173 | for processing it. A preliminary version of these tools is available |
174 | at <http://www.physik3.uni-rostock.de/tim/kernel/utils/acct/>. | 174 | at <http://www.gnu.org/software/acct/>. |
175 | 175 | ||
176 | config TASKSTATS | 176 | config TASKSTATS |
177 | bool "Export task/process statistics through netlink (EXPERIMENTAL)" | 177 | bool "Export task/process statistics through netlink (EXPERIMENTAL)" |
@@ -486,7 +486,7 @@ config PID_NS | |||
486 | default n | 486 | default n |
487 | depends on NAMESPACES && EXPERIMENTAL | 487 | depends on NAMESPACES && EXPERIMENTAL |
488 | help | 488 | help |
489 | Suport process id namespaces. This allows having multiple | 489 | Support process id namespaces. This allows having multiple |
490 | process with the same pid as long as they are in different | 490 | process with the same pid as long as they are in different |
491 | pid namespaces. This is a building block of containers. | 491 | pid namespaces. This is a building block of containers. |
492 | 492 | ||
@@ -522,7 +522,7 @@ config CC_OPTIMIZE_FOR_SIZE | |||
522 | Enabling this option will pass "-Os" instead of "-O2" to gcc | 522 | Enabling this option will pass "-Os" instead of "-O2" to gcc |
523 | resulting in a smaller kernel. | 523 | resulting in a smaller kernel. |
524 | 524 | ||
525 | If unsure, say N. | 525 | If unsure, say Y. |
526 | 526 | ||
527 | config SYSCTL | 527 | config SYSCTL |
528 | bool | 528 | bool |
@@ -558,17 +558,6 @@ config SYSCTL_SYSCALL | |||
558 | 558 | ||
559 | If unsure say Y here. | 559 | If unsure say Y here. |
560 | 560 | ||
561 | config SYSCTL_SYSCALL_CHECK | ||
562 | bool "Sysctl checks" if EMBEDDED | ||
563 | depends on SYSCTL_SYSCALL | ||
564 | default y | ||
565 | ---help--- | ||
566 | sys_sysctl uses binary paths that have been found challenging | ||
567 | to properly maintain and use. This enables checks that help | ||
568 | you to keep things correct. | ||
569 | |||
570 | If unsure say Y here. | ||
571 | |||
572 | config KALLSYMS | 561 | config KALLSYMS |
573 | bool "Load all symbols for debugging/ksymoops" if EMBEDDED | 562 | bool "Load all symbols for debugging/ksymoops" if EMBEDDED |
574 | default y | 563 | default y |
@@ -802,6 +791,10 @@ config PROC_PAGE_MONITOR | |||
802 | 791 | ||
803 | endmenu # General setup | 792 | endmenu # General setup |
804 | 793 | ||
794 | config HAVE_GENERIC_DMA_COHERENT | ||
795 | bool | ||
796 | default n | ||
797 | |||
805 | config SLABINFO | 798 | config SLABINFO |
806 | bool | 799 | bool |
807 | depends on PROC_FS | 800 | depends on PROC_FS |
@@ -841,9 +834,10 @@ menuconfig MODULES | |||
841 | 834 | ||
842 | If unsure, say Y. | 835 | If unsure, say Y. |
843 | 836 | ||
837 | if MODULES | ||
838 | |||
844 | config MODULE_FORCE_LOAD | 839 | config MODULE_FORCE_LOAD |
845 | bool "Forced module loading" | 840 | bool "Forced module loading" |
846 | depends on MODULES | ||
847 | default n | 841 | default n |
848 | help | 842 | help |
849 | Allow loading of modules without version information (ie. modprobe | 843 | Allow loading of modules without version information (ie. modprobe |
@@ -852,12 +846,11 @@ config MODULE_FORCE_LOAD | |||
852 | 846 | ||
853 | config MODULE_UNLOAD | 847 | config MODULE_UNLOAD |
854 | bool "Module unloading" | 848 | bool "Module unloading" |
855 | depends on MODULES | ||
856 | help | 849 | help |
857 | Without this option you will not be able to unload any | 850 | Without this option you will not be able to unload any |
858 | modules (note that some modules may not be unloadable | 851 | modules (note that some modules may not be unloadable |
859 | anyway), which makes your kernel slightly smaller and | 852 | anyway), which makes your kernel smaller, faster |
860 | simpler. If unsure, say Y. | 853 | and simpler. If unsure, say Y. |
861 | 854 | ||
862 | config MODULE_FORCE_UNLOAD | 855 | config MODULE_FORCE_UNLOAD |
863 | bool "Forced module unloading" | 856 | bool "Forced module unloading" |
@@ -871,7 +864,6 @@ config MODULE_FORCE_UNLOAD | |||
871 | 864 | ||
872 | config MODVERSIONS | 865 | config MODVERSIONS |
873 | bool "Module versioning support" | 866 | bool "Module versioning support" |
874 | depends on MODULES | ||
875 | help | 867 | help |
876 | Usually, you have to use modules compiled with your kernel. | 868 | Usually, you have to use modules compiled with your kernel. |
877 | Saying Y here makes it sometimes possible to use modules | 869 | Saying Y here makes it sometimes possible to use modules |
@@ -882,7 +874,6 @@ config MODVERSIONS | |||
882 | 874 | ||
883 | config MODULE_SRCVERSION_ALL | 875 | config MODULE_SRCVERSION_ALL |
884 | bool "Source checksum for all modules" | 876 | bool "Source checksum for all modules" |
885 | depends on MODULES | ||
886 | help | 877 | help |
887 | Modules which contain a MODULE_VERSION get an extra "srcversion" | 878 | Modules which contain a MODULE_VERSION get an extra "srcversion" |
888 | field inserted into their modinfo section, which contains a | 879 | field inserted into their modinfo section, which contains a |
@@ -893,16 +884,12 @@ config MODULE_SRCVERSION_ALL | |||
893 | will be created for all modules. If unsure, say N. | 884 | will be created for all modules. If unsure, say N. |
894 | 885 | ||
895 | config KMOD | 886 | config KMOD |
896 | bool "Automatic kernel module loading" | 887 | def_bool y |
897 | depends on MODULES | 888 | help |
898 | help | 889 | This is being removed soon. These days, CONFIG_MODULES |
899 | Normally when you have selected some parts of the kernel to | 890 | implies CONFIG_KMOD, so use that instead. |
900 | be created as kernel modules, you must load them (using the | 891 | |
901 | "modprobe" command) before you can use them. If you say Y | 892 | endif # MODULES |
902 | here, some parts of the kernel will be able to load modules | ||
903 | automatically: when a part of the kernel needs a module, it | ||
904 | runs modprobe with the appropriate arguments, thereby | ||
905 | loading the module if it is available. If unsure, say Y. | ||
906 | 893 | ||
907 | config STOP_MACHINE | 894 | config STOP_MACHINE |
908 | bool | 895 | bool |
diff --git a/init/calibrate.c b/init/calibrate.c index 7963e3fc51d9..a379c9061199 100644 --- a/init/calibrate.c +++ b/init/calibrate.c | |||
@@ -170,7 +170,7 @@ void __cpuinit calibrate_delay(void) | |||
170 | loops_per_jiffy &= ~loopbit; | 170 | loops_per_jiffy &= ~loopbit; |
171 | } | 171 | } |
172 | } | 172 | } |
173 | printk(KERN_INFO "%lu.%02lu BogoMIPS (lpj=%lu)\n", | 173 | printk(KERN_CONT "%lu.%02lu BogoMIPS (lpj=%lu)\n", |
174 | loops_per_jiffy/(500000/HZ), | 174 | loops_per_jiffy/(500000/HZ), |
175 | (loops_per_jiffy/(5000/HZ)) % 100, loops_per_jiffy); | 175 | (loops_per_jiffy/(5000/HZ)) % 100, loops_per_jiffy); |
176 | } | 176 | } |
diff --git a/init/do_mounts.c b/init/do_mounts.c index a1de1bf3d6b9..3715feb8446d 100644 --- a/init/do_mounts.c +++ b/init/do_mounts.c | |||
@@ -12,6 +12,7 @@ | |||
12 | #include <linux/device.h> | 12 | #include <linux/device.h> |
13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
14 | #include <linux/fs.h> | 14 | #include <linux/fs.h> |
15 | #include <linux/initrd.h> | ||
15 | 16 | ||
16 | #include <linux/nfs_fs.h> | 17 | #include <linux/nfs_fs.h> |
17 | #include <linux/nfs_fs_sb.h> | 18 | #include <linux/nfs_fs_sb.h> |
@@ -22,7 +23,7 @@ | |||
22 | int __initdata rd_doload; /* 1 = load RAM disk, 0 = don't load */ | 23 | int __initdata rd_doload; /* 1 = load RAM disk, 0 = don't load */ |
23 | 24 | ||
24 | int root_mountflags = MS_RDONLY | MS_SILENT; | 25 | int root_mountflags = MS_RDONLY | MS_SILENT; |
25 | char * __initdata root_device_name; | 26 | static char * __initdata root_device_name; |
26 | static char __initdata saved_root_name[64]; | 27 | static char __initdata saved_root_name[64]; |
27 | static int __initdata root_wait; | 28 | static int __initdata root_wait; |
28 | 29 | ||
diff --git a/init/do_mounts.h b/init/do_mounts.h index 735705d137ff..9aa968d54329 100644 --- a/init/do_mounts.h +++ b/init/do_mounts.h | |||
@@ -11,7 +11,6 @@ void change_floppy(char *fmt, ...); | |||
11 | void mount_block_root(char *name, int flags); | 11 | void mount_block_root(char *name, int flags); |
12 | void mount_root(void); | 12 | void mount_root(void); |
13 | extern int root_mountflags; | 13 | extern int root_mountflags; |
14 | extern char *root_device_name; | ||
15 | 14 | ||
16 | static inline int create_dev(char *name, dev_t dev) | 15 | static inline int create_dev(char *name, dev_t dev) |
17 | { | 16 | { |
diff --git a/init/do_mounts_rd.c b/init/do_mounts_rd.c index 46dfd64ae8fb..fedef93b586f 100644 --- a/init/do_mounts_rd.c +++ b/init/do_mounts_rd.c | |||
@@ -10,8 +10,6 @@ | |||
10 | 10 | ||
11 | #include "do_mounts.h" | 11 | #include "do_mounts.h" |
12 | 12 | ||
13 | #define BUILD_CRAMDISK | ||
14 | |||
15 | int __initdata rd_prompt = 1;/* 1 = prompt for RAM disk, 0 = don't prompt */ | 13 | int __initdata rd_prompt = 1;/* 1 = prompt for RAM disk, 0 = don't prompt */ |
16 | 14 | ||
17 | static int __init prompt_ramdisk(char *str) | 15 | static int __init prompt_ramdisk(char *str) |
@@ -162,14 +160,8 @@ int __init rd_load_image(char *from) | |||
162 | goto done; | 160 | goto done; |
163 | 161 | ||
164 | if (nblocks == 0) { | 162 | if (nblocks == 0) { |
165 | #ifdef BUILD_CRAMDISK | ||
166 | if (crd_load(in_fd, out_fd) == 0) | 163 | if (crd_load(in_fd, out_fd) == 0) |
167 | goto successful_load; | 164 | goto successful_load; |
168 | #else | ||
169 | printk(KERN_NOTICE | ||
170 | "RAMDISK: Kernel does not support compressed " | ||
171 | "RAM disk images\n"); | ||
172 | #endif | ||
173 | goto done; | 165 | goto done; |
174 | } | 166 | } |
175 | 167 | ||
@@ -267,8 +259,6 @@ int __init rd_load_disk(int n) | |||
267 | return rd_load_image("/dev/root"); | 259 | return rd_load_image("/dev/root"); |
268 | } | 260 | } |
269 | 261 | ||
270 | #ifdef BUILD_CRAMDISK | ||
271 | |||
272 | /* | 262 | /* |
273 | * gzip declarations | 263 | * gzip declarations |
274 | */ | 264 | */ |
@@ -313,32 +303,11 @@ static int crd_infd, crd_outfd; | |||
313 | 303 | ||
314 | static int __init fill_inbuf(void); | 304 | static int __init fill_inbuf(void); |
315 | static void __init flush_window(void); | 305 | static void __init flush_window(void); |
316 | static void __init *malloc(size_t size); | ||
317 | static void __init free(void *where); | ||
318 | static void __init error(char *m); | 306 | static void __init error(char *m); |
319 | static void __init gzip_mark(void **); | ||
320 | static void __init gzip_release(void **); | ||
321 | |||
322 | #include "../lib/inflate.c" | ||
323 | 307 | ||
324 | static void __init *malloc(size_t size) | 308 | #define NO_INFLATE_MALLOC |
325 | { | ||
326 | return kmalloc(size, GFP_KERNEL); | ||
327 | } | ||
328 | |||
329 | static void __init free(void *where) | ||
330 | { | ||
331 | kfree(where); | ||
332 | } | ||
333 | |||
334 | static void __init gzip_mark(void **ptr) | ||
335 | { | ||
336 | } | ||
337 | |||
338 | static void __init gzip_release(void **ptr) | ||
339 | { | ||
340 | } | ||
341 | 309 | ||
310 | #include "../lib/inflate.c" | ||
342 | 311 | ||
343 | /* =========================================================================== | 312 | /* =========================================================================== |
344 | * Fill the input buffer. This is called only when the buffer is empty | 313 | * Fill the input buffer. This is called only when the buffer is empty |
@@ -425,5 +394,3 @@ static int __init crd_load(int in_fd, int out_fd) | |||
425 | kfree(window); | 394 | kfree(window); |
426 | return result; | 395 | return result; |
427 | } | 396 | } |
428 | |||
429 | #endif /* BUILD_CRAMDISK */ | ||
diff --git a/init/initramfs.c b/init/initramfs.c index 8eeeccb328c9..644fc01ad5f0 100644 --- a/init/initramfs.c +++ b/init/initramfs.c | |||
@@ -14,16 +14,6 @@ static void __init error(char *x) | |||
14 | message = x; | 14 | message = x; |
15 | } | 15 | } |
16 | 16 | ||
17 | static void __init *malloc(size_t size) | ||
18 | { | ||
19 | return kmalloc(size, GFP_KERNEL); | ||
20 | } | ||
21 | |||
22 | static void __init free(void *where) | ||
23 | { | ||
24 | kfree(where); | ||
25 | } | ||
26 | |||
27 | /* link hash */ | 17 | /* link hash */ |
28 | 18 | ||
29 | #define N_ALIGN(len) ((((len) + 1) & ~3) + 2) | 19 | #define N_ALIGN(len) ((((len) + 1) & ~3) + 2) |
@@ -407,18 +397,10 @@ static long bytes_out; | |||
407 | 397 | ||
408 | static void __init flush_window(void); | 398 | static void __init flush_window(void); |
409 | static void __init error(char *m); | 399 | static void __init error(char *m); |
410 | static void __init gzip_mark(void **); | ||
411 | static void __init gzip_release(void **); | ||
412 | 400 | ||
413 | #include "../lib/inflate.c" | 401 | #define NO_INFLATE_MALLOC |
414 | 402 | ||
415 | static void __init gzip_mark(void **ptr) | 403 | #include "../lib/inflate.c" |
416 | { | ||
417 | } | ||
418 | |||
419 | static void __init gzip_release(void **ptr) | ||
420 | { | ||
421 | } | ||
422 | 404 | ||
423 | /* =========================================================================== | 405 | /* =========================================================================== |
424 | * Write the output window window[0..outcnt-1] and update crc and bytes_out. | 406 | * Write the output window window[0..outcnt-1] and update crc and bytes_out. |
diff --git a/init/main.c b/init/main.c index edeace036fd9..f6f7042331dc 100644 --- a/init/main.c +++ b/init/main.c | |||
@@ -22,7 +22,6 @@ | |||
22 | #include <linux/init.h> | 22 | #include <linux/init.h> |
23 | #include <linux/smp_lock.h> | 23 | #include <linux/smp_lock.h> |
24 | #include <linux/initrd.h> | 24 | #include <linux/initrd.h> |
25 | #include <linux/hdreg.h> | ||
26 | #include <linux/bootmem.h> | 25 | #include <linux/bootmem.h> |
27 | #include <linux/tty.h> | 26 | #include <linux/tty.h> |
28 | #include <linux/gfp.h> | 27 | #include <linux/gfp.h> |
@@ -87,8 +86,6 @@ extern void init_IRQ(void); | |||
87 | extern void fork_init(unsigned long); | 86 | extern void fork_init(unsigned long); |
88 | extern void mca_init(void); | 87 | extern void mca_init(void); |
89 | extern void sbus_init(void); | 88 | extern void sbus_init(void); |
90 | extern void pidhash_init(void); | ||
91 | extern void pidmap_init(void); | ||
92 | extern void prio_tree_init(void); | 89 | extern void prio_tree_init(void); |
93 | extern void radix_tree_init(void); | 90 | extern void radix_tree_init(void); |
94 | extern void free_initmem(void); | 91 | extern void free_initmem(void); |
@@ -415,6 +412,13 @@ static void __init smp_init(void) | |||
415 | { | 412 | { |
416 | unsigned int cpu; | 413 | unsigned int cpu; |
417 | 414 | ||
415 | /* | ||
416 | * Set up the current CPU as possible to migrate to. | ||
417 | * The other ones will be done by cpu_up/cpu_down() | ||
418 | */ | ||
419 | cpu = smp_processor_id(); | ||
420 | cpu_set(cpu, cpu_active_map); | ||
421 | |||
418 | /* FIXME: This should be done in userspace --RR */ | 422 | /* FIXME: This should be done in userspace --RR */ |
419 | for_each_present_cpu(cpu) { | 423 | for_each_present_cpu(cpu) { |
420 | if (num_online_cpus() >= setup_max_cpus) | 424 | if (num_online_cpus() >= setup_max_cpus) |
@@ -630,9 +634,11 @@ asmlinkage void __init start_kernel(void) | |||
630 | 634 | ||
631 | #ifdef CONFIG_BLK_DEV_INITRD | 635 | #ifdef CONFIG_BLK_DEV_INITRD |
632 | if (initrd_start && !initrd_below_start_ok && | 636 | if (initrd_start && !initrd_below_start_ok && |
633 | initrd_start < min_low_pfn << PAGE_SHIFT) { | 637 | page_to_pfn(virt_to_page((void *)initrd_start)) < min_low_pfn) { |
634 | printk(KERN_CRIT "initrd overwritten (0x%08lx < 0x%08lx) - " | 638 | printk(KERN_CRIT "initrd overwritten (0x%08lx < 0x%08lx) - " |
635 | "disabling it.\n",initrd_start,min_low_pfn << PAGE_SHIFT); | 639 | "disabling it.\n", |
640 | page_to_pfn(virt_to_page((void *)initrd_start)), | ||
641 | min_low_pfn); | ||
636 | initrd_start = 0; | 642 | initrd_start = 0; |
637 | } | 643 | } |
638 | #endif | 644 | #endif |
@@ -685,7 +691,7 @@ asmlinkage void __init start_kernel(void) | |||
685 | rest_init(); | 691 | rest_init(); |
686 | } | 692 | } |
687 | 693 | ||
688 | static int __initdata initcall_debug; | 694 | static int initcall_debug; |
689 | 695 | ||
690 | static int __init initcall_debug_setup(char *str) | 696 | static int __init initcall_debug_setup(char *str) |
691 | { | 697 | { |
@@ -694,7 +700,7 @@ static int __init initcall_debug_setup(char *str) | |||
694 | } | 700 | } |
695 | __setup("initcall_debug", initcall_debug_setup); | 701 | __setup("initcall_debug", initcall_debug_setup); |
696 | 702 | ||
697 | static void __init do_one_initcall(initcall_t fn) | 703 | int do_one_initcall(initcall_t fn) |
698 | { | 704 | { |
699 | int count = preempt_count(); | 705 | int count = preempt_count(); |
700 | ktime_t t0, t1, delta; | 706 | ktime_t t0, t1, delta; |
@@ -734,16 +740,18 @@ static void __init do_one_initcall(initcall_t fn) | |||
734 | print_fn_descriptor_symbol(KERN_WARNING "initcall %s", fn); | 740 | print_fn_descriptor_symbol(KERN_WARNING "initcall %s", fn); |
735 | printk(" returned with %s\n", msgbuf); | 741 | printk(" returned with %s\n", msgbuf); |
736 | } | 742 | } |
743 | |||
744 | return result; | ||
737 | } | 745 | } |
738 | 746 | ||
739 | 747 | ||
740 | extern initcall_t __initcall_start[], __initcall_end[]; | 748 | extern initcall_t __initcall_start[], __initcall_end[], __early_initcall_end[]; |
741 | 749 | ||
742 | static void __init do_initcalls(void) | 750 | static void __init do_initcalls(void) |
743 | { | 751 | { |
744 | initcall_t *call; | 752 | initcall_t *call; |
745 | 753 | ||
746 | for (call = __initcall_start; call < __initcall_end; call++) | 754 | for (call = __early_initcall_end; call < __initcall_end; call++) |
747 | do_one_initcall(*call); | 755 | do_one_initcall(*call); |
748 | 756 | ||
749 | /* Make sure there is no pending stuff from the initcall sequence */ | 757 | /* Make sure there is no pending stuff from the initcall sequence */ |
@@ -768,24 +776,12 @@ static void __init do_basic_setup(void) | |||
768 | do_initcalls(); | 776 | do_initcalls(); |
769 | } | 777 | } |
770 | 778 | ||
771 | static int __initdata nosoftlockup; | ||
772 | |||
773 | static int __init nosoftlockup_setup(char *str) | ||
774 | { | ||
775 | nosoftlockup = 1; | ||
776 | return 1; | ||
777 | } | ||
778 | __setup("nosoftlockup", nosoftlockup_setup); | ||
779 | |||
780 | static void __init do_pre_smp_initcalls(void) | 779 | static void __init do_pre_smp_initcalls(void) |
781 | { | 780 | { |
782 | extern int spawn_ksoftirqd(void); | 781 | initcall_t *call; |
783 | 782 | ||
784 | init_call_single_data(); | 783 | for (call = __initcall_start; call < __early_initcall_end; call++) |
785 | migration_init(); | 784 | do_one_initcall(*call); |
786 | spawn_ksoftirqd(); | ||
787 | if (!nosoftlockup) | ||
788 | spawn_softlockup_task(); | ||
789 | } | 785 | } |
790 | 786 | ||
791 | static void run_init_process(char *init_filename) | 787 | static void run_init_process(char *init_filename) |
diff --git a/init/version.c b/init/version.c index 9d17d70ee02d..52a8b98642b8 100644 --- a/init/version.c +++ b/init/version.c | |||
@@ -13,10 +13,13 @@ | |||
13 | #include <linux/utsrelease.h> | 13 | #include <linux/utsrelease.h> |
14 | #include <linux/version.h> | 14 | #include <linux/version.h> |
15 | 15 | ||
16 | #ifndef CONFIG_KALLSYMS | ||
16 | #define version(a) Version_ ## a | 17 | #define version(a) Version_ ## a |
17 | #define version_string(a) version(a) | 18 | #define version_string(a) version(a) |
18 | 19 | ||
20 | extern int version_string(LINUX_VERSION_CODE); | ||
19 | int version_string(LINUX_VERSION_CODE); | 21 | int version_string(LINUX_VERSION_CODE); |
22 | #endif | ||
20 | 23 | ||
21 | struct uts_namespace init_uts_ns = { | 24 | struct uts_namespace init_uts_ns = { |
22 | .kref = { | 25 | .kref = { |