From 3a6e581f2f56097aa1b17a131b818a70a888cd98 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jos=C3=A9=20Fonseca?= Date: Thu, 18 Feb 2010 14:12:31 +0000 Subject: [PATCH] svga: Note ranges even when there is no hardware buffer around. Not having a hardware buffer around doesn't change the fact that the range is dirty and needs to be uploaded eventually. --- src/gallium/drivers/svga/svga_screen_buffer.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/gallium/drivers/svga/svga_screen_buffer.c b/src/gallium/drivers/svga/svga_screen_buffer.c index bf637f2aa93..14fa40d206d 100644 --- a/src/gallium/drivers/svga/svga_screen_buffer.c +++ b/src/gallium/drivers/svga/svga_screen_buffer.c @@ -312,7 +312,6 @@ svga_buffer_add_range(struct svga_buffer *sbuf, unsigned nearest_range; unsigned nearest_dist; - assert(sbuf->hwbuf); assert(end > start); if (sbuf->map.num_ranges < SVGA_BUFFER_MAX_RANGES) { @@ -466,8 +465,7 @@ svga_buffer_flush_mapped_range( struct pipe_screen *screen, assert(sbuf->map.writing); if(sbuf->map.writing) { assert(sbuf->map.flush_explicit); - if(sbuf->hwbuf) - svga_buffer_add_range(sbuf, offset, offset + length); + svga_buffer_add_range(sbuf, offset, offset + length); } pipe_mutex_unlock(ss->swc_mutex); } @@ -494,8 +492,7 @@ svga_buffer_unmap( struct pipe_screen *screen, /* No mapped range was flushed -- flush the whole buffer */ SVGA_DBG(DEBUG_DMA, "flushing the whole buffer\n"); - if(sbuf->hwbuf) - svga_buffer_add_range(sbuf, 0, sbuf->base.size); + svga_buffer_add_range(sbuf, 0, sbuf->base.size); } sbuf->map.writing = FALSE; -- 2.30.2