diff options
author | Gerald Schaefer <gerald.schaefer@de.ibm.com> | 2012-10-08 19:30:04 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-10-09 03:22:29 -0400 |
commit | 15626062f4a98279c59a2a5208c496cf65cbf8c0 (patch) | |
tree | 793c32816204cc879c1c80065c5cc24789ab4b3b | |
parent | ca42b26ab285edc5ee3f9faa48379d258db53c35 (diff) |
thp, x86: introduce HAVE_ARCH_TRANSPARENT_HUGEPAGE
Cleanup patch in preparation for transparent hugepage support on s390.
Adding new architectures to the TRANSPARENT_HUGEPAGE config option can
make the "depends" line rather ugly, like "depends on (X86 || (S390 &&
64BIT)) && MMU".
This patch adds a HAVE_ARCH_TRANSPARENT_HUGEPAGE instead. x86 already has
MMU "def_bool y", so the MMU check is superfluous there and
HAVE_ARCH_TRANSPARENT_HUGEPAGE can be selected in arch/x86/Kconfig.
Signed-off-by: Gerald Schaefer <gerald.schaefer@de.ibm.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Hugh Dickins <hughd@google.com>
Cc: Hillf Danton <dhillf@gmail.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | arch/Kconfig | 3 | ||||
-rw-r--r-- | arch/x86/Kconfig | 1 | ||||
-rw-r--r-- | mm/Kconfig | 2 |
3 files changed, 5 insertions, 1 deletions
diff --git a/arch/Kconfig b/arch/Kconfig index a62965d057f6..550cce4dd648 100644 --- a/arch/Kconfig +++ b/arch/Kconfig | |||
@@ -313,4 +313,7 @@ config HAVE_IRQ_TIME_ACCOUNTING | |||
313 | Archs need to ensure they use a high enough resolution clock to | 313 | Archs need to ensure they use a high enough resolution clock to |
314 | support irq time accounting and then call enable_sched_clock_irqtime(). | 314 | support irq time accounting and then call enable_sched_clock_irqtime(). |
315 | 315 | ||
316 | config HAVE_ARCH_TRANSPARENT_HUGEPAGE | ||
317 | bool | ||
318 | |||
316 | source "kernel/gcov/Kconfig" | 319 | source "kernel/gcov/Kconfig" |
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index 6119d6c7002e..1ae94bcae5d9 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig | |||
@@ -88,6 +88,7 @@ config X86 | |||
88 | select IRQ_FORCED_THREADING | 88 | select IRQ_FORCED_THREADING |
89 | select USE_GENERIC_SMP_HELPERS if SMP | 89 | select USE_GENERIC_SMP_HELPERS if SMP |
90 | select HAVE_BPF_JIT if X86_64 | 90 | select HAVE_BPF_JIT if X86_64 |
91 | select HAVE_ARCH_TRANSPARENT_HUGEPAGE | ||
91 | select CLKEVT_I8253 | 92 | select CLKEVT_I8253 |
92 | select ARCH_HAVE_NMI_SAFE_CMPXCHG | 93 | select ARCH_HAVE_NMI_SAFE_CMPXCHG |
93 | select GENERIC_IOMAP | 94 | select GENERIC_IOMAP |
diff --git a/mm/Kconfig b/mm/Kconfig index d5c8019c6627..3322342a1ffb 100644 --- a/mm/Kconfig +++ b/mm/Kconfig | |||
@@ -318,7 +318,7 @@ config NOMMU_INITIAL_TRIM_EXCESS | |||
318 | 318 | ||
319 | config TRANSPARENT_HUGEPAGE | 319 | config TRANSPARENT_HUGEPAGE |
320 | bool "Transparent Hugepage Support" | 320 | bool "Transparent Hugepage Support" |
321 | depends on X86 && MMU | 321 | depends on HAVE_ARCH_TRANSPARENT_HUGEPAGE |
322 | select COMPACTION | 322 | select COMPACTION |
323 | help | 323 | help |
324 | Transparent Hugepages allows the kernel to use huge pages and | 324 | Transparent Hugepages allows the kernel to use huge pages and |