- Timestamp:
- Aug 23, 2010 4:26:42 PM (14 years ago)
- Location:
- trunk/src/VBox/Additions/WINNT/Graphics/Miniport
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/WINNT/Graphics/Miniport/VBoxVideo.cpp
r31863 r31873 1450 1450 } 1451 1451 1452 /* Unmapping adapter information must be done carefully WRT the interrupt handler. */ 1453 BOOLEAN VBoxUnmapAdpInfoCallback(PVOID ext) 1454 { 1455 PDEVICE_EXTENSION PrimaryExtension = (PDEVICE_EXTENSION)ext; 1456 void *ppv; 1457 1458 ppv = PrimaryExtension->u.primary.pvAdapterInformation; 1459 if (ppv) 1460 { 1461 #ifndef VBOXWDDM 1462 VideoPortUnmapMemory(PrimaryExtension, ppv, NULL); 1463 #else 1464 NTSTATUS ntStatus = PrimaryExtension->u.primary.DxgkInterface.DxgkCbUnmapMemory(PrimaryExtension->u.primary.DxgkInterface.DeviceHandle, 1465 ppv); 1466 Assert(ntStatus == STATUS_SUCCESS); 1467 #endif 1468 PrimaryExtension->u.primary.pvAdapterInformation = NULL; 1469 PrimaryExtension->u.primary.pHostFlags = NULL; /* Mapped through pvAdapterInformation */ 1470 } 1471 return TRUE; 1472 } 1473 1474 void VBoxUnmapAdapterInformation(PDEVICE_EXTENSION PrimaryExtension) 1475 { 1476 dprintf(("VBoxVideo::VBoxUnmapAdapterInformation\n")); 1477 1478 VideoPortSynchronizeExecution(PrimaryExtension, VpMediumPriority, 1479 VBoxUnmapAdpInfoCallback, PrimaryExtension); 1480 } 1481 1452 1482 void VBoxUnmapAdapterMemory (PDEVICE_EXTENSION PrimaryExtension, void **ppv, ULONG ulSize) 1453 1483 { 1454 dprintf(("VBoxVideo::VBox MapAdapterMemory\n"));1484 dprintf(("VBoxVideo::VBoxUnmapAdapterMemory\n")); 1455 1485 1456 1486 if (*ppv) … … 1751 1781 /* Unmap the memory if VBoxVideo is not supported. */ 1752 1782 VBoxUnmapAdapterMemory (PrimaryExtension, &PrimaryExtension->u.primary.pvMiniportHeap, PrimaryExtension->u.primary.cbMiniportHeap); 1753 VBoxUnmapAdapter Memory (PrimaryExtension, &PrimaryExtension->u.primary.pvAdapterInformation, VBOX_VIDEO_ADAPTER_INFORMATION_SIZE);1783 VBoxUnmapAdapterInformation (PrimaryExtension); 1754 1784 } 1755 1785 … … 2844 2874 2845 2875 VBoxUnmapAdapterMemory (pDevExt, &pDevExt->u.primary.pvMiniportHeap, pDevExt->u.primary.cbMiniportHeap); 2846 VBoxUnmapAdapter Memory (pDevExt, &pDevExt->u.primary.pvAdapterInformation, VBVA_ADAPTER_INFORMATION_SIZE);2876 VBoxUnmapAdapterInformation (pDevExt); 2847 2877 2848 2878 return TRUE; -
trunk/src/VBox/Additions/WINNT/Graphics/Miniport/VBoxVideo.h
r31756 r31873 851 851 void VBoxUnmapAdapterMemory (PDEVICE_EXTENSION PrimaryExtension, 852 852 void **ppv, ULONG ulSize); 853 void VBoxUnmapAdapterInformation (PDEVICE_EXTENSION PrimaryExtension); 853 854 854 855 void VBoxComputeFrameBufferSizes (PDEVICE_EXTENSION PrimaryExtension); -
trunk/src/VBox/Additions/WINNT/Graphics/Miniport/VBoxVideoHGSMI.cpp
r30942 r31873 741 741 PrimaryExtension->u.primary.pvMiniportHeap = NULL; 742 742 PrimaryExtension->u.primary.pvAdapterInformation = NULL; 743 PrimaryExtension->u.primary.pHostFlags = NULL; 743 744 PrimaryExtension->u.primary.ulMaxFrameBufferSize = 0; 744 745 PrimaryExtension->u.primary.bHGSMI = VBoxHGSMIIsSupported (PrimaryExtension); … … 1039 1040 /* Unmap the memory if VBoxVideo is not supported. */ 1040 1041 VBoxUnmapAdapterMemory (PrimaryExtension, &PrimaryExtension->u.primary.pvMiniportHeap, PrimaryExtension->u.primary.cbMiniportHeap); 1041 VBoxUnmapAdapter Memory (PrimaryExtension, &PrimaryExtension->u.primary.pvAdapterInformation, VBVA_ADAPTER_INFORMATION_SIZE);1042 VBoxUnmapAdapterInformation (PrimaryExtension); 1042 1043 1043 1044 HGSMIHeapDestroy (&PrimaryExtension->u.primary.hgsmiAdapterHeap); … … 1093 1094 1094 1095 /* Map the adapter information. It will be needed for HGSMI IO. */ 1095 /*rc = */VBoxUnmapAdapter Memory(PrimaryExtension, &PrimaryExtension->u.primary.pvAdapterInformation, VBVA_ADAPTER_INFORMATION_SIZE);1096 /*rc = */VBoxUnmapAdapterInformation(PrimaryExtension); 1096 1097 /* 1097 1098 AssertRC(rc);
Note:
See TracChangeset
for help on using the changeset viewer.