diff options
Diffstat (limited to 'src/gallium/drivers/freedreno/freedreno_util.h')
-rw-r--r-- | src/gallium/drivers/freedreno/freedreno_util.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gallium/drivers/freedreno/freedreno_util.h b/src/gallium/drivers/freedreno/freedreno_util.h index cdac08be6e2..d8dec0151d0 100644 --- a/src/gallium/drivers/freedreno/freedreno_util.h +++ b/src/gallium/drivers/freedreno/freedreno_util.h @@ -355,6 +355,9 @@ OUT_WFI5(struct fd_ringbuffer *ring) static inline void __OUT_IB(struct fd_ringbuffer *ring, bool prefetch, struct fd_ringbuffer *target) { + if (target->cur == target->start) + return; + unsigned count = fd_ringbuffer_cmd_count(target); debug_assert(__gpu_id(ring) < 500); @@ -382,6 +385,9 @@ __OUT_IB(struct fd_ringbuffer *ring, bool prefetch, struct fd_ringbuffer *target static inline void __OUT_IB5(struct fd_ringbuffer *ring, struct fd_ringbuffer *target) { + if (target->cur == target->start) + return; + unsigned count = fd_ringbuffer_cmd_count(target); for (unsigned i = 0; i < count; i++) { |