Changeset 88535 in vbox
- Timestamp:
- Apr 15, 2021 12:18:52 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Bus/DevIommuIntel.cpp
r88521 r88535 60 60 * minimum number of registers (which is 1). 61 61 * 62 * See Intel VT-d spec. 10.4.2 "Capability Register" (CAP_REG ::NFR). */62 * See Intel VT-d spec. 10.4.2 "Capability Register" (CAP_REG.NFR). */ 63 63 #define DMAR_FRCD_REG_COUNT UINT32_C(1) 64 64 … … 90 90 #define DMAR_MMIO_GROUP_1_SIZE (DMAR_MMIO_GROUP_1_OFF_END - DMAR_MMIO_GROUP_1_OFF_FIRST) 91 91 92 /** DMAR implementation's major version number (exposed to software). 93 * We report 6 as the major version since we support queued invalidations as 94 * software may make assumptions based on that. 95 * 96 * See Intel VT-d spec. 10.4.7 "Context Command Register" (CCMD_REG.CAIG). */ 97 #define DMAR_VER_MAJOR 6 92 98 /** DMAR implementation's minor version number (exposed to software). */ 93 99 #define DMAR_VER_MINOR 0 94 /** DMAR implementation's major version number (exposed to software). */95 #define DMAR_VER_MAJOR 196 100 /** @} */ 97 101 … … 125 129 /** @name Register copies for a tiny bit faster and more convenient access. 126 130 * @{ */ 131 /** Copy of VER_REG. */ 132 uint8_t uVerReg; 133 /** Alignment. */ 134 uint8_t abPadding[7]; 127 135 /** Copy of CAP_REG. */ 128 136 uint64_t fCap; … … 860 868 /* VER_REG */ 861 869 { 862 uint8_t const uVer= RT_BF_MAKE(VTD_BF_VER_REG_MIN, DMAR_VER_MINOR)863 864 dmarRegWriteRaw64(pThis, VTD_MMIO_OFF_VER_REG, uVer);870 pThis->uVerReg = RT_BF_MAKE(VTD_BF_VER_REG_MIN, DMAR_VER_MINOR) 871 | RT_BF_MAKE(VTD_BF_VER_REG_MAX, DMAR_VER_MAJOR); 872 dmarRegWriteRaw64(pThis, VTD_MMIO_OFF_VER_REG, pThis->uVerReg); 865 873 } 866 874 … … 907 915 | RT_BF_MAKE(VTD_BF_CAP_REG_MAMV, fPsi & fMamv) 908 916 | RT_BF_MAKE(VTD_BF_CAP_REG_DWD, 1) 917 | RT_BF_MAKE(VTD_BF_CAP_REG_DRD, 1) 909 918 | RT_BF_MAKE(VTD_BF_CAP_REG_FL1GP, fFlts & fFl1gp) 910 919 | RT_BF_MAKE(VTD_BF_CAP_REG_PI, 0) /* Posted Interrupts not supported. */ … … 1122 1131 * Log some of the features exposed to software. 1123 1132 */ 1124 uint32_t const uVerReg = dmarRegRead32(pThis, VTD_MMIO_OFF_VER_REG);1133 uint32_t const uVerReg = pThis->uVerReg; 1125 1134 uint8_t const cMaxGstAddrBits = RT_BF_GET(pThis->fCap, VTD_BF_CAP_REG_MGAW) + 1; 1126 1135 uint8_t const cSupGstAddrBits = vtdCapRegGetSagawBits(RT_BF_GET(pThis->fCap, VTD_BF_CAP_REG_SAGAW));
Note:
See TracChangeset
for help on using the changeset viewer.