Mesa (master): turnip: use buffer size instead of bo size for VFD_FETCH_SIZE

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Thu Apr 9 02:17:21 UTC 2020


Module: Mesa
Branch: master
Commit: 420ca1e4a1814c86af5fabff8658526a6e2baab1
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=420ca1e4a1814c86af5fabff8658526a6e2baab1

Author: Jonathan Marek <jonathan at marek.ca>
Date:   Wed Apr  8 19:43:24 2020 -0400

turnip: use buffer size instead of bo size for VFD_FETCH_SIZE

Signed-off-by: Jonathan Marek <jonathan at marek.ca>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4224>

---

 src/freedreno/vulkan/tu_cmd_buffer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/freedreno/vulkan/tu_cmd_buffer.c b/src/freedreno/vulkan/tu_cmd_buffer.c
index e629c941ef2..1a01e67267b 100644
--- a/src/freedreno/vulkan/tu_cmd_buffer.c
+++ b/src/freedreno/vulkan/tu_cmd_buffer.c
@@ -3443,7 +3443,7 @@ tu6_bind_draw_states(struct tu_cmd_buffer *cmd,
          const VkDeviceSize offset = buf->bo_offset +
                                      cmd->state.vb.offsets[binding];
          const VkDeviceSize size =
-            offset < buf->bo->size ? buf->bo->size - offset : 0;
+            offset < buf->size ? buf->size - offset : 0;
 
          tu_cs_emit_regs(cs,
                          A6XX_VFD_FETCH_BASE(i, .bo = buf->bo, .bo_offset = offset),



More information about the mesa-commit mailing list