[Mesa-dev] [PATCH 5/7] st/nine: Process pending commands on Reset

Axel Davy axel.davy at ens.fr
Fri Jan 6 20:17:19 UTC 2017


Some nine_state_* and nine_context_* functions
used for Reset() require all pending commands are
flushed.

Signed-off-by: Axel Davy <axel.davy at ens.fr>
---
 src/gallium/state_trackers/nine/device9.c    | 1 +
 src/gallium/state_trackers/nine/device9ex.c  | 1 +
 src/gallium/state_trackers/nine/nine_state.c | 3 +++
 3 files changed, 5 insertions(+)

diff --git a/src/gallium/state_trackers/nine/device9.c b/src/gallium/state_trackers/nine/device9.c
index 6f2e5e9962..03564203df 100644
--- a/src/gallium/state_trackers/nine/device9.c
+++ b/src/gallium/state_trackers/nine/device9.c
@@ -919,6 +919,7 @@ NineDevice9_Reset( struct NineDevice9 *This,
             break;
     }
 
+    nine_csmt_process(This);
     nine_state_clear(&This->state, TRUE);
     nine_context_clear(This);
 
diff --git a/src/gallium/state_trackers/nine/device9ex.c b/src/gallium/state_trackers/nine/device9ex.c
index 30c8c65e2b..2853a813ba 100644
--- a/src/gallium/state_trackers/nine/device9ex.c
+++ b/src/gallium/state_trackers/nine/device9ex.c
@@ -257,6 +257,7 @@ NineDevice9Ex_Reset( struct NineDevice9Ex *This,
             break;
     }
 
+    nine_csmt_process(&This->base);
     nine_state_clear(&This->base.state, TRUE);
     nine_context_clear(&This->base);
 
diff --git a/src/gallium/state_trackers/nine/nine_state.c b/src/gallium/state_trackers/nine/nine_state.c
index 697e216436..8909692594 100644
--- a/src/gallium/state_trackers/nine/nine_state.c
+++ b/src/gallium/state_trackers/nine/nine_state.c
@@ -2995,6 +2995,9 @@ static const DWORD nine_samp_state_defaults[NINED3DSAMP_LAST + 1] =
     [NINED3DSAMP_CUBETEX] = 0
 };
 
+/* Note: The following 4 functions assume there is no
+ * pending commands */
+
 void nine_state_restore_non_cso(struct NineDevice9 *device)
 {
     struct nine_context *context = &device->context;
-- 
2.11.0



More information about the mesa-dev mailing list