diff options
author | José Fonseca <[email protected]> | 2010-02-16 16:43:53 +0000 |
---|---|---|
committer | José Fonseca <[email protected]> | 2010-02-22 21:46:22 +0000 |
commit | 21480fb9e4cad4f0e411c2ffc64e8c9a752d45e8 (patch) | |
tree | a3bf34477f33965b1a2bd95b343b29da92eb013f /src/gallium/drivers | |
parent | 935929595c31ded8827f081150d1024ff2909d6b (diff) |
svga: Remove unused buffer download code.
Unnecessary now that we never destroy buffer storage.
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r-- | src/gallium/drivers/svga/svga_screen_buffer.c | 40 | ||||
-rw-r--r-- | src/gallium/drivers/svga/svga_screen_buffer.h | 5 |
2 files changed, 0 insertions, 45 deletions
diff --git a/src/gallium/drivers/svga/svga_screen_buffer.c b/src/gallium/drivers/svga/svga_screen_buffer.c index 0371ddde368..525352f347c 100644 --- a/src/gallium/drivers/svga/svga_screen_buffer.c +++ b/src/gallium/drivers/svga/svga_screen_buffer.c @@ -288,8 +288,6 @@ svga_buffer_upload_flush(struct svga_context *svga, sbuf->hw.svga = NULL; sbuf->hw.boxes = NULL; - sbuf->host_written = TRUE; - /* Decrement reference count */ pipe_reference(&(sbuf->base.reference), NULL); sbuf = NULL; @@ -420,44 +418,6 @@ svga_buffer_map_range( struct pipe_screen *screen, if(!sbuf->hw.buf) { if(svga_buffer_create_hw_storage(ss, sbuf) != PIPE_OK) return NULL; - - /* Populate the hardware storage if the host surface pre-existed */ - if(sbuf->host_written) { - SVGA3dSurfaceDMAFlags flags; - enum pipe_error ret; - struct pipe_fence_handle *fence = NULL; - - assert(sbuf->handle); - - SVGA_DBG(DEBUG_DMA|DEBUG_PERF, "dma from sid %p (buffer), bytes %u - %u\n", - sbuf->handle, 0, sbuf->base.size); - - memset(&flags, 0, sizeof flags); - - ret = SVGA3D_BufferDMA(ss->swc, - sbuf->hw.buf, - sbuf->handle, - SVGA3D_READ_HOST_VRAM, - sbuf->base.size, - 0, - flags); - if(ret != PIPE_OK) { - ss->swc->flush(ss->swc, NULL); - - ret = SVGA3D_BufferDMA(ss->swc, - sbuf->hw.buf, - sbuf->handle, - SVGA3D_READ_HOST_VRAM, - sbuf->base.size, - 0, - flags); - assert(ret == PIPE_OK); - } - - ss->swc->flush(ss->swc, &fence); - sws->fence_finish(sws, fence, 0); - sws->fence_reference(sws, &fence, NULL); - } } map = sws->buffer_map(sws, sbuf->hw.buf, usage); diff --git a/src/gallium/drivers/svga/svga_screen_buffer.h b/src/gallium/drivers/svga/svga_screen_buffer.h index 448ac107c7f..e0e1b22e462 100644 --- a/src/gallium/drivers/svga/svga_screen_buffer.h +++ b/src/gallium/drivers/svga/svga_screen_buffer.h @@ -135,11 +135,6 @@ struct svga_buffer */ struct svga_winsys_surface *handle; - /** - * Whether the host has been ever written. - */ - boolean host_written; - struct { unsigned count; boolean writing; |