diff options
author | Michael Ellerman <mpe@ellerman.id.au> | 2022-11-23 21:26:10 +1100 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2022-11-23 21:26:10 +1100 |
commit | a39818a3fb2bf12ae945a7c5fba8c5d9048a0e96 (patch) | |
tree | 64a9c4cb033c8c97d4d974a3d2b171b360ac42fa /tools/objtool | |
parent | c984aef8c8326035570ff6e01d0ff9e79a5dfa76 (diff) |
objtool/powerpc: Implement arch_pc_relative_reloc()
Provide an implementation for arch_pc_relative_reloc(). It is needed to
pass the build once 61c6065ef7ec ("objtool: Allow !PC relative
relocations") is merged.
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'tools/objtool')
-rw-r--r-- | tools/objtool/arch/powerpc/decode.c | 9 | ||||
-rw-r--r-- | tools/objtool/include/objtool/arch.h | 2 |
2 files changed, 11 insertions, 0 deletions
diff --git a/tools/objtool/arch/powerpc/decode.c b/tools/objtool/arch/powerpc/decode.c index 01cade98b49e..9c653805a08a 100644 --- a/tools/objtool/arch/powerpc/decode.c +++ b/tools/objtool/arch/powerpc/decode.c @@ -82,6 +82,15 @@ unsigned long arch_jump_destination(struct instruction *insn) return insn->offset + insn->immediate; } +bool arch_pc_relative_reloc(struct reloc *reloc) +{ + /* + * The powerpc build only allows certain relocation types, see + * relocs_check.sh, and none of those accepted are PC relative. + */ + return false; +} + void arch_initial_func_cfi_state(struct cfi_init_state *state) { int i; diff --git a/tools/objtool/include/objtool/arch.h b/tools/objtool/include/objtool/arch.h index 5149330f400f..4ecb480131c7 100644 --- a/tools/objtool/include/objtool/arch.h +++ b/tools/objtool/include/objtool/arch.h @@ -95,4 +95,6 @@ bool arch_is_rethunk(struct symbol *sym); int arch_rewrite_retpolines(struct objtool_file *file); +bool arch_pc_relative_reloc(struct reloc *reloc); + #endif /* _ARCH_H */ |