summaryrefslogtreecommitdiff
path: root/tools/objtool/special.c
diff options
context:
space:
mode:
authorAlexandre Chartre <alexandre.chartre@oracle.com>2025-11-21 10:53:35 +0100
committerPeter Zijlstra <peterz@infradead.org>2025-11-21 15:30:14 +0100
commitbe5ee60ac554c6189cda963e886c4b97d2cb978c (patch)
tree69ceafd770bba3e8d44e24f31a278b686502954f /tools/objtool/special.c
parent4aae0d3f77b1104e55847870d15c3749ca575fcf (diff)
objtool: Provide access to feature and flags of group alternatives
Each alternative of a group alternative depends on a specific feature and flags. Provide access to the feature/flags for each alternative as an attribute (feature) in struct alt_group. Signed-off-by: Alexandre Chartre <alexandre.chartre@oracle.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Josh Poimboeuf <jpoimboe@kernel.org> Link: https://patch.msgid.link/20251121095340.464045-26-alexandre.chartre@oracle.com
Diffstat (limited to 'tools/objtool/special.c')
-rw-r--r--tools/objtool/special.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/objtool/special.c b/tools/objtool/special.c
index e262af917143..2a533afbc69a 100644
--- a/tools/objtool/special.c
+++ b/tools/objtool/special.c
@@ -81,6 +81,8 @@ static int get_alt_entry(struct elf *elf, const struct special_entry *entry,
entry->orig_len);
alt->new_len = *(unsigned char *)(sec->data->d_buf + offset +
entry->new_len);
+ alt->feature = *(unsigned int *)(sec->data->d_buf + offset +
+ entry->feature);
}
orig_reloc = find_reloc_by_dest(elf, sec, offset + entry->orig);