mirror of
https://github.com/Motorhead1991/qemu.git
synced 2026-03-12 05:45:59 -06:00
i386/cpuid: Decrease cpuid_i when skipping CPUID leaf 1F
Existing code misses a decrement of cpuid_i when skip leaf 0x1F.
There's a blank CPUID entry(with leaf, subleaf as 0, and all fields
stuffed 0s) left in the CPUID array.
It conflicts with correct CPUID leaf 0.
Signed-off-by: Xiaoyao Li <xiaoyao.li@intel.com>
Reviewed-by:Yang Weijiang <weijiang.yang@intel.com>
Message-ID: <20240125024016.2521244-2-xiaoyao.li@intel.com>
Cc: qemu-stable@nongnu.org
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
(cherry picked from commit 10f92799af)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
This commit is contained in:
parent
72c4ef9da0
commit
e8d27721cb
1 changed files with 1 additions and 0 deletions
|
|
@ -1914,6 +1914,7 @@ int kvm_arch_init_vcpu(CPUState *cs)
|
|||
}
|
||||
case 0x1f:
|
||||
if (env->nr_dies < 2) {
|
||||
cpuid_i--;
|
||||
break;
|
||||
}
|
||||
/* fallthrough */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue