summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorRob Clark <[email protected]>2016-12-01 13:57:22 -0500
committerRob Clark <[email protected]>2016-12-06 18:01:31 -0500
commitf143eeaffa3c0df7acd6a4c2816a6444de44b2fc (patch)
tree97a1da6e199e661e00763bacd49a4fce76e167fd /src/gallium
parentf5c5f7625552ba76d38184e19187a4badfc52dbc (diff)
freedreno/a5xx: fix fragcoord
Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/drivers/freedreno/a5xx/fd5_program.c15
1 files changed, 11 insertions, 4 deletions
diff --git a/src/gallium/drivers/freedreno/a5xx/fd5_program.c b/src/gallium/drivers/freedreno/a5xx/fd5_program.c
index a7ac81312db..f9ff8f52bba 100644
--- a/src/gallium/drivers/freedreno/a5xx/fd5_program.c
+++ b/src/gallium/drivers/freedreno/a5xx/fd5_program.c
@@ -441,9 +441,6 @@ fd5_program_emit(struct fd_ringbuffer *ring, struct fd5_emit *emit,
A5XX_HLSQ_CONTROL_4_REG_ZWCOORDREGID(zwcoord_regid) |
0x0000fcfc); /* XXX */
- OUT_PKT4(ring, REG_A5XX_GRAS_CNTL, 1);
- OUT_RING(ring, COND(s[FS].v->total_in > 0, A5XX_GRAS_CNTL_VARYING));
-
OUT_PKT4(ring, REG_A5XX_SP_FS_CTRL_REG0, 1);
OUT_RING(ring, COND(s[FS].v->total_in > 0, A5XX_SP_FS_CTRL_REG0_VARYING) |
0x4000e | /* XXX set pretty much everywhere */
@@ -461,13 +458,23 @@ fd5_program_emit(struct fd_ringbuffer *ring, struct fd5_emit *emit,
OUT_PKT4(ring, REG_A5XX_SP_SP_CNTL, 1);
OUT_RING(ring, 0x00000010); /* XXX */
+ OUT_PKT4(ring, REG_A5XX_GRAS_CNTL, 1);
+ OUT_RING(ring, COND(s[FS].v->total_in > 0, A5XX_GRAS_CNTL_VARYING) |
+ COND(s[FS].v->frag_coord, A5XX_GRAS_CNTL_XCOORD |
+ A5XX_GRAS_CNTL_YCOORD |
+ A5XX_GRAS_CNTL_ZCOORD |
+ A5XX_GRAS_CNTL_WCOORD |
+ A5XX_GRAS_CNTL_UNK3));
+
OUT_PKT4(ring, REG_A5XX_RB_RENDER_CONTROL0, 3);
OUT_RING(ring,
COND(s[FS].v->total_in > 0, A5XX_RB_RENDER_CONTROL0_VARYING) |
COND(s[FS].v->frag_coord, A5XX_RB_RENDER_CONTROL0_XCOORD |
A5XX_RB_RENDER_CONTROL0_YCOORD |
A5XX_RB_RENDER_CONTROL0_ZCOORD |
- A5XX_RB_RENDER_CONTROL0_WCOORD));
+ A5XX_RB_RENDER_CONTROL0_WCOORD |
+ A5XX_RB_RENDER_CONTROL0_UNK3));
+
OUT_RING(ring,
COND(s[FS].v->frag_face, A5XX_RB_RENDER_CONTROL1_FACENESS));
OUT_RING(ring, A5XX_RB_FS_OUTPUT_CNTL_MRT(nr) |