diff options
-rw-r--r-- | src/intel_batchbuffer.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/intel_batchbuffer.h b/src/intel_batchbuffer.h index 3f783b00..0d6c3f72 100644 --- a/src/intel_batchbuffer.h +++ b/src/intel_batchbuffer.h @@ -63,8 +63,10 @@ static inline void intel_batch_start_atomic(ScrnInfoPtr scrn, unsigned int sz) assert(!intel->in_batch_atomic); - if (intel->current_batch != RENDER_BATCH) - intel_batch_submit(scrn, FALSE); + if (intel->current_batch != RENDER_BATCH) { + if (intel->current_batch && intel->context_switch) + intel->context_switch(intel, RENDER_BATCH); + } intel_batch_require_space(scrn, intel, sz * 4); intel->current_batch = RENDER_BATCH; |