[Spice-devel] [PATCH qxl-win] miniport/qxl: store vram_start on video memory map for later debug usage

Alon Levy alevy at redhat.com
Mon Jun 20 03:59:27 PDT 2011


---
 miniport/qxl.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/miniport/qxl.c b/miniport/qxl.c
index 19c0033..6e9bd8e 100644
--- a/miniport/qxl.c
+++ b/miniport/qxl.c
@@ -77,6 +77,7 @@ typedef struct QXLExtension {
 
     PHYSICAL_ADDRESS vram_physical;
     ULONG vram_size;
+    UINT8 *vram_start;
 
     ULONG current_mode;
     ULONG n_modes;
@@ -928,6 +929,7 @@ BOOLEAN StartIO(PVOID dev_extension, PVIDEO_REQUEST_PACKET packet)
                 DEBUG_PRINT((0, "%s: map filed\n", __FUNCTION__));
                 goto err;
             }
+            dev_ext->vram_start = mem_info->VideoRamBase;
             DEBUG_PRINT((0, "%s: vram size %lu ret size %lu fb vaddr 0x%lx\n",
                          __FUNCTION__,
                          dev_ext->vram_size,
@@ -963,6 +965,7 @@ BOOLEAN StartIO(PVOID dev_extension, PVIDEO_REQUEST_PACKET packet)
             if ((error = VideoPortUnmapMemory(dev_ext, addr, NULL)) != NO_ERROR) {
                 DEBUG_PRINT((0, "%s: unmap failed\n", __FUNCTION__));
             }
+            dev_ext->vram_start = NULL;
         }
         break;
     case IOCTL_VIDEO_RESET_DEVICE:
-- 
1.7.5.2



More information about the Spice-devel mailing list