VirtualBox

Ignore:
Timestamp:
Oct 18, 2010 7:26:40 PM (14 years ago)
Author:
vboxsync
Message:

wddm/3d: chromium hgsmi fixes

Location:
trunk/src/VBox/Additions/WINNT/Graphics/Display/wddm
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/WINNT/Graphics/Display/wddm/VBoxDispD3D.cpp

    r33171 r33216  
    728728/* cr hgsmi */
    729729static VBOXCRHGSMI_CALLBACKS g_VBoxCrHgsmiCallbacks = {0};
    730 static VBOXUHGSMI_PRIVATE_KMT g_VBoxUhgsmiKmt;
    731 static uint32_t g_cVBoxUhgsmiKmtRefs = 0;
     730#define VBOXUHGSMIKMT_PERTHREAD
     731#ifdef VBOXUHGSMIKMT_PERTHREAD
     732#define VBOXUHGSMIKMT_VAR(_type) __declspec(thread) _type
     733#else
     734#define VBOXUHGSMIKMT_VAR(_type) _type
     735#endif
     736static VBOXUHGSMIKMT_VAR(VBOXUHGSMI_PRIVATE_KMT) g_VBoxUhgsmiKmt;
     737static VBOXUHGSMIKMT_VAR(uint32_t) g_cVBoxUhgsmiKmtRefs = 0;
    732738#endif
    733739
     
    50135019    PVBOXWDDMDISP_DEVICE pDevice = (PVBOXWDDMDISP_DEVICE)hDevice;
    50145020    Assert(pDevice);
     5021    VBOXDISPCRHGSMI_SCOPE_SET_DEV(pDevice);
    50155022    Assert(pResource);
    50165023    PVBOXWDDMDISP_ADAPTER pAdapter = pDevice->pAdapter;
  • trunk/src/VBox/Additions/WINNT/Graphics/Display/wddm/VBoxUhgsmiDisp.cpp

    r33146 r33216  
    5858
    5959    int rc = vboxUhgsmiBaseLockData(pBuf, offLock, cbLock, fFlags,
    60                                          &DdiLock.Flags, pBuffer->aLockPageIndices, &DdiLock.NumPages);
     60                                         &DdiLock.Flags, &DdiLock.NumPages, pBuffer->aLockPageIndices);
    6161    AssertRC(rc);
    6262    if (RT_FAILURE(rc))
  • trunk/src/VBox/Additions/WINNT/Graphics/Display/wddm/VBoxUhgsmiKmt.cpp

    r33146 r33216  
    2222    VBOXUHGSMI_BUFFER_PRIVATE_BASE BasePrivate;
    2323    PVBOXUHGSMI_PRIVATE_KMT pHgsmi;
     24    CRITICAL_SECTION CritSect;
    2425    UINT aLockPageIndices[1];
    2526} VBOXUHGSMI_BUFFER_PRIVATE_KMT, *PVBOXUHGSMI_BUFFER_PRIVATE_KMT;
     
    5556    DdiLock.PrivateDriverData = NULL;
    5657
     58    EnterCriticalSection(&pBuffer->CritSect);
     59
    5760    int rc = vboxUhgsmiBaseLockData(pBuf, offLock, cbLock, fFlags,
    58                                          &DdiLock.Flags, pBuffer->aLockPageIndices, &DdiLock.NumPages);
     61                                         &DdiLock.Flags, &DdiLock.NumPages, pBuffer->aLockPageIndices);
    5962    AssertRC(rc);
    6063    if (RT_FAILURE(rc))
     
    6568    NTSTATUS Status = pBuffer->pHgsmi->Callbacks.pfnD3DKMTLock(&DdiLock);
    6669    Assert(!Status);
     70    LeaveCriticalSection(&pBuffer->CritSect);
    6771    if (!Status)
    6872    {
     
    132136        if (hr == S_OK)
    133137        {
     138            InitializeCriticalSection(&pBuf->CritSect);
     139
    134140            Assert(Buf.DdiAllocInfo.hAllocation);
    135141            pBuf->BasePrivate.Base.pfnLock = vboxUhgsmiKmtBufferLock;
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