drm/meson: Reduce the FIFO lines held when AFBC is not used
authorCarlo Caione <ccaione@baylibre.com>
Mon, 19 Dec 2022 08:43:05 +0000 (09:43 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 12 Jan 2023 10:59:14 +0000 (11:59 +0100)
commitf34b03ce3a86af33a32d9a576391b771f01f2cba
tree3c017fe7ebe8cef99fa1df74b2265019dfdeca16
parent05a8410b0fce194c5006d48244cd3546b92d022f
drm/meson: Reduce the FIFO lines held when AFBC is not used

[ Upstream commit 3b754ed6d1cd90017e66e5cc16f3923e4a952ffc ]

Having a bigger number of FIFO lines held after vsync is only useful to
SoCs using AFBC to give time to the AFBC decoder to be reset, configured
and enabled again.

For SoCs not using AFBC this, on the contrary, is causing on some
displays issues and a few pixels vertical offset in the displayed image.

Conditionally increase the number of lines held after vsync only for
SoCs using AFBC, leaving the default value for all the others.

Fixes: 24e0d4058eff ("drm/meson: hold 32 lines after vsync to give time for AFBC start")
Signed-off-by: Carlo Caione <ccaione@baylibre.com>
Acked-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Acked-by: Neil Armstrong <neil.armstrong@linaro.org>
[narmstrong: added fixes tag]
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20221216-afbc_s905x-v1-0-033bebf780d9@baylibre.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/meson/meson_viu.c