aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/freedreno/a3xx/fd3_program.c
diff options
context:
space:
mode:
authorIlia Mirkin <[email protected]>2020-05-17 18:05:42 -0400
committerIlia Mirkin <[email protected]>2020-05-17 19:51:10 -0400
commit1c05e16666c78a099fd8c732fc6156a85950ee6a (patch)
tree52e46cf6b6837901ebfd01e5c49a138a74b49842 /src/gallium/drivers/freedreno/a3xx/fd3_program.c
parent9048adbd246c725ae80942b6b56a742ad02295dc (diff)
freedreno/a3xx: fix const footprint
In commit 5d8f40a53a5, the change was done incorrectly, switching from max_const to constlen + 1. Instead it should have been constlen - 1, which is the analog to the former max_const. Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Rob Clark <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5077>
Diffstat (limited to 'src/gallium/drivers/freedreno/a3xx/fd3_program.c')
-rw-r--r--src/gallium/drivers/freedreno/a3xx/fd3_program.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gallium/drivers/freedreno/a3xx/fd3_program.c b/src/gallium/drivers/freedreno/a3xx/fd3_program.c
index 93773358d1a..ad1861f273d 100644
--- a/src/gallium/drivers/freedreno/a3xx/fd3_program.c
+++ b/src/gallium/drivers/freedreno/a3xx/fd3_program.c
@@ -231,7 +231,7 @@ fd3_program_emit(struct fd_ringbuffer *ring, struct fd3_emit *emit,
A3XX_SP_VS_CTRL_REG0_LENGTH(vpbuffersz));
OUT_RING(ring, A3XX_SP_VS_CTRL_REG1_CONSTLENGTH(vp->constlen) |
A3XX_SP_VS_CTRL_REG1_INITIALOUTSTANDING(vp->total_in) |
- A3XX_SP_VS_CTRL_REG1_CONSTFOOTPRINT(MAX2(vp->constlen + 1, 0)));
+ A3XX_SP_VS_CTRL_REG1_CONSTFOOTPRINT(MAX2(vp->constlen - 1, 0)));
OUT_RING(ring, A3XX_SP_VS_PARAM_REG_POSREGID(pos_regid) |
A3XX_SP_VS_PARAM_REG_PSIZEREGID(psize_regid) |
A3XX_SP_VS_PARAM_REG_TOTALVSOUTVAR(fp->varying_in));
@@ -302,7 +302,7 @@ fd3_program_emit(struct fd_ringbuffer *ring, struct fd3_emit *emit,
A3XX_SP_FS_CTRL_REG0_LENGTH(fpbuffersz));
OUT_RING(ring, A3XX_SP_FS_CTRL_REG1_CONSTLENGTH(fp->constlen) |
A3XX_SP_FS_CTRL_REG1_INITIALOUTSTANDING(fp->total_in) |
- A3XX_SP_FS_CTRL_REG1_CONSTFOOTPRINT(MAX2(fp->constlen + 1, 0)) |
+ A3XX_SP_FS_CTRL_REG1_CONSTFOOTPRINT(MAX2(fp->constlen - 1, 0)) |
A3XX_SP_FS_CTRL_REG1_HALFPRECVAROFFSET(63));
OUT_PKT0(ring, REG_A3XX_SP_FS_OBJ_OFFSET_REG, 2);