From f9aa75718708076e50033287fde993799878ecf6 Mon Sep 17 00:00:00 2001 From: Brian Date: Sat, 20 Oct 2007 15:52:36 -0600 Subject: [PATCH] Call softpipe_unmap_surfaces() in softpipe_flush(). This fixes a DRM BO failure upon swapbuffers caused by the color buffer still being mapped. This is a bit heavy handed since we don't always need to unmap buffers when flushing. Need to pass a flag to flush() or design a new function. --- src/mesa/pipe/softpipe/sp_flush.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/mesa/pipe/softpipe/sp_flush.c b/src/mesa/pipe/softpipe/sp_flush.c index f2186dbb653..5eb4d3367d1 100644 --- a/src/mesa/pipe/softpipe/sp_flush.c +++ b/src/mesa/pipe/softpipe/sp_flush.c @@ -63,5 +63,13 @@ softpipe_flush( struct pipe_context *pipe, if (softpipe->sbuf_cache) sp_flush_tile_cache(softpipe->sbuf_cache); + + /* Need this call for hardware buffers before swapbuffers. + * + * there should probably be another/different flush-type function + * that's called before swapbuffers because we don't always want + * to unmap surfaces when flushing. + */ + softpipe_unmap_surfaces(softpipe); } -- 2.30.2