iris: fix pull bufs that aren't the first user upload
authorKenneth Graunke <kenneth@whitecape.org>
Thu, 7 Jun 2018 07:23:23 +0000 (00:23 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 21 Feb 2019 18:26:06 +0000 (10:26 -0800)
src/gallium/drivers/iris/iris_state.c

index d47c90f32fb74e0311b457544b9e8488abc2efd3..dcf5c62f9a8ef556d02b3aa48ca6ca7654d6cc7e 100644 (file)
@@ -1373,7 +1373,7 @@ iris_set_constant_buffer(struct pipe_context *ctx,
       cbuf->surface_state_offset += iris_bo_offset_from_base_address(surf_bo);
 
       isl_buffer_fill_state(&screen->isl_dev, map,
-                            .address = res->bo->gtt_offset,
+                            .address = res->bo->gtt_offset + cbuf->offset,
                             .size_B = input->buffer_size,
                             .format = ISL_FORMAT_R32G32B32A32_FLOAT,
                             .stride_B = 1,