Loading Makefile +1 −1 Original line number Diff line number Diff line # SPDX-License-Identifier: GPL-2.0 VERSION = 4 PATCHLEVEL = 19 SUBLEVEL = 67 SUBLEVEL = 68 EXTRAVERSION = NAME = "People's Front" Loading arch/arm64/include/asm/efi.h +5 −1 Original line number Diff line number Diff line Loading @@ -94,7 +94,11 @@ static inline unsigned long efi_get_max_initrd_addr(unsigned long dram_base, ((protocol##_t *)instance)->f(instance, ##__VA_ARGS__) #define alloc_screen_info(x...) &screen_info #define free_screen_info(x...) static inline void free_screen_info(efi_system_table_t *sys_table_arg, struct screen_info *si) { } /* redeclare as 'hidden' so the compiler will generate relative references */ extern struct screen_info screen_info __attribute__((__visibility__("hidden"))); Loading arch/arm64/include/asm/pgtable.h +2 −2 Original line number Diff line number Diff line Loading @@ -448,8 +448,8 @@ extern pgprot_t phys_mem_access_prot(struct file *file, unsigned long pfn, PMD_TYPE_SECT) #if defined(CONFIG_ARM64_64K_PAGES) || CONFIG_PGTABLE_LEVELS < 3 #define pud_sect(pud) (0) #define pud_table(pud) (1) static inline bool pud_sect(pud_t pud) { return false; } static inline bool pud_table(pud_t pud) { return true; } #else #define pud_sect(pud) ((pud_val(pud) & PUD_TYPE_MASK) == \ PUD_TYPE_SECT) Loading arch/arm64/kernel/ftrace.c +12 −9 Original line number Diff line number Diff line Loading @@ -76,7 +76,7 @@ int ftrace_make_call(struct dyn_ftrace *rec, unsigned long addr) if (offset < -SZ_128M || offset >= SZ_128M) { #ifdef CONFIG_ARM64_MODULE_PLTS struct plt_entry trampoline; struct plt_entry trampoline, *dst; struct module *mod; /* Loading Loading @@ -104,24 +104,27 @@ int ftrace_make_call(struct dyn_ftrace *rec, unsigned long addr) * is added in the future, but for now, the pr_err() below * deals with a theoretical issue only. */ dst = mod->arch.ftrace_trampoline; trampoline = get_plt_entry(addr); if (!plt_entries_equal(mod->arch.ftrace_trampoline, &trampoline)) { if (!plt_entries_equal(mod->arch.ftrace_trampoline, &(struct plt_entry){})) { if (!plt_entries_equal(dst, &trampoline)) { if (!plt_entries_equal(dst, &(struct plt_entry){})) { pr_err("ftrace: far branches to multiple entry points unsupported inside a single module\n"); return -EINVAL; } /* point the trampoline to our ftrace entry point */ module_disable_ro(mod); *mod->arch.ftrace_trampoline = trampoline; *dst = trampoline; module_enable_ro(mod, true); /* update trampoline before patching in the branch */ smp_wmb(); /* * Ensure updated trampoline is visible to instruction * fetch before we patch in the branch. */ __flush_icache_range((unsigned long)&dst[0], (unsigned long)&dst[1]); } addr = (unsigned long)(void *)mod->arch.ftrace_trampoline; addr = (unsigned long)dst; #else /* CONFIG_ARM64_MODULE_PLTS */ return -EINVAL; #endif /* CONFIG_ARM64_MODULE_PLTS */ Loading arch/arm64/kernel/return_address.c +3 −0 Original line number Diff line number Diff line Loading @@ -11,6 +11,7 @@ #include <linux/export.h> #include <linux/ftrace.h> #include <linux/kprobes.h> #include <asm/stack_pointer.h> #include <asm/stacktrace.h> Loading @@ -32,6 +33,7 @@ static int save_return_addr(struct stackframe *frame, void *d) return 0; } } NOKPROBE_SYMBOL(save_return_addr); void *return_address(unsigned int level) { Loading @@ -55,3 +57,4 @@ void *return_address(unsigned int level) return NULL; } EXPORT_SYMBOL_GPL(return_address); NOKPROBE_SYMBOL(return_address); Loading
Makefile +1 −1 Original line number Diff line number Diff line # SPDX-License-Identifier: GPL-2.0 VERSION = 4 PATCHLEVEL = 19 SUBLEVEL = 67 SUBLEVEL = 68 EXTRAVERSION = NAME = "People's Front" Loading
arch/arm64/include/asm/efi.h +5 −1 Original line number Diff line number Diff line Loading @@ -94,7 +94,11 @@ static inline unsigned long efi_get_max_initrd_addr(unsigned long dram_base, ((protocol##_t *)instance)->f(instance, ##__VA_ARGS__) #define alloc_screen_info(x...) &screen_info #define free_screen_info(x...) static inline void free_screen_info(efi_system_table_t *sys_table_arg, struct screen_info *si) { } /* redeclare as 'hidden' so the compiler will generate relative references */ extern struct screen_info screen_info __attribute__((__visibility__("hidden"))); Loading
arch/arm64/include/asm/pgtable.h +2 −2 Original line number Diff line number Diff line Loading @@ -448,8 +448,8 @@ extern pgprot_t phys_mem_access_prot(struct file *file, unsigned long pfn, PMD_TYPE_SECT) #if defined(CONFIG_ARM64_64K_PAGES) || CONFIG_PGTABLE_LEVELS < 3 #define pud_sect(pud) (0) #define pud_table(pud) (1) static inline bool pud_sect(pud_t pud) { return false; } static inline bool pud_table(pud_t pud) { return true; } #else #define pud_sect(pud) ((pud_val(pud) & PUD_TYPE_MASK) == \ PUD_TYPE_SECT) Loading
arch/arm64/kernel/ftrace.c +12 −9 Original line number Diff line number Diff line Loading @@ -76,7 +76,7 @@ int ftrace_make_call(struct dyn_ftrace *rec, unsigned long addr) if (offset < -SZ_128M || offset >= SZ_128M) { #ifdef CONFIG_ARM64_MODULE_PLTS struct plt_entry trampoline; struct plt_entry trampoline, *dst; struct module *mod; /* Loading Loading @@ -104,24 +104,27 @@ int ftrace_make_call(struct dyn_ftrace *rec, unsigned long addr) * is added in the future, but for now, the pr_err() below * deals with a theoretical issue only. */ dst = mod->arch.ftrace_trampoline; trampoline = get_plt_entry(addr); if (!plt_entries_equal(mod->arch.ftrace_trampoline, &trampoline)) { if (!plt_entries_equal(mod->arch.ftrace_trampoline, &(struct plt_entry){})) { if (!plt_entries_equal(dst, &trampoline)) { if (!plt_entries_equal(dst, &(struct plt_entry){})) { pr_err("ftrace: far branches to multiple entry points unsupported inside a single module\n"); return -EINVAL; } /* point the trampoline to our ftrace entry point */ module_disable_ro(mod); *mod->arch.ftrace_trampoline = trampoline; *dst = trampoline; module_enable_ro(mod, true); /* update trampoline before patching in the branch */ smp_wmb(); /* * Ensure updated trampoline is visible to instruction * fetch before we patch in the branch. */ __flush_icache_range((unsigned long)&dst[0], (unsigned long)&dst[1]); } addr = (unsigned long)(void *)mod->arch.ftrace_trampoline; addr = (unsigned long)dst; #else /* CONFIG_ARM64_MODULE_PLTS */ return -EINVAL; #endif /* CONFIG_ARM64_MODULE_PLTS */ Loading
arch/arm64/kernel/return_address.c +3 −0 Original line number Diff line number Diff line Loading @@ -11,6 +11,7 @@ #include <linux/export.h> #include <linux/ftrace.h> #include <linux/kprobes.h> #include <asm/stack_pointer.h> #include <asm/stacktrace.h> Loading @@ -32,6 +33,7 @@ static int save_return_addr(struct stackframe *frame, void *d) return 0; } } NOKPROBE_SYMBOL(save_return_addr); void *return_address(unsigned int level) { Loading @@ -55,3 +57,4 @@ void *return_address(unsigned int level) return NULL; } EXPORT_SYMBOL_GPL(return_address); NOKPROBE_SYMBOL(return_address);