
Add hardware xcall framework support. Changes in v7: - Add missing lock for xinfo syscall table copy. - Check xcall entry under lock for set_hw_xcall_entry(). - Clear ACTLR_ELx_XCALL when xcall_scno_count count to zero to reduce overhead. Changes in v6: - Use system_uses_xcall_xint() instead of static key for hardware xcall. - xcall_scno_enabled -> xcall_scno_count for each task_struct. - Use xcall_scno_enabled instead of static_branch_unlikely() for performance-insensitive code. - Some cleanup. Changes in v5: - Not adjust the software xcall and hardware xcall hwcap detect order. - Not udapte xcall 1.0 enrty code. - Some cleanup. Changes in v4: - Merge the percpu and csel patch. - Use static key to improve the software and hardware xcall code. - Some cleanup. - Fix a build problem. Changes in v3: - Optimize the use of hardware xcall and not use them at the same time. - Use syscall table instead of xcall enable bitmap in hardware xcall. - Use percpu syscall table cache to simplfy code. - Use csel to improve the jump instruction. Changes in v2: - Split software xcall and hardware xcall code and use same bitmap to check xcall enable. Jinjie Ruan (3): arm64: Refactor the xcall proc code arm64: Reserve a kabi in task_struct exclusively for xcall arm64: Add hardware xcall framework support arch/arm64/Kconfig.turbo | 1 + arch/arm64/include/asm/cpufeature.h | 2 - arch/arm64/include/asm/exception.h | 5 + arch/arm64/include/asm/mmu_context.h | 7 + arch/arm64/include/asm/xcall.h | 96 +++++++++++++ arch/arm64/kernel/Makefile | 1 + arch/arm64/kernel/asm-offsets.c | 2 +- arch/arm64/kernel/cpufeature.c | 41 +++--- arch/arm64/kernel/entry-common.c | 2 +- arch/arm64/kernel/entry.S | 6 +- arch/arm64/kernel/xcall/Makefile | 2 + arch/arm64/kernel/xcall/entry.S | 195 +++++++++++++++++++++++++++ arch/arm64/kernel/xcall/xcall.c | 77 +++++++++++ fs/proc/Makefile | 1 + fs/proc/base.c | 109 --------------- fs/proc/internal.h | 4 + fs/proc/proc_xcall.c | 178 ++++++++++++++++++++++++ include/linux/sched.h | 2 +- kernel/fork.c | 15 +-- 19 files changed, 605 insertions(+), 141 deletions(-) create mode 100644 arch/arm64/include/asm/xcall.h create mode 100644 arch/arm64/kernel/xcall/Makefile create mode 100644 arch/arm64/kernel/xcall/entry.S create mode 100644 arch/arm64/kernel/xcall/xcall.c create mode 100644 fs/proc/proc_xcall.c -- 2.34.1