[Mesa-dev] [PATCH 08/75] st/nine: Wait for pending tasks to execute in swapchain
Axel Davy
axel.davy at ens.fr
Wed Oct 5 20:08:41 UTC 2016
Fixes crash after Reset() when using thread_submit=true
Signed-off-by: Axel Davy <axel.davy at ens.fr>
---
src/gallium/state_trackers/nine/swapchain9.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/gallium/state_trackers/nine/swapchain9.c b/src/gallium/state_trackers/nine/swapchain9.c
index bc34dd2..ccc6511 100644
--- a/src/gallium/state_trackers/nine/swapchain9.c
+++ b/src/gallium/state_trackers/nine/swapchain9.c
@@ -242,6 +242,10 @@ NineSwapChain9_Resize( struct NineSwapChain9 *This,
desc.Width = pParams->BackBufferWidth;
desc.Height = pParams->BackBufferHeight;
+ for (i = 0; i < oldBufferCount; i++) {
+ if (This->tasks[i])
+ _mesa_threadpool_wait_for_task(This->pool, &(This->tasks[i]));
+ }
memset(This->tasks, 0, sizeof(This->tasks));
if (This->pool) {
--
2.10.0
More information about the mesa-dev
mailing list