Files
linux/tools/objtool
Josh Poimboeuf 4cdee7888f objtool: Fix "unexpected end of section" warning for alternatives
Due to the short circuiting logic in next_insn_to_validate(), control
flow may silently transition from .altinstr_replacement to .text without
a corresponding nested call to validate_branch().

As a result the validate_branch() 'sec' variable doesn't get
reinitialized, which can trigger a confusing "unexpected end of section"
warning which blames .altinstr_replacement rather than the offending
fallthrough function.

Fix that by not caching the section.  There's no point in doing that
anyway.

Acked-by: Petr Mladek <pmladek@suse.com>
Tested-by: Joe Lawrence <joe.lawrence@redhat.com>
Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
2025-10-14 14:45:24 -07:00
..
2023-01-30 16:27:46 -08:00
2023-01-30 16:27:46 -08:00
2025-10-14 14:45:23 -07:00
2025-09-04 13:15:59 +02:00
2022-04-22 12:32:01 +02:00