From: Juergen Gross <jgross@suse.com>
Date: Wed, 26 Oct 2022 16:29:29 +0200
Subject: [PATCH] kABI: Fix kABI after backport Emulate RDPID only if it
is enabled in guest
Patch-mainline: Never, kABI fix
References: git-fixes
Signed-off-by: Juergen Gross <jgross@suse.com>
---
arch/x86/kvm/kvm_emulate.h | 4 +++-
1 file changed, 3 insertion(+), 1 deletion(-)
diff --git a/arch/x86/kvm/kvm_emulate.h b/arch/x86/kvm/kvm_emulate.h
--- a/arch/x86/kvm/kvm_emulate.h
+++ b/arch/x86/kvm/kvm_emulate.h
@@ -226,7 +226,6 @@ struct x86_emulate_ops {
bool (*guest_has_long_mode)(struct x86_emulate_ctxt *ctxt);
bool (*guest_has_movbe)(struct x86_emulate_ctxt *ctxt);
bool (*guest_has_fxsr)(struct x86_emulate_ctxt *ctxt);
- bool (*guest_has_rdpid)(struct x86_emulate_ctxt *ctxt);
void (*set_nmi_mask)(struct x86_emulate_ctxt *ctxt, bool masked);
@@ -235,6 +234,9 @@ struct x86_emulate_ops {
int (*leave_smm)(struct x86_emulate_ctxt *ctxt, const char *smstate);
void (*triple_fault)(struct x86_emulate_ctxt *ctxt);
int (*set_xcr)(struct x86_emulate_ctxt *ctxt, u32 index, u64 xcr);
+#ifndef __GENKSYMS__
+ bool (*guest_has_rdpid)(struct x86_emulate_ctxt *ctxt);
+#endif
};
/* Type, address-of, and value of an instruction's operand. */