panfrost: Only clamp the LOD to disable mipmapping when needed
authorTomeu Vizoso <tomeu.vizoso@collabora.com>
Tue, 4 Feb 2020 07:57:52 +0000 (08:57 +0100)
committerTomeu Vizoso <tomeu.vizoso@collabora.com>
Tue, 4 Feb 2020 14:46:26 +0000 (15:46 +0100)
commit64541dd69875d043d90525769901d18fdde4b68b
tree81c7957440c34db01ba5842cde526e9cfbf96243
parent255227ececb4444fdf5cc2925fc1064d729021f4
panfrost: Only clamp the LOD to disable mipmapping when needed

Otherwise, we may be incrementing max_lod over the limit, causing a
DATA_INVALID_FAULT.

Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3692>
src/gallium/drivers/panfrost/pan_context.c