From: Heiko Carstens Date: Fri, 1 Oct 2021 12:21:43 +0000 (+0200) Subject: s390/ftrace: use text_poke_sync_lock() X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=ae2b9a11b494a9ec59d7dc11d42654d659f859c6;p=linux.git s390/ftrace: use text_poke_sync_lock() Signed-off-by: Heiko Carstens Signed-off-by: Vasily Gorbik --- diff --git a/arch/s390/kernel/ftrace.c b/arch/s390/kernel/ftrace.c index 5d0c45c13b5fa..04a3e88c58d75 100644 --- a/arch/s390/kernel/ftrace.c +++ b/arch/s390/kernel/ftrace.c @@ -17,6 +17,7 @@ #include #include #include +#include #include #include #include @@ -207,14 +208,13 @@ void arch_ftrace_update_code(int command) ftrace_modify_all_code(command); } -static void __ftrace_sync(void *dummy) -{ -} - int ftrace_arch_code_modify_post_process(void) { - /* Send SIGP to the other CPUs, so they see the new code. */ - smp_call_function(__ftrace_sync, NULL, 1); + /* + * Flush any pre-fetched instructions on all + * CPUs to make the new code visible. + */ + text_poke_sync_lock(); return 0; }