freedreno: Fix resource layout dump loop.

Apparently I've never dumped a fully populated slices array, so the 0-init
always terminated the loop.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5020>
This commit is contained in:
Eric Anholt
2020-05-12 14:41:53 -07:00
committed by Marge Bot
parent 2eb180db94
commit a6fe0799fa
+1 -1
View File
@@ -45,7 +45,7 @@ fdl_layout_buffer(struct fdl_layout *layout, uint32_t size)
void
fdl_dump_layout(struct fdl_layout *layout)
{
for (uint32_t level = 0; level < layout->slices[level].size0; level++) {
for (uint32_t level = 0; level < ARRAY_SIZE(layout->slices) && layout->slices[level].size0; level++) {
struct fdl_slice *slice = &layout->slices[level];
struct fdl_slice *ubwc_slice = &layout->ubwc_slices[level];