panfrost: Align NPOT divisor records

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11123>
This commit is contained in:
Alyssa Rosenzweig 2021-06-03 15:06:05 -04:00 committed by Marge Bot
parent 1760511e02
commit afc4ebdcc0

View file

@ -1756,6 +1756,10 @@ panfrost_emit_vertex_data(struct panfrost_batch *batch,
unsigned magic_divisor =
panfrost_compute_magic_divisor(hw_divisor, &shift, &extra_flags);
/* Records with continuations must be aligned */
k = ALIGN_POT(k, 2);
attrib_to_buffer[i] = k;
pan_pack(bufs + k, ATTRIBUTE_BUFFER, cfg) {
cfg.type = MALI_ATTRIBUTE_TYPE_1D_NPOT_DIVISOR;
cfg.pointer = addr;