[PATCH 8/9] drm/exynos/fimd: use polarization flags provided by drm_display_mode

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch replaces fimd private bindings for signal polarization by
polarization flags provided by drm_display_mode.

Signed-off-by: Andrzej Hajda <a.hajda@xxxxxxxxxxx>
---
 drivers/gpu/drm/exynos/exynos_drm_fimd.c | 12 +++++-------
 1 file changed, 5 insertions(+), 7 deletions(-)

diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c b/drivers/gpu/drm/exynos/exynos_drm_fimd.c
index 15d6b37..dbfad4e 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_fimd.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_fimd.c
@@ -115,7 +115,6 @@ struct fimd_context {
 	unsigned int			default_win;
 	unsigned long			irq_flags;
 	u32				vidcon0;
-	u32				vidcon1;
 	bool				suspended;
 	int				pipe;
 	wait_queue_head_t		wait_vsync_queue;
@@ -232,7 +231,11 @@ static void fimd_commit(struct exynos_drm_manager *mgr)
 		return;
 
 	/* setup polarity values */
-	vidcon1 = ctx->vidcon1;
+	vidcon1 = 0;
+	if (mode->pol_flags & DRM_MODE_FLAG_POL_DE_NEGEDGE)
+		vidcon1 |= VIDCON1_INV_VDEN;
+	if (mode->pol_flags & DRM_MODE_FLAG_POL_PIXDATA_NEGEDGE)
+		vidcon1 |= VIDCON1_INV_VCLK;
 	if (mode->flags & DRM_MODE_FLAG_NVSYNC)
 		vidcon1 |= VIDCON1_INV_VSYNC;
 	if (mode->flags & DRM_MODE_FLAG_NHSYNC)
@@ -875,11 +878,6 @@ static int fimd_probe(struct platform_device *pdev)
 	ctx->dev = dev;
 	ctx->suspended = true;
 
-	if (of_property_read_bool(dev->of_node, "samsung,invert-vden"))
-		ctx->vidcon1 |= VIDCON1_INV_VDEN;
-	if (of_property_read_bool(dev->of_node, "samsung,invert-vclk"))
-		ctx->vidcon1 |= VIDCON1_INV_VCLK;
-
 	ctx->bus_clk = devm_clk_get(dev, "fimd");
 	if (IS_ERR(ctx->bus_clk)) {
 		dev_err(dev, "failed to get bus clock\n");
-- 
1.8.3.2

_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux