summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/freedreno/freedreno_context.h
diff options
context:
space:
mode:
authorRob Clark <[email protected]>2014-01-08 10:06:52 -0500
committerRob Clark <[email protected]>2014-01-08 16:30:18 -0500
commit725d736f6a6a14d10223888d585ddab80ee803f0 (patch)
tree6a179b0ee61b07db32eedb8ac85ce47282bafc73 /src/gallium/drivers/freedreno/freedreno_context.h
parentc0766528baaef48902c87bbdaa4f5926c472269b (diff)
freedreno/a3xx: use cs patch instead of RFI+RMW
Since we now have the cmdstream patch mechanism needed for hw binning, might as well also use it for RB_RENDER_CONTROL updates. This avoids the need to use RMW (and associated WFI) to update RB_RENDER_CONTROL. Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno/freedreno_context.h')
-rw-r--r--src/gallium/drivers/freedreno/freedreno_context.h18
1 files changed, 4 insertions, 14 deletions
diff --git a/src/gallium/drivers/freedreno/freedreno_context.h b/src/gallium/drivers/freedreno/freedreno_context.h
index a0227e49c03..5373de6c638 100644
--- a/src/gallium/drivers/freedreno/freedreno_context.h
+++ b/src/gallium/drivers/freedreno/freedreno_context.h
@@ -159,16 +159,7 @@ struct fd_context {
/* Keep track if WAIT_FOR_IDLE is needed for registers we need
* to update via RMW:
*/
- struct {
- bool need_wfi;
- /* note: would be nicer to have in fd3_context, fd2_context,
- * etc, because the registered modified via RMR differ across
- * generation. But as long as it is a small set of registers
- * that might be more hassle than it's worth.
- */
- /* state for RB_RENDER_CONTROL: */
- uint32_t rbrc_draw;
- } rmw;
+ bool rmw_needs_wfi;
/* Keep track of DRAW initiators that need to be patched up depending
* on whether we using binning or not:
@@ -277,17 +268,16 @@ fd_supported_prim(struct fd_context *ctx, unsigned prim)
static INLINE void
fd_reset_rmw_state(struct fd_context *ctx)
{
- ctx->rmw.need_wfi = true;
- ctx->rmw.rbrc_draw = ~0;
+ ctx->rmw_needs_wfi = true;
}
/* emit before a RMW a WAIT_FOR_IDLE only if needed: */
static inline void
fd_rmw_wfi(struct fd_context *ctx, struct fd_ringbuffer *ring)
{
- if (ctx->rmw.need_wfi) {
+ if (ctx->rmw_needs_wfi) {
OUT_WFI(ring);
- ctx->rmw.need_wfi = false;
+ ctx->rmw_needs_wfi = false;
}
}