VirtualBox

Changeset 76200 in vbox for trunk/include


Ignore:
Timestamp:
Dec 13, 2018 9:23:47 AM (6 years ago)
Author:
vboxsync
Message:

VMM: Nested VMX: bugref:9180 Initialize VMX guest-MSRs from the exploded and merged VMX guest-CPU features and store them in CPUMCTX like all other relevant MSRs.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/VBox/vmm/cpum.h

    r75830 r76200  
    12991299/** @name Guest Register Getters.
    13001300 * @{ */
    1301 VMMDECL(void)       CPUMGetGuestGDTR(PVMCPU pVCpu, PVBOXGDTR pGDTR);
    1302 VMMDECL(RTGCPTR)    CPUMGetGuestIDTR(PVMCPU pVCpu, uint16_t *pcbLimit);
    1303 VMMDECL(RTSEL)      CPUMGetGuestTR(PVMCPU pVCpu, PCPUMSELREGHID pHidden);
    1304 VMMDECL(RTSEL)      CPUMGetGuestLDTR(PVMCPU pVCpu);
    1305 VMMDECL(RTSEL)      CPUMGetGuestLdtrEx(PVMCPU pVCpu, uint64_t *pGCPtrBase, uint32_t *pcbLimit);
    1306 VMMDECL(uint64_t)   CPUMGetGuestCR0(PVMCPU pVCpu);
    1307 VMMDECL(uint64_t)   CPUMGetGuestCR2(PVMCPU pVCpu);
    1308 VMMDECL(uint64_t)   CPUMGetGuestCR3(PVMCPU pVCpu);
    1309 VMMDECL(uint64_t)   CPUMGetGuestCR4(PVMCPU pVCpu);
    1310 VMMDECL(uint64_t)   CPUMGetGuestCR8(PVMCPU pVCpu);
    1311 VMMDECL(int)        CPUMGetGuestCRx(PVMCPU pVCpu, unsigned iReg, uint64_t *pValue);
    1312 VMMDECL(uint32_t)   CPUMGetGuestEFlags(PVMCPU pVCpu);
    1313 VMMDECL(uint32_t)   CPUMGetGuestEIP(PVMCPU pVCpu);
    1314 VMMDECL(uint64_t)   CPUMGetGuestRIP(PVMCPU pVCpu);
    1315 VMMDECL(uint32_t)   CPUMGetGuestEAX(PVMCPU pVCpu);
    1316 VMMDECL(uint32_t)   CPUMGetGuestEBX(PVMCPU pVCpu);
    1317 VMMDECL(uint32_t)   CPUMGetGuestECX(PVMCPU pVCpu);
    1318 VMMDECL(uint32_t)   CPUMGetGuestEDX(PVMCPU pVCpu);
    1319 VMMDECL(uint32_t)   CPUMGetGuestESI(PVMCPU pVCpu);
    1320 VMMDECL(uint32_t)   CPUMGetGuestEDI(PVMCPU pVCpu);
    1321 VMMDECL(uint32_t)   CPUMGetGuestESP(PVMCPU pVCpu);
    1322 VMMDECL(uint32_t)   CPUMGetGuestEBP(PVMCPU pVCpu);
    1323 VMMDECL(RTSEL)      CPUMGetGuestCS(PVMCPU pVCpu);
    1324 VMMDECL(RTSEL)      CPUMGetGuestDS(PVMCPU pVCpu);
    1325 VMMDECL(RTSEL)      CPUMGetGuestES(PVMCPU pVCpu);
    1326 VMMDECL(RTSEL)      CPUMGetGuestFS(PVMCPU pVCpu);
    1327 VMMDECL(RTSEL)      CPUMGetGuestGS(PVMCPU pVCpu);
    1328 VMMDECL(RTSEL)      CPUMGetGuestSS(PVMCPU pVCpu);
    1329 VMMDECL(uint64_t)   CPUMGetGuestFlatPC(PVMCPU pVCpu);
    1330 VMMDECL(uint64_t)   CPUMGetGuestFlatSP(PVMCPU pVCpu);
    1331 VMMDECL(uint64_t)   CPUMGetGuestDR0(PVMCPU pVCpu);
    1332 VMMDECL(uint64_t)   CPUMGetGuestDR1(PVMCPU pVCpu);
    1333 VMMDECL(uint64_t)   CPUMGetGuestDR2(PVMCPU pVCpu);
    1334 VMMDECL(uint64_t)   CPUMGetGuestDR3(PVMCPU pVCpu);
    1335 VMMDECL(uint64_t)   CPUMGetGuestDR6(PVMCPU pVCpu);
    1336 VMMDECL(uint64_t)   CPUMGetGuestDR7(PVMCPU pVCpu);
    1337 VMMDECL(int)        CPUMGetGuestDRx(PVMCPU pVCpu, uint32_t iReg, uint64_t *pValue);
    1338 VMMDECL(void)       CPUMGetGuestCpuId(PVMCPU pVCpu, uint32_t iLeaf, uint32_t iSubLeaf,
    1339                                       uint32_t *pEax, uint32_t *pEbx, uint32_t *pEcx, uint32_t *pEdx);
    1340 VMMDECL(uint64_t)   CPUMGetGuestEFER(PVMCPU pVCpu);
     1301VMMDECL(void)           CPUMGetGuestGDTR(PVMCPU pVCpu, PVBOXGDTR pGDTR);
     1302VMMDECL(RTGCPTR)        CPUMGetGuestIDTR(PVMCPU pVCpu, uint16_t *pcbLimit);
     1303VMMDECL(RTSEL)          CPUMGetGuestTR(PVMCPU pVCpu, PCPUMSELREGHID pHidden);
     1304VMMDECL(RTSEL)          CPUMGetGuestLDTR(PVMCPU pVCpu);
     1305VMMDECL(RTSEL)          CPUMGetGuestLdtrEx(PVMCPU pVCpu, uint64_t *pGCPtrBase, uint32_t *pcbLimit);
     1306VMMDECL(uint64_t)       CPUMGetGuestCR0(PVMCPU pVCpu);
     1307VMMDECL(uint64_t)       CPUMGetGuestCR2(PVMCPU pVCpu);
     1308VMMDECL(uint64_t)       CPUMGetGuestCR3(PVMCPU pVCpu);
     1309VMMDECL(uint64_t)       CPUMGetGuestCR4(PVMCPU pVCpu);
     1310VMMDECL(uint64_t)       CPUMGetGuestCR8(PVMCPU pVCpu);
     1311VMMDECL(int)            CPUMGetGuestCRx(PVMCPU pVCpu, unsigned iReg, uint64_t *pValue);
     1312VMMDECL(uint32_t)       CPUMGetGuestEFlags(PVMCPU pVCpu);
     1313VMMDECL(uint32_t)       CPUMGetGuestEIP(PVMCPU pVCpu);
     1314VMMDECL(uint64_t)       CPUMGetGuestRIP(PVMCPU pVCpu);
     1315VMMDECL(uint32_t)       CPUMGetGuestEAX(PVMCPU pVCpu);
     1316VMMDECL(uint32_t)       CPUMGetGuestEBX(PVMCPU pVCpu);
     1317VMMDECL(uint32_t)       CPUMGetGuestECX(PVMCPU pVCpu);
     1318VMMDECL(uint32_t)       CPUMGetGuestEDX(PVMCPU pVCpu);
     1319VMMDECL(uint32_t)       CPUMGetGuestESI(PVMCPU pVCpu);
     1320VMMDECL(uint32_t)       CPUMGetGuestEDI(PVMCPU pVCpu);
     1321VMMDECL(uint32_t)       CPUMGetGuestESP(PVMCPU pVCpu);
     1322VMMDECL(uint32_t)       CPUMGetGuestEBP(PVMCPU pVCpu);
     1323VMMDECL(RTSEL)          CPUMGetGuestCS(PVMCPU pVCpu);
     1324VMMDECL(RTSEL)          CPUMGetGuestDS(PVMCPU pVCpu);
     1325VMMDECL(RTSEL)          CPUMGetGuestES(PVMCPU pVCpu);
     1326VMMDECL(RTSEL)          CPUMGetGuestFS(PVMCPU pVCpu);
     1327VMMDECL(RTSEL)          CPUMGetGuestGS(PVMCPU pVCpu);
     1328VMMDECL(RTSEL)          CPUMGetGuestSS(PVMCPU pVCpu);
     1329VMMDECL(uint64_t)       CPUMGetGuestFlatPC(PVMCPU pVCpu);
     1330VMMDECL(uint64_t)       CPUMGetGuestFlatSP(PVMCPU pVCpu);
     1331VMMDECL(uint64_t)       CPUMGetGuestDR0(PVMCPU pVCpu);
     1332VMMDECL(uint64_t)       CPUMGetGuestDR1(PVMCPU pVCpu);
     1333VMMDECL(uint64_t)       CPUMGetGuestDR2(PVMCPU pVCpu);
     1334VMMDECL(uint64_t)       CPUMGetGuestDR3(PVMCPU pVCpu);
     1335VMMDECL(uint64_t)       CPUMGetGuestDR6(PVMCPU pVCpu);
     1336VMMDECL(uint64_t)       CPUMGetGuestDR7(PVMCPU pVCpu);
     1337VMMDECL(int)            CPUMGetGuestDRx(PVMCPU pVCpu, uint32_t iReg, uint64_t *pValue);
     1338VMMDECL(void)           CPUMGetGuestCpuId(PVMCPU pVCpu, uint32_t iLeaf, uint32_t iSubLeaf,
     1339                                          uint32_t *pEax, uint32_t *pEbx, uint32_t *pEcx, uint32_t *pEdx);
     1340VMMDECL(uint64_t)       CPUMGetGuestEFER(PVMCPU pVCpu);
    13411341VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32MtrrCap(PVMCPU pVCpu);
    1342 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32FeatureControl(PVMCPU pVCpu);
    1343 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxBasic(PVMCPU pVCpu);
    1344 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxPinbasedCtls(PVMCPU pVCpu);
    1345 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxProcbasedCtls(PVMCPU pVCpu);
    1346 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxProcbasedCtls2(PVMCPU pVCpu);
    1347 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxExitCtls(PVMCPU pVCpu);
    1348 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxEntryCtls(PVMCPU pVCpu);
    1349 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxMisc(PVMCPU pVCpu);
    1350 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxCr0Fixed0(PVMCPU pVCpu);
    1351 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxCr0Fixed1(PVMCPU pVCpu);
    1352 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxCr4Fixed0(PVMCPU pVCpu);
    1353 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxCr4Fixed1(PVMCPU pVCpu);
    1354 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxVmcsEnum(PVMCPU pVCpu);
    1355 VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32VmxVmFunc(PVMCPU pVCpu);
    13561342VMM_INT_DECL(uint64_t)  CPUMGetGuestIa32SmmMonitorCtl(PVMCPU pVCpu);
    13571343VMMDECL(VBOXSTRICTRC)   CPUMQueryGuestMsr(PVMCPU pVCpu, uint32_t idMsr, uint64_t *puValue);
     
    13631349/** @name Guest Register Setters.
    13641350 * @{ */
    1365 VMMDECL(int)        CPUMSetGuestGDTR(PVMCPU pVCpu, uint64_t GCPtrBase, uint16_t cbLimit);
    1366 VMMDECL(int)        CPUMSetGuestIDTR(PVMCPU pVCpu, uint64_t GCPtrBase, uint16_t cbLimit);
    1367 VMMDECL(int)        CPUMSetGuestTR(PVMCPU pVCpu, uint16_t tr);
    1368 VMMDECL(int)        CPUMSetGuestLDTR(PVMCPU pVCpu, uint16_t ldtr);
    1369 VMMDECL(int)        CPUMSetGuestCR0(PVMCPU pVCpu, uint64_t cr0);
    1370 VMMDECL(int)        CPUMSetGuestCR2(PVMCPU pVCpu, uint64_t cr2);
    1371 VMMDECL(int)        CPUMSetGuestCR3(PVMCPU pVCpu, uint64_t cr3);
    1372 VMMDECL(int)        CPUMSetGuestCR4(PVMCPU pVCpu, uint64_t cr4);
    1373 VMMDECL(int)        CPUMSetGuestDR0(PVMCPU pVCpu, uint64_t uDr0);
    1374 VMMDECL(int)        CPUMSetGuestDR1(PVMCPU pVCpu, uint64_t uDr1);
    1375 VMMDECL(int)        CPUMSetGuestDR2(PVMCPU pVCpu, uint64_t uDr2);
    1376 VMMDECL(int)        CPUMSetGuestDR3(PVMCPU pVCpu, uint64_t uDr3);
    1377 VMMDECL(int)        CPUMSetGuestDR6(PVMCPU pVCpu, uint64_t uDr6);
    1378 VMMDECL(int)        CPUMSetGuestDR7(PVMCPU pVCpu, uint64_t uDr7);
    1379 VMMDECL(int)        CPUMSetGuestDRx(PVMCPU pVCpu, uint32_t iReg, uint64_t Value);
    1380 VMM_INT_DECL(int)   CPUMSetGuestXcr0(PVMCPU pVCpu, uint64_t uNewValue);
    1381 VMMDECL(int)        CPUMSetGuestEFlags(PVMCPU pVCpu, uint32_t eflags);
    1382 VMMDECL(int)        CPUMSetGuestEIP(PVMCPU pVCpu, uint32_t eip);
    1383 VMMDECL(int)        CPUMSetGuestEAX(PVMCPU pVCpu, uint32_t eax);
    1384 VMMDECL(int)        CPUMSetGuestEBX(PVMCPU pVCpu, uint32_t ebx);
    1385 VMMDECL(int)        CPUMSetGuestECX(PVMCPU pVCpu, uint32_t ecx);
    1386 VMMDECL(int)        CPUMSetGuestEDX(PVMCPU pVCpu, uint32_t edx);
    1387 VMMDECL(int)        CPUMSetGuestESI(PVMCPU pVCpu, uint32_t esi);
    1388 VMMDECL(int)        CPUMSetGuestEDI(PVMCPU pVCpu, uint32_t edi);
    1389 VMMDECL(int)        CPUMSetGuestESP(PVMCPU pVCpu, uint32_t esp);
    1390 VMMDECL(int)        CPUMSetGuestEBP(PVMCPU pVCpu, uint32_t ebp);
    1391 VMMDECL(int)        CPUMSetGuestCS(PVMCPU pVCpu, uint16_t cs);
    1392 VMMDECL(int)        CPUMSetGuestDS(PVMCPU pVCpu, uint16_t ds);
    1393 VMMDECL(int)        CPUMSetGuestES(PVMCPU pVCpu, uint16_t es);
    1394 VMMDECL(int)        CPUMSetGuestFS(PVMCPU pVCpu, uint16_t fs);
    1395 VMMDECL(int)        CPUMSetGuestGS(PVMCPU pVCpu, uint16_t gs);
    1396 VMMDECL(int)        CPUMSetGuestSS(PVMCPU pVCpu, uint16_t ss);
    1397 VMMDECL(void)       CPUMSetGuestEFER(PVMCPU pVCpu, uint64_t val);
    1398 VMMR3_INT_DECL(void) CPUMR3SetGuestCpuIdFeature(PVM pVM, CPUMCPUIDFEATURE enmFeature);
    1399 VMMR3_INT_DECL(void) CPUMR3ClearGuestCpuIdFeature(PVM pVM, CPUMCPUIDFEATURE enmFeature);
    1400 VMMR3_INT_DECL(bool) CPUMR3GetGuestCpuIdFeature(PVM pVM, CPUMCPUIDFEATURE enmFeature);
    1401 VMMDECL(bool)       CPUMSetGuestCpuIdPerCpuApicFeature(PVMCPU pVCpu, bool fVisible);
    1402 VMMDECL(void)       CPUMSetGuestCtx(PVMCPU pVCpu, const PCPUMCTX pCtx);
    1403 VMM_INT_DECL(void)  CPUMGuestLazyLoadHiddenCsAndSs(PVMCPU pVCpu);
    1404 VMM_INT_DECL(void)  CPUMGuestLazyLoadHiddenSelectorReg(PVMCPU pVCpu, PCPUMSELREG pSReg);
     1351VMMDECL(int)           CPUMSetGuestGDTR(PVMCPU pVCpu, uint64_t GCPtrBase, uint16_t cbLimit);
     1352VMMDECL(int)           CPUMSetGuestIDTR(PVMCPU pVCpu, uint64_t GCPtrBase, uint16_t cbLimit);
     1353VMMDECL(int)           CPUMSetGuestTR(PVMCPU pVCpu, uint16_t tr);
     1354VMMDECL(int)           CPUMSetGuestLDTR(PVMCPU pVCpu, uint16_t ldtr);
     1355VMMDECL(int)           CPUMSetGuestCR0(PVMCPU pVCpu, uint64_t cr0);
     1356VMMDECL(int)           CPUMSetGuestCR2(PVMCPU pVCpu, uint64_t cr2);
     1357VMMDECL(int)           CPUMSetGuestCR3(PVMCPU pVCpu, uint64_t cr3);
     1358VMMDECL(int)           CPUMSetGuestCR4(PVMCPU pVCpu, uint64_t cr4);
     1359VMMDECL(int)           CPUMSetGuestDR0(PVMCPU pVCpu, uint64_t uDr0);
     1360VMMDECL(int)           CPUMSetGuestDR1(PVMCPU pVCpu, uint64_t uDr1);
     1361VMMDECL(int)           CPUMSetGuestDR2(PVMCPU pVCpu, uint64_t uDr2);
     1362VMMDECL(int)           CPUMSetGuestDR3(PVMCPU pVCpu, uint64_t uDr3);
     1363VMMDECL(int)           CPUMSetGuestDR6(PVMCPU pVCpu, uint64_t uDr6);
     1364VMMDECL(int)           CPUMSetGuestDR7(PVMCPU pVCpu, uint64_t uDr7);
     1365VMMDECL(int)           CPUMSetGuestDRx(PVMCPU pVCpu, uint32_t iReg, uint64_t Value);
     1366VMM_INT_DECL(int)      CPUMSetGuestXcr0(PVMCPU pVCpu, uint64_t uNewValue);
     1367VMMDECL(int)           CPUMSetGuestEFlags(PVMCPU pVCpu, uint32_t eflags);
     1368VMMDECL(int)           CPUMSetGuestEIP(PVMCPU pVCpu, uint32_t eip);
     1369VMMDECL(int)           CPUMSetGuestEAX(PVMCPU pVCpu, uint32_t eax);
     1370VMMDECL(int)           CPUMSetGuestEBX(PVMCPU pVCpu, uint32_t ebx);
     1371VMMDECL(int)           CPUMSetGuestECX(PVMCPU pVCpu, uint32_t ecx);
     1372VMMDECL(int)           CPUMSetGuestEDX(PVMCPU pVCpu, uint32_t edx);
     1373VMMDECL(int)           CPUMSetGuestESI(PVMCPU pVCpu, uint32_t esi);
     1374VMMDECL(int)           CPUMSetGuestEDI(PVMCPU pVCpu, uint32_t edi);
     1375VMMDECL(int)           CPUMSetGuestESP(PVMCPU pVCpu, uint32_t esp);
     1376VMMDECL(int)           CPUMSetGuestEBP(PVMCPU pVCpu, uint32_t ebp);
     1377VMMDECL(int)           CPUMSetGuestCS(PVMCPU pVCpu, uint16_t cs);
     1378VMMDECL(int)           CPUMSetGuestDS(PVMCPU pVCpu, uint16_t ds);
     1379VMMDECL(int)           CPUMSetGuestES(PVMCPU pVCpu, uint16_t es);
     1380VMMDECL(int)           CPUMSetGuestFS(PVMCPU pVCpu, uint16_t fs);
     1381VMMDECL(int)           CPUMSetGuestGS(PVMCPU pVCpu, uint16_t gs);
     1382VMMDECL(int)           CPUMSetGuestSS(PVMCPU pVCpu, uint16_t ss);
     1383VMMDECL(void)          CPUMSetGuestEFER(PVMCPU pVCpu, uint64_t val);
     1384VMMR3_INT_DECL(void)   CPUMR3SetGuestCpuIdFeature(PVM pVM, CPUMCPUIDFEATURE enmFeature);
     1385VMMR3_INT_DECL(void)   CPUMR3ClearGuestCpuIdFeature(PVM pVM, CPUMCPUIDFEATURE enmFeature);
     1386VMMR3_INT_DECL(bool)   CPUMR3GetGuestCpuIdFeature(PVM pVM, CPUMCPUIDFEATURE enmFeature);
     1387VMMDECL(bool)          CPUMSetGuestCpuIdPerCpuApicFeature(PVMCPU pVCpu, bool fVisible);
     1388VMMDECL(void)          CPUMSetGuestCtx(PVMCPU pVCpu, const PCPUMCTX pCtx);
     1389VMM_INT_DECL(void)     CPUMGuestLazyLoadHiddenCsAndSs(PVMCPU pVCpu);
     1390VMM_INT_DECL(void)     CPUMGuestLazyLoadHiddenSelectorReg(PVMCPU pVCpu, PCPUMSELREG pSReg);
    14051391VMM_INT_DECL(void)     CPUMSetGuestTscAux(PVMCPU pVCpu, uint64_t uValue);
    14061392VMM_INT_DECL(uint64_t) CPUMGetGuestTscAux(PVMCPU pVCpu);
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette