From 628f435be4359e6ae8ecfdda9b492053be76a057 Mon Sep 17 00:00:00 2001
From: Philipp Zabel
Date: Tue, 25 Feb 2014 11:55:04 +0100
Subject: [PATCH] imx-drm: parallel-display: Add drm_panel support
This patch allows to optionally attach the parallel-display to a panel
supported by a drm_panel driver instead of supplying the modes via
device tree.
Before:
parallel-display {
compatible = "fsl,imx-parallel-display";
...
display-timings {
native-timing = <&timing1>;
timing1: etm0700g0dh6 {
hactive = <800>;
vactive = <480>;
clock-frequency = <33260000>;
hsync-len = <128>;
hback-porch = <88>;
hfront-porch = <40>;
vsync-len = <2>;
vback-porch = <33>;
vfront-porch = <10>;
hsync-active = <0>;
vsync-active = <0>;
...
};
};
...
};
After:
parallel-display {
compatible = "fsl,imx-parallel-display";
fsl,panel = <&panel>;
...
};
panel: panel {
compatible = "edt,etm0700g0dh6", "simple-panel";
};
Signed-off-by: Philipp Zabel
Signed-off-by: Greg Kroah-Hartman
---
drivers/staging/imx-drm/Kconfig | 1 +
drivers/staging/imx-drm/parallel-display.c | 23 ++++++++++++++++++++++
2 files changed, 24 insertions(+)
diff --git a/drivers/staging/imx-drm/Kconfig b/drivers/staging/imx-drm/Kconfig
index 78319ad176c..c6e8ba7b3e4 100644
--- a/drivers/staging/imx-drm/Kconfig
+++ b/drivers/staging/imx-drm/Kconfig
@@ -20,6 +20,7 @@ config DRM_IMX_FB_HELPER
config DRM_IMX_PARALLEL_DISPLAY
tristate "Support for parallel displays"
+ select DRM_PANEL
depends on DRM_IMX
select VIDEOMODE_HELPERS
diff --git a/drivers/staging/imx-drm/parallel-display.c b/drivers/staging/imx-drm/parallel-display.c
index d610f0726bb..6bce1405efd 100644
--- a/drivers/staging/imx-drm/parallel-display.c
+++ b/drivers/staging/imx-drm/parallel-display.c
@@ -23,6 +23,7 @@
#include
#include
#include
+#include
#include
#include