powerpc: Move patch sites out of asm-prototypes.h
authorMichael Ellerman <mpe@ellerman.id.au>
Thu, 18 Aug 2022 05:06:59 +0000 (15:06 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Fri, 26 Aug 2022 01:02:20 +0000 (11:02 +1000)
The definitions for the patch sites etc. don't belong in
asm-prototypes.h, they are not EXPORT'ed asm symbols.

Move them into sections.h which is traditionally used for asm symbols.

Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20220818050659.187181-1-mpe@ellerman.id.au
arch/powerpc/include/asm/asm-prototypes.h
arch/powerpc/include/asm/sections.h
arch/powerpc/kernel/security.c

index 81631e64dbeb7135463fbaf86fefee442dc3ed74..e1b3e90eec94600bbf6fdc19aae886b5495a3d4f 100644 (file)
@@ -55,19 +55,6 @@ struct kvm_vcpu;
 void _kvmppc_restore_tm_pr(struct kvm_vcpu *vcpu, u64 guest_msr);
 void _kvmppc_save_tm_pr(struct kvm_vcpu *vcpu, u64 guest_msr);
 
-/* Patch sites */
-extern s32 patch__call_flush_branch_caches1;
-extern s32 patch__call_flush_branch_caches2;
-extern s32 patch__call_flush_branch_caches3;
-extern s32 patch__flush_count_cache_return;
-extern s32 patch__flush_link_stack_return;
-extern s32 patch__call_kvm_flush_link_stack;
-extern s32 patch__call_kvm_flush_link_stack_p9;
-extern s32 patch__memset_nocache, patch__memcpy_nocache;
-
-extern long flush_branch_caches;
-extern long kvm_flush_link_stack;
-
 #ifdef CONFIG_PPC_TRANSACTIONAL_MEM
 void kvmppc_save_tm_hv(struct kvm_vcpu *vcpu, u64 msr, bool preserve_nv);
 void kvmppc_restore_tm_hv(struct kvm_vcpu *vcpu, u64 msr, bool preserve_nv);
index 8be2c491c73319526549baf1a2cb32611f9448bc..183e6b8af392dcc3daf79538a64ca55d230685dd 100644 (file)
@@ -14,6 +14,19 @@ typedef struct func_desc func_desc_t;
 
 extern char __head_end[];
 
+/* Patch sites */
+extern s32 patch__call_flush_branch_caches1;
+extern s32 patch__call_flush_branch_caches2;
+extern s32 patch__call_flush_branch_caches3;
+extern s32 patch__flush_count_cache_return;
+extern s32 patch__flush_link_stack_return;
+extern s32 patch__call_kvm_flush_link_stack;
+extern s32 patch__call_kvm_flush_link_stack_p9;
+extern s32 patch__memset_nocache, patch__memcpy_nocache;
+
+extern long flush_branch_caches;
+extern long kvm_flush_link_stack;
+
 #ifdef __powerpc64__
 
 extern char __start_interrupts[];
index d96fd14bd7c9c614036f758b466502bb4d84b0aa..b562a1d2c7500700b04e2ca530512c6ece82ac6f 100644 (file)
@@ -16,6 +16,7 @@
 #include <asm/asm-prototypes.h>
 #include <asm/code-patching.h>
 #include <asm/security_features.h>
+#include <asm/sections.h>
 #include <asm/setup.h>
 #include <asm/inst.h>