[PATCH v1 0/6] Add jump table support for objtool on LoongArch

From: Tiezhu Yang
Date: Tue Oct 15 2024 - 07:39:40 EST


This series is based on 6.12-rc3, tested with the latest (20241012)
upstream mainline binutils and gcc.

The first three patches are to support the jump table of switch cases,
the last three patches are to support the jump table of computed gotos,
patch #4 is a small change of kernel/bpf/core.c, the other patches are
related with tools/objtool and arch/loongarch.

Tiezhu Yang (6):
objtool: Check various symbol types for jump table
objtool/LoongArch: Add support for jump table
LoongArch: Enable jump table for objtool
bpf, core: Add weak arch_prepare_goto()
LoongArch: Define specified arch_prepare_goto()
objtool/LoongArch: Add support for goto table

arch/loongarch/Kconfig | 9 +++-
arch/loongarch/Makefile | 5 +-
arch/loongarch/include/asm/compiler.h | 13 ++++++
kernel/bpf/core.c | 9 ++++
tools/objtool/arch/loongarch/special.c | 63 +++++++++++++++++++++++++-
tools/objtool/check.c | 20 ++++++--
6 files changed, 109 insertions(+), 10 deletions(-)
create mode 100644 arch/loongarch/include/asm/compiler.h

--
2.42.0