The routine kvm_spurious_fault() is a common kvm routine, so move its declaration from arch/x86/include/asm/kvm_host.h to arch/arm/include/asm/kvm_host.h. Fixes sparse warning when building on arm64: virt/kvm/kvm_main.c:warning: symbol 'kvm_spurious_fault' was not declared. Should it be static? Signed-off-by: Geoff Levand <geoff@xxxxxxxxxxxxx> --- arch/x86/include/asm/kvm_host.h | 6 ------ include/linux/kvm_host.h | 7 +++++++ 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h index 40fc39f..da7c126 100644 --- a/arch/x86/include/asm/kvm_host.h +++ b/arch/x86/include/asm/kvm_host.h @@ -964,12 +964,6 @@ enum { #define HF_IRET_MASK (1 << 4) #define HF_GUEST_MASK (1 << 5) /* VCPU is in guest-mode */ -/* - * Hardware virtualization extension instructions may fault if a - * reboot turns off virtualization while processes are running. - * Trap the fault and ignore the instruction if that happens. - */ -asmlinkage void kvm_spurious_fault(void); extern bool kvm_rebooting; #define ____kvm_handle_fault_on_reboot(insn, cleanup_insn) \ diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index 8ef2212..4bfb062 100644 --- a/include/linux/kvm_host.h +++ b/include/linux/kvm_host.h @@ -1031,6 +1031,13 @@ static inline bool kvm_check_request(int req, struct kvm_vcpu *vcpu) } } +/* + * Hardware virtualization extension instructions may fault if a + * reboot turns off virtualization while processes are running. + * Trap the fault and ignore the instruction if that happens. + */ +asmlinkage void kvm_spurious_fault(void); + #ifdef CONFIG_HAVE_KVM_CPU_RELAX_INTERCEPT static inline void kvm_vcpu_set_in_spin_loop(struct kvm_vcpu *vcpu, bool val) -- 1.7.9.5 -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html