aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/brcm2708/patches-4.14/950-0356-drm-vc4-Add-missing-formats-to-vc4_format_mod_suppor.patch
diff options
context:
space:
mode:
Diffstat (limited to 'target/linux/brcm2708/patches-4.14/950-0356-drm-vc4-Add-missing-formats-to-vc4_format_mod_suppor.patch')
-rw-r--r--target/linux/brcm2708/patches-4.14/950-0356-drm-vc4-Add-missing-formats-to-vc4_format_mod_suppor.patch33
1 files changed, 33 insertions, 0 deletions
diff --git a/target/linux/brcm2708/patches-4.14/950-0356-drm-vc4-Add-missing-formats-to-vc4_format_mod_suppor.patch b/target/linux/brcm2708/patches-4.14/950-0356-drm-vc4-Add-missing-formats-to-vc4_format_mod_suppor.patch
new file mode 100644
index 0000000000..bf9f9e2653
--- /dev/null
+++ b/target/linux/brcm2708/patches-4.14/950-0356-drm-vc4-Add-missing-formats-to-vc4_format_mod_suppor.patch
@@ -0,0 +1,33 @@
+From 0360325765bee2f76e11d42abf8e601320054230 Mon Sep 17 00:00:00 2001
+From: Eric Anholt <eric@anholt.net>
+Date: Fri, 16 Mar 2018 15:04:34 -0700
+Subject: [PATCH 356/454] drm/vc4: Add missing formats to
+ vc4_format_mod_supported().
+
+Daniel's format_mod_supported() patch predated Dave's for NV21/61, and
+I didn't catch that when rebasing. This is a problem since the
+formats are now getting validated before being passed to the driver's
+atomic hooks.
+
+Signed-off-by: Eric Anholt <eric@anholt.net>
+Acked-by: Daniel Stone <daniels@collabora.com>
+Cc: Dave Stevenson <dave.stevenson@raspberrypi.org>
+Fixes: 423ad7b3cbd1 ("drm/vc4: Advertise supported modifiers for planes")
+Link: https://patchwork.freedesktop.org/patch/msgid/20180316220435.31416-2-eric@anholt.net
+(cherry picked from commit 1e871d65e375280757833d9fce91dda71980bdf5)
+---
+ drivers/gpu/drm/vc4/vc4_plane.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+--- a/drivers/gpu/drm/vc4/vc4_plane.c
++++ b/drivers/gpu/drm/vc4/vc4_plane.c
+@@ -887,7 +887,9 @@ static bool vc4_format_mod_supported(str
+ case DRM_FORMAT_YUV420:
+ case DRM_FORMAT_YVU420:
+ case DRM_FORMAT_NV12:
++ case DRM_FORMAT_NV21:
+ case DRM_FORMAT_NV16:
++ case DRM_FORMAT_NV61:
+ default:
+ return (modifier == DRM_FORMAT_MOD_LINEAR);
+ }