VirtualBox

Changeset 36400 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Mar 24, 2011 1:14:26 PM (14 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
70754
Message:

PCI: work on IOMMU notifications

Location:
trunk/src/VBox
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/VBoxPci/VBoxPci.c

    r36340 r36400  
    8383
    8484DECLINLINE(void) vboxPciDevUnlock(PVBOXRAWPCIINS pThis)
     85{
     86    RTSemFastMutexRelease(pThis->hFastMtx);
     87}
     88
     89DECLINLINE(int) vboxPciVmLock(PVBOXRAWPCIDRVVM pThis)
     90{
     91    int rc = RTSemFastMutexRequest(pThis->hFastMtx);
     92    AssertRC(rc);
     93    return rc;
     94}
     95
     96DECLINLINE(void) vboxPciVmUnlock(PVBOXRAWPCIDRVVM pThis)
    8597{
    8698    RTSemFastMutexRelease(pThis->hFastMtx);
     
    380392
    381393    rc = vboxPciOsDevPowerStateChange(pThis, aState);
    382    
     394
    383395    vboxPciDevUnlock(pThis);
    384396
  • trunk/src/VBox/HostDrivers/VBoxPci/VBoxPciInternal.h

    r36343 r36400  
    100100#ifdef RT_OS_LINUX
    101101# ifdef VBOX_WITH_IOMMU
    102     struct iommu_domain* iommu_domain;
     102    struct iommu_domain* pIommuDomain;
    103103# endif
    104104#endif
     105    int32_t        fFlags;
    105106} VBOXRAWPCIDRVVM;
    106107
  • trunk/src/VBox/Main/src-client/ConsoleImpl2.cpp

    r36260 r36400  
    509509
    510510    if (assignments.size() > 0)
     511    {
    511512        InsertConfigNode(pDevices,     "pciraw",  &pPciDevs);
     513
     514        /*
     515         * Currently, using IOMMU needed for PCI passthrough
     516         * requires RAM preallocation.
     517         * @todo: check if we can lift this requirement
     518         */
     519        PCFGMNODE pRoot = CFGMR3GetParent(pDevices);
     520        Assert(pRoot);
     521        CFGMR3RemoveValue(pRoot, "RamPreAlloc");
     522        CFGMR3InsertInteger(pRoot, "RamPreAlloc",    1);
     523    }
    512524
    513525    for (size_t iDev = 0; iDev < assignments.size(); iDev++)
  • trunk/src/VBox/VMM/VMMR0/GMMR0.cpp

    r35917 r36400  
    151151*******************************************************************************/
    152152#define LOG_GROUP LOG_GROUP_GMM
     153#include <VBox/rawpci.h>
    153154#include <VBox/vmm/vm.h>
    154155#include <VBox/vmm/gmm.h>
     
    20922093                                    pPage->Private.pfn = GMM_PAGE_PFN_UNSHAREABLE;
    20932094                                /* else: NIL_RTHCPHYS nothing */
     2095#if 0
     2096#ifdef VBOX_WITH_PCI_PASSTHROUGH
     2097                                if (pVM->rawpci.s.pfnContigMemInfo)
     2098                                    pVM->rawpci.s.pfnContigMemInfo(pVM, paPages[iPage].HCPhysGCPhys, 0, PAGE_SIZE, PCIRAW_MEMINFO_MAP);
     2099#endif
     2100#endif
    20942101
    20952102                                paPages[iPage].idPage = NIL_GMM_PAGEID;
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