freedreno: Make the slice pitch be bytes, not pixels.
[mesa.git] / src / gallium / drivers / freedreno / a4xx / fd4_emit.c
index 8d07ceff9bbdec1ddbf783be10ef5b48cf636b93..7394993d5a769e74270d9f7c1f78e30cddc380e3 100644 (file)
@@ -323,7 +323,7 @@ fd4_emit_gmem_restore_tex(struct fd_ringbuffer *ring, unsigned nr_bufs,
                                                        PIPE_SWIZZLE_Z, PIPE_SWIZZLE_W));
                        OUT_RING(ring, A4XX_TEX_CONST_1_WIDTH(bufs[i]->width) |
                                        A4XX_TEX_CONST_1_HEIGHT(bufs[i]->height));
-                       OUT_RING(ring, A4XX_TEX_CONST_2_PITCH(slice->pitch * rsc->layout.cpp) |
+                       OUT_RING(ring, A4XX_TEX_CONST_2_PITCH(slice->pitch) |
                                        A4XX_TEX_CONST_2_FETCHSIZE(fd4_pipe2fetchsize(format)));
                        OUT_RING(ring, 0x00000000);
                        OUT_RELOC(ring, rsc->bo, offset, 0, 0);