turnip: clamp sampler minLod/maxLod
authorJonathan Marek <jonathan@marek.ca>
Sun, 7 Jun 2020 02:08:41 +0000 (22:08 -0400)
committerMarge Bot <eric+marge@anholt.net>
Mon, 8 Jun 2020 19:52:41 +0000 (19:52 +0000)
commit88d5917cc1c5bd0dec26147a8779b50e94e56dd1
tree937e5e5f6c321fcbe0c112c49ebec57a3494dd89
parentfecd83a0e8e8e19c5cceaf892cfad0f1b9c1dbc9
turnip: clamp sampler minLod/maxLod

Otherwise A6XX_TEX_SAMP_1_{MIN,MAX}_LOD silently overflows.

This fixes these tests:
dEQP-VK.texture.explicit_lod.2d.derivatives.*

Signed-off-by: Jonathan Marek <jonathan@marek.ca>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5375>
src/freedreno/vulkan/tu_device.c