diff options
author | Mark Brown <broonie@kernel.org> | 2023-07-24 01:34:35 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2023-07-24 01:34:35 +0300 |
commit | 447281e71527080244ed1fa07e84a9d4e0654616 (patch) | |
tree | 58f57b177501db3a12da06cbe34a3a3ee412e97e /samples/ftrace/ftrace-direct-modify.c | |
parent | 79232ec0ee0dfd11f0070a63d9307480ac39f87d (diff) | |
parent | 6eaae198076080886b9e7d57f4ae06fa782f90ef (diff) | |
download | linux-447281e71527080244ed1fa07e84a9d4e0654616.tar.xz |
regulator: Merge up fixes from mainline
There's several things here that will really help my CI.
Diffstat (limited to 'samples/ftrace/ftrace-direct-modify.c')
-rw-r--r-- | samples/ftrace/ftrace-direct-modify.c | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/samples/ftrace/ftrace-direct-modify.c b/samples/ftrace/ftrace-direct-modify.c index 06d889149012..e5ed08098ff3 100644 --- a/samples/ftrace/ftrace-direct-modify.c +++ b/samples/ftrace/ftrace-direct-modify.c @@ -2,7 +2,9 @@ #include <linux/module.h> #include <linux/kthread.h> #include <linux/ftrace.h> +#ifndef CONFIG_ARM64 #include <asm/asm-offsets.h> +#endif extern void my_direct_func1(void); extern void my_direct_func2(void); @@ -96,6 +98,38 @@ asm ( #endif /* CONFIG_S390 */ +#ifdef CONFIG_ARM64 + +asm ( +" .pushsection .text, \"ax\", @progbits\n" +" .type my_tramp1, @function\n" +" .globl my_tramp1\n" +" my_tramp1:" +" bti c\n" +" sub sp, sp, #16\n" +" stp x9, x30, [sp]\n" +" bl my_direct_func1\n" +" ldp x30, x9, [sp]\n" +" add sp, sp, #16\n" +" ret x9\n" +" .size my_tramp1, .-my_tramp1\n" + +" .type my_tramp2, @function\n" +" .globl my_tramp2\n" +" my_tramp2:" +" bti c\n" +" sub sp, sp, #16\n" +" stp x9, x30, [sp]\n" +" bl my_direct_func2\n" +" ldp x30, x9, [sp]\n" +" add sp, sp, #16\n" +" ret x9\n" +" .size my_tramp2, .-my_tramp2\n" +" .popsection\n" +); + +#endif /* CONFIG_ARM64 */ + #ifdef CONFIG_LOONGARCH asm ( |