mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-09 10:30:13 +01:00
freedreno/a6xx: Fix use of uninitialized img->level in the SSBO/image path.
I think enough things lined up that the uninitialized level in the buffer paths would end effectively not being used (no ubwc, not tiling anyway), but let's just zero-init it to be sure and quiet the compiler. Reviewed-by: Rob Clark <robdclark@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7664>
This commit is contained in:
parent
3390870cec
commit
530a32bb95
1 changed files with 2 additions and 0 deletions
|
|
@ -91,6 +91,7 @@ static void translate_image(struct fd6_image *img, const struct pipe_image_view
|
|||
img->width = sz & MASK(15);
|
||||
img->height = sz >> 15;
|
||||
img->depth = 0;
|
||||
img->level = 0;
|
||||
} else {
|
||||
img->buffer = false;
|
||||
|
||||
|
|
@ -155,6 +156,7 @@ static void translate_buf(struct fd6_image *img, const struct pipe_shader_buffer
|
|||
img->offset = pimg->buffer_offset;
|
||||
img->pitch = 0;
|
||||
img->array_pitch = 0;
|
||||
img->level = 0;
|
||||
|
||||
/* size is encoded with low 15b in WIDTH and high bits in HEIGHT,
|
||||
* in units of elements:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue