From: Rob Clark Date: Tue, 5 Jun 2018 13:50:26 +0000 (-0400) Subject: freedreno/a5xx: correct image/ssbo offset X-Git-Tag: upstream/19.0.0~4693 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e9fc9c16c9d0e3c2a8688e06ab33c35f28671ec5;p=platform%2Fupstream%2Fmesa.git freedreno/a5xx: correct image/ssbo offset Signed-off-by: Rob Clark --- diff --git a/src/gallium/drivers/freedreno/a5xx/fd5_image.c b/src/gallium/drivers/freedreno/a5xx/fd5_image.c index a945e7e..6699375 100644 --- a/src/gallium/drivers/freedreno/a5xx/fd5_image.c +++ b/src/gallium/drivers/freedreno/a5xx/fd5_image.c @@ -84,7 +84,7 @@ static void translate_image(struct fd5_image *img, struct pipe_image_view *pimg) img->array_pitch = 0; } else { lvl = pimg->u.tex.level; - img->offset = rsc->slices[lvl].offset; + img->offset = fd_resource_offset(rsc, lvl, pimg->u.tex.first_layer); img->pitch = rsc->slices[lvl].pitch * rsc->cpp; img->array_pitch = rsc->layer_size; }