mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Barebox List <barebox@lists.infradead.org>
Subject: [PATCH 06/13] ARM: i.MX51 Efikasb: update device tree
Date: Thu,  9 Jul 2015 09:24:10 +0200	[thread overview]
Message-ID: <1436426657-5266-7-git-send-email-s.hauer@pengutronix.de> (raw)
In-Reply-To: <1436426657-5266-1-git-send-email-s.hauer@pengutronix.de>

Use the correct display pins (which are DISP2* and not DISP1*) and
use the of_graph bindings to describe the video hardware.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 arch/arm/dts/imx51-genesi-efika-sb.dts | 128 ++++++++++++++++++++++-----------
 1 file changed, 87 insertions(+), 41 deletions(-)

diff --git a/arch/arm/dts/imx51-genesi-efika-sb.dts b/arch/arm/dts/imx51-genesi-efika-sb.dts
index 9772259..78cb1b7 100644
--- a/arch/arm/dts/imx51-genesi-efika-sb.dts
+++ b/arch/arm/dts/imx51-genesi-efika-sb.dts
@@ -90,12 +90,34 @@
 		mux-ext-port = <3>;
 	};
 
-	backlight {
+	backlight: backlight {
 		compatible = "pwm-backlight";
+		enable-gpios = <&gpio4 12 GPIO_ACTIVE_LOW>;
 		pwms = <&pwm1 0 78770>;
-		brightness-levels = <0 4 8 16 32 64 128 255>;
-		default-brightness-level = <6>;
-        };
+		brightness-levels = <0 1 2 4 8 16 32 64 128 255>;
+		default-brightness-level = <9>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&pinctrl_backlight>;
+	};
+
+	panel {
+		compatible = "simple-panel";
+		backlight = <&backlight>;
+		enable-gpios = <&gpio3 13 GPIO_ACTIVE_HIGH>;
+		ddc-i2c-bus = <&i2c2>;
+		enable-delay = <200>;
+
+		port {
+			panel_in: endpoint {
+				remote-endpoint = <&mtl017_out>;
+			};
+		};
+	};
+
+	lvds_reg: lvds_regulator {
+		compatible = "regulator-fixed";
+		gpio = <&gpio3 7 GPIO_ACTIVE_HIGH>;
+	};
 };
 
 &ssi1 {
@@ -115,16 +137,17 @@
 				MX51_PAD_DI1_PIN12__GPIO3_1 0x80000000		/* WLAN switch */
 				MX51_PAD_EIM_A17__GPIO2_11  0x80000000		/* Bluetooth power */
 				MX51_PAD_EIM_A23__GPIO2_17 0x80000000		/* Audio amp enable, 1 = on */
-				MX51_PAD_CSI1_D8__GPIO3_12 0x80000000		/* LVDS enable, 1 = on */
-				MX51_PAD_GPIO1_2__GPIO1_2 0x80000000		/* Backlight PWM */
-				MX51_PAD_CSI2_D19__GPIO4_12 0x80000000		/* Backlight power, 0 = on */
-				MX51_PAD_DISPB2_SER_DIN__GPIO3_5 0x80000000	/* LVDS reset (1 = reset) */
-				MX51_PAD_DISPB2_SER_CLK__GPIO3_7 0x80000000	/* LVDS power, 1 = on */
-				MX51_PAD_CSI1_D9__GPIO3_13 0x80000000		/* LCD enable (1 = on */
 				MX51_PAD_NANDF_CS0__GPIO3_16 0x80000000		/* Camera power, 0 = on */
 				MX51_PAD_GPIO1_5__GPIO1_5 0x80000000		/* USB hub reset, 0 = reset */
 				MX51_PAD_EIM_D27__GPIO2_9  0x80000000		/* USB phy reset, 0 = reset */
 				MX51_PAD_CSPI1_RDY__GPIO4_26 0x80000000		/* Audio clk enable */
+				MX51_PAD_CSI2_D19__GPIO4_12 0x80000000		/* Backlight power, 0 = on */
+			>;
+		};
+
+		pinctrl_backlight: backlightgrp {
+			fsl,pins = <
+				MX51_PAD_GPIO1_2__PWM1_PWMO 0x80000000		/* Backlight PWM */
 			>;
 		};
 
@@ -187,34 +210,32 @@
 			>;
 		};
 
-		pinctrl_ipu_disp1: ipudisp1grp {
+		pinctrl_ipu_disp2: ipudisp2grp {
 			fsl,pins = <
-				MX51_PAD_DISP1_DAT0__DISP1_DAT0	0x5
-				MX51_PAD_DISP1_DAT1__DISP1_DAT1	0x5
-				MX51_PAD_DISP1_DAT2__DISP1_DAT2	0x5
-				MX51_PAD_DISP1_DAT3__DISP1_DAT3	0x5
-				MX51_PAD_DISP1_DAT4__DISP1_DAT4	0x5
-				MX51_PAD_DISP1_DAT5__DISP1_DAT5	0x5
-				MX51_PAD_DISP1_DAT6__DISP1_DAT6	0x5
-				MX51_PAD_DISP1_DAT7__DISP1_DAT7	0x5
-				MX51_PAD_DISP1_DAT8__DISP1_DAT8	0x5
-				MX51_PAD_DISP1_DAT9__DISP1_DAT9	0x5
-				MX51_PAD_DISP1_DAT10__DISP1_DAT10 0x5
-				MX51_PAD_DISP1_DAT11__DISP1_DAT11 0x5
-				MX51_PAD_DISP1_DAT12__DISP1_DAT12 0x5
-				MX51_PAD_DISP1_DAT13__DISP1_DAT13 0x5
-				MX51_PAD_DISP1_DAT14__DISP1_DAT14 0x5
-				MX51_PAD_DISP1_DAT15__DISP1_DAT15 0x5
-				MX51_PAD_DISP1_DAT16__DISP1_DAT16 0x5
-				MX51_PAD_DISP1_DAT17__DISP1_DAT17 0x5
-				MX51_PAD_DISP1_DAT18__DISP1_DAT18 0x5
-				MX51_PAD_DISP1_DAT19__DISP1_DAT19 0x5
-				MX51_PAD_DISP1_DAT20__DISP1_DAT20 0x5
-				MX51_PAD_DISP1_DAT21__DISP1_DAT21 0x5
-				MX51_PAD_DISP1_DAT22__DISP1_DAT22 0x5
-				MX51_PAD_DISP1_DAT23__DISP1_DAT23 0x5
-				MX51_PAD_DI1_PIN2__DI1_PIN2 0x5
-				MX51_PAD_DI1_PIN3__DI1_PIN3 0x5
+				MX51_PAD_DISP2_DAT0__DISP2_DAT0     0x5
+				MX51_PAD_DISP2_DAT1__DISP2_DAT1     0x5
+				MX51_PAD_DISP2_DAT2__DISP2_DAT2     0x5
+				MX51_PAD_DISP2_DAT3__DISP2_DAT3     0x5
+				MX51_PAD_DISP2_DAT4__DISP2_DAT4     0x5
+				MX51_PAD_DISP2_DAT5__DISP2_DAT5     0x5
+				MX51_PAD_DISP2_DAT6__DISP2_DAT6     0x5
+				MX51_PAD_DISP2_DAT7__DISP2_DAT7     0x5
+				MX51_PAD_DISP2_DAT8__DISP2_DAT8     0x5
+				MX51_PAD_DISP2_DAT9__DISP2_DAT9     0x5
+				MX51_PAD_DISP2_DAT10__DISP2_DAT10   0x5
+				MX51_PAD_DISP2_DAT11__DISP2_DAT11   0x5
+				MX51_PAD_DISP2_DAT12__DISP2_DAT12   0x5
+				MX51_PAD_DISP2_DAT13__DISP2_DAT13   0x5
+				MX51_PAD_DISP2_DAT14__DISP2_DAT14   0x5
+				MX51_PAD_DISP2_DAT15__DISP2_DAT15   0x5
+				MX51_PAD_DI2_PIN2__DI2_PIN2         0x5 /* hsync */
+				MX51_PAD_DI2_PIN3__DI2_PIN3         0x5 /* vsync */
+				MX51_PAD_DI2_DISP_CLK__DI2_DISP_CLK 0x5
+				MX51_PAD_DI_GP4__DI2_PIN15          0x5
+				MX51_PAD_CSI1_D8__GPIO3_12 0x80000000		/* LVDS enable, 1 = on */
+				MX51_PAD_DISPB2_SER_DIN__GPIO3_5 0x80000000	/* LVDS reset (1 = reset) */
+				MX51_PAD_DISPB2_SER_CLK__GPIO3_7 0x80000000	/* LVDS power, 1 = on */
+				MX51_PAD_CSI1_D9__GPIO3_13 0x80000000		/* LCD enable (1 = on */
 			>;
 		};
 
@@ -342,13 +363,38 @@
 	};
 
 	lvds: mtl017@3a {
+		#address-cells = <1>;
+		#size-cells = <0>;
 		compatible = "mtl017";
 		pinctrl-names = "default";
-		pinctrl-0 = <&pinctrl_ipu_disp1>;
+		pinctrl-0 = <&pinctrl_ipu_disp2>;
+		enable-gpios =  <&gpio3 12 GPIO_ACTIVE_HIGH>;
+		reset-gpios =  <&gpio3 5 GPIO_ACTIVE_HIGH>;
+		vdd-supply = <&lvds_reg>;
 		reg = <0x3a>;
-		crtcs = <&ipu 1>;
-		edid-i2c = <&i2c2>;
-		interface-pix-fmt = "rgb565";
+
+		port@0 {
+			reg = <0>;
+
+			mtl017_in: endpoint {
+				remote-endpoint = <&ipu_di1_disp1>;
+			};
+		};
+
+		port@1 {
+			reg = <1>;
+
+			mtl017_out: endpoint {
+				remote-endpoint = <&panel_in>;
+			};
+		};
+	};
+};
+
+&ipu_di1 {
+	interface-pix-fmt = "rgb565";
+	endpoint {
+		remote-endpoint = <&mtl017_in>;
 	};
 };
 
-- 
2.1.4


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  parent reply	other threads:[~2015-07-09  7:25 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-09  7:24 Video support for EfikaSB Sascha Hauer
2015-07-09  7:24 ` [PATCH 01/13] of: base: implement of_get_next_child Sascha Hauer
2015-07-09  7:24 ` [PATCH 02/13] of: import of_graph functions Sascha Hauer
2015-07-09  7:24 ` [PATCH 03/13] of_graph: add of_graph_port_is_available Sascha Hauer
2015-07-09  7:24 ` [PATCH 04/13] ARM: i.MX51 Efikasb: Disable backlight earlier Sascha Hauer
2015-07-09  7:24 ` [PATCH 05/13] ARM: i.MX51 Efikasb: make more space for barebox Sascha Hauer
2015-07-09  7:24 ` Sascha Hauer [this message]
2015-07-09  7:24 ` [PATCH 07/13] video: Add Video Pipeline (VPL) support Sascha Hauer
2015-07-09  7:24 ` [PATCH 08/13] video: Add MTL017 LVDS encoder support Sascha Hauer
2015-07-09  7:24 ` [PATCH 09/13] video: Add missing prototype for display_timings_release Sascha Hauer
2015-07-09  7:24 ` [PATCH 10/13] video: ipuv3: remove unused variable Sascha Hauer
2015-07-09  7:24 ` [PATCH 11/13] video: ipuv3: Replace ipu_output with VPL Sascha Hauer
2015-07-09  7:24 ` [PATCH 12/13] video: ipuv3: match ipu_di_signal_cfg's clk_pol with its description Sascha Hauer
2015-07-09  7:24 ` [PATCH 13/13] video: Add simple-panel support Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1436426657-5266-7-git-send-email-s.hauer@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox