Add missing setting of hv_base to the leaf that we used.

Correct setting hv_high to use regs[0], not leaf.
This commit is contained in:
Stephen J. Kiernan 2019-05-19 15:07:14 +00:00
parent d49fb289c8
commit c5c8916278
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=347972

View File

@ -1382,7 +1382,8 @@ identify_hypervisor_cpuid_base(void)
* and vendor identifier.
*/
if (vm_guest != VM_GUEST_VM || leaf == 0x40000000) {
hv_high = leaf;
hv_base = leaf;
hv_high = regs[0];
((u_int *)&hv_vendor)[0] = regs[1];
((u_int *)&hv_vendor)[1] = regs[2];
((u_int *)&hv_vendor)[2] = regs[3];