Patchwork [PATCHv14,4/4] ARM: dts: imx25: mbimxsd25: Add displays support.

login
register
mail settings
Submitter Denis Carikli
Date Jan. 22, 2014, 5:09 p.m.
Message ID <1390410577-22073-4-git-send-email-denis@eukrea.com>
Download mbox | patch
Permalink /patch/313337/
State New
Headers show

Comments

Denis Carikli - Jan. 22, 2014, 5:09 p.m.
The CMO-QVGA(With backlight), DVI-VGA and DVI-SVGA displays
were added.

Cc: Eric Bénard <eric@eukrea.com>
Cc: Shawn Guo <shawn.guo@linaro.org>
Cc: Sascha Hauer <kernel@pengutronix.de>
Cc: linux-arm-kernel@lists.infradead.org
Signed-off-by: Denis Carikli <denis@eukrea.com>
---
ChangeLog v13->v14:
- Remove people not concerned by this patch from the Cc list.
- changed the fsl,pwmr lcdc property to fsl,lpccr,
  to match the previous patches in that serie.

ChangeLog v10->v13:
- This patch is the display part splitted out from the patch adding
  support for the cpuimx25(and its baseboard).
- Shawn Guo was added to the Cc list.
- The regulator part was updated to match the current style.
- The new GPIO defines are now used in the dts(i).
---
 .../imx25-eukrea-mbimxsd25-baseboard-cmo-qvga.dts  |   72 ++++++++++++++++++++
 .../imx25-eukrea-mbimxsd25-baseboard-dvi-svga.dts  |   45 ++++++++++++
 .../imx25-eukrea-mbimxsd25-baseboard-dvi-vga.dts   |   45 ++++++++++++
 3 files changed, 162 insertions(+)
 create mode 100644 arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-cmo-qvga.dts
 create mode 100644 arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-dvi-svga.dts
 create mode 100644 arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-dvi-vga.dts
Eric Benard - March 12, 2014, 5:40 p.m.
Hi Fabio,

Le Wed, 12 Mar 2014 14:27:25 -0300,
Fabio Estevam <festevam@gmail.com> a écrit :
> Any ideas?
> 
do you drive the signal LCD_EN GPIO3_17 ?

Eric
Fabio Estevam - March 12, 2014, 6:24 p.m.
Hi Eric,

On Wed, Mar 12, 2014 at 2:40 PM, Eric Bénard <eric@eukrea.com> wrote:
> Hi Fabio,
>
> Le Wed, 12 Mar 2014 14:27:25 -0300,
> Fabio Estevam <festevam@gmail.com> a écrit :
>> Any ideas?
>>
> do you drive the signal LCD_EN GPIO3_17 ?

Good point. Even though I am not touching LCD_EN it is at the correct
level of 0.

I get 3.3V at LCD_VCC and VDD_LCDIO. 5V is present at LCD_5V that
drives the backlight.

So the LCD supplies seem to be good.

The problem should be in some other area.

Thanks,

Fabio Estevam
Fabio Estevam - March 12, 2014, 8:30 p.m.
Denis/Eric,

On Wed, Mar 12, 2014 at 3:24 PM, Fabio Estevam <festevam@gmail.com> wrote:
> Hi Eric,
>
> On Wed, Mar 12, 2014 at 2:40 PM, Eric Bénard <eric@eukrea.com> wrote:
>> Hi Fabio,
>>
>> Le Wed, 12 Mar 2014 14:27:25 -0300,
>> Fabio Estevam <festevam@gmail.com> a écrit :
>>> Any ideas?
>>>
>> do you drive the signal LCD_EN GPIO3_17 ?
>
> Good point. Even though I am not touching LCD_EN it is at the correct
> level of 0.
>
> I get 3.3V at LCD_VCC and VDD_LCDIO. 5V is present at LCD_5V that
> drives the backlight.
>
> So the LCD supplies seem to be good.
>
> The problem should be in some other area.

Do you know of a kernel version where imxfb is functional?

I have tried latest linus tree and booted a non-dt kernel on mx25pdk
and I get the same white display.

Regards,

Fabio Estevam
Eric Benard - March 12, 2014, 9:07 p.m.
Hi Fabio,

Le Wed, 12 Mar 2014 15:24:57 -0300,
Fabio Estevam <festevam@gmail.com> a écrit :
> The problem should be in some other area.
> 
if you have an oscilloscope, can you probe PIXCLK, HSYNC, VSYNC and DE
to check the signals are properly configured vs the datasheet of your
display.

Eric
Fabio Estevam - March 12, 2014, 9:16 p.m.
Hi Eric,

On Wed, Mar 12, 2014 at 6:07 PM, Eric Bénard <eric@eukrea.com> wrote:

> if you have an oscilloscope, can you probe PIXCLK, HSYNC, VSYNC and DE
> to check the signals are properly configured vs the datasheet of your
> display.

Yes, I have measured VSYNC and there is no activity on this line.

Also tried 3.13 with a non-dt kernel and the same issue is seen.

Running FSL 2.6.31 I can see VSYNC at 57Hz and Tux on the display, so
the hardware is good.

At least for me imxfb seems to be broken even for the non-dt case.

Regards,

Fabio Estevam
Alexander Shiyan - March 13, 2014, 4:25 a.m.
Среда, 12 марта 2014, 18:16 -03:00 от Fabio Estevam <festevam@gmail.com>:
> Hi Eric,
> 
> On Wed, Mar 12, 2014 at 6:07 PM, Eric Bénard <eric@eukrea.com> wrote:
> 
> > if you have an oscilloscope, can you probe PIXCLK, HSYNC, VSYNC and DE
> > to check the signals are properly configured vs the datasheet of your
> > display.
> 
> Yes, I have measured VSYNC and there is no activity on this line.
> 
> Also tried 3.13 with a non-dt kernel and the same issue is seen.
> 
> Running FSL 2.6.31 I can see VSYNC at 57Hz and Tux on the display, so
> the hardware is good.
> 
> At least for me imxfb seems to be broken even for the non-dt case.

I will check the latest changes on the weekends for i.MX27.

---
Denis Carikli - March 13, 2014, 9:28 a.m.
On 03/12/2014 06:27 PM, Fabio Estevam wrote:
> Hi Denis,
Hi,

> I turned on the backlight supply via bootloader (kernel still does not
> support MC34704 PMIC yet),

Maybe this patchset[1] could help, but it still requires some work, and 
I don't have the hardware to test anymore right now.
So feel free to improve it and resubmit it.

References:
-----------
[1]http://lists.infradead.org/pipermail/linux-arm-kernel/2013-November/thread.html#214619

Denis.
Alexander Shiyan - March 15, 2014, 5:14 a.m.
+CC: Tomi Valkeinen

Четверг, 13 марта 2014, 8:25 +04:00 от Alexander Shiyan <shc_work@mail.ru>:
> Среда, 12 марта 2014, 18:16 -03:00 от Fabio Estevam <festevam@gmail.com>:
> > Hi Eric,
> > 
> > On Wed, Mar 12, 2014 at 6:07 PM, Eric Bénard <eric@eukrea.com> wrote:
> > 
> > > if you have an oscilloscope, can you probe PIXCLK, HSYNC, VSYNC and DE
> > > to check the signals are properly configured vs the datasheet of your
> > > display.
> > 
> > Yes, I have measured VSYNC and there is no activity on this line.
> > 
> > Also tried 3.13 with a non-dt kernel and the same issue is seen.
> > 
> > Running FSL 2.6.31 I can see VSYNC at 57Hz and Tux on the display, so
> > the hardware is good.
> > 
> > At least for me imxfb seems to be broken even for the non-dt case.
> 
> I will check the latest changes on the weekends for i.MX27.

I acknowledge that the (linux-next-20140314) framebuffer driver works fine.
Today I checked it on Phytec-PCM970 board with i.MX27 (DT).

Nevertheless, I ask Tomi to apply at least two patches for this driver:
http://www.spinics.net/lists/arm-kernel/msg315522.html
http://www.spinics.net/lists/arm-kernel/msg315523.html

---
Fabio Estevam - March 15, 2014, 2:17 p.m.
On Sat, Mar 15, 2014 at 2:14 AM, Alexander Shiyan <shc_work@mail.ru> wrote:

> I acknowledge that the (linux-next-20140314) framebuffer driver works fine.
> Today I checked it on Phytec-PCM970 board with i.MX27 (DT).

Thanks for confirming imxfb is functional, Alexander.

Just tried linux-next-20140314 and still do not get LCD functional, so
it looks like a mx25pdk specific issue then.

Regards,

Fabio Estevam
Alexander Shiyan - March 15, 2014, 2:27 p.m.
Суббота, 15 марта 2014, 11:17 -03:00 от Fabio Estevam <festevam@gmail.com>:
> On Sat, Mar 15, 2014 at 2:14 AM, Alexander Shiyan <shc_work@mail.ru> wrote:
> 
> > I acknowledge that the (linux-next-20140314) framebuffer driver works fine.
> > Today I checked it on Phytec-PCM970 board with i.MX27 (DT).
> 
> Thanks for confirming imxfb is functional, Alexander.
> 
> Just tried linux-next-20140314 and still do not get LCD functional, so
> it looks like a mx25pdk specific issue then.

Fabio, I use settings, which sent in the patch. Look, maybe it will help ...
http://www.spinics.net/lists/arm-kernel/msg315707.html

---

Patch

diff --git a/arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-cmo-qvga.dts b/arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-cmo-qvga.dts
new file mode 100644
index 0000000..9de68de
--- /dev/null
+++ b/arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-cmo-qvga.dts
@@ -0,0 +1,72 @@ 
+/*
+ * Copyright 2013 Eukréa Electromatique <denis@eukrea.com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ */
+
+#include "imx25-eukrea-mbimxsd25-baseboard.dts"
+
+/ {
+	model = "Eukrea MBIMXSD25 with the CMO-QVGA Display";
+	compatible = "eukrea,mbimxsd25-baseboard-cmo-qvga", "eukrea,mbimxsd25-baseboard", "eukrea,cpuimx25", "fsl,imx25";
+
+	cmo_qvga: display {
+		model = "CMO-QVGA";
+		bits-per-pixel = <16>;
+		fsl,pcr = <0xcad08b80>;
+		bus-width = <18>;
+		native-mode = <&qvga_timings>;
+		display-timings {
+			qvga_timings: 320x240 {
+				clock-frequency = <6500000>;
+				hactive = <320>;
+				vactive = <240>;
+				hback-porch = <30>;
+				hfront-porch = <38>;
+				vback-porch = <20>;
+				vfront-porch = <3>;
+				hsync-len = <15>;
+				vsync-len = <4>;
+			};
+		};
+	};
+
+	regulators {
+		compatible = "simple-bus";
+		#address-cells = <1>;
+		#size-cells = <0>;
+
+		reg_lcd_3v3: regulator@0 {
+			compatible = "regulator-fixed";
+			pinctrl-names = "default";
+			pinctrl-0 = <&pinctrl_reg_lcd_3v3>;
+			regulator-name = "lcd-3v3";
+			regulator-min-microvolt = <3300000>;
+			regulator-max-microvolt = <3300000>;
+			gpio = <&gpio1 26 GPIO_ACTIVE_HIGH>;
+			enable-active-high;
+		};
+	};
+};
+
+&iomuxc {
+	imx25-eukrea-mbimxsd25-baseboard-cmo-qvga {
+		pinctrl_reg_lcd_3v3: reg_lcd_3v3 {
+			fsl,pins = <MX25_PAD_PWM__GPIO_1_26 0x80000000>;
+		};
+	};
+};
+
+&lcdc {
+	display = <&cmo_qvga>;
+	fsl,lpccr = <0x00a903ff>;
+	lcd-supply = <&reg_lcd_3v3>;
+	status = "okay";
+};
diff --git a/arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-dvi-svga.dts b/arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-dvi-svga.dts
new file mode 100644
index 0000000..8eee2f6
--- /dev/null
+++ b/arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-dvi-svga.dts
@@ -0,0 +1,45 @@ 
+/*
+ * Copyright 2013 Eukréa Electromatique <denis@eukrea.com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ */
+
+#include "imx25-eukrea-mbimxsd25-baseboard.dts"
+
+/ {
+	model = "Eukrea MBIMXSD25 with the DVI-SVGA Display";
+	compatible = "eukrea,mbimxsd25-baseboard-dvi-svga", "eukrea,mbimxsd25-baseboard", "eukrea,cpuimx25", "fsl,imx25";
+
+	dvi_svga: display {
+		model = "DVI-SVGA";
+		bits-per-pixel = <16>;
+		fsl,pcr = <0xfa208b80>;
+		bus-width = <18>;
+		native-mode = <&dvi_svga_timings>;
+		display-timings {
+			dvi_svga_timings: 800x600 {
+				clock-frequency = <40000000>;
+				hactive = <800>;
+				vactive = <600>;
+				hback-porch = <75>;
+				hfront-porch = <75>;
+				vback-porch = <7>;
+				vfront-porch = <75>;
+				hsync-len = <7>;
+				vsync-len = <7>;
+			};
+		};
+	};
+};
+
+&lcdc {
+	display = <&dvi_svga>;
+	status = "okay";
+};
diff --git a/arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-dvi-vga.dts b/arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-dvi-vga.dts
new file mode 100644
index 0000000..447da62
--- /dev/null
+++ b/arch/arm/boot/dts/imx25-eukrea-mbimxsd25-baseboard-dvi-vga.dts
@@ -0,0 +1,45 @@ 
+/*
+ * Copyright 2013 Eukréa Electromatique <denis@eukrea.com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ */
+
+#include "imx25-eukrea-mbimxsd25-baseboard.dts"
+
+/ {
+	model = "Eukrea MBIMXSD25 with the DVI-VGA Display";
+	compatible = "eukrea,mbimxsd25-baseboard-dvi-vga", "eukrea,mbimxsd25-baseboard", "eukrea,cpuimx25", "fsl,imx25";
+
+	dvi_vga: display {
+		model = "DVI-VGA";
+		bits-per-pixel = <16>;
+		fsl,pcr = <0xfa208b80>;
+		bus-width = <18>;
+		native-mode = <&dvi_vga_timings>;
+		display-timings {
+			dvi_vga_timings: 640x480 {
+				clock-frequency = <31250000>;
+				hactive = <640>;
+				vactive = <480>;
+				hback-porch = <100>;
+				hfront-porch = <100>;
+				vback-porch = <7>;
+				vfront-porch = <100>;
+				hsync-len = <7>;
+				vsync-len = <7>;
+			};
+		};
+	};
+};
+
+&lcdc {
+	display = <&dvi_vga>;
+	status = "okay";
+};