- Timestamp:
- Apr 19, 2021 3:53:34 PM (4 years ago)
- svn:sync-xref-src-repo-rev:
- 143879
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/PC/DevIoApic.cpp
r86927 r88581 914 914 RT_ZERO(ApicIntr); 915 915 916 #if def VBOX_WITH_IOMMU_AMD916 #if defined(VBOX_WITH_IOMMU_AMD) || defined(VBOX_WITH_IOMMU_INTEL) 917 917 /* 918 918 * The MSI may need to be remapped (or discarded) if an IOMMU is present. 919 * 920 * If the Bus:Dev:Fn isn't valid, it is ASSUMED the device generating the 921 * MSI is the IOMMU itself and hence is not subject to remapping. 919 922 */ 920 MSIMSG MsiOut; 921 RT_ZERO(MsiOut); 922 Assert(PCIBDF_IS_VALID(uBusDevFn)); 923 int rcRemap = pThisCC->pIoApicHlp->pfnIommuMsiRemap(pDevIns, uBusDevFn, pMsi, &MsiOut); 924 if (RT_SUCCESS(rcRemap)) 923 if (PCIBDF_IS_VALID(uBusDevFn)) 925 924 { 926 STAM_COUNTER_INC(&pThis->StatIommuRemappedMsi); 927 ioapicGetApicIntrFromMsi(&MsiOut, &ApicIntr); 925 MSIMSG MsiOut; 926 RT_ZERO(MsiOut); 927 int rcRemap = pThisCC->pIoApicHlp->pfnIommuMsiRemap(pDevIns, uBusDevFn, pMsi, &MsiOut); 928 if (RT_SUCCESS(rcRemap)) 929 { 930 STAM_COUNTER_INC(&pThis->StatIommuRemappedMsi); 931 ioapicGetApicIntrFromMsi(&MsiOut, &ApicIntr); 932 } 933 else 934 { 935 STAM_COUNTER_INC(&pThis->StatIommuDiscardedMsi); 936 Log(("IOAPIC: MSI (Addr=%#RX64 Data=%#RX32) remapping failed. rc=%Rrc", pMsi->Addr.u64, pMsi->Data.u32, rcRemap)); 937 return; 938 } 928 939 } 929 940 else 930 { 931 STAM_COUNTER_INC(&pThis->StatIommuDiscardedMsi); 932 Log(("IOAPIC: MSI (Addr=%#RX64 Data=%#RX32) remapping failed. rc=%Rrc", pMsi->Addr.u64, pMsi->Data.u32, rcRemap)); 933 return; 934 } 941 ioapicGetApicIntrFromMsi(pMsi, &ApicIntr); 935 942 #else 936 943 NOREF(uBusDevFn);
Note:
See TracChangeset
for help on using the changeset viewer.