panfrost: Simplify attribute format expression

Chew through a layer of indirection for clarity.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16035>
This commit is contained in:
Alyssa Rosenzweig 2022-04-19 09:54:12 -04:00 committed by Marge Bot
parent 603c06d00f
commit 2a027abfcf
1 changed files with 1 additions and 3 deletions

View File

@ -3720,9 +3720,7 @@ panfrost_create_vertex_elements_state(
for (int i = 0; i < num_elements; ++i) {
enum pipe_format fmt = elements[i].src_format;
const struct util_format_description *desc = util_format_description(fmt);
so->formats[i] = dev->formats[desc->format].hw;
assert(so->formats[i]);
so->formats[i] = dev->formats[fmt].hw;
}
/* Let's also prepare vertex builtins */