Module: Mesa
Branch: 9.1
Commit: a650092fd6e5a78bc04832c485361c11f7200e80
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=a650092fd6e5a78bc04832c485361c11f7200e80

Author: Alex Deucher <alexander.deuc...@amd.com>
Date:   Fri Feb 22 17:04:43 2013 -0500

r600g: r6xx deadlock workaround (v6)

Fixes:
https://bugs.freedesktop.org/show_bug.cgi?id=50655
https://bugs.freedesktop.org/show_bug.cgi?id=47116

v2: flush along with workaround.
v3: just need a flush
v4: try WAIT_UNTIL
v5: switch to PS partial flush
v6: rework patch

Note: this is a candidate for the 9.1 branch.

Signed-off-by: Alex Deucher <alexander.deuc...@amd.com>
(cherry picked from commit 8442b67f5f3aedbfdb4446164dd09d4eaeda4888)

---

 src/gallium/drivers/r600/r600_state_common.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/src/gallium/drivers/r600/r600_state_common.c 
b/src/gallium/drivers/r600/r600_state_common.c
index c03ce3d..88bb62b 100644
--- a/src/gallium/drivers/r600/r600_state_common.c
+++ b/src/gallium/drivers/r600/r600_state_common.c
@@ -1359,6 +1359,12 @@ static void r600_draw_vbo(struct pipe_context *ctx, 
const struct pipe_draw_info
                rctx->vgt_state.atom.dirty = true;
        }
 
+       /* Workaround for hardware deadlock on certain R600 ASICs: write into a 
CB register. */
+       if (rctx->chip_class == R600) {
+               rctx->flags |= R600_CONTEXT_PS_PARTIAL_FLUSH;
+               rctx->cb_misc_state.atom.dirty = true;
+       }
+
        /* Emit states. */
        r600_need_cs_space(rctx, ib.user_buffer ? 5 : 0, TRUE);
        r600_flush_emit(rctx);

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to