gcov: enable GCOV_PROFILE_ALL from ARCH Kconfigs
authorRiku Voipio <riku.voipio@linaro.org>
Sat, 13 Dec 2014 00:57:44 +0000 (16:57 -0800)
committerMark Brown <broonie@kernel.org>
Tue, 17 Mar 2015 21:53:42 +0000 (21:53 +0000)
Following the suggestions from Andrew Morton and Stephen Rothwell,
Dont expand the ARCH list in kernel/gcov/Kconfig. Instead,
define a ARCH_HAS_GCOV_PROFILE_ALL bool which architectures
can enable.

set ARCH_HAS_GCOV_PROFILE_ALL on Architectures where it was
previously allowed + ARM64 which I tested.

Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
Cc: Peter Oberparleiter <oberpar@linux.vnet.ibm.com>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
(cherry picked from commit 957e3facd147510f2cf8780e38606f1d707f0e33)
Signed-off-by: Mark Brown <broonie@kernel.org>
Conflicts:
arch/arm/Kconfig
arch/arm64/Kconfig
arch/microblaze/Kconfig
arch/s390/Kconfig
arch/x86/Kconfig

arch/arm/Kconfig
arch/arm64/Kconfig
arch/microblaze/Kconfig
arch/powerpc/Kconfig
arch/s390/Kconfig
arch/sh/Kconfig
arch/x86/Kconfig
kernel/gcov/Kconfig

index 136f263ed47b79d010cf4ca06e7b1e2a07e4fd73..143846a2c5170ece36eab0b87c08657772f16e19 100644 (file)
@@ -5,6 +5,7 @@ config ARM
        select ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE
        select ARCH_HAVE_CUSTOM_GPIO_H
        select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST
+       select ARCH_HAS_GCOV_PROFILE_ALL
        select ARCH_WANT_IPC_PARSE_VERSION
        select BUILDTIME_EXTABLE_SORT if MMU
        select CPU_PM if (SUSPEND || CPU_IDLE)
index 56b3f6d447ae10b8d53f9cfb767826fe90a97c11..177723e0fee05e45a74f498bf19089e2f30182bd 100644 (file)
@@ -1,6 +1,7 @@
 config ARM64
        def_bool y
        select ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE
+       select ARCH_HAS_GCOV_PROFILE_ALL
        select ARCH_WANT_OPTIONAL_GPIOLIB
        select ARCH_WANT_COMPAT_IPC_PARSE_VERSION
        select ARCH_WANT_FRAME_POINTERS
index d22a4ecffff422f542e96f81527b45a4e3f9c6c2..2199bfbd4050c305214f928769a87fc6c2adc785 100644 (file)
@@ -1,5 +1,6 @@
 config MICROBLAZE
        def_bool y
+       select ARCH_HAS_GCOV_PROFILE_ALL
        select HAVE_MEMBLOCK
        select HAVE_MEMBLOCK_NODE_MAP
        select HAVE_FUNCTION_TRACER
index c33e3ad2c8fd52c9e0c31dfc272faf3d34902f37..661d77c7fd55d739ac2a7f982928f74301e39d43 100644 (file)
@@ -126,6 +126,7 @@ config PPC
        select HAVE_BPF_JIT if PPC64
        select HAVE_ARCH_JUMP_LABEL
        select ARCH_HAVE_NMI_SAFE_CMPXCHG
+       select ARCH_HAS_GCOV_PROFILE_ALL
        select GENERIC_SMP_IDLE_THREAD
        select GENERIC_CMOS_UPDATE
        select GENERIC_TIME_VSYSCALL_OLD
index da183c5a103ce1df1da3617bbde788011f0351d3..b0a78940b7c446676a848ab53e957f69c4b71955 100644 (file)
@@ -62,6 +62,7 @@ config S390
        def_bool y
        select ARCH_DISCARD_MEMBLOCK
        select ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE
+       select ARCH_HAS_GCOV_PROFILE_ALL
        select ARCH_HAVE_NMI_SAFE_CMPXCHG
        select ARCH_INLINE_READ_LOCK
        select ARCH_INLINE_READ_LOCK_BH
index 8c868cf2cf93febf478cc199e2a996ff64b244d1..69c567f98f82cfc8bf6334c6502df3747584ff02 100644 (file)
@@ -15,6 +15,7 @@ config SUPERH
        select HAVE_DEBUG_BUGVERBOSE
        select ARCH_HAVE_CUSTOM_GPIO_H
        select ARCH_HAVE_NMI_SAFE_CMPXCHG if (GUSA_RB || CPU_SH4A)
+       select ARCH_HAS_GCOV_PROFILE_ALL
        select PERF_USE_VMALLOC
        select HAVE_DEBUG_KMEMLEAK
        select HAVE_KERNEL_GZIP
index fe120da25625b23ef52c74b479bf715f265261b4..3317b3c83f6d5c25251762ddcdaa130f9d1d8aa0 100644 (file)
@@ -21,6 +21,7 @@ config X86_64
 config X86
        def_bool y
        select ARCH_HAS_DEBUG_STRICT_USER_COPY_CHECKS
+       select ARCH_HAS_GCOV_PROFILE_ALL
        select HAVE_AOUT if X86_32
        select HAVE_UNSTABLE_SCHED_CLOCK
        select ARCH_SUPPORTS_NUMA_BALANCING
index 3b7408759bdfdfc4a5fe469df649d631efdae40d..c92e44855ddda18843a2b7c9102a323811d27917 100644 (file)
@@ -32,10 +32,13 @@ config GCOV_KERNEL
        Note that the debugfs filesystem has to be mounted to access
        profiling data.
 
+config ARCH_HAS_GCOV_PROFILE_ALL
+       def_bool n
+
 config GCOV_PROFILE_ALL
        bool "Profile entire Kernel"
        depends on GCOV_KERNEL
-       depends on SUPERH || S390 || X86 || PPC || MICROBLAZE || ARM || ARM64
+       depends on ARCH_HAS_GCOV_PROFILE_ALL
        default n
        ---help---
        This options activates profiling for the entire kernel.