Skip to contentSkip to conversation

drm/amd/display: validate plane format on primary plane

PATCH New Shirish S 1 participant 1 message Mar 7, 2018

Subsystems (3)
lore
Share & tools
lore

Shirish S

author
#0 lore raw

PATCH 1/1 drm/amd/display: validate plane format on primary plane

In dce110, the plane configuration is such that plane 0 or the primary plane should be rendered with only RGB data.

This patch adds the validation to ensure that no video data is rendered on plane 0.

---
 drivers/gpu/drm/amd/display/dc/dce110/dce110_resource.c | 7 +++++++
 1 file changed, 7 insertions(+)
drivers/gpu/drm/amd/display/dc/dce110/dce110_resource.c +7 -0
index 830cbbc..b1f14be 100644
@@ -879,6 +879,13 @@ static bool dce110_validate_surface_sets(
 					plane->src_rect.height > 1080))
 					return false;
 
+				/* we don't have the logic to support underlay
+				 * only yet so block the use case where we get
+				 * NV12 plane as top layer
+				 */
+				if (j == 0)
+					return false;
+
 				/* irrespective of plane format,
 				 * stream should be RGB encoded
 				 */
Signature · 6 lines
2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx