- Timestamp:
- Feb 23, 2012 2:48:24 PM (13 years ago)
- Location:
- trunk/src/VBox/VMM
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMAll/CPUMAllRegs.cpp
r40170 r40234 1455 1455 if (iLeaf < RT_ELEMENTS(pVM->cpum.s.aGuestCpuIdStd)) 1456 1456 pCpuId = &pVM->cpum.s.aGuestCpuIdStd[iLeaf]; 1457 else if (iLeaf - UINT32_C(0x40000000) < RT_ELEMENTS(pVM->cpum.s.aGuestCpuIdHyper)) 1458 if ((pVCpu->CTX_SUFF(pVM)->cpum.s.aGuestCpuIdStd[1].ecx & X86_CPUID_FEATURE_ECX_HVP) != 0) 1459 pCpuId = &pVM->cpum.s.aGuestCpuIdHyper[iLeaf - UINT32_C(0x40000000)]; /* Only report if HVP bit set. */ 1457 1460 else if (iLeaf - UINT32_C(0x80000000) < RT_ELEMENTS(pVM->cpum.s.aGuestCpuIdExt)) 1458 1461 pCpuId = &pVM->cpum.s.aGuestCpuIdExt[iLeaf - UINT32_C(0x80000000)]; … … 1884 1887 1885 1888 case CPUMCPUIDFEATURE_HVP: 1886 if (pVM->cpum.s.aGuestCpuId Ext[0].eax >= 1)1887 pVM->cpum.s.aGuestCpuId Ext[1].ecx &= ~X86_CPUID_FEATURE_ECX_HVP;1889 if (pVM->cpum.s.aGuestCpuIdStd[0].eax >= 1) 1890 pVM->cpum.s.aGuestCpuIdStd[1].ecx &= ~X86_CPUID_FEATURE_ECX_HVP; 1888 1891 break; 1889 1892 -
trunk/src/VBox/VMM/VMMR3/CPUM.cpp
r40170 r40234 906 906 pCPUM->aGuestCpuIdCentaur[i] = pCPUM->GuestCpuIdDef; 907 907 908 /* 909 * Hypervisor identification. 910 * 911 * We only return minimal information, primarily ensuring that the 912 * 0x40000000 function returns 0x40000001 and identifying ourselves. 913 * Currently we do not support any hypervisor-specific interface. 914 */ 915 pCPUM->aGuestCpuIdHyper[0].eax = UINT32_C(0x40000001); 916 pCPUM->aGuestCpuIdHyper[0].ebx = pCPUM->aGuestCpuIdHyper[0].ecx 917 = pCPUM->aGuestCpuIdHyper[0].edx = 0x786f4256; /* 'VBox' */ 918 pCPUM->aGuestCpuIdHyper[1].eax = 0x656e6f6e; /* 'none' */ 919 pCPUM->aGuestCpuIdHyper[1].ebx = pCPUM->aGuestCpuIdHyper[1].ecx 920 = pCPUM->aGuestCpuIdHyper[1].edx = 0; /* Reserved */ 908 921 909 922 /* … … 1553 1566 CPUID_RAW_FEATURE_RET(Std, ecx, RT_BIT_32(29) /*reserved*/); 1554 1567 CPUID_RAW_FEATURE_RET(Std, ecx, RT_BIT_32(30) /*reserved*/); 1555 CPUID_RAW_FEATURE_RET(Std, ecx, RT_BIT_32(31) /*reserved*/);1568 CPUID_RAW_FEATURE_RET(Std, ecx, X86_CPUID_FEATURE_ECX_HVP); 1556 1569 1557 1570 /* CPUID(1).edx */ … … 1759 1772 CPUID_GST_FEATURE_RET(Std, ecx, RT_BIT_32(29) /*reserved*/); 1760 1773 CPUID_GST_FEATURE_RET(Std, ecx, RT_BIT_32(30) /*reserved*/); 1761 CPUID_GST_FEATURE_ RET(Std, ecx, RT_BIT_32(31) /*reserved*/);1774 CPUID_GST_FEATURE_IGN(Std, ecx, X86_CPUID_FEATURE_ECX_HVP); // Normally not set by host 1762 1775 1763 1776 /* CPUID(1).edx */ -
trunk/src/VBox/VMM/include/CPUMInternal.h
r40170 r40234 303 303 uint8_t abPadding[HC_ARCH_BITS == 64 ? 5 : 1]; 304 304 305 /** The standard set of CpuId lea fs. */305 /** The standard set of CpuId leaves. */ 306 306 CPUMCPUID aGuestCpuIdStd[6]; 307 /** The extended set of CpuId lea fs. */307 /** The extended set of CpuId leaves. */ 308 308 CPUMCPUID aGuestCpuIdExt[10]; 309 /** The centaur set of CpuId lea fs. */309 /** The centaur set of CpuId leaves. */ 310 310 CPUMCPUID aGuestCpuIdCentaur[4]; 311 /** The default set of CpuId leafs. */ 311 /** The hypervisor specific set of CpuId leaves. */ 312 CPUMCPUID aGuestCpuIdHyper[4]; 313 /** The default set of CpuId leaves. */ 312 314 CPUMCPUID GuestCpuIdDef; 313 315 -
trunk/src/VBox/VMM/include/CPUMInternal.mac
r40170 r40234 80 80 .aGuestCpuIdExt resb 16*10 81 81 .aGuestCpuIdCentaur resb 16*4 82 .aGuestCpuIdHyper resb 16*4 82 83 .GuestCpuIdDef resb 16 83 84
Note:
See TracChangeset
for help on using the changeset viewer.