VirtualBox

Changeset 88814 in vbox for trunk/src/VBox


Ignore:
Timestamp:
May 3, 2021 5:12:06 AM (4 years ago)
Author:
vboxsync
Message:

Intel IOMMU: bugref:9967 Start work on interrupt remapping. Queued invalidation assertion fix.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Bus/DevIommuIntel.cpp

    r88808 r88814  
    11911191    }
    11921192
    1193     /*
    1194      * Set Interrupt Remapping Table Pointer (SIRTP).
    1195      */
    1196     if (   (fExtCapReg & VTD_BF_ECAP_REG_IR_MASK)
    1197         && (uGcmdReg & VTD_BF_GCMD_REG_SIRTP_MASK))
    1198     {
    1199         /** @todo Perform global invalidation of all interrupt-entry cache when ESIRTPS is
    1200          *        supported. */
    1201         pThis->uIrtaReg = dmarRegReadRaw64(pThis, VTD_MMIO_OFF_IRTA_REG);
    1202         dmarRegChangeRaw32(pThis, VTD_MMIO_OFF_GSTS_REG, UINT32_MAX /* fAndMask */, VTD_BF_GSTS_REG_IRTPS_MASK /* fOrMask */);
     1193    if (fExtCapReg & VTD_BF_ECAP_REG_IR_MASK)
     1194    {
     1195        /*
     1196         * Set Interrupt Remapping Table Pointer (SIRTP).
     1197         */
     1198        if (uGcmdReg & VTD_BF_GCMD_REG_SIRTP_MASK)
     1199        {
     1200            /** @todo Perform global invalidation of all interrupt-entry cache when ESIRTPS is
     1201             *        supported. */
     1202            pThis->uIrtaReg = dmarRegReadRaw64(pThis, VTD_MMIO_OFF_IRTA_REG);
     1203            dmarRegChangeRaw32(pThis, VTD_MMIO_OFF_GSTS_REG, UINT32_MAX /* fAndMask */, VTD_BF_GSTS_REG_IRTPS_MASK /* fOrMask */);
     1204        }
     1205
     1206        /*
     1207         * Interrupt remapping.
     1208         */
     1209        if (fChanged & VTD_BF_GCMD_REG_IRE_MASK)
     1210        {
     1211            if (uGcmdReg & VTD_BF_GCMD_REG_IRE_MASK)
     1212                dmarRegChangeRaw32(pThis, VTD_MMIO_OFF_GSTS_REG, UINT32_MAX /* fAndMask */,
     1213                                   VTD_BF_GSTS_REG_IRES_MASK /* fOrMask */);
     1214            else
     1215                dmarRegChangeRaw32(pThis, VTD_MMIO_OFF_GSTS_REG, ~VTD_BF_GSTS_REG_IRES_MASK /* fAndMask */, 0 /* fOrMask */);
     1216        }
    12031217    }
    12041218
     
    16971711                /* Paranoia. */
    16981712                Assert(cbQueue <= cbMaxQs);
    1699                 Assert(!(offQueueTail & ~VTD_IQT_REG_RW_MASK));
    1700                 Assert(!(offQueueHead & ~VTD_IQH_REG_RW_MASK));
     1713                Assert(!(offQueueTail & ~VTD_BF_IQT_REG_QT_MASK));
     1714                Assert(!(offQueueHead & ~VTD_BF_IQH_REG_QH_MASK));
    17011715                Assert(fDw != VTD_IQA_REG_DW_256_BIT || !(offQueueTail & RT_BIT(4)));
    17021716                Assert(fDw != VTD_IQA_REG_DW_256_BIT || !(offQueueHead & RT_BIT(4)));
     
    20432057        pHlp->pfnPrintf(pHlp, " FEADDR_REG   = %#RX32\n", uFeaddrReg);
    20442058        pHlp->pfnPrintf(pHlp, " FEUADDR_REG  = %#RX32\n", uFeuaddrReg);
    2045         /** @todo Verbose others as needed during debugging/rainy day. */
    20462059        pHlp->pfnPrintf(pHlp, " AFLOG_REG    = %#RX64\n", uAflogReg);
    20472060        pHlp->pfnPrintf(pHlp, " PMEN_REG     = %#RX32\n", uPmenReg);
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