From: Laurentiu Palcu Date: Fri, 31 Aug 2018 10:58:01 +0000 (+0300) Subject: MLK-19419: drm: imx: dcss: Add linear modifier support for all formats X-Git-Tag: rel_imx_4.19.35_1.1.0~1193 X-Git-Url: https://git.somdevices.com/?a=commitdiff_plain;h=536c148e536785ae15f84ea7be04276c47a378d6;p=linux.git MLK-19419: drm: imx: dcss: Add linear modifier support for all formats Tiled formats are supported only for YUV420 semi-planar formats. However, the other formats should support at least the LINEAR modifier. Some userspace app may pass on framebuffers with the linear modifier attached and, currently, this is rejected for YUV422 and RGB formats. This patch fixes that. Signed-off-by: Laurentiu Palcu Reported-by: Jared Hu --- diff --git a/drivers/gpu/drm/imx/dcss/dcss-plane.c b/drivers/gpu/drm/imx/dcss/dcss-plane.c index 61e2866525b1..9edb1cf48684 100644 --- a/drivers/gpu/drm/imx/dcss/dcss-plane.c +++ b/drivers/gpu/drm/imx/dcss/dcss-plane.c @@ -158,7 +158,7 @@ static bool dcss_plane_format_mod_supported(struct drm_plane *plane, modifier == DRM_FORMAT_MOD_VSI_G2_TILED || modifier == DRM_FORMAT_MOD_VSI_G2_TILED_COMPRESSED; default: - return false; + return modifier == DRM_FORMAT_MOD_LINEAR; } break; default: