diff options
author | Avi Kivity <avi@redhat.com> | 2012-06-07 15:10:16 +0400 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2012-07-09 15:19:00 +0400 |
commit | 0017f93a2776597b798ec1a9594e41dfd96d3c11 (patch) | |
tree | ef0a1e1a409f6d9a5d48894b0256a723c1b1183b /arch/x86/include/asm/kvm_emulate.h | |
parent | 62046e5a867cbff35e0beff42718dda41ff5d74b (diff) | |
download | linux-0017f93a2776597b798ec1a9594e41dfd96d3c11.tar.xz |
KVM: x86 emulator: change ->get_cpuid() accessor to use the x86 semantics
Instead of getting an exact leaf, follow the spec and fall back to the last
main leaf instead. This lets us easily emulate the cpuid instruction in the
emulator.
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/x86/include/asm/kvm_emulate.h')
-rw-r--r-- | arch/x86/include/asm/kvm_emulate.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/x86/include/asm/kvm_emulate.h b/arch/x86/include/asm/kvm_emulate.h index 1ac46c22dd50..cd5c96b2496e 100644 --- a/arch/x86/include/asm/kvm_emulate.h +++ b/arch/x86/include/asm/kvm_emulate.h @@ -192,8 +192,8 @@ struct x86_emulate_ops { struct x86_instruction_info *info, enum x86_intercept_stage stage); - bool (*get_cpuid)(struct x86_emulate_ctxt *ctxt, - u32 *eax, u32 *ebx, u32 *ecx, u32 *edx); + void (*get_cpuid)(struct x86_emulate_ctxt *ctxt, + u32 *eax, u32 *ebx, u32 *ecx, u32 *edx); }; typedef u32 __attribute__((vector_size(16))) sse128_t; |