radeonsi: fix HTILE for NPOT textures with mipmapping on SI/CI

VI uses addrlib so it's unaffected.

Cc: 18.1 18.2 <mesa-stable@lists.freedesktop.org>
Tested-by: Dieter Nützel <Dieter@nuetzel-hh.de>
(cherry picked from commit a1b9a00f82)
Conflicts resolved by Dylan

Conflicts:
	src/gallium/drivers/radeonsi/si_texture.c
This commit is contained in:
Marek Olšák 2018-08-28 15:49:31 -04:00 committed by Dylan Baker
parent 4670daa12d
commit aeb8b00661

View file

@ -1019,8 +1019,8 @@ static void si_texture_get_htile_size(struct si_screen *sscreen,
return;
}
width = align(rtex->resource.b.b.width0, cl_width * 8);
height = align(rtex->resource.b.b.height0, cl_height * 8);
width = align(rtex->surface.u.legacy.level[0].nblk_x, cl_width * 8);
height = align(rtex->surface.u.legacy.level[0].nblk_y, cl_height * 8);
slice_elements = (width * height) / (8 * 8);
slice_bytes = slice_elements * 4;