summaryrefslogtreecommitdiff
path: root/security
diff options
context:
space:
mode:
authorJosh Poimboeuf <jpoimboe@kernel.org>2026-08-08 16:17:05 -0700
committerJosh Poimboeuf <jpoimboe@kernel.org>2026-08-12 13:52:07 -0700
commit7df1638df97b2aaaff4731b72d4940053257c952 (patch)
tree2979e3dbcb34e0805632be5af5cf21c9cb7c6bce /security
parent6656cf1e975aa152c082012b820efffaebd49979 (diff)
objtool/klp: Fix .kcfi_traps special section extraction
create_fake_symbols() creates a symbol per entry for special sections. It does so in two steps: first for the sections which have ANNOTATE_DATA_SPECIAL annotations, then for the rest, using entsize or the reloc count to infer the entry size. The second step skips the sections already handled by the first one by looking for a symbol at offset 0. That heuristic is too fuzzy: with Clang and CONFIG_CFI, it misfires on .kcfi_traps because Clang emits a .Ltmp* assembler-local label at the start of the section, so no symbols are created and clone_special_sections() extracts nothing. klp-build still reports SUCCESS, but the livepatch module has no __kcfi_traps section and the traps for the patched functions are lost. Look for the actual fake symbols created by the first step instead. Fixes: da4326573ae8d ("objtool/klp: Fix kCFI trap handling") Reported-by: Joe Lawrence <joe.lawrence@redhat.com> Closes: https://lore.kernel.org/r/akQNqlfFC0T5pcMa@redhat.com Acked-by: Song Liu <song@kernel.org> Link: https://patch.msgid.link/8faaead205b219607b6fc2359ae743be824056eb.1786230311.git.jpoimboe@kernel.org Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
Diffstat (limited to 'security')
0 files changed, 0 insertions, 0 deletions