trace: fix SKIP_STACK_VALIDATION=1 build
PATCH 1/1 trace: fix SKIP_STACK_VALIDATION=1 build
Non gcc-5 builds with CONFIG_STACK_VALIDATION=y and SKIP_STACK_VALIDATION=1 fail.
Example output:
/bin/sh: init/.tmp_main.o: Permission denied
commit 96f60dfa5819 ("trace: Use -mcount-record for dynamic ftrace"), added a mismatched endif. This causes cmd_objtool to get mistakenly set.
Relocate endif to balance the newly added -record-mcount check.
--- scripts/Makefile.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/Makefile.build +1 -1
@@ -239,6 +239,7 @@ cmd_record_mcount = \ "$(CC_FLAGS_FTRACE)" ]; then \ $(sub_cmd_record_mcount) \ fi; +endif # -record-mcount endif # CONFIG_FTRACE_MCOUNT_RECORD ifdef CONFIG_STACK_VALIDATION
@@ -263,7 +264,6 @@ ifneq ($(RETPOLINE_CFLAGS),) objtool_args += --retpoline endif endif -endif ifdef CONFIG_MODVERSIONS
Signature · 1 line
2.18.0.rc1.242.g61856ae69a-goog
Quoted 5 lines · Greg Thelen
Non gcc-5 builds with
CONFIG_STACK_VALIDATION=yand SKIP_STACK_VALIDATION=1 fail.
Example output:
/bin/sh:init/.tmp_main.o: Permission denied
Quoted 8 lines
commit
96f60dfa5819("trace: Use -mcount-record for dynamic ftrace"), added a mismatched endif. This causescmd_objtoolto get mistakenly set.Relocate endif to balance the newly added -record-mcount check.
Fixes 96f60dfa5819 ("trace: Use -mcount-record for dynamic ftrace")Signed-off-by Greg Thelen <[email protected]>
Looks good thanks.
-Andi
Quoted 5 lines · Greg Thelen
Non gcc-5 builds with
CONFIG_STACK_VALIDATION=yand SKIP_STACK_VALIDATION=1 fail.
Example output:
/bin/sh:init/.tmp_main.o: Permission denied
Quoted 8 lines
commit
96f60dfa5819("trace: Use -mcount-record for dynamic ftrace"), added a mismatched endif. This causescmd_objtoolto get mistakenly set.Relocate endif to balance the newly added -record-mcount check.
Fixes 96f60dfa5819 ("trace: Use -mcount-record for dynamic ftrace")Signed-off-by Greg Thelen <[email protected]>
2018-06-09 6:47 GMT+09:00 Greg Thelen <[email protected]>:
Quoted 9 lines
Non gcc-5 builds with
CONFIG_STACK_VALIDATION=yand SKIP_STACK_VALIDATION=1 fail.
Example output:
/bin/sh:init/.tmp_main.o: Permission deniedcommit
96f60dfa5819("trace: Use -mcount-record for dynamic ftrace"), added a mismatched endif. This causescmd_objtoolto get mistakenly set.
Quoted 5 lines
Relocate endif to balance the newly added -record-mcount check.
Fixes 96f60dfa5819 ("trace: Use -mcount-record for dynamic ftrace")Signed-off-by Greg Thelen <[email protected]>---
Applied to linux-kbuild/fixes. Thanks!
Quoted 30 lines
scripts/Makefile.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)scripts/Makefile.build +1
-2@@ -239,6 +239,7 @@ cmd_record_mcount = \ "$(CC_FLAGS_FTRACE)" ]; then \ $(sub_cmd_record_mcount) \ fi; +endif # -record-mcount endif # CONFIG_FTRACE_MCOUNT_RECORD ifdef CONFIG_STACK_VALIDATION@@ -263,7 +264,6 @@ ifneq ($(RETPOLINE_CFLAGS),) objtool_args += --retpoline endif endif -endif ifdef CONFIG_MODVERSIONS --2.18.0.rc1.242.g61856ae69a-goog
--
To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 2 lines
Best Regards Masahiro Yamada
Quoted 10 lines · On Sat, 23 Jun 2018 02:42:26 +0900 Masahiro Yamada…
2018-06-09 6:47 GMT+09:00 Greg Thelen <[email protected]>:
Quoted 9 lines
Non gcc-5 builds with
CONFIG_STACK_VALIDATION=yand SKIP_STACK_VALIDATION=1 fail.
Example output:
/bin/sh:init/.tmp_main.o: Permission deniedcommit
96f60dfa5819("trace: Use -mcount-record for dynamic ftrace"), added a mismatched endif. This causescmd_objtoolto get mistakenly set.
Quoted 9 lines
Quoted 5 lines
Relocate endif to balance the newly added -record-mcount check.
Fixes 96f60dfa5819 ("trace: Use -mcount-record for dynamic ftrace")Signed-off-by Greg Thelen <[email protected]>---
Applied to linux-kbuild/fixes. Thanks!
I already pushed this to Linus. As I was the one to mess it up in the first place ;-) (I think I applied it with some fuzz)
-- Steve
2018-06-25 23:16 GMT+09:00 Steven Rostedt <[email protected]>:
Quoted 19 lines
Quoted 16 lines · On Sat, 23 Jun 2018 02:42:26 +0900 Masahiro Yamada…
2018-06-09 6:47 GMT+09:00 Greg Thelen <[email protected]>:
Quoted 14 lines
Non gcc-5 builds with
CONFIG_STACK_VALIDATION=yand SKIP_STACK_VALIDATION=1 fail.
Example output:
/bin/sh:init/.tmp_main.o: Permission deniedcommit
96f60dfa5819("trace: Use -mcount-record for dynamic ftrace"), added a mismatched endif. This causescmd_objtoolto get mistakenly set.Relocate endif to balance the newly added -record-mcount check.
Fixes 96f60dfa5819 ("trace: Use -mcount-record for dynamic ftrace")Signed-off-by Greg Thelen <[email protected]>---
Quoted 9 lines
Quoted 3 lines
Applied to linux-kbuild/fixes. Thanks!
I already pushed this to Linus. As I was the one to mess it up in the first place ;-) (I think I applied it with some fuzz)
OK.
I will drop this, then.
Thanks for the info.
Quoted 5 lines
-- Steve
--
To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 2 lines
Best Regards Masahiro Yamada