Changeset 54738 in vbox for trunk/include
- Timestamp:
- Mar 12, 2015 9:04:02 PM (10 years ago)
- Location:
- trunk/include
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/err.h
r54728 r54738 631 631 /** Return to ring-3 to write the MSR there. */ 632 632 #define VINF_CPUM_R3_MSR_WRITE (1759) 633 /** Too may CPUID leaves. */ 634 #define VERR_TOO_MANY_CPUID_LEAVES (1760) 633 635 /** @} */ 634 636 -
trunk/include/VBox/vmm/cpum.h
r54714 r54738 305 305 /** @name CPUMCPUIDLEAF::fFlags 306 306 * @{ */ 307 /** Indicates that ECX (the sub-leaf indicator) doesn't change when 308 * requesting the final leaf and all undefined leaves that follows it. 309 * Observed for 0x0000000b on Intel. */ 310 #define CPUMCPUIDLEAF_F_SUBLEAVES_ECX_UNCHANGED RT_BIT_32(0) 307 /** Indicates working intel leaf 0xb where the lower 8 ECX bits are not modified 308 * and EDX containing the extended APIC ID. */ 309 #define CPUMCPUIDLEAF_F_INTEL_TOPOLOGY_SUBLEAVES RT_BIT_32(0) 310 /** The leaf contains an APIC ID that needs changing to that of the current CPU. */ 311 #define CPUMCPUIDLEAF_F_CONTAINS_APIC_ID RT_BIT_32(1) 312 /** Mask of the valid flags. */ 313 #define CPUMCPUIDLEAF_F_VALID_MASK UINT32_C(0x3) 311 314 /** @} */ 312 315 313 316 /** 314 * Method used to deal with unknown CPUID lea fs.317 * Method used to deal with unknown CPUID leaves. 315 318 * @remarks Used in patch code. 316 319 */ 317 typedef enum CPUMU KNOWNCPUID320 typedef enum CPUMUNKNOWNCPUID 318 321 { 319 322 /** Invalid zero value. */ 320 CPUMU KNOWNCPUID_INVALID = 0,323 CPUMUNKNOWNCPUID_INVALID = 0, 321 324 /** Use given default values (DefCpuId). */ 322 CPUMU KNOWNCPUID_DEFAULTS,325 CPUMUNKNOWNCPUID_DEFAULTS, 323 326 /** Return the last standard leaf. 324 327 * Intel Sandy Bridge has been observed doing this. */ 325 CPUMU KNOWNCPUID_LAST_STD_LEAF,328 CPUMUNKNOWNCPUID_LAST_STD_LEAF, 326 329 /** Return the last standard leaf, with ecx observed. 327 330 * Intel Sandy Bridge has been observed doing this. */ 328 CPUMU KNOWNCPUID_LAST_STD_LEAF_WITH_ECX,331 CPUMUNKNOWNCPUID_LAST_STD_LEAF_WITH_ECX, 329 332 /** The register values are passed thru unmodified. */ 330 CPUMU KNOWNCPUID_PASSTHRU,333 CPUMUNKNOWNCPUID_PASSTHRU, 331 334 /** End of valid value. */ 332 CPUMU KNOWNCPUID_END,335 CPUMUNKNOWNCPUID_END, 333 336 /** Ensure 32-bit type. */ 334 CPUMU KNOWNCPUID_32BIT_HACK = 0x7fffffff335 } CPUMU KNOWNCPUID;337 CPUMUNKNOWNCPUID_32BIT_HACK = 0x7fffffff 338 } CPUMUNKNOWNCPUID; 336 339 /** Pointer to unknown CPUID leaf method. */ 337 typedef CPUMU KNOWNCPUID *PCPUMUKNOWNCPUID;340 typedef CPUMUNKNOWNCPUID *PCPUMUNKNOWNCPUID; 338 341 339 342 … … 923 926 VMMDECL(uint64_t) CPUMGetGuestDR7(PVMCPU pVCpu); 924 927 VMMDECL(int) CPUMGetGuestDRx(PVMCPU pVCpu, uint32_t iReg, uint64_t *pValue); 925 VMMDECL(void) CPUMGetGuestCpuId(PVMCPU pVCpu, uint32_t iLeaf, uint32_t *pEax, uint32_t *pEbx, uint32_t *pEcx, uint32_t *pEdx); 928 VMMDECL(void) CPUMGetGuestCpuId(PVMCPU pVCpu, uint32_t iLeaf, uint32_t iSubLeaf, 929 uint32_t *pEax, uint32_t *pEbx, uint32_t *pEcx, uint32_t *pEdx); 926 930 VMMDECL(uint64_t) CPUMGetGuestEFER(PVMCPU pVCpu); 927 931 VMMDECL(VBOXSTRICTRC) CPUMQueryGuestMsr(PVMCPU pVCpu, uint32_t idMsr, uint64_t *puValue); … … 1268 1272 VMMR3DECL(const char *) CPUMR3MicroarchName(CPUMMICROARCH enmMicroarch); 1269 1273 VMMR3DECL(int) CPUMR3CpuIdCollectLeaves(PCPUMCPUIDLEAF *ppaLeaves, uint32_t *pcLeaves); 1270 VMMR3DECL(int) CPUMR3CpuIdDetectUnknownLeafMethod(PCPUMU KNOWNCPUID penmUnknownMethod, PCPUMCPUID pDefUnknown);1271 VMMR3DECL(const char *) CPUMR3CpuIdUnknownLeafMethodName(CPUMU KNOWNCPUID enmUnknownMethod);1274 VMMR3DECL(int) CPUMR3CpuIdDetectUnknownLeafMethod(PCPUMUNKNOWNCPUID penmUnknownMethod, PCPUMCPUID pDefUnknown); 1275 VMMR3DECL(const char *) CPUMR3CpuIdUnknownLeafMethodName(CPUMUNKNOWNCPUID enmUnknownMethod); 1272 1276 VMMR3DECL(CPUMCPUVENDOR) CPUMR3CpuIdDetectVendorEx(uint32_t uEAX, uint32_t uEBX, uint32_t uECX, uint32_t uEDX); 1273 1277 VMMR3DECL(const char *) CPUMR3CpuVendorName(CPUMCPUVENDOR enmVendor); … … 1281 1285 VMMR3_INT_DECL(RCPTRTYPE(PCCPUMCPUIDLEAF)) CPUMR3GetGuestCpuIdPatmArrayRCPtr(PVM pVM); 1282 1286 VMMR3_INT_DECL(RCPTRTYPE(PCCPUMCPUIDLEAF)) CPUMR3GetGuestCpuIdPatmArrayEndRCPtr(PVM pVM); 1283 VMMR3_INT_DECL(CPUMU KNOWNCPUID) CPUMR3GetGuestCpuIdPatmUnknownLeafMethod(PVM pVM);1287 VMMR3_INT_DECL(CPUMUNKNOWNCPUID) CPUMR3GetGuestCpuIdPatmUnknownLeafMethod(PVM pVM); 1284 1288 /* Legacy: */ 1285 1289 VMMR3_INT_DECL(uint32_t) CPUMR3GetGuestCpuIdPatmStdMax(PVM pVM); -
trunk/include/VBox/vmm/cpum.mac
r54714 r54738 43 43 .fFlags resd 1 44 44 endstruc 45 %define CPUMCPUIDLEAF_F_ SUBLEAVES_ECX_UNCHANGEDRT_BIT_32(0)45 %define CPUMCPUIDLEAF_F_INTEL_TOPOLOGY_SUBLEAVES RT_BIT_32(0) 46 46 47 47 ;; … … 56 56 57 57 58 ;; @name Method used to deal with unknown CPUID lea fs.58 ;; @name Method used to deal with unknown CPUID leaves. 59 59 ;; @{ 60 %define CPUMU KNOWNCPUID_DEFAULTS 161 %define CPUMU KNOWNCPUID_LAST_STD_LEAF 262 %define CPUMU KNOWNCPUID_LAST_STD_LEAF_WITH_ECX 363 %define CPUMU KNOWNCPUID_PASSTHRU 460 %define CPUMUNKNOWNCPUID_DEFAULTS 1 61 %define CPUMUNKNOWNCPUID_LAST_STD_LEAF 2 62 %define CPUMUNKNOWNCPUID_LAST_STD_LEAF_WITH_ECX 3 63 %define CPUMUNKNOWNCPUID_PASSTHRU 4 64 64 ;; @} 65 65 -
trunk/include/iprt/x86.h
r53630 r54738 583 583 /** EBX Bit 29 - SHA - Supports Secure Hash Algorithm extensions. */ 584 584 #define X86_CPUID_STEXT_FEATURE_EBX_SHA RT_BIT(29) 585 586 /** ECX Bit 0 - PREFETCHWT1 - Supports the PREFETCHWT1 instruction. */ 587 #define X86_CPUID_STEXT_FEATURE_ECX_PREFETCHWT1 RT_BIT(0) 585 588 /** @} */ 586 589 … … 654 657 #define X86_CPUID_AMD_FEATURE_EDX_3DNOW RT_BIT(31) 655 658 656 /** Bit 1 - C MPL- Core multi-processing legacy mode. */659 /** Bit 1 - CmpLegacy - Core multi-processing legacy mode. */ 657 660 #define X86_CPUID_AMD_FEATURE_ECX_CMPL RT_BIT(1) 658 661 /** Bit 2 - SVM - AMD VM extensions. */ … … 680 683 /** Bit 13 - WDT - AMD Watchdog timer support. */ 681 684 #define X86_CPUID_AMD_FEATURE_ECX_WDT RT_BIT(13) 682 685 /** Bit 15 - LWP - Lightweight profiling support. */ 686 #define X86_CPUID_AMD_FEATURE_ECX_LWP RT_BIT(15) 687 /** Bit 16 - FMA4 - Four operand FMA instruction support. */ 688 #define X86_CPUID_AMD_FEATURE_ECX_FMA4 RT_BIT(16) 689 /** Bit 19 - NodeId - Indicates support for 690 * MSR_C001_100C[NodeId,NodesPerProcessr]. */ 691 #define X86_CPUID_AMD_FEATURE_ECX_NODEID RT_BIT(19) 692 /** Bit 21 - TBM - Trailing bit manipulation instruction support. */ 693 #define X86_CPUID_AMD_FEATURE_ECX_TBM RT_BIT(21) 694 /** Bit 22 - TopologyExtensions - . */ 695 #define X86_CPUID_AMD_FEATURE_ECX_TOPOEXT RT_BIT(22) 683 696 /** @} */ 684 697 … … 706 719 /** Bit 8 - TSCINVAR - TSC Invariant. */ 707 720 #define X86_CPUID_AMD_ADVPOWER_EDX_TSCINVAR RT_BIT(8) 721 /** Bit 9 - CPB - TSC Invariant. */ 722 #define X86_CPUID_AMD_ADVPOWER_EDX_CPB RT_BIT(9) 723 /** Bit 10 - EffFreqRO - MPERF/APERF. */ 724 #define X86_CPUID_AMD_ADVPOWER_EDX_EFRO RT_BIT(10) 725 /** Bit 11 - PFI - Processor feedback interface (see EAX). */ 726 #define X86_CPUID_AMD_ADVPOWER_EDX_PFI RT_BIT(11) 727 /** Bit 12 - PA - Processor accumulator (MSR c001_007a). */ 728 #define X86_CPUID_AMD_ADVPOWER_EDX_PA RT_BIT(12) 708 729 /** @} */ 709 730
Note:
See TracChangeset
for help on using the changeset viewer.