2015-04-09 00:05:58

by Gregory Fong

[permalink] [raw]
Subject: [RFC PATCH] ARM: debug: Add prompt for FRAME_POINTER to Kconfig.debug

Without a prompt string, it is impossible to disable FRAME_POINTER on
ARM. It will simply set the default value anytime you run 'make'.

To reproduce the original issue, run:
make multi_v7_defconfig
scripts/config -d ARM_UNWIND
make oldconfig
# check .config, note that FRAME_POINTER=y
scripts/config -d FRAME_POINTER
make oldconfig
# check .config, note that FRAME_POINTER is still y

Signed-off-by: Gregory Fong <[email protected]>
---
arch/arm/Kconfig.debug | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
index 970de75..b881fd3 100644
--- a/arch/arm/Kconfig.debug
+++ b/arch/arm/Kconfig.debug
@@ -33,7 +33,7 @@ config STRICT_DEVMEM
# traces, you can get a slightly smaller kernel by setting this option to
# n, but then RMK will have to kill you ;).
config FRAME_POINTER
- bool
+ bool "Compile the kernel with frame pointers"
depends on !THUMB2_KERNEL
default y if !ARM_UNWIND || FUNCTION_GRAPH_TRACER
help
--
1.9.1


2015-04-09 07:46:07

by Russell King - ARM Linux

[permalink] [raw]
Subject: Re: [RFC PATCH] ARM: debug: Add prompt for FRAME_POINTER to Kconfig.debug

On Wed, Apr 08, 2015 at 05:04:43PM -0700, Gregory Fong wrote:
> Without a prompt string, it is impossible to disable FRAME_POINTER on
> ARM. It will simply set the default value anytime you run 'make'.

Have you read the comment above it?

--
FTTC broadband for 0.8mile line: currently at 10.5Mbps down 400kbps up
according to speedtest.net.

2015-04-09 18:17:05

by Gregory Fong

[permalink] [raw]
Subject: Re: [RFC PATCH] ARM: debug: Add prompt for FRAME_POINTER to Kconfig.debug

On Thu, Apr 9, 2015 at 12:45 AM, Russell King - ARM Linux
<[email protected]> wrote:
> On Wed, Apr 08, 2015 at 05:04:43PM -0700, Gregory Fong wrote:
>> Without a prompt string, it is impossible to disable FRAME_POINTER on
>> ARM. It will simply set the default value anytime you run 'make'.
>
> Have you read the comment above it?

Yes! It says that you'll kill those who disable the option, but
that's not itself a reason to be completely unable to turn it off.

Just think of it as a good way to increase your reputation as a bounty hunter ;)

Seriously though, I agree it's a terrible idea to turn this off in
general, but really that's not a reason to make it impossible, as it
does still have value in very specific cases. You can still disable
CONFIG_BUG, for example.

2015-04-13 22:35:05

by Gregory Fong

[permalink] [raw]
Subject: Re: [RFC PATCH] ARM: debug: Add prompt for FRAME_POINTER to Kconfig.debug

On Wed, Apr 8, 2015 at 5:04 PM, Gregory Fong <[email protected]> wrote:
> Without a prompt string, it is impossible to disable FRAME_POINTER on
> ARM. It will simply set the default value anytime you run 'make'.

NAK'ing myself. You should not disable both FRAME_POINTER and
ARM_UNWIND on ARM, as a working unwind_frame() is required in several
places. Sorry for the noise.