linux_dsm_epyc7002/drivers/gpu/drm/rockchip
Alyssa Rosenzweig dab6fbf2b3 drm/rockchip: Require the YTR modifier for AFBC
commit 5f94e3571459abb626077aedb65d71264c2a58c0 upstream.

The AFBC decoder used in the Rockchip VOP assumes the use of the
YUV-like colourspace transform (YTR). YTR is lossless for RGB(A)
buffers, which covers the RGBA8 and RGB565 formats supported in
vop_convert_afbc_format. Use of YTR is signaled with the
AFBC_FORMAT_MOD_YTR modifier, which prior to this commit was missing. As
such, a producer would have to generate buffers that do not use YTR,
which the VOP would erroneously decode as YTR, leading to severe visual
corruption.

The upstream AFBC support was developed against a captured frame, which
failed to exercise modifier support. Prior to bring-up of AFBC in Mesa
(in the Panfrost driver), no open userspace respected modifier
reporting. As such, this change is not expected to affect broken
userspaces.

Tested on RK3399 with Panfrost and Weston.

Fixes: 7707f7227f ("drm/rockchip: Add support for afbc")
Cc: stable@vger.kernel.org
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Acked-by: Daniel Stone <daniels@collabora.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Link: https://patchwork.freedesktop.org/patch/msgid/20200811202631.3603-1-alyssa.rosenzweig@collabora.com
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-03-04 11:38:28 +01:00
..
analogix_dp-rockchip.c
cdn-dp-core.c
cdn-dp-core.h
cdn-dp-reg.c
cdn-dp-reg.h
dw_hdmi-rockchip.c
dw-mipi-dsi-rockchip.c
inno_hdmi.c
inno_hdmi.h
Kconfig
Makefile
rk3066_hdmi.c
rk3066_hdmi.h
rockchip_drm_drv.c
rockchip_drm_drv.h
rockchip_drm_fb.c
rockchip_drm_fb.h
rockchip_drm_fbdev.c
rockchip_drm_fbdev.h
rockchip_drm_gem.c drm-misc-next for 5.10: 2020-09-23 09:52:24 +10:00
rockchip_drm_gem.h
rockchip_drm_vop.c
rockchip_drm_vop.h drm/rockchip: Require the YTR modifier for AFBC 2021-03-04 11:38:28 +01:00
rockchip_lvds.c drm/rockchip: Avoid uninitialized use of endpoint id in LVDS 2020-11-29 17:33:32 +01:00
rockchip_lvds.h
rockchip_rgb.c
rockchip_rgb.h
rockchip_vop_reg.c
rockchip_vop_reg.h