diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2010-02-21 14:17:22 -0500 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2010-02-21 14:17:22 -0500 |
commit | 5f854cfc024622e4aae14d7cf422f6ff86278688 (patch) | |
tree | 426e77c6f6e4939c80440bf1fabcb020e3ee145b /init | |
parent | cc24da0742870f152ddf1002aa39dfcd83f7cf9c (diff) | |
parent | 4ec62b2b2e6bd7ddef7b6cea6e5db7b5578a6532 (diff) |
Forward to 2.6.33-rc8
Merge branch 'linus' into rt/head with a pile of conflicts.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'init')
-rw-r--r-- | init/Kconfig | 192 | ||||
-rw-r--r-- | init/Makefile | 8 | ||||
-rw-r--r-- | init/calibrate.c | 24 | ||||
-rw-r--r-- | init/do_mounts.c | 2 | ||||
-rw-r--r-- | init/initramfs.c | 10 | ||||
-rw-r--r-- | init/main.c | 105 | ||||
-rw-r--r-- | init/version.c | 4 |
7 files changed, 183 insertions, 162 deletions
diff --git a/init/Kconfig b/init/Kconfig index ef7c8dbb2127..5cc04424f552 100644 --- a/init/Kconfig +++ b/init/Kconfig | |||
@@ -115,10 +115,13 @@ config HAVE_KERNEL_BZIP2 | |||
115 | config HAVE_KERNEL_LZMA | 115 | config HAVE_KERNEL_LZMA |
116 | bool | 116 | bool |
117 | 117 | ||
118 | config HAVE_KERNEL_LZO | ||
119 | bool | ||
120 | |||
118 | choice | 121 | choice |
119 | prompt "Kernel compression mode" | 122 | prompt "Kernel compression mode" |
120 | default KERNEL_GZIP | 123 | default KERNEL_GZIP |
121 | depends on HAVE_KERNEL_GZIP || HAVE_KERNEL_BZIP2 || HAVE_KERNEL_LZMA | 124 | depends on HAVE_KERNEL_GZIP || HAVE_KERNEL_BZIP2 || HAVE_KERNEL_LZMA || HAVE_KERNEL_LZO |
122 | help | 125 | help |
123 | The linux kernel is a kind of self-extracting executable. | 126 | The linux kernel is a kind of self-extracting executable. |
124 | Several compression algorithms are available, which differ | 127 | Several compression algorithms are available, which differ |
@@ -141,9 +144,8 @@ config KERNEL_GZIP | |||
141 | bool "Gzip" | 144 | bool "Gzip" |
142 | depends on HAVE_KERNEL_GZIP | 145 | depends on HAVE_KERNEL_GZIP |
143 | help | 146 | help |
144 | The old and tried gzip compression. Its compression ratio is | 147 | The old and tried gzip compression. It provides a good balance |
145 | the poorest among the 3 choices; however its speed (both | 148 | between compression ratio and decompression speed. |
146 | compression and decompression) is the fastest. | ||
147 | 149 | ||
148 | config KERNEL_BZIP2 | 150 | config KERNEL_BZIP2 |
149 | bool "Bzip2" | 151 | bool "Bzip2" |
@@ -164,6 +166,14 @@ config KERNEL_LZMA | |||
164 | two. Compression is slowest. The kernel size is about 33% | 166 | two. Compression is slowest. The kernel size is about 33% |
165 | smaller with LZMA in comparison to gzip. | 167 | smaller with LZMA in comparison to gzip. |
166 | 168 | ||
169 | config KERNEL_LZO | ||
170 | bool "LZO" | ||
171 | depends on HAVE_KERNEL_LZO | ||
172 | help | ||
173 | Its compression ratio is the poorest among the 4. The kernel | ||
174 | size is about about 10% bigger than gzip; however its speed | ||
175 | (both compression and decompression) is the fastest. | ||
176 | |||
167 | endchoice | 177 | endchoice |
168 | 178 | ||
169 | config SWAP | 179 | config SWAP |
@@ -297,7 +307,7 @@ config AUDIT | |||
297 | 307 | ||
298 | config AUDITSYSCALL | 308 | config AUDITSYSCALL |
299 | bool "Enable system-call auditing support" | 309 | bool "Enable system-call auditing support" |
300 | depends on AUDIT && (X86 || PPC || PPC64 || S390 || IA64 || UML || SPARC64|| SUPERH) | 310 | depends on AUDIT && (X86 || PPC || S390 || IA64 || UML || SPARC64 || SUPERH) |
301 | default y if SECURITY_SELINUX | 311 | default y if SECURITY_SELINUX |
302 | help | 312 | help |
303 | Enable low-overhead system-call auditing infrastructure that | 313 | Enable low-overhead system-call auditing infrastructure that |
@@ -316,40 +326,39 @@ choice | |||
316 | prompt "RCU Implementation" | 326 | prompt "RCU Implementation" |
317 | default TREE_RCU | 327 | default TREE_RCU |
318 | 328 | ||
319 | config CLASSIC_RCU | ||
320 | bool "Classic RCU" | ||
321 | depends on !PREEMPT_RT | ||
322 | help | ||
323 | This option selects the classic RCU implementation that is | ||
324 | designed for best read-side performance on non-realtime | ||
325 | systems. | ||
326 | |||
327 | Select this option if you are unsure. | ||
328 | |||
329 | config TREE_RCU | 329 | config TREE_RCU |
330 | bool "Tree-based hierarchical RCU" | 330 | bool "Tree-based hierarchical RCU" |
331 | depends on !PREEMPT_RT | 331 | depends on !PREEMPT_RT |
332 | help | 332 | help |
333 | This option selects the RCU implementation that is | 333 | This option selects the RCU implementation that is |
334 | designed for very large SMP system with hundreds or | 334 | designed for very large SMP system with hundreds or |
335 | thousands of CPUs. | 335 | thousands of CPUs. It also scales down nicely to |
336 | smaller systems. | ||
336 | 337 | ||
337 | config PREEMPT_RCU | 338 | config TREE_PREEMPT_RCU |
338 | bool "Preemptible RCU" | 339 | bool "Preemptable tree-based hierarchical RCU" |
339 | depends on PREEMPT | 340 | depends on PREEMPT |
340 | help | 341 | help |
341 | This option reduces the latency of the kernel by making certain | 342 | This option selects the RCU implementation that is |
342 | RCU sections preemptible. Normally RCU code is non-preemptible, if | 343 | designed for very large SMP systems with hundreds or |
343 | this option is selected then read-only RCU sections become | 344 | thousands of CPUs, but for which real-time response |
344 | preemptible. This helps latency, but may expose bugs due to | 345 | is also required. It also scales down nicely to |
345 | now-naive assumptions about each RCU read-side critical section | 346 | smaller systems. |
346 | remaining on a given CPU through its execution. | 347 | |
348 | config TINY_RCU | ||
349 | bool "UP-only small-memory-footprint RCU" | ||
350 | depends on !SMP && !PREEMPT_RT | ||
351 | help | ||
352 | This option selects the RCU implementation that is | ||
353 | designed for UP systems from which real-time response | ||
354 | is not required. This option greatly reduces the | ||
355 | memory footprint of RCU. | ||
347 | 356 | ||
348 | endchoice | 357 | endchoice |
349 | 358 | ||
350 | config RCU_TRACE | 359 | config RCU_TRACE |
351 | bool "Enable tracing for RCU" | 360 | bool "Enable tracing for RCU" |
352 | depends on TREE_RCU || PREEMPT_RCU | 361 | depends on TREE_RCU || TREE_PREEMPT_RCU |
353 | help | 362 | help |
354 | This option provides tracing in RCU which presents stats | 363 | This option provides tracing in RCU which presents stats |
355 | in debugfs for debugging RCU implementation. | 364 | in debugfs for debugging RCU implementation. |
@@ -361,7 +370,7 @@ config RCU_FANOUT | |||
361 | int "Tree-based hierarchical RCU fanout value" | 370 | int "Tree-based hierarchical RCU fanout value" |
362 | range 2 64 if 64BIT | 371 | range 2 64 if 64BIT |
363 | range 2 32 if !64BIT | 372 | range 2 32 if !64BIT |
364 | depends on TREE_RCU | 373 | depends on TREE_RCU || TREE_PREEMPT_RCU |
365 | default 64 if 64BIT | 374 | default 64 if 64BIT |
366 | default 32 if !64BIT | 375 | default 32 if !64BIT |
367 | help | 376 | help |
@@ -376,7 +385,7 @@ config RCU_FANOUT | |||
376 | 385 | ||
377 | config RCU_FANOUT_EXACT | 386 | config RCU_FANOUT_EXACT |
378 | bool "Disable tree-based hierarchical RCU auto-balancing" | 387 | bool "Disable tree-based hierarchical RCU auto-balancing" |
379 | depends on TREE_RCU | 388 | depends on TREE_RCU || TREE_PREEMPT_RCU |
380 | default n | 389 | default n |
381 | help | 390 | help |
382 | This option forces use of the exact RCU_FANOUT value specified, | 391 | This option forces use of the exact RCU_FANOUT value specified, |
@@ -389,18 +398,12 @@ config RCU_FANOUT_EXACT | |||
389 | Say N if unsure. | 398 | Say N if unsure. |
390 | 399 | ||
391 | config TREE_RCU_TRACE | 400 | config TREE_RCU_TRACE |
392 | def_bool RCU_TRACE && TREE_RCU | 401 | def_bool RCU_TRACE && ( TREE_RCU || TREE_PREEMPT_RCU ) |
393 | select DEBUG_FS | 402 | select DEBUG_FS |
394 | help | 403 | help |
395 | This option provides tracing for the TREE_RCU implementation, | 404 | This option provides tracing for the TREE_RCU and |
396 | permitting Makefile to trivially select kernel/rcutree_trace.c. | 405 | TREE_PREEMPT_RCU implementations, permitting Makefile to |
397 | 406 | trivially select kernel/rcutree_trace.c. | |
398 | config PREEMPT_RCU_TRACE | ||
399 | def_bool RCU_TRACE && PREEMPT_RCU | ||
400 | select DEBUG_FS | ||
401 | help | ||
402 | This option provides tracing for the PREEMPT_RCU implementation, | ||
403 | permitting Makefile to trivially select kernel/rcupreempt_trace.c. | ||
404 | 407 | ||
405 | endmenu # "RCU Subsystem" | 408 | endmenu # "RCU Subsystem" |
406 | 409 | ||
@@ -623,7 +626,7 @@ config SYSFS_DEPRECATED | |||
623 | bool | 626 | bool |
624 | 627 | ||
625 | config SYSFS_DEPRECATED_V2 | 628 | config SYSFS_DEPRECATED_V2 |
626 | bool "remove sysfs features which may confuse old userspace tools" | 629 | bool "enable deprecated sysfs features to support old userspace tools" |
627 | depends on SYSFS | 630 | depends on SYSFS |
628 | default n | 631 | default n |
629 | select SYSFS_DEPRECATED | 632 | select SYSFS_DEPRECATED |
@@ -771,6 +774,7 @@ config UID16 | |||
771 | 774 | ||
772 | config SYSCTL_SYSCALL | 775 | config SYSCTL_SYSCALL |
773 | bool "Sysctl syscall support" if EMBEDDED | 776 | bool "Sysctl syscall support" if EMBEDDED |
777 | depends on PROC_SYSCTL | ||
774 | default y | 778 | default y |
775 | select SYSCTL | 779 | select SYSCTL |
776 | ---help--- | 780 | ---help--- |
@@ -933,31 +937,41 @@ config AIO | |||
933 | by some high performance threaded applications. Disabling | 937 | by some high performance threaded applications. Disabling |
934 | this option saves about 7k. | 938 | this option saves about 7k. |
935 | 939 | ||
936 | config HAVE_PERF_COUNTERS | 940 | config HAVE_PERF_EVENTS |
937 | bool | 941 | bool |
938 | help | 942 | help |
939 | See tools/perf/design.txt for details. | 943 | See tools/perf/design.txt for details. |
940 | 944 | ||
941 | menu "Performance Counters" | 945 | config PERF_USE_VMALLOC |
946 | bool | ||
947 | help | ||
948 | See tools/perf/design.txt for details | ||
942 | 949 | ||
943 | config PERF_COUNTERS | 950 | menu "Kernel Performance Events And Counters" |
944 | bool "Kernel Performance Counters" | 951 | |
945 | default y if PROFILING | 952 | config PERF_EVENTS |
946 | depends on HAVE_PERF_COUNTERS | 953 | bool "Kernel performance events and counters" |
954 | default y if (PROFILING || PERF_COUNTERS) | ||
955 | depends on HAVE_PERF_EVENTS | ||
947 | select ANON_INODES | 956 | select ANON_INODES |
948 | help | 957 | help |
949 | Enable kernel support for performance counter hardware. | 958 | Enable kernel support for various performance events provided |
959 | by software and hardware. | ||
960 | |||
961 | Software events are supported either built-in or via the | ||
962 | use of generic tracepoints. | ||
950 | 963 | ||
951 | Performance counters are special hardware registers available | 964 | Most modern CPUs support performance events via performance |
952 | on most modern CPUs. These registers count the number of certain | 965 | counter registers. These registers count the number of certain |
953 | types of hw events: such as instructions executed, cachemisses | 966 | types of hw events: such as instructions executed, cachemisses |
954 | suffered, or branches mis-predicted - without slowing down the | 967 | suffered, or branches mis-predicted - without slowing down the |
955 | kernel or applications. These registers can also trigger interrupts | 968 | kernel or applications. These registers can also trigger interrupts |
956 | when a threshold number of events have passed - and can thus be | 969 | when a threshold number of events have passed - and can thus be |
957 | used to profile the code that runs on that CPU. | 970 | used to profile the code that runs on that CPU. |
958 | 971 | ||
959 | The Linux Performance Counter subsystem provides an abstraction of | 972 | The Linux Performance Event subsystem provides an abstraction of |
960 | these hardware capabilities, available via a system call. It | 973 | these software and hardware event capabilities, available via a |
974 | system call and used by the "perf" utility in tools/perf/. It | ||
961 | provides per task and per CPU counters, and it provides event | 975 | provides per task and per CPU counters, and it provides event |
962 | capabilities on top of those. | 976 | capabilities on top of those. |
963 | 977 | ||
@@ -965,17 +979,42 @@ config PERF_COUNTERS | |||
965 | 979 | ||
966 | config EVENT_PROFILE | 980 | config EVENT_PROFILE |
967 | bool "Tracepoint profiling sources" | 981 | bool "Tracepoint profiling sources" |
968 | depends on PERF_COUNTERS && EVENT_TRACING | 982 | depends on PERF_EVENTS && EVENT_TRACING |
969 | default y | 983 | default y |
970 | help | 984 | help |
971 | Allow the use of tracepoints as software performance counters. | 985 | Allow the use of tracepoints as software performance events. |
972 | 986 | ||
973 | When this is enabled, you can create perf counters based on | 987 | When this is enabled, you can create perf events based on |
974 | tracepoints using PERF_TYPE_TRACEPOINT and the tracepoint ID | 988 | tracepoints using PERF_TYPE_TRACEPOINT and the tracepoint ID |
975 | found in debugfs://tracing/events/*/*/id. (The -e/--events | 989 | found in debugfs://tracing/events/*/*/id. (The -e/--events |
976 | option to the perf tool can parse and interpret symbolic | 990 | option to the perf tool can parse and interpret symbolic |
977 | tracepoints, in the subsystem:tracepoint_name format.) | 991 | tracepoints, in the subsystem:tracepoint_name format.) |
978 | 992 | ||
993 | config PERF_COUNTERS | ||
994 | bool "Kernel performance counters (old config option)" | ||
995 | depends on HAVE_PERF_EVENTS | ||
996 | help | ||
997 | This config has been obsoleted by the PERF_EVENTS | ||
998 | config option - please see that one for details. | ||
999 | |||
1000 | It has no effect on the kernel whether you enable | ||
1001 | it or not, it is a compatibility placeholder. | ||
1002 | |||
1003 | Say N if unsure. | ||
1004 | |||
1005 | config DEBUG_PERF_USE_VMALLOC | ||
1006 | default n | ||
1007 | bool "Debug: use vmalloc to back perf mmap() buffers" | ||
1008 | depends on PERF_EVENTS && DEBUG_KERNEL | ||
1009 | select PERF_USE_VMALLOC | ||
1010 | help | ||
1011 | Use vmalloc memory to back perf mmap() buffers. | ||
1012 | |||
1013 | Mostly useful for debugging the vmalloc code on platforms | ||
1014 | that don't require it. | ||
1015 | |||
1016 | Say N if unsure. | ||
1017 | |||
979 | endmenu | 1018 | endmenu |
980 | 1019 | ||
981 | config VM_EVENT_COUNTERS | 1020 | config VM_EVENT_COUNTERS |
@@ -1006,14 +1045,6 @@ config SLUB_DEBUG | |||
1006 | SLUB sysfs support. /sys/slab will not exist and there will be | 1045 | SLUB sysfs support. /sys/slab will not exist and there will be |
1007 | no support for cache validation etc. | 1046 | no support for cache validation etc. |
1008 | 1047 | ||
1009 | config STRIP_ASM_SYMS | ||
1010 | bool "Strip assembler-generated symbols during link" | ||
1011 | default n | ||
1012 | help | ||
1013 | Strip internal assembler-generated symbols during a link (symbols | ||
1014 | that look like '.Lxxx') so they don't pollute the output of | ||
1015 | get_wchan() and suchlike. | ||
1016 | |||
1017 | config COMPAT_BRK | 1048 | config COMPAT_BRK |
1018 | bool "Disable heap randomization" | 1049 | bool "Disable heap randomization" |
1019 | default y | 1050 | default y |
@@ -1060,6 +1091,28 @@ config SLOB | |||
1060 | 1091 | ||
1061 | endchoice | 1092 | endchoice |
1062 | 1093 | ||
1094 | config MMAP_ALLOW_UNINITIALIZED | ||
1095 | bool "Allow mmapped anonymous memory to be uninitialized" | ||
1096 | depends on EMBEDDED && !MMU | ||
1097 | default n | ||
1098 | help | ||
1099 | Normally, and according to the Linux spec, anonymous memory obtained | ||
1100 | from mmap() has it's contents cleared before it is passed to | ||
1101 | userspace. Enabling this config option allows you to request that | ||
1102 | mmap() skip that if it is given an MAP_UNINITIALIZED flag, thus | ||
1103 | providing a huge performance boost. If this option is not enabled, | ||
1104 | then the flag will be ignored. | ||
1105 | |||
1106 | This is taken advantage of by uClibc's malloc(), and also by | ||
1107 | ELF-FDPIC binfmt's brk and stack allocator. | ||
1108 | |||
1109 | Because of the obvious security issues, this option should only be | ||
1110 | enabled on embedded devices where you control what is run in | ||
1111 | userspace. Since that isn't generally a problem on no-MMU systems, | ||
1112 | it is normally safe to say Y here. | ||
1113 | |||
1114 | See Documentation/nommu-mmap.txt for more information. | ||
1115 | |||
1063 | config PROFILING | 1116 | config PROFILING |
1064 | bool "Profiling support (EXPERIMENTAL)" | 1117 | bool "Profiling support (EXPERIMENTAL)" |
1065 | help | 1118 | help |
@@ -1073,14 +1126,6 @@ config PROFILING | |||
1073 | config TRACEPOINTS | 1126 | config TRACEPOINTS |
1074 | bool | 1127 | bool |
1075 | 1128 | ||
1076 | config MARKERS | ||
1077 | bool "Activate markers" | ||
1078 | depends on !PREEMPT_RT | ||
1079 | select TRACEPOINTS | ||
1080 | help | ||
1081 | Place an empty function call at each marker site. Can be | ||
1082 | dynamically changed for a probe function. | ||
1083 | |||
1084 | source "arch/Kconfig" | 1129 | source "arch/Kconfig" |
1085 | 1130 | ||
1086 | config SLOW_WORK | 1131 | config SLOW_WORK |
@@ -1097,6 +1142,16 @@ config SLOW_WORK | |||
1097 | 1142 | ||
1098 | See Documentation/slow-work.txt. | 1143 | See Documentation/slow-work.txt. |
1099 | 1144 | ||
1145 | config SLOW_WORK_DEBUG | ||
1146 | bool "Slow work debugging through debugfs" | ||
1147 | default n | ||
1148 | depends on SLOW_WORK && DEBUG_FS | ||
1149 | help | ||
1150 | Display the contents of the slow work run queue through debugfs, | ||
1151 | including items currently executing. | ||
1152 | |||
1153 | See Documentation/slow-work.txt. | ||
1154 | |||
1100 | endmenu # General setup | 1155 | endmenu # General setup |
1101 | 1156 | ||
1102 | config HAVE_GENERIC_DMA_COHERENT | 1157 | config HAVE_GENERIC_DMA_COHERENT |
@@ -1209,3 +1264,4 @@ source "block/Kconfig" | |||
1209 | config PREEMPT_NOTIFIERS | 1264 | config PREEMPT_NOTIFIERS |
1210 | bool | 1265 | bool |
1211 | 1266 | ||
1267 | source "kernel/Kconfig.locks" | ||
diff --git a/init/Makefile b/init/Makefile index 3f6e894183d0..dc276e46e964 100644 --- a/init/Makefile +++ b/init/Makefile | |||
@@ -15,12 +15,8 @@ mounts-$(CONFIG_BLK_DEV_RAM) += do_mounts_rd.o | |||
15 | mounts-$(CONFIG_BLK_DEV_INITRD) += do_mounts_initrd.o | 15 | mounts-$(CONFIG_BLK_DEV_INITRD) += do_mounts_initrd.o |
16 | mounts-$(CONFIG_BLK_DEV_MD) += do_mounts_md.o | 16 | mounts-$(CONFIG_BLK_DEV_MD) += do_mounts_md.o |
17 | 17 | ||
18 | # files to be removed upon make clean | ||
19 | clean-files := ../include/linux/compile.h | ||
20 | |||
21 | # dependencies on generated files need to be listed explicitly | 18 | # dependencies on generated files need to be listed explicitly |
22 | 19 | $(obj)/version.o: include/generated/compile.h | |
23 | $(obj)/version.o: include/linux/compile.h | ||
24 | 20 | ||
25 | # compile.h changes depending on hostname, generation number, etc, | 21 | # compile.h changes depending on hostname, generation number, etc, |
26 | # so we regenerate it always. | 22 | # so we regenerate it always. |
@@ -30,7 +26,7 @@ $(obj)/version.o: include/linux/compile.h | |||
30 | chk_compile.h = : | 26 | chk_compile.h = : |
31 | quiet_chk_compile.h = echo ' CHK $@' | 27 | quiet_chk_compile.h = echo ' CHK $@' |
32 | silent_chk_compile.h = : | 28 | silent_chk_compile.h = : |
33 | include/linux/compile.h: FORCE | 29 | include/generated/compile.h: FORCE |
34 | @$($(quiet)chk_compile.h) | 30 | @$($(quiet)chk_compile.h) |
35 | $(Q)$(CONFIG_SHELL) $(srctree)/scripts/mkcompile_h $@ \ | 31 | $(Q)$(CONFIG_SHELL) $(srctree)/scripts/mkcompile_h $@ \ |
36 | "$(UTS_MACHINE)" "$(CONFIG_SMP)" "$(CONFIG_PREEMPT)" "$(CONFIG_PREEMPT_RT)" \ | 32 | "$(UTS_MACHINE)" "$(CONFIG_SMP)" "$(CONFIG_PREEMPT)" "$(CONFIG_PREEMPT_RT)" \ |
diff --git a/init/calibrate.c b/init/calibrate.c index a379c9061199..6eb48e53d61c 100644 --- a/init/calibrate.c +++ b/init/calibrate.c | |||
@@ -123,23 +123,26 @@ void __cpuinit calibrate_delay(void) | |||
123 | { | 123 | { |
124 | unsigned long ticks, loopbit; | 124 | unsigned long ticks, loopbit; |
125 | int lps_precision = LPS_PREC; | 125 | int lps_precision = LPS_PREC; |
126 | static bool printed; | ||
126 | 127 | ||
127 | if (preset_lpj) { | 128 | if (preset_lpj) { |
128 | loops_per_jiffy = preset_lpj; | 129 | loops_per_jiffy = preset_lpj; |
129 | printk(KERN_INFO | 130 | if (!printed) |
130 | "Calibrating delay loop (skipped) preset value.. "); | 131 | pr_info("Calibrating delay loop (skipped) " |
131 | } else if ((smp_processor_id() == 0) && lpj_fine) { | 132 | "preset value.. "); |
133 | } else if ((!printed) && lpj_fine) { | ||
132 | loops_per_jiffy = lpj_fine; | 134 | loops_per_jiffy = lpj_fine; |
133 | printk(KERN_INFO | 135 | pr_info("Calibrating delay loop (skipped), " |
134 | "Calibrating delay loop (skipped), " | ||
135 | "value calculated using timer frequency.. "); | 136 | "value calculated using timer frequency.. "); |
136 | } else if ((loops_per_jiffy = calibrate_delay_direct()) != 0) { | 137 | } else if ((loops_per_jiffy = calibrate_delay_direct()) != 0) { |
137 | printk(KERN_INFO | 138 | if (!printed) |
138 | "Calibrating delay using timer specific routine.. "); | 139 | pr_info("Calibrating delay using timer " |
140 | "specific routine.. "); | ||
139 | } else { | 141 | } else { |
140 | loops_per_jiffy = (1<<12); | 142 | loops_per_jiffy = (1<<12); |
141 | 143 | ||
142 | printk(KERN_INFO "Calibrating delay loop... "); | 144 | if (!printed) |
145 | pr_info("Calibrating delay loop... "); | ||
143 | while ((loops_per_jiffy <<= 1) != 0) { | 146 | while ((loops_per_jiffy <<= 1) != 0) { |
144 | /* wait for "start of" clock tick */ | 147 | /* wait for "start of" clock tick */ |
145 | ticks = jiffies; | 148 | ticks = jiffies; |
@@ -170,7 +173,10 @@ void __cpuinit calibrate_delay(void) | |||
170 | loops_per_jiffy &= ~loopbit; | 173 | loops_per_jiffy &= ~loopbit; |
171 | } | 174 | } |
172 | } | 175 | } |
173 | printk(KERN_CONT "%lu.%02lu BogoMIPS (lpj=%lu)\n", | 176 | if (!printed) |
177 | pr_cont("%lu.%02lu BogoMIPS (lpj=%lu)\n", | ||
174 | loops_per_jiffy/(500000/HZ), | 178 | loops_per_jiffy/(500000/HZ), |
175 | (loops_per_jiffy/(5000/HZ)) % 100, loops_per_jiffy); | 179 | (loops_per_jiffy/(5000/HZ)) % 100, loops_per_jiffy); |
180 | |||
181 | printed = true; | ||
176 | } | 182 | } |
diff --git a/init/do_mounts.c b/init/do_mounts.c index 093f65915501..bb008d064c1a 100644 --- a/init/do_mounts.c +++ b/init/do_mounts.c | |||
@@ -415,7 +415,7 @@ void __init prepare_namespace(void) | |||
415 | 415 | ||
416 | mount_root(); | 416 | mount_root(); |
417 | out: | 417 | out: |
418 | devtmpfs_mount("dev"); | ||
418 | sys_mount(".", "/", NULL, MS_MOVE, NULL); | 419 | sys_mount(".", "/", NULL, MS_MOVE, NULL); |
419 | sys_chroot("."); | 420 | sys_chroot("."); |
420 | } | 421 | } |
421 | |||
diff --git a/init/initramfs.c b/init/initramfs.c index 4c00edc59689..b37d34beb90b 100644 --- a/init/initramfs.c +++ b/init/initramfs.c | |||
@@ -413,7 +413,7 @@ static unsigned my_inptr; /* index of next byte to be processed in inbuf */ | |||
413 | 413 | ||
414 | static char * __init unpack_to_rootfs(char *buf, unsigned len) | 414 | static char * __init unpack_to_rootfs(char *buf, unsigned len) |
415 | { | 415 | { |
416 | int written; | 416 | int written, res; |
417 | decompress_fn decompress; | 417 | decompress_fn decompress; |
418 | const char *compress_name; | 418 | const char *compress_name; |
419 | static __initdata char msg_buf[64]; | 419 | static __initdata char msg_buf[64]; |
@@ -445,10 +445,12 @@ static char * __init unpack_to_rootfs(char *buf, unsigned len) | |||
445 | } | 445 | } |
446 | this_header = 0; | 446 | this_header = 0; |
447 | decompress = decompress_method(buf, len, &compress_name); | 447 | decompress = decompress_method(buf, len, &compress_name); |
448 | if (decompress) | 448 | if (decompress) { |
449 | decompress(buf, len, NULL, flush_buffer, NULL, | 449 | res = decompress(buf, len, NULL, flush_buffer, NULL, |
450 | &my_inptr, error); | 450 | &my_inptr, error); |
451 | else if (compress_name) { | 451 | if (res) |
452 | error("decompressor failed"); | ||
453 | } else if (compress_name) { | ||
452 | if (!message) { | 454 | if (!message) { |
453 | snprintf(msg_buf, sizeof msg_buf, | 455 | snprintf(msg_buf, sizeof msg_buf, |
454 | "compression method %s not configured", | 456 | "compression method %s not configured", |
diff --git a/init/main.c b/init/main.c index ff438b198fe3..aa48b7bec262 100644 --- a/init/main.c +++ b/init/main.c | |||
@@ -18,7 +18,6 @@ | |||
18 | #include <linux/string.h> | 18 | #include <linux/string.h> |
19 | #include <linux/ctype.h> | 19 | #include <linux/ctype.h> |
20 | #include <linux/delay.h> | 20 | #include <linux/delay.h> |
21 | #include <linux/utsname.h> | ||
22 | #include <linux/ioport.h> | 21 | #include <linux/ioport.h> |
23 | #include <linux/init.h> | 22 | #include <linux/init.h> |
24 | #include <linux/smp_lock.h> | 23 | #include <linux/smp_lock.h> |
@@ -69,6 +68,8 @@ | |||
69 | #include <linux/async.h> | 68 | #include <linux/async.h> |
70 | #include <linux/kmemcheck.h> | 69 | #include <linux/kmemcheck.h> |
71 | #include <linux/kmemtrace.h> | 70 | #include <linux/kmemtrace.h> |
71 | #include <linux/sfi.h> | ||
72 | #include <linux/shmem_fs.h> | ||
72 | #include <trace/boot.h> | 73 | #include <trace/boot.h> |
73 | 74 | ||
74 | #include <asm/io.h> | 75 | #include <asm/io.h> |
@@ -251,7 +252,7 @@ early_param("loglevel", loglevel); | |||
251 | 252 | ||
252 | /* | 253 | /* |
253 | * Unknown boot options get handed to init, unless they look like | 254 | * Unknown boot options get handed to init, unless they look like |
254 | * failed parameters | 255 | * unused parameters (modprobe will find them in /proc/cmdline). |
255 | */ | 256 | */ |
256 | static int __init unknown_bootoption(char *param, char *val) | 257 | static int __init unknown_bootoption(char *param, char *val) |
257 | { | 258 | { |
@@ -272,14 +273,9 @@ static int __init unknown_bootoption(char *param, char *val) | |||
272 | if (obsolete_checksetup(param)) | 273 | if (obsolete_checksetup(param)) |
273 | return 0; | 274 | return 0; |
274 | 275 | ||
275 | /* | 276 | /* Unused module parameter. */ |
276 | * Preemptive maintenance for "why didn't my misspelled command | 277 | if (strchr(param, '.') && (!val || strchr(param, '.') < val)) |
277 | * line work?" | ||
278 | */ | ||
279 | if (strchr(param, '.') && (!val || strchr(param, '.') < val)) { | ||
280 | printk(KERN_ERR "Unknown boot option `%s': ignoring\n", param); | ||
281 | return 0; | 278 | return 0; |
282 | } | ||
283 | 279 | ||
284 | if (panic_later) | 280 | if (panic_later) |
285 | return 0; | 281 | return 0; |
@@ -354,17 +350,11 @@ static void __init smp_init(void) | |||
354 | #define smp_init() do { } while (0) | 350 | #define smp_init() do { } while (0) |
355 | #endif | 351 | #endif |
356 | 352 | ||
357 | static inline void setup_per_cpu_areas(void) { } | ||
358 | static inline void setup_nr_cpu_ids(void) { } | 353 | static inline void setup_nr_cpu_ids(void) { } |
359 | static inline void smp_prepare_cpus(unsigned int maxcpus) { } | 354 | static inline void smp_prepare_cpus(unsigned int maxcpus) { } |
360 | 355 | ||
361 | #else | 356 | #else |
362 | 357 | ||
363 | #if NR_CPUS > BITS_PER_LONG | ||
364 | cpumask_t cpu_mask_all __read_mostly = CPU_MASK_ALL; | ||
365 | EXPORT_SYMBOL(cpu_mask_all); | ||
366 | #endif | ||
367 | |||
368 | /* Setup number of possible processor ids */ | 358 | /* Setup number of possible processor ids */ |
369 | int nr_cpu_ids __read_mostly = NR_CPUS; | 359 | int nr_cpu_ids __read_mostly = NR_CPUS; |
370 | EXPORT_SYMBOL(nr_cpu_ids); | 360 | EXPORT_SYMBOL(nr_cpu_ids); |
@@ -375,40 +365,11 @@ static void __init setup_nr_cpu_ids(void) | |||
375 | nr_cpu_ids = find_last_bit(cpumask_bits(cpu_possible_mask),NR_CPUS) + 1; | 365 | nr_cpu_ids = find_last_bit(cpumask_bits(cpu_possible_mask),NR_CPUS) + 1; |
376 | } | 366 | } |
377 | 367 | ||
378 | #ifndef CONFIG_HAVE_SETUP_PER_CPU_AREA | ||
379 | unsigned long __per_cpu_offset[NR_CPUS] __read_mostly; | ||
380 | |||
381 | EXPORT_SYMBOL(__per_cpu_offset); | ||
382 | |||
383 | static void __init setup_per_cpu_areas(void) | ||
384 | { | ||
385 | unsigned long size, i; | ||
386 | char *ptr; | ||
387 | unsigned long nr_possible_cpus = num_possible_cpus(); | ||
388 | |||
389 | /* Copy section for each CPU (we discard the original) */ | ||
390 | size = ALIGN(PERCPU_ENOUGH_ROOM, PAGE_SIZE); | ||
391 | ptr = alloc_bootmem_pages(size * nr_possible_cpus); | ||
392 | |||
393 | for_each_possible_cpu(i) { | ||
394 | __per_cpu_offset[i] = ptr - __per_cpu_start; | ||
395 | memcpy(ptr, __per_cpu_start, __per_cpu_end - __per_cpu_start); | ||
396 | ptr += size; | ||
397 | } | ||
398 | } | ||
399 | #endif /* CONFIG_HAVE_SETUP_PER_CPU_AREA */ | ||
400 | |||
401 | /* Called by boot processor to activate the rest. */ | 368 | /* Called by boot processor to activate the rest. */ |
402 | static void __init smp_init(void) | 369 | static void __init smp_init(void) |
403 | { | 370 | { |
404 | unsigned int cpu; | 371 | unsigned int cpu; |
405 | 372 | ||
406 | /* | ||
407 | * Set up the current CPU as possible to migrate to. | ||
408 | * The other ones will be done by cpu_up/cpu_down() | ||
409 | */ | ||
410 | set_cpu_active(smp_processor_id(), true); | ||
411 | |||
412 | /* FIXME: This should be done in userspace --RR */ | 373 | /* FIXME: This should be done in userspace --RR */ |
413 | for_each_present_cpu(cpu) { | 374 | for_each_present_cpu(cpu) { |
414 | if (num_online_cpus() >= setup_max_cpus) | 375 | if (num_online_cpus() >= setup_max_cpus) |
@@ -454,6 +415,7 @@ static noinline void __init_refok rest_init(void) | |||
454 | 415 | ||
455 | system_state = SYSTEM_BOOTING_SCHEDULER_OK; | 416 | system_state = SYSTEM_BOOTING_SCHEDULER_OK; |
456 | 417 | ||
418 | rcu_scheduler_starting(); | ||
457 | kernel_thread(kernel_init, NULL, CLONE_FS | CLONE_SIGHAND); | 419 | kernel_thread(kernel_init, NULL, CLONE_FS | CLONE_SIGHAND); |
458 | numa_default_policy(); | 420 | numa_default_policy(); |
459 | pid = kernel_thread(kthreadd, NULL, CLONE_FS | CLONE_FILES); | 421 | pid = kernel_thread(kthreadd, NULL, CLONE_FS | CLONE_FILES); |
@@ -465,7 +427,6 @@ static noinline void __init_refok rest_init(void) | |||
465 | * at least once to get things moving: | 427 | * at least once to get things moving: |
466 | */ | 428 | */ |
467 | init_idle_bootup_task(current); | 429 | init_idle_bootup_task(current); |
468 | rcu_scheduler_starting(); | ||
469 | preempt_enable_and_schedule(); | 430 | preempt_enable_and_schedule(); |
470 | preempt_disable(); | 431 | preempt_disable(); |
471 | 432 | ||
@@ -521,6 +482,7 @@ static void __init boot_cpu_init(void) | |||
521 | int cpu = smp_processor_id(); | 482 | int cpu = smp_processor_id(); |
522 | /* Mark the boot cpu "present", "online" etc for SMP and UP case */ | 483 | /* Mark the boot cpu "present", "online" etc for SMP and UP case */ |
523 | set_cpu_online(cpu, true); | 484 | set_cpu_online(cpu, true); |
485 | set_cpu_active(cpu, true); | ||
524 | set_cpu_present(cpu, true); | 486 | set_cpu_present(cpu, true); |
525 | set_cpu_possible(cpu, true); | 487 | set_cpu_possible(cpu, true); |
526 | } | 488 | } |
@@ -633,7 +595,6 @@ asmlinkage void __init start_kernel(void) | |||
633 | softirq_init(); | 595 | softirq_init(); |
634 | timekeeping_init(); | 596 | timekeeping_init(); |
635 | time_init(); | 597 | time_init(); |
636 | sched_clock_init(); | ||
637 | profile_init(); | 598 | profile_init(); |
638 | if (!irqs_disabled()) | 599 | if (!irqs_disabled()) |
639 | printk(KERN_CRIT "start_kernel(): bug: interrupts were " | 600 | printk(KERN_CRIT "start_kernel(): bug: interrupts were " |
@@ -662,7 +623,16 @@ asmlinkage void __init start_kernel(void) | |||
662 | * to self-test [hard/soft]-irqs on/off lock inversion bugs | 623 | * to self-test [hard/soft]-irqs on/off lock inversion bugs |
663 | * too: | 624 | * too: |
664 | */ | 625 | */ |
665 | locking_selftest(); | 626 | if (1) { |
627 | /* | ||
628 | * Hack around the fact that locking_selftest() destroys | ||
629 | * the lockdep state, so release the one known lock and | ||
630 | * acquire it again after the self-test is done. | ||
631 | */ | ||
632 | mutex_release(&kernel_sem.dep_map, 1, _THIS_IP_); | ||
633 | locking_selftest(); | ||
634 | mutex_acquire(&kernel_sem.dep_map, 0, 0, _THIS_IP_); | ||
635 | } | ||
666 | 636 | ||
667 | #ifdef CONFIG_BLK_DEV_INITRD | 637 | #ifdef CONFIG_BLK_DEV_INITRD |
668 | if (initrd_start && !initrd_below_start_ok && | 638 | if (initrd_start && !initrd_below_start_ok && |
@@ -684,6 +654,7 @@ asmlinkage void __init start_kernel(void) | |||
684 | numa_policy_init(); | 654 | numa_policy_init(); |
685 | if (late_time_init) | 655 | if (late_time_init) |
686 | late_time_init(); | 656 | late_time_init(); |
657 | sched_clock_init(); | ||
687 | calibrate_delay(); | 658 | calibrate_delay(); |
688 | pidmap_init(); | 659 | pidmap_init(); |
689 | anon_vma_init(); | 660 | anon_vma_init(); |
@@ -693,13 +664,13 @@ asmlinkage void __init start_kernel(void) | |||
693 | #endif | 664 | #endif |
694 | thread_info_cache_init(); | 665 | thread_info_cache_init(); |
695 | cred_init(); | 666 | cred_init(); |
696 | fork_init(num_physpages); | 667 | fork_init(totalram_pages); |
697 | proc_caches_init(); | 668 | proc_caches_init(); |
698 | buffer_init(); | 669 | buffer_init(); |
699 | key_init(); | 670 | key_init(); |
700 | security_init(); | ||
701 | vfs_caches_init(num_physpages); | ||
702 | radix_tree_init(); | 671 | radix_tree_init(); |
672 | security_init(); | ||
673 | vfs_caches_init(totalram_pages); | ||
703 | signals_init(); | 674 | signals_init(); |
704 | /* rootfs populating might need page-writeback */ | 675 | /* rootfs populating might need page-writeback */ |
705 | page_writeback_init(); | 676 | page_writeback_init(); |
@@ -714,6 +685,7 @@ asmlinkage void __init start_kernel(void) | |||
714 | check_bugs(); | 685 | check_bugs(); |
715 | 686 | ||
716 | acpi_early_init(); /* before LAPIC and SMP init */ | 687 | acpi_early_init(); /* before LAPIC and SMP init */ |
688 | sfi_init_late(); | ||
717 | 689 | ||
718 | ftrace_init(); | 690 | ftrace_init(); |
719 | 691 | ||
@@ -728,10 +700,10 @@ asmlinkage void __init start_kernel(void) | |||
728 | static void __init do_ctors(void) | 700 | static void __init do_ctors(void) |
729 | { | 701 | { |
730 | #ifdef CONFIG_CONSTRUCTORS | 702 | #ifdef CONFIG_CONSTRUCTORS |
731 | ctor_fn_t *call = (ctor_fn_t *) __ctors_start; | 703 | ctor_fn_t *fn = (ctor_fn_t *) __ctors_start; |
732 | 704 | ||
733 | for (; call < (ctor_fn_t *) __ctors_end; call++) | 705 | for (; fn < (ctor_fn_t *) __ctors_end; fn++) |
734 | (*call)(); | 706 | (*fn)(); |
735 | #endif | 707 | #endif |
736 | } | 708 | } |
737 | 709 | ||
@@ -792,10 +764,10 @@ extern initcall_t __initcall_start[], __initcall_end[], __early_initcall_end[]; | |||
792 | 764 | ||
793 | static void __init do_initcalls(void) | 765 | static void __init do_initcalls(void) |
794 | { | 766 | { |
795 | initcall_t *call; | 767 | initcall_t *fn; |
796 | 768 | ||
797 | for (call = __early_initcall_end; call < __initcall_end; call++) | 769 | for (fn = __early_initcall_end; fn < __initcall_end; fn++) |
798 | do_one_initcall(*call); | 770 | do_one_initcall(*fn); |
799 | 771 | ||
800 | /* Make sure there is no pending stuff from the initcall sequence */ | 772 | /* Make sure there is no pending stuff from the initcall sequence */ |
801 | flush_scheduled_work(); | 773 | flush_scheduled_work(); |
@@ -810,10 +782,10 @@ static void __init do_initcalls(void) | |||
810 | */ | 782 | */ |
811 | static void __init do_basic_setup(void) | 783 | static void __init do_basic_setup(void) |
812 | { | 784 | { |
813 | rcu_init_sched(); /* needed by module_init stage. */ | ||
814 | init_workqueues(); | 785 | init_workqueues(); |
815 | cpuset_init_smp(); | 786 | cpuset_init_smp(); |
816 | usermodehelper_init(); | 787 | usermodehelper_init(); |
788 | init_tmpfs(); | ||
817 | driver_init(); | 789 | driver_init(); |
818 | init_irq_proc(); | 790 | init_irq_proc(); |
819 | do_ctors(); | 791 | do_ctors(); |
@@ -822,11 +794,11 @@ static void __init do_basic_setup(void) | |||
822 | 794 | ||
823 | static void __init do_pre_smp_initcalls(void) | 795 | static void __init do_pre_smp_initcalls(void) |
824 | { | 796 | { |
825 | initcall_t *call; | 797 | initcall_t *fn; |
826 | extern int spawn_desched_task(void); | 798 | extern int spawn_desched_task(void); |
827 | 799 | ||
828 | for (call = __initcall_start; call < __early_initcall_end; call++) | 800 | for (fn = __initcall_start; fn < __early_initcall_end; fn++) |
829 | do_one_initcall(*call); | 801 | do_one_initcall(*fn); |
830 | spawn_desched_task(); | 802 | spawn_desched_task(); |
831 | } | 803 | } |
832 | 804 | ||
@@ -936,15 +908,7 @@ static int __init kernel_init(void * unused) | |||
936 | WARN_ON(irqs_disabled()); | 908 | WARN_ON(irqs_disabled()); |
937 | #endif | 909 | #endif |
938 | 910 | ||
939 | #define DEBUG_COUNT (defined(CONFIG_DEBUG_RT_MUTEXES) + \ | 911 | #define DEBUG_COUNT (defined(CONFIG_DEBUG_RT_MUTEXES) + defined(CONFIG_IRQSOFF_TRACER) + defined(CONFIG_PREEMPT_TRACER) + defined(CONFIG_STACK_TRACER) + defined(CONFIG_INTERRUPT_OFF_HIST) + defined(CONFIG_PREEMPT_OFF_HIST) + defined(CONFIG_WAKEUP_LATENCY_HIST) + defined(CONFIG_DEBUG_SLAB) + defined(CONFIG_DEBUG_PAGEALLOC) + defined(CONFIG_LOCKDEP) + (defined(CONFIG_FTRACE) - defined(CONFIG_FTRACE_MCOUNT_RECORD))) |
940 | defined(CONFIG_IRQSOFF_TRACER) + defined(CONFIG_PREEMPT_TRACER) + \ | ||
941 | defined(CONFIG_STACK_TRACER) + defined(CONFIG_INTERRUPT_OFF_HIST) + \ | ||
942 | defined(CONFIG_PREEMPT_OFF_HIST) + \ | ||
943 | defined(CONFIG_WAKEUP_LATENCY_HIST) + \ | ||
944 | defined(CONFIG_MISSED_TIMER_OFFSETS_HIST) + \ | ||
945 | defined(CONFIG_DEBUG_SLAB) + defined(CONFIG_DEBUG_PAGEALLOC) + \ | ||
946 | defined(CONFIG_LOCKDEP) + \ | ||
947 | (defined(CONFIG_FTRACE) - defined(CONFIG_FTRACE_MCOUNT_RECORD))) | ||
948 | 912 | ||
949 | #if DEBUG_COUNT > 0 | 913 | #if DEBUG_COUNT > 0 |
950 | printk(KERN_ERR "*****************************************************************************\n"); | 914 | printk(KERN_ERR "*****************************************************************************\n"); |
@@ -976,9 +940,6 @@ static int __init kernel_init(void * unused) | |||
976 | #ifdef CONFIG_WAKEUP_LATENCY_HIST | 940 | #ifdef CONFIG_WAKEUP_LATENCY_HIST |
977 | printk(KERN_ERR "* CONFIG_WAKEUP_LATENCY_HIST *\n"); | 941 | printk(KERN_ERR "* CONFIG_WAKEUP_LATENCY_HIST *\n"); |
978 | #endif | 942 | #endif |
979 | #ifdef CONFIG_MISSED_TIMER_OFFSETS_HIST | ||
980 | printk(KERN_ERR "* CONFIG_MISSED_TIMER_OFFSETS_HIST *\n"); | ||
981 | #endif | ||
982 | #ifdef CONFIG_DEBUG_SLAB | 943 | #ifdef CONFIG_DEBUG_SLAB |
983 | printk(KERN_ERR "* CONFIG_DEBUG_SLAB *\n"); | 944 | printk(KERN_ERR "* CONFIG_DEBUG_SLAB *\n"); |
984 | #endif | 945 | #endif |
diff --git a/init/version.c b/init/version.c index 52a8b98642b8..adff586401a5 100644 --- a/init/version.c +++ b/init/version.c | |||
@@ -6,11 +6,11 @@ | |||
6 | * May be freely distributed as part of Linux. | 6 | * May be freely distributed as part of Linux. |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/compile.h> | 9 | #include <generated/compile.h> |
10 | #include <linux/module.h> | 10 | #include <linux/module.h> |
11 | #include <linux/uts.h> | 11 | #include <linux/uts.h> |
12 | #include <linux/utsname.h> | 12 | #include <linux/utsname.h> |
13 | #include <linux/utsrelease.h> | 13 | #include <generated/utsrelease.h> |
14 | #include <linux/version.h> | 14 | #include <linux/version.h> |
15 | 15 | ||
16 | #ifndef CONFIG_KALLSYMS | 16 | #ifndef CONFIG_KALLSYMS |