Zheng Yejian (33): livepatch/core: Allow implementation without ftrace livepatch/core: Reuse common codes in the solution without ftrace Revert "x86/insn: Make insn_complete() static" livepatch/x86: Support livepatch without ftrace livepatch/core: Disable support for replacing livepatch/core: Restrict livepatch patched/unpatched when plant kprobe livepatch/core: Support load and unload hooks livepatch: samples: Adapt livepatch-sample for solution without ftrace livepatch/core: Support jump_label livepatch: Fix crash when access the global variable in hook livepatch: Fix patching functions which have static_call livepatch/core: Avoid conflict with static {call,key} livepatch/arm64: Support livepatch without ftrace livepatch/core: Revert module_enable_ro and module_disable_ro livepatch: Enable livepatch configs in openeuler_defconfig arm/module: Use plt section indices for relocations livepatch/core: Add support for arm for klp relocation livepatch/arm: Support livepatch without ftrace livepatch/ppc32: Support livepatch without ftrace livepatch: Use breakpoint exception to optimize enabling livepatch livepatch/x86: Support breakpoint exception optimization livepatch: Add arch_klp_init livepatch/arm64: Support breakpoint exception optimization livepatch/arm: Support breakpoint exception optimization livepatch: Add klp_module_delete_safety_check livepatch/x86: Add arch_klp_module_check_calltrace livepatch/arm64: Add arch_klp_module_check_calltrace livepatch/arm: Add arch_klp_module_check_calltrace livepatch: Bypass dead thread when check calltrace livepatch/ppc64: Implement livepatch without ftrace for ppc64be livepatch/ppc64: Sample testcase fix ppc64 livepatch/powerpc: Support breakpoint exception optimization livepatch/powerpc: Add arch_klp_module_check_calltrace
Documentation/filesystems/proc.rst | 2 +- arch/arm/Kconfig | 3 + arch/arm/include/asm/livepatch.h | 61 + arch/arm/include/asm/module.h | 4 +- arch/arm/kernel/Makefile | 1 + arch/arm/kernel/ftrace.c | 4 +- arch/arm/kernel/livepatch.c | 322 ++++ arch/arm/kernel/module-plts.c | 22 +- arch/arm/kernel/module.c | 4 +- arch/arm64/Kconfig | 3 + arch/arm64/configs/openeuler_defconfig | 12 + arch/arm64/include/asm/brk-imm.h | 1 + arch/arm64/include/asm/debug-monitors.h | 2 + arch/arm64/include/asm/livepatch.h | 56 + arch/arm64/kernel/Makefile | 1 + arch/arm64/kernel/livepatch.c | 290 ++++ arch/powerpc/Kconfig | 5 +- arch/powerpc/include/asm/livepatch.h | 80 + arch/powerpc/include/asm/module.h | 3 + arch/powerpc/kernel/Makefile | 2 + arch/powerpc/kernel/livepatch.c | 357 +++++ arch/powerpc/kernel/livepatch_32.c | 124 ++ arch/powerpc/kernel/livepatch_64.c | 264 ++++ arch/powerpc/kernel/livepatch_tramp.S | 126 ++ arch/powerpc/kernel/module_64.c | 109 ++ arch/powerpc/kernel/traps.c | 8 + arch/s390/Kconfig | 2 +- arch/s390/configs/debug_defconfig | 1 + arch/s390/configs/defconfig | 1 + arch/x86/Kconfig | 3 +- arch/x86/configs/openeuler_defconfig | 12 +- arch/x86/include/asm/insn.h | 7 + arch/x86/include/asm/livepatch.h | 43 + arch/x86/kernel/Makefile | 1 + arch/x86/kernel/livepatch.c | 376 +++++ arch/x86/kernel/module.c | 2 +- arch/x86/kernel/traps.c | 10 + arch/x86/lib/insn.c | 7 - include/linux/jump_label.h | 10 + include/linux/livepatch.h | 129 +- include/linux/livepatch_sched.h | 6 +- include/linux/module.h | 33 + include/linux/moduleloader.h | 4 +- include/linux/static_call.h | 6 + kernel/jump_label.c | 22 + kernel/livepatch/Kconfig | 78 +- kernel/livepatch/Makefile | 3 +- kernel/livepatch/core.c | 1563 +++++++++++++++++++- kernel/livepatch/core.h | 16 + kernel/module/main.c | 16 +- kernel/module/strict_rwx.c | 17 + kernel/static_call_inline.c | 20 + lib/Kconfig.debug | 2 +- samples/livepatch/Makefile | 2 + samples/livepatch/livepatch-sample.c | 47 + tools/arch/x86/include/asm/insn.h | 7 + tools/arch/x86/lib/insn.c | 7 - tools/testing/selftests/bpf/config.aarch64 | 1 + tools/testing/selftests/bpf/config.s390x | 1 + tools/testing/selftests/livepatch/README | 1 + tools/testing/selftests/livepatch/config | 1 + 61 files changed, 4266 insertions(+), 57 deletions(-) create mode 100644 arch/arm/include/asm/livepatch.h create mode 100644 arch/arm/kernel/livepatch.c create mode 100644 arch/arm64/include/asm/livepatch.h create mode 100644 arch/arm64/kernel/livepatch.c create mode 100644 arch/powerpc/kernel/livepatch.c create mode 100644 arch/powerpc/kernel/livepatch_32.c create mode 100644 arch/powerpc/kernel/livepatch_64.c create mode 100644 arch/powerpc/kernel/livepatch_tramp.S create mode 100644 arch/x86/include/asm/livepatch.h create mode 100644 arch/x86/kernel/livepatch.c