zink: fix ZINK_MAX_DESCRIPTORS_PER_TYPE to stop exploding the stack

this isn't the max per type, it's the max that can be used for a type,
which is the max used by a shader stage * the number of shader stages

Cc: mesa-stable

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12829>
This commit is contained in:
Mike Blumenkrantz 2021-09-13 07:49:54 -04:00 committed by Marge Bot
parent a601cae51c
commit a45c84f226

View file

@ -48,7 +48,7 @@ enum zink_descriptor_type {
ZINK_DESCRIPTOR_TYPES,
};
#define ZINK_MAX_DESCRIPTORS_PER_TYPE 32
#define ZINK_MAX_DESCRIPTORS_PER_TYPE (32 * ZINK_SHADER_COUNT)
struct zink_descriptor_refs {
struct util_dynarray refs;