VirtualBox

Changeset 89493 in vbox


Ignore:
Timestamp:
Jun 4, 2021 4:30:29 AM (4 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
144850
Message:

Intel IOMMU: bugref:9967 Address translation, nits.

File:
1 edited

Legend:

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

    r89492 r89493  
    22542254    Assert(pIoPagePrev->fPerm  == pIoPage->fPerm);
    22552255
    2256     size_t const   cbPrev      = RT_BIT_64(pIoPagePrev->cShift);
    2257     RTGCPHYS const GCPhysPrev  = pIoPagePrev->GCPhysBase;
    2258     RTGCPHYS const GCPhys      = pIoPage->GCPhysBase;
     2256    size_t const   cbPrev     = RT_BIT_64(pIoPagePrev->cShift);
     2257    RTGCPHYS const GCPhysPrev = pIoPagePrev->GCPhysBase;
     2258    RTGCPHYS const GCPhys     = pIoPage->GCPhysBase;
    22592259#ifdef RT_STRICT
    22602260    /* Paranoia: Ensure offset bits are 0. */
     
    22822282    RTGCPHYS       GCPhysAddr  = NIL_RTGCPHYS;
    22832283    DMARMEMREQIN   MemReqIn    = pMemReqRemap->In;
    2284     uint64_t const uAddrIn     = pMemReqRemap->In.AddrRange.uAddr;
    2285     size_t const   cbAddrIn    = pMemReqRemap->In.AddrRange.cb;
    2286     uint64_t       uAddrInBase = pMemReqRemap->In.AddrRange.uAddr & X86_PAGE_4K_BASE_MASK;
    2287     uint64_t       offAddrIn   = pMemReqRemap->In.AddrRange.uAddr & X86_PAGE_4K_OFFSET_MASK;
     2284    uint64_t const uAddrIn     = MemReqIn.AddrRange.uAddr;
     2285    size_t const   cbAddrIn    = MemReqIn.AddrRange.cb;
     2286    uint64_t       uAddrInBase = MemReqIn.AddrRange.uAddr & X86_PAGE_4K_BASE_MASK;
     2287    uint64_t       offAddrIn   = MemReqIn.AddrRange.uAddr & X86_PAGE_4K_OFFSET_MASK;
    22882288    size_t         cbRemaining = cbAddrIn;
    22892289
     
    23062306            if (cbRemaining == cbAddrIn)
    23072307            {
    2308                 uint64_t const fIoPageMask = X86_GET_PAGE_OFFSET_MASK(IoPage.cShift);
    2309                 uint64_t const offAddrOut  = uAddrIn & fIoPageMask;
     2308                uint64_t const fOffMask  = X86_GET_PAGE_OFFSET_MASK(IoPage.cShift);
     2309                uint64_t const offAddrOut = uAddrIn & fOffMask;
    23102310                Assert(!(IoPage.GCPhysBase & fIoPageMask));
    23112311                GCPhysAddr = IoPage.GCPhysBase | offAddrOut;
Note: See TracChangeset for help on using the changeset viewer.

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