Skip to content

Commit 44ec7ab

Browse files
bebarinotorvalds
authored andcommitted
lib: consolidate DEBUG_PER_CPU_MAPS
DEBUG_PER_CPU_MAPS is used in lib/cpumask.c as well as in inlcude/linux/cpumask.h and thus it has outgrown its use within x86 and powerpc alone. Any arch with SMP support may want to get some more debugging, so make this option generic. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Cc: <linux-arch@vger.kernel.org> Cc: Ingo Molnar <mingo@elte.hu> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: "H. Peter Anvin" <hpa@zytor.com> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent c196e32 commit 44ec7ab

3 files changed

Lines changed: 11 additions & 23 deletions

File tree

‎arch/powerpc/Kconfig.debug‎

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -44,18 +44,6 @@ config DEBUG_STACK_USAGE
4444

4545
This option will slow down process creation somewhat.
4646

47-
config DEBUG_PER_CPU_MAPS
48-
bool "Debug access to per_cpu maps"
49-
depends on DEBUG_KERNEL
50-
depends on SMP
51-
default n
52-
---help---
53-
Say Y to verify that the per_cpu map being accessed has
54-
been setup. Adds a fair amount of code to kernel memory
55-
and decreases performance.
56-
57-
Say N if unsure.
58-
5947
config HCALL_STATS
6048
bool "Hypervisor call instrumentation"
6149
depends on PPC_PSERIES && DEBUG_FS && TRACEPOINTS

‎arch/x86/Kconfig.debug‎

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -75,17 +75,6 @@ config DEBUG_STACK_USAGE
7575

7676
This option will slow down process creation somewhat.
7777

78-
config DEBUG_PER_CPU_MAPS
79-
bool "Debug access to per_cpu maps"
80-
depends on DEBUG_KERNEL
81-
depends on SMP
82-
---help---
83-
Say Y to verify that the per_cpu map being accessed has
84-
been setup. Adds a fair amount of code to kernel memory
85-
and decreases performance.
86-
87-
Say N if unsure.
88-
8978
config X86_PTDUMP
9079
bool "Export kernel pagetable layout to userspace via debugfs"
9180
depends on DEBUG_KERNEL

‎lib/Kconfig.debug‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -983,6 +983,17 @@ config DEBUG_FORCE_WEAK_PER_CPU
983983
To ensure that generic code follows the above rules, this
984984
option forces all percpu variables to be defined as weak.
985985

986+
config DEBUG_PER_CPU_MAPS
987+
bool "Debug access to per_cpu maps"
988+
depends on DEBUG_KERNEL
989+
depends on SMP
990+
help
991+
Say Y to verify that the per_cpu map being accessed has
992+
been set up. This adds a fair amount of code to kernel memory
993+
and decreases performance.
994+
995+
Say N if unsure.
996+
986997
config LKDTM
987998
tristate "Linux Kernel Dump Test Tool Module"
988999
depends on DEBUG_FS

0 commit comments

Comments
 (0)