diff options
-rw-r--r-- | arch/x86/Kconfig | 12 | ||||
-rw-r--r-- | arch/x86/Makefile | 7 | ||||
-rw-r--r-- | arch/x86/boot/Makefile | 7 | ||||
-rw-r--r-- | arch/x86/boot/compressed/Makefile | 19 | ||||
-rw-r--r-- | arch/x86/boot/compressed/aslr.c | 3 | ||||
-rw-r--r-- | arch/x86/boot/compressed/early_serial_console.c | 4 | ||||
-rw-r--r-- | arch/x86/boot/cpu.c | 68 | ||||
-rw-r--r-- | arch/x86/configs/tiny.config | 1 | ||||
-rw-r--r-- | arch/x86/include/asm/cpufeature.h | 7 | ||||
-rw-r--r-- | arch/x86/kernel/cpu/Makefile | 7 | ||||
-rw-r--r-- | arch/x86/kernel/cpu/common.c | 4 | ||||
-rw-r--r-- | init/Kconfig | 10 | ||||
-rw-r--r-- | kernel/configs/tiny.config | 4 | ||||
-rw-r--r-- | kernel/sys_ni.c | 3 | ||||
-rw-r--r-- | mm/Makefile | 7 | ||||
-rw-r--r-- | scripts/kconfig/Makefile | 19 |
16 files changed, 125 insertions, 57 deletions
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index 5d0bf1aa9dcb..a11f27c4266a 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig | |||
@@ -136,6 +136,7 @@ config X86 | |||
136 | select HAVE_ACPI_APEI if ACPI | 136 | select HAVE_ACPI_APEI if ACPI |
137 | select HAVE_ACPI_APEI_NMI if ACPI | 137 | select HAVE_ACPI_APEI_NMI if ACPI |
138 | select ACPI_LEGACY_TABLES_LOOKUP if ACPI | 138 | select ACPI_LEGACY_TABLES_LOOKUP if ACPI |
139 | select X86_FEATURE_NAMES if PROC_FS | ||
139 | 140 | ||
140 | config INSTRUCTION_DECODER | 141 | config INSTRUCTION_DECODER |
141 | def_bool y | 142 | def_bool y |
@@ -313,6 +314,17 @@ config SMP | |||
313 | 314 | ||
314 | If you don't know what to do here, say N. | 315 | If you don't know what to do here, say N. |
315 | 316 | ||
317 | config X86_FEATURE_NAMES | ||
318 | bool "Processor feature human-readable names" if EMBEDDED | ||
319 | default y | ||
320 | ---help--- | ||
321 | This option compiles in a table of x86 feature bits and corresponding | ||
322 | names. This is required to support /proc/cpuinfo and a few kernel | ||
323 | messages. You can disable this to save space, at the expense of | ||
324 | making those few kernel messages show numeric feature bits instead. | ||
325 | |||
326 | If in doubt, say Y. | ||
327 | |||
316 | config X86_X2APIC | 328 | config X86_X2APIC |
317 | bool "Support x2apic" | 329 | bool "Support x2apic" |
318 | depends on X86_LOCAL_APIC && X86_64 && IRQ_REMAP | 330 | depends on X86_LOCAL_APIC && X86_64 && IRQ_REMAP |
diff --git a/arch/x86/Makefile b/arch/x86/Makefile index c1aa36887843..7705b6f921ac 100644 --- a/arch/x86/Makefile +++ b/arch/x86/Makefile | |||
@@ -255,12 +255,6 @@ archclean: | |||
255 | $(Q)$(MAKE) $(clean)=$(boot) | 255 | $(Q)$(MAKE) $(clean)=$(boot) |
256 | $(Q)$(MAKE) $(clean)=arch/x86/tools | 256 | $(Q)$(MAKE) $(clean)=arch/x86/tools |
257 | 257 | ||
258 | PHONY += kvmconfig | ||
259 | kvmconfig: | ||
260 | $(if $(wildcard $(objtree)/.config),, $(error You need an existing .config for this target)) | ||
261 | $(Q)$(CONFIG_SHELL) $(srctree)/scripts/kconfig/merge_config.sh -m -O $(objtree) $(objtree)/.config $(srctree)/arch/x86/configs/kvm_guest.config | ||
262 | $(Q)yes "" | $(MAKE) -f $(srctree)/Makefile oldconfig | ||
263 | |||
264 | define archhelp | 258 | define archhelp |
265 | echo '* bzImage - Compressed kernel image (arch/x86/boot/bzImage)' | 259 | echo '* bzImage - Compressed kernel image (arch/x86/boot/bzImage)' |
266 | echo ' install - Install kernel using' | 260 | echo ' install - Install kernel using' |
@@ -274,5 +268,4 @@ define archhelp | |||
274 | echo ' bzdisk/fdimage*/isoimage also accept:' | 268 | echo ' bzdisk/fdimage*/isoimage also accept:' |
275 | echo ' FDARGS="..." arguments for the booted kernel' | 269 | echo ' FDARGS="..." arguments for the booted kernel' |
276 | echo ' FDINITRD=file initrd for the booted kernel' | 270 | echo ' FDINITRD=file initrd for the booted kernel' |
277 | echo ' kvmconfig - Enable additional options for guest kernel support' | ||
278 | endef | 271 | endef |
diff --git a/arch/x86/boot/Makefile b/arch/x86/boot/Makefile index dbe8dd2fe247..5b016e2498f3 100644 --- a/arch/x86/boot/Makefile +++ b/arch/x86/boot/Makefile | |||
@@ -35,19 +35,22 @@ setup-y += video-vesa.o | |||
35 | setup-y += video-bios.o | 35 | setup-y += video-bios.o |
36 | 36 | ||
37 | targets += $(setup-y) | 37 | targets += $(setup-y) |
38 | hostprogs-y := mkcpustr tools/build | 38 | hostprogs-y := tools/build |
39 | hostprogs-$(CONFIG_X86_FEATURE_NAMES) += mkcpustr | ||
39 | 40 | ||
40 | HOST_EXTRACFLAGS += -I$(srctree)/tools/include \ | 41 | HOST_EXTRACFLAGS += -I$(srctree)/tools/include \ |
41 | -include include/generated/autoconf.h \ | 42 | -include include/generated/autoconf.h \ |
42 | -D__EXPORTED_HEADERS__ | 43 | -D__EXPORTED_HEADERS__ |
43 | 44 | ||
45 | ifdef CONFIG_X86_FEATURE_NAMES | ||
44 | $(obj)/cpu.o: $(obj)/cpustr.h | 46 | $(obj)/cpu.o: $(obj)/cpustr.h |
45 | 47 | ||
46 | quiet_cmd_cpustr = CPUSTR $@ | 48 | quiet_cmd_cpustr = CPUSTR $@ |
47 | cmd_cpustr = $(obj)/mkcpustr > $@ | 49 | cmd_cpustr = $(obj)/mkcpustr > $@ |
48 | targets += cpustr.h | 50 | targets += cpustr.h |
49 | $(obj)/cpustr.h: $(obj)/mkcpustr FORCE | 51 | $(obj)/cpustr.h: $(obj)/mkcpustr FORCE |
50 | $(call if_changed,cpustr) | 52 | $(call if_changed,cpustr) |
53 | endif | ||
51 | 54 | ||
52 | # --------------------------------------------------------------------------- | 55 | # --------------------------------------------------------------------------- |
53 | 56 | ||
diff --git a/arch/x86/boot/compressed/Makefile b/arch/x86/boot/compressed/Makefile index 7a801a310e37..20db5b3609de 100644 --- a/arch/x86/boot/compressed/Makefile +++ b/arch/x86/boot/compressed/Makefile | |||
@@ -26,18 +26,19 @@ LDFLAGS_vmlinux := -T | |||
26 | hostprogs-y := mkpiggy | 26 | hostprogs-y := mkpiggy |
27 | HOST_EXTRACFLAGS += -I$(srctree)/tools/include | 27 | HOST_EXTRACFLAGS += -I$(srctree)/tools/include |
28 | 28 | ||
29 | VMLINUX_OBJS = $(obj)/vmlinux.lds $(obj)/head_$(BITS).o $(obj)/misc.o \ | 29 | vmlinux-objs-y := $(obj)/vmlinux.lds $(obj)/head_$(BITS).o $(obj)/misc.o \ |
30 | $(obj)/string.o $(obj)/cmdline.o $(obj)/early_serial_console.o \ | 30 | $(obj)/string.o $(obj)/cmdline.o \ |
31 | $(obj)/piggy.o $(obj)/cpuflags.o $(obj)/aslr.o | 31 | $(obj)/piggy.o $(obj)/cpuflags.o |
32 | |||
33 | vmlinux-objs-$(CONFIG_EARLY_PRINTK) += $(obj)/early_serial_console.o | ||
34 | vmlinux-objs-$(CONFIG_RANDOMIZE_BASE) += $(obj)/aslr.o | ||
32 | 35 | ||
33 | $(obj)/eboot.o: KBUILD_CFLAGS += -fshort-wchar -mno-red-zone | 36 | $(obj)/eboot.o: KBUILD_CFLAGS += -fshort-wchar -mno-red-zone |
34 | 37 | ||
35 | ifeq ($(CONFIG_EFI_STUB), y) | 38 | vmlinux-objs-$(CONFIG_EFI_STUB) += $(obj)/eboot.o $(obj)/efi_stub_$(BITS).o \ |
36 | VMLINUX_OBJS += $(obj)/eboot.o $(obj)/efi_stub_$(BITS).o \ | 39 | $(objtree)/drivers/firmware/efi/libstub/lib.a |
37 | $(objtree)/drivers/firmware/efi/libstub/lib.a | ||
38 | endif | ||
39 | 40 | ||
40 | $(obj)/vmlinux: $(VMLINUX_OBJS) FORCE | 41 | $(obj)/vmlinux: $(vmlinux-objs-y) FORCE |
41 | $(call if_changed,ld) | 42 | $(call if_changed,ld) |
42 | @: | 43 | @: |
43 | 44 | ||
@@ -45,7 +46,7 @@ OBJCOPYFLAGS_vmlinux.bin := -R .comment -S | |||
45 | $(obj)/vmlinux.bin: vmlinux FORCE | 46 | $(obj)/vmlinux.bin: vmlinux FORCE |
46 | $(call if_changed,objcopy) | 47 | $(call if_changed,objcopy) |
47 | 48 | ||
48 | targets += $(patsubst $(obj)/%,%,$(VMLINUX_OBJS)) vmlinux.bin.all vmlinux.relocs | 49 | targets += $(patsubst $(obj)/%,%,$(vmlinux-objs-y)) vmlinux.bin.all vmlinux.relocs |
49 | 50 | ||
50 | CMD_RELOCS = arch/x86/tools/relocs | 51 | CMD_RELOCS = arch/x86/tools/relocs |
51 | quiet_cmd_relocs = RELOCS $@ | 52 | quiet_cmd_relocs = RELOCS $@ |
diff --git a/arch/x86/boot/compressed/aslr.c b/arch/x86/boot/compressed/aslr.c index fc6091abedb7..913c999b0045 100644 --- a/arch/x86/boot/compressed/aslr.c +++ b/arch/x86/boot/compressed/aslr.c | |||
@@ -1,6 +1,5 @@ | |||
1 | #include "misc.h" | 1 | #include "misc.h" |
2 | 2 | ||
3 | #ifdef CONFIG_RANDOMIZE_BASE | ||
4 | #include <asm/msr.h> | 3 | #include <asm/msr.h> |
5 | #include <asm/archrandom.h> | 4 | #include <asm/archrandom.h> |
6 | #include <asm/e820.h> | 5 | #include <asm/e820.h> |
@@ -320,5 +319,3 @@ unsigned char *choose_kernel_location(unsigned char *input, | |||
320 | out: | 319 | out: |
321 | return (unsigned char *)choice; | 320 | return (unsigned char *)choice; |
322 | } | 321 | } |
323 | |||
324 | #endif /* CONFIG_RANDOMIZE_BASE */ | ||
diff --git a/arch/x86/boot/compressed/early_serial_console.c b/arch/x86/boot/compressed/early_serial_console.c index d3d003cb5481..261e81fb9582 100644 --- a/arch/x86/boot/compressed/early_serial_console.c +++ b/arch/x86/boot/compressed/early_serial_console.c | |||
@@ -1,9 +1,5 @@ | |||
1 | #include "misc.h" | 1 | #include "misc.h" |
2 | 2 | ||
3 | #ifdef CONFIG_EARLY_PRINTK | ||
4 | |||
5 | int early_serial_base; | 3 | int early_serial_base; |
6 | 4 | ||
7 | #include "../early_serial_console.c" | 5 | #include "../early_serial_console.c" |
8 | |||
9 | #endif | ||
diff --git a/arch/x86/boot/cpu.c b/arch/x86/boot/cpu.c index 6ec6bb6e9957..29207f69ae8c 100644 --- a/arch/x86/boot/cpu.c +++ b/arch/x86/boot/cpu.c | |||
@@ -16,7 +16,9 @@ | |||
16 | */ | 16 | */ |
17 | 17 | ||
18 | #include "boot.h" | 18 | #include "boot.h" |
19 | #ifdef CONFIG_X86_FEATURE_NAMES | ||
19 | #include "cpustr.h" | 20 | #include "cpustr.h" |
21 | #endif | ||
20 | 22 | ||
21 | static char *cpu_name(int level) | 23 | static char *cpu_name(int level) |
22 | { | 24 | { |
@@ -32,11 +34,48 @@ static char *cpu_name(int level) | |||
32 | } | 34 | } |
33 | } | 35 | } |
34 | 36 | ||
37 | static void show_cap_strs(u32 *err_flags) | ||
38 | { | ||
39 | int i, j; | ||
40 | #ifdef CONFIG_X86_FEATURE_NAMES | ||
41 | const unsigned char *msg_strs = (const unsigned char *)x86_cap_strs; | ||
42 | for (i = 0; i < NCAPINTS; i++) { | ||
43 | u32 e = err_flags[i]; | ||
44 | for (j = 0; j < 32; j++) { | ||
45 | if (msg_strs[0] < i || | ||
46 | (msg_strs[0] == i && msg_strs[1] < j)) { | ||
47 | /* Skip to the next string */ | ||
48 | msg_strs += 2; | ||
49 | while (*msg_strs++) | ||
50 | ; | ||
51 | } | ||
52 | if (e & 1) { | ||
53 | if (msg_strs[0] == i && | ||
54 | msg_strs[1] == j && | ||
55 | msg_strs[2]) | ||
56 | printf("%s ", msg_strs+2); | ||
57 | else | ||
58 | printf("%d:%d ", i, j); | ||
59 | } | ||
60 | e >>= 1; | ||
61 | } | ||
62 | } | ||
63 | #else | ||
64 | for (i = 0; i < NCAPINTS; i++) { | ||
65 | u32 e = err_flags[i]; | ||
66 | for (j = 0; j < 32; j++) { | ||
67 | if (e & 1) | ||
68 | printf("%d:%d ", i, j); | ||
69 | e >>= 1; | ||
70 | } | ||
71 | } | ||
72 | #endif | ||
73 | } | ||
74 | |||
35 | int validate_cpu(void) | 75 | int validate_cpu(void) |
36 | { | 76 | { |
37 | u32 *err_flags; | 77 | u32 *err_flags; |
38 | int cpu_level, req_level; | 78 | int cpu_level, req_level; |
39 | const unsigned char *msg_strs; | ||
40 | 79 | ||
41 | check_cpu(&cpu_level, &req_level, &err_flags); | 80 | check_cpu(&cpu_level, &req_level, &err_flags); |
42 | 81 | ||
@@ -49,34 +88,9 @@ int validate_cpu(void) | |||
49 | } | 88 | } |
50 | 89 | ||
51 | if (err_flags) { | 90 | if (err_flags) { |
52 | int i, j; | ||
53 | puts("This kernel requires the following features " | 91 | puts("This kernel requires the following features " |
54 | "not present on the CPU:\n"); | 92 | "not present on the CPU:\n"); |
55 | 93 | show_cap_strs(err_flags); | |
56 | msg_strs = (const unsigned char *)x86_cap_strs; | ||
57 | |||
58 | for (i = 0; i < NCAPINTS; i++) { | ||
59 | u32 e = err_flags[i]; | ||
60 | |||
61 | for (j = 0; j < 32; j++) { | ||
62 | if (msg_strs[0] < i || | ||
63 | (msg_strs[0] == i && msg_strs[1] < j)) { | ||
64 | /* Skip to the next string */ | ||
65 | msg_strs += 2; | ||
66 | while (*msg_strs++) | ||
67 | ; | ||
68 | } | ||
69 | if (e & 1) { | ||
70 | if (msg_strs[0] == i && | ||
71 | msg_strs[1] == j && | ||
72 | msg_strs[2]) | ||
73 | printf("%s ", msg_strs+2); | ||
74 | else | ||
75 | printf("%d:%d ", i, j); | ||
76 | } | ||
77 | e >>= 1; | ||
78 | } | ||
79 | } | ||
80 | putchar('\n'); | 94 | putchar('\n'); |
81 | return -1; | 95 | return -1; |
82 | } else { | 96 | } else { |
diff --git a/arch/x86/configs/tiny.config b/arch/x86/configs/tiny.config new file mode 100644 index 000000000000..4e2ecfa23c15 --- /dev/null +++ b/arch/x86/configs/tiny.config | |||
@@ -0,0 +1 @@ | |||
CONFIG_NOHIGHMEM=y | |||
diff --git a/arch/x86/include/asm/cpufeature.h b/arch/x86/include/asm/cpufeature.h index bb9b258d60e7..516903b98e06 100644 --- a/arch/x86/include/asm/cpufeature.h +++ b/arch/x86/include/asm/cpufeature.h | |||
@@ -250,8 +250,15 @@ | |||
250 | #include <asm/asm.h> | 250 | #include <asm/asm.h> |
251 | #include <linux/bitops.h> | 251 | #include <linux/bitops.h> |
252 | 252 | ||
253 | #ifdef CONFIG_X86_FEATURE_NAMES | ||
253 | extern const char * const x86_cap_flags[NCAPINTS*32]; | 254 | extern const char * const x86_cap_flags[NCAPINTS*32]; |
254 | extern const char * const x86_power_flags[32]; | 255 | extern const char * const x86_power_flags[32]; |
256 | #define X86_CAP_FMT "%s" | ||
257 | #define x86_cap_flag(flag) x86_cap_flags[flag] | ||
258 | #else | ||
259 | #define X86_CAP_FMT "%d:%d" | ||
260 | #define x86_cap_flag(flag) ((flag) >> 5), ((flag) & 31) | ||
261 | #endif | ||
255 | 262 | ||
256 | /* | 263 | /* |
257 | * In order to save room, we index into this array by doing | 264 | * In order to save room, we index into this array by doing |
diff --git a/arch/x86/kernel/cpu/Makefile b/arch/x86/kernel/cpu/Makefile index 7fd54f09b011..77dcab277710 100644 --- a/arch/x86/kernel/cpu/Makefile +++ b/arch/x86/kernel/cpu/Makefile | |||
@@ -13,10 +13,13 @@ nostackp := $(call cc-option, -fno-stack-protector) | |||
13 | CFLAGS_common.o := $(nostackp) | 13 | CFLAGS_common.o := $(nostackp) |
14 | 14 | ||
15 | obj-y := intel_cacheinfo.o scattered.o topology.o | 15 | obj-y := intel_cacheinfo.o scattered.o topology.o |
16 | obj-y += proc.o capflags.o powerflags.o common.o | 16 | obj-y += common.o |
17 | obj-y += rdrand.o | 17 | obj-y += rdrand.o |
18 | obj-y += match.o | 18 | obj-y += match.o |
19 | 19 | ||
20 | obj-$(CONFIG_PROC_FS) += proc.o | ||
21 | obj-$(CONFIG_X86_FEATURE_NAMES) += capflags.o powerflags.o | ||
22 | |||
20 | obj-$(CONFIG_X86_32) += bugs.o | 23 | obj-$(CONFIG_X86_32) += bugs.o |
21 | obj-$(CONFIG_X86_64) += bugs_64.o | 24 | obj-$(CONFIG_X86_64) += bugs_64.o |
22 | 25 | ||
@@ -48,6 +51,7 @@ obj-$(CONFIG_X86_LOCAL_APIC) += perfctr-watchdog.o perf_event_amd_ibs.o | |||
48 | 51 | ||
49 | obj-$(CONFIG_HYPERVISOR_GUEST) += vmware.o hypervisor.o mshyperv.o | 52 | obj-$(CONFIG_HYPERVISOR_GUEST) += vmware.o hypervisor.o mshyperv.o |
50 | 53 | ||
54 | ifdef CONFIG_X86_FEATURE_NAMES | ||
51 | quiet_cmd_mkcapflags = MKCAP $@ | 55 | quiet_cmd_mkcapflags = MKCAP $@ |
52 | cmd_mkcapflags = $(CONFIG_SHELL) $(srctree)/$(src)/mkcapflags.sh $< $@ | 56 | cmd_mkcapflags = $(CONFIG_SHELL) $(srctree)/$(src)/mkcapflags.sh $< $@ |
53 | 57 | ||
@@ -56,3 +60,4 @@ cpufeature = $(src)/../../include/asm/cpufeature.h | |||
56 | targets += capflags.c | 60 | targets += capflags.c |
57 | $(obj)/capflags.c: $(cpufeature) $(src)/mkcapflags.sh FORCE | 61 | $(obj)/capflags.c: $(cpufeature) $(src)/mkcapflags.sh FORCE |
58 | $(call if_changed,mkcapflags) | 62 | $(call if_changed,mkcapflags) |
63 | endif | ||
diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c index e4ab2b42bd6f..c649f236e288 100644 --- a/arch/x86/kernel/cpu/common.c +++ b/arch/x86/kernel/cpu/common.c | |||
@@ -346,8 +346,8 @@ static void filter_cpuid_features(struct cpuinfo_x86 *c, bool warn) | |||
346 | continue; | 346 | continue; |
347 | 347 | ||
348 | printk(KERN_WARNING | 348 | printk(KERN_WARNING |
349 | "CPU: CPU feature %s disabled, no CPUID level 0x%x\n", | 349 | "CPU: CPU feature " X86_CAP_FMT " disabled, no CPUID level 0x%x\n", |
350 | x86_cap_flags[df->feature], df->level); | 350 | x86_cap_flag(df->feature), df->level); |
351 | } | 351 | } |
352 | } | 352 | } |
353 | 353 | ||
diff --git a/init/Kconfig b/init/Kconfig index e84c6423a2e5..782a65bf76ea 100644 --- a/init/Kconfig +++ b/init/Kconfig | |||
@@ -1537,6 +1537,16 @@ config AIO | |||
1537 | by some high performance threaded applications. Disabling | 1537 | by some high performance threaded applications. Disabling |
1538 | this option saves about 7k. | 1538 | this option saves about 7k. |
1539 | 1539 | ||
1540 | config ADVISE_SYSCALLS | ||
1541 | bool "Enable madvise/fadvise syscalls" if EXPERT | ||
1542 | default y | ||
1543 | help | ||
1544 | This option enables the madvise and fadvise syscalls, used by | ||
1545 | applications to advise the kernel about their future memory or file | ||
1546 | usage, improving performance. If building an embedded system where no | ||
1547 | applications use these syscalls, you can disable this option to save | ||
1548 | space. | ||
1549 | |||
1540 | config PCI_QUIRKS | 1550 | config PCI_QUIRKS |
1541 | default y | 1551 | default y |
1542 | bool "Enable PCI quirk workarounds" if EXPERT | 1552 | bool "Enable PCI quirk workarounds" if EXPERT |
diff --git a/kernel/configs/tiny.config b/kernel/configs/tiny.config new file mode 100644 index 000000000000..c2de56ab0fce --- /dev/null +++ b/kernel/configs/tiny.config | |||
@@ -0,0 +1,4 @@ | |||
1 | CONFIG_CC_OPTIMIZE_FOR_SIZE=y | ||
2 | CONFIG_KERNEL_XZ=y | ||
3 | CONFIG_OPTIMIZE_INLINING=y | ||
4 | CONFIG_SLOB=y | ||
diff --git a/kernel/sys_ni.c b/kernel/sys_ni.c index 391d4ddb6f4b..d4709d481053 100644 --- a/kernel/sys_ni.c +++ b/kernel/sys_ni.c | |||
@@ -156,6 +156,9 @@ cond_syscall(sys_process_vm_writev); | |||
156 | cond_syscall(compat_sys_process_vm_readv); | 156 | cond_syscall(compat_sys_process_vm_readv); |
157 | cond_syscall(compat_sys_process_vm_writev); | 157 | cond_syscall(compat_sys_process_vm_writev); |
158 | cond_syscall(sys_uselib); | 158 | cond_syscall(sys_uselib); |
159 | cond_syscall(sys_fadvise64); | ||
160 | cond_syscall(sys_fadvise64_64); | ||
161 | cond_syscall(sys_madvise); | ||
159 | 162 | ||
160 | /* arch-specific weak syscall entries */ | 163 | /* arch-specific weak syscall entries */ |
161 | cond_syscall(sys_pciconfig_read); | 164 | cond_syscall(sys_pciconfig_read); |
diff --git a/mm/Makefile b/mm/Makefile index 632ae77e6070..fe7a053c0f45 100644 --- a/mm/Makefile +++ b/mm/Makefile | |||
@@ -3,7 +3,7 @@ | |||
3 | # | 3 | # |
4 | 4 | ||
5 | mmu-y := nommu.o | 5 | mmu-y := nommu.o |
6 | mmu-$(CONFIG_MMU) := fremap.o gup.o highmem.o madvise.o memory.o mincore.o \ | 6 | mmu-$(CONFIG_MMU) := fremap.o gup.o highmem.o memory.o mincore.o \ |
7 | mlock.o mmap.o mprotect.o mremap.o msync.o rmap.o \ | 7 | mlock.o mmap.o mprotect.o mremap.o msync.o rmap.o \ |
8 | vmalloc.o pagewalk.o pgtable-generic.o | 8 | vmalloc.o pagewalk.o pgtable-generic.o |
9 | 9 | ||
@@ -11,7 +11,7 @@ ifdef CONFIG_CROSS_MEMORY_ATTACH | |||
11 | mmu-$(CONFIG_MMU) += process_vm_access.o | 11 | mmu-$(CONFIG_MMU) += process_vm_access.o |
12 | endif | 12 | endif |
13 | 13 | ||
14 | obj-y := filemap.o mempool.o oom_kill.o fadvise.o \ | 14 | obj-y := filemap.o mempool.o oom_kill.o \ |
15 | maccess.o page_alloc.o page-writeback.o \ | 15 | maccess.o page_alloc.o page-writeback.o \ |
16 | readahead.o swap.o truncate.o vmscan.o shmem.o \ | 16 | readahead.o swap.o truncate.o vmscan.o shmem.o \ |
17 | util.o mmzone.o vmstat.o backing-dev.o \ | 17 | util.o mmzone.o vmstat.o backing-dev.o \ |
@@ -28,6 +28,9 @@ else | |||
28 | obj-y += bootmem.o | 28 | obj-y += bootmem.o |
29 | endif | 29 | endif |
30 | 30 | ||
31 | ifdef CONFIG_MMU | ||
32 | obj-$(CONFIG_ADVISE_SYSCALLS) += fadvise.o madvise.o | ||
33 | endif | ||
31 | obj-$(CONFIG_HAVE_MEMBLOCK) += memblock.o | 34 | obj-$(CONFIG_HAVE_MEMBLOCK) += memblock.o |
32 | 35 | ||
33 | obj-$(CONFIG_SWAP) += page_io.o swap_state.o swapfile.o | 36 | obj-$(CONFIG_SWAP) += page_io.o swap_state.o swapfile.o |
diff --git a/scripts/kconfig/Makefile b/scripts/kconfig/Makefile index 9c4d2412fb72..ebf40f6edb4d 100644 --- a/scripts/kconfig/Makefile +++ b/scripts/kconfig/Makefile | |||
@@ -104,6 +104,23 @@ endif | |||
104 | %_defconfig: $(obj)/conf | 104 | %_defconfig: $(obj)/conf |
105 | $(Q)$< --defconfig=arch/$(SRCARCH)/configs/$@ $(Kconfig) | 105 | $(Q)$< --defconfig=arch/$(SRCARCH)/configs/$@ $(Kconfig) |
106 | 106 | ||
107 | configfiles=$(wildcard $(srctree)/kernel/configs/$(1).config $(srctree)/arch/$(SRCARCH)/configs/$(1).config) | ||
108 | |||
109 | define mergeconfig | ||
110 | $(if $(wildcard $(objtree)/.config),, $(error You need an existing .config for this target)) | ||
111 | $(if $(call configfiles,$(1)),, $(error No configuration exists for this target on this architecture)) | ||
112 | $(Q)$(CONFIG_SHELL) $(srctree)/scripts/kconfig/merge_config.sh -m -O $(objtree) $(objtree)/.config $(call configfiles,$(1)) | ||
113 | $(Q)yes "" | $(MAKE) -f $(srctree)/Makefile oldconfig | ||
114 | endef | ||
115 | |||
116 | PHONY += kvmconfig | ||
117 | kvmconfig: | ||
118 | $(call mergeconfig,kvm_guest) | ||
119 | |||
120 | PHONY += tinyconfig | ||
121 | tinyconfig: allnoconfig | ||
122 | $(call mergeconfig,tiny) | ||
123 | |||
107 | # Help text used by make help | 124 | # Help text used by make help |
108 | help: | 125 | help: |
109 | @echo ' config - Update current config utilising a line-oriented program' | 126 | @echo ' config - Update current config utilising a line-oriented program' |
@@ -124,6 +141,8 @@ help: | |||
124 | @echo ' randconfig - New config with random answer to all options' | 141 | @echo ' randconfig - New config with random answer to all options' |
125 | @echo ' listnewconfig - List new options' | 142 | @echo ' listnewconfig - List new options' |
126 | @echo ' olddefconfig - Same as silentoldconfig but sets new symbols to their default value' | 143 | @echo ' olddefconfig - Same as silentoldconfig but sets new symbols to their default value' |
144 | @echo ' kvmconfig - Enable additional options for guest kernel support' | ||
145 | @echo ' tinyconfig - Configure the tiniest possible kernel' | ||
127 | 146 | ||
128 | # lxdialog stuff | 147 | # lxdialog stuff |
129 | check-lxdialog := $(srctree)/$(src)/lxdialog/check-lxdialog.sh | 148 | check-lxdialog := $(srctree)/$(src)/lxdialog/check-lxdialog.sh |