Changeset 83714 in vbox for trunk/src/VBox/Devices
- Timestamp:
- Apr 16, 2020 9:37:02 AM (5 years ago)
- svn:sync-xref-src-repo-rev:
- 137224
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Bus/DevIommuAmd.cpp
r83712 r83714 2072 2072 2073 2073 2074 DECL INLINE(IOMMU_STATUS_T) iommuAmdGetStatus(PCIOMMU pThis)2074 DECL_FORCE_INLINE(IOMMU_STATUS_T) iommuAmdGetStatus(PCIOMMU pThis) 2075 2075 { 2076 2076 IOMMU_STATUS_T Status; … … 2129 2129 pThis->CmdBufBaseAddr.u64 = u64Value & IOMMU_CMD_BUF_BAR_VALID_MASK; 2130 2130 iommuAmdCheckBufferLength(pThis->CmdBufBaseAddr.n.u4CmdLen, __PRETTY_FUNCTION__); 2131 2132 /* 2133 * While this is not explicitly specified like the event log base address register, 2134 * the AMD spec. does specify "CmdBufRun must be 0b to modify the command buffer registers properly". 2135 * Inconsistent specs :/ 2136 */ 2137 IOMMU_STATUS_T const Status = iommuAmdGetStatus(pThis); 2138 if (Status.n.u1CmdBufRunning) 2139 { 2140 Log((IOMMU_LOG_PFX ": Setting CmdBufBar (%#RX64) when command buffer is running -> Ignored\n", u64Value)); 2141 return VINF_SUCCESS; 2142 } 2143 2144 /* 2145 * Writing the command log base address, clears the command buffer head and tail pointers. 2146 * See AMD spec. 2.4 "Commands". 2147 */ 2148 pThis->CmdBufHeadPtr.u64 = 0; 2149 pThis->CmdBufTailPtr.u64 = 0; 2150 2131 2151 return VINF_SUCCESS; 2132 2152 } … … 3539 3559 MsiReg.iMsiCapOffset = IOMMU_PCI_OFF_MSI_CAP_HDR; 3540 3560 MsiReg.iMsiNextOffset = 0; /* IOMMU_PCI_OFF_MSI_MAP_CAP_HDR */ 3561 MsiReg.fMsi64bit = 1; /* 64-bit addressing support is mandatory; See AMD spec. 2.8 "IOMMU Interrupt Support". */ 3541 3562 rc = PDMDevHlpPCIRegisterMsi(pDevIns, &MsiReg); 3542 3563 AssertRCReturn(rc, rc);
Note:
See TracChangeset
for help on using the changeset viewer.