- Timestamp:
- Dec 22, 2018 10:32:24 PM (6 years ago)
- svn:sync-xref-src-repo-rev:
- 127674
- Location:
- trunk
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/Graphics/VBoxUhgsmi.h
r69686 r76376 35 35 typedef struct VBOXUHGSMI_BUFFER *PVBOXUHGSMI_BUFFER; 36 36 37 typedef structVBOXUHGSMI_BUFFER_TYPE_FLAGS37 typedef union VBOXUHGSMI_BUFFER_TYPE_FLAGS 38 38 { 39 union 39 uint32_t Value; 40 struct 40 41 { 41 struct 42 { 43 uint32_t fCommand : 1; 44 uint32_t Reserved : 31; 45 } RT_STRUCT_NM(s); 46 uint32_t Value; 47 } RT_UNION_NM(u); 42 uint32_t fCommand : 1; 43 uint32_t Reserved : 31; 44 } s; 48 45 } VBOXUHGSMI_BUFFER_TYPE_FLAGS; 49 46 50 typedef structVBOXUHGSMI_BUFFER_LOCK_FLAGS47 typedef union VBOXUHGSMI_BUFFER_LOCK_FLAGS 51 48 { 52 union 49 uint32_t Value; 50 struct 53 51 { 54 struct 55 { 56 uint32_t bReadOnly : 1; 57 uint32_t bWriteOnly : 1; 58 uint32_t bDonotWait : 1; 59 uint32_t bDiscard : 1; 60 uint32_t bLockEntire : 1; 61 uint32_t Reserved : 27; 62 } RT_STRUCT_NM(s); 63 uint32_t Value; 64 } RT_UNION_NM(u); 52 uint32_t fReadOnly : 1; 53 uint32_t fWriteOnly : 1; 54 uint32_t fDonotWait : 1; 55 uint32_t fDiscard : 1; 56 uint32_t fLockEntire : 1; 57 uint32_t Reserved : 27; 58 } s; 65 59 } VBOXUHGSMI_BUFFER_LOCK_FLAGS; 66 60 67 typedef structVBOXUHGSMI_BUFFER_SUBMIT_FLAGS61 typedef union VBOXUHGSMI_BUFFER_SUBMIT_FLAGS 68 62 { 69 union 63 uint32_t Value; 64 struct 70 65 { 71 struct 72 { 73 uint32_t bHostReadOnly : 1; 74 uint32_t bHostWriteOnly : 1; 75 uint32_t bDoNotRetire : 1; /**< the buffer will be used in a subsequent command */ 76 uint32_t bEntireBuffer : 1; 77 uint32_t Reserved : 28; 78 } RT_STRUCT_NM(s); 79 uint32_t Value; 80 } RT_UNION_NM(u); 66 uint32_t fHostReadOnly : 1; 67 uint32_t fHostWriteOnly : 1; 68 uint32_t fDoNotRetire : 1; /**< the buffer will be used in a subsequent command */ 69 uint32_t fEntireBuffer : 1; 70 uint32_t Reserved : 28; 71 } s; 81 72 } VBOXUHGSMI_BUFFER_SUBMIT_FLAGS, *PVBOXUHGSMI_BUFFER_SUBMIT_FLAGS; 82 73 -
trunk/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm/VBoxUhgsmiBase.cpp
r73097 r76376 48 48 *phSynch = NULL; 49 49 50 if (fUhgsmiType. fCommand)50 if (fUhgsmiType.s.fCommand) 51 51 { 52 52 *phSynch = CreateEvent( … … 186 186 PVBOXUHGSMI_BUFFER_PRIVATE_ESC_BASE pBuf = VBOXUHGSMIESCBASE_GET_BUFFER(pBufInfo->pBuf); 187 187 pSubmInfo->hAlloc = pBuf->Alloc.hAlloc; 188 if (pBufInfo->fFlags. bEntireBuffer)188 if (pBufInfo->fFlags.s.fEntireBuffer) 189 189 { 190 190 pSubmInfo->Info.offData = 0; -
trunk/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm/VBoxUhgsmiBase.h
r73097 r76376 94 94 D3DDDICB_LOCKFLAGS fLockFlags; 95 95 fLockFlags.Value = 0; 96 if (fFlags. bLockEntire)96 if (fFlags.s.fLockEntire) 97 97 { 98 98 Assert(!offLock); … … 126 126 } 127 127 128 fLockFlags.ReadOnly = fFlags.bReadOnly;129 fLockFlags.WriteOnly = fFlags. bWriteOnly;130 fLockFlags.DonotWait = fFlags. bDonotWait;131 // fLockFlags.Discard = fFlags. bDiscard;128 fLockFlags.ReadOnly = fFlags.s.fReadOnly; 129 fLockFlags.WriteOnly = fFlags.s.fWriteOnly; 130 fLockFlags.DonotWait = fFlags.s.fDonotWait; 131 // fLockFlags.Discard = fFlags.s.fDiscard; 132 132 *pfFlags = fLockFlags; 133 133 return VINF_SUCCESS; … … 173 173 pAllocationList->hAllocation = pBuffer->hAllocation; 174 174 pAllocationList->Value = 0; 175 pAllocationList->WriteOperation = !pBufInfo->fFlags. bHostReadOnly;176 pAllocationList->DoNotRetireInstance = pBufInfo->fFlags. bDoNotRetire;177 if (pBufInfo->fFlags. bEntireBuffer)175 pAllocationList->WriteOperation = !pBufInfo->fFlags.s.fHostReadOnly; 176 pAllocationList->DoNotRetireInstance = pBufInfo->fFlags.s.fDoNotRetire; 177 if (pBufInfo->fFlags.s.fEntireBuffer) 178 178 { 179 179 pBufSubmInfo->offData = 0; -
trunk/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm/VBoxUhgsmiKmt.cpp
r75445 r76376 54 54 } 55 55 56 DECLCALLBACK(int) vboxUhgsmiKmtBufferLock(PVBOXUHGSMI_BUFFER pBuf, uint32_t offLock, uint32_t cbLock, VBOXUHGSMI_BUFFER_LOCK_FLAGS fFlags, void**pvLock) 56 DECLCALLBACK(int) vboxUhgsmiKmtBufferLock(PVBOXUHGSMI_BUFFER pBuf, uint32_t offLock, uint32_t cbLock, 57 VBOXUHGSMI_BUFFER_LOCK_FLAGS fFlags, void**pvLock) 57 58 { 58 59 PVBOXUHGSMI_BUFFER_PRIVATE_DX_ALLOC_BASE pBuffer = VBOXUHGSMDXALLOCBASE_GET_BUFFER(pBuf); -
trunk/src/VBox/GuestHost/OpenGL/util/vboxhgcm.c
r73223 r76376 241 241 VBOXUHGSMI_BUFFER_TYPE_FLAGS Flags = {0}; 242 242 pClient->pHgsmi = pHgsmi; 243 Flags. fCommand = 1;243 Flags.s.fCommand = 1; 244 244 rc = pHgsmi->pfnBufferCreate(pHgsmi, CRVBOXHGSMI_PAGE_ALIGN(1), Flags, &pClient->pCmdBuffer); 245 245 if (RT_SUCCESS(rc)) … … 417 417 int rc; 418 418 fFlags.Value = 0; 419 fFlags. bDiscard = 1;419 fFlags.s.fDiscard = 1; 420 420 rc = pClient->pCmdBuffer->pfnLock(pClient->pCmdBuffer, 0, cbBuffer, fFlags, (void**)&pHdr); 421 421 if (RT_SUCCESS(rc)) 422 422 return pHdr; 423 else 424 crWarning("_crVBoxHGSMICmdBufferLock: pfnLock failed rc %d", rc); 423 crWarning("_crVBoxHGSMICmdBufferLock: pfnLock failed rc %d", rc); 425 424 426 425 crWarning("Failed to Lock the command buffer of size(%d), rc(%d)\n", cbBuffer, rc); … … 444 443 int rc; 445 444 fFlags.Value = 0; 446 fFlags. bReadOnly = 1;445 fFlags.s.fReadOnly = 1; 447 446 rc = pClient->pCmdBuffer->pfnLock(pClient->pCmdBuffer, 0, cbBuffer, fFlags, (void**)&pHdr); 448 447 if (RT_FAILURE(rc)) … … 465 464 466 465 fFlags.Value = 0; 467 fFlags. bReadOnly = 1;466 fFlags.s.fReadOnly = 1; 468 467 rc = pClient->pCmdBuffer->pfnLock(pClient->pCmdBuffer, 0, sizeof (*pHdr), fFlags, (void**)&pHdr); 469 468 if (RT_FAILURE(rc)) … … 515 514 pSubm->cbData = cbData; 516 515 pSubm->fFlags.Value = 0; 517 pSubm->fFlags. bDoNotRetire = 1;516 pSubm->fFlags.s.fDoNotRetire = 1; 518 517 # if 0 519 518 pSubm->fFlags.bDoNotSignalCompletion = 1; /* <- we do not need that actually since … … 1615 1614 aSubmit[1].cbData = pRecvBuffer->cbBuffer; 1616 1615 aSubmit[1].fFlags.Value = 0; 1617 aSubmit[1].fFlags. bHostWriteOnly = 1;1616 aSubmit[1].fFlags.s.fHostWriteOnly = 1; 1618 1617 1619 1618 rc = pClient->pHgsmi->pfnBufferSubmit(pClient->pHgsmi, aSubmit, 2); … … 1702 1701 offBuffer = 0; 1703 1702 fFlags.Value = 0; 1704 fFlags. bDiscard = 1;1705 fFlags. bWriteOnly = 1;1703 fFlags.s.fDiscard = 1; 1704 fFlags.s.fWriteOnly = 1; 1706 1705 rc = pBuf->pfnLock(pBuf, 0, len, fFlags, &pvBuf); 1707 1706 if (RT_SUCCESS(rc)) … … 1740 1739 aSubmit[1].cbData = len; 1741 1740 aSubmit[1].fFlags.Value = 0; 1742 aSubmit[1].fFlags. bHostReadOnly = 1;1741 aSubmit[1].fFlags.s.fHostReadOnly = 1; 1743 1742 1744 1743 aSubmit[2].pBuf = pRecvBuffer; … … 1862 1861 aSubmit[1].cbData = len; 1863 1862 aSubmit[1].fFlags.Value = 0; 1864 aSubmit[1].fFlags. bHostReadOnly = 1;1863 aSubmit[1].fFlags.s.fHostReadOnly = 1; 1865 1864 1866 1865 rc = pClient->pHgsmi->pfnBufferSubmit(pClient->pHgsmi, aSubmit, 2); … … 1894 1893 aSubmit[1].cbData = len; 1895 1894 aSubmit[1].fFlags.Value = 0; 1896 aSubmit[1].fFlags. bHostReadOnly = 1;1895 aSubmit[1].fFlags.s.fHostReadOnly = 1; 1897 1896 1898 1897 rc = pClient->pHgsmi->pfnBufferSubmit(pClient->pHgsmi, aSubmit, 2);
Note:
See TracChangeset
for help on using the changeset viewer.