From patchwork Mon Apr 13 10:22:25 2015
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
X-Patchwork-Submitter: Philipp Zabel
X-Patchwork-Id: 6207181
Return-Path:
X-Original-To: patchwork-linux-arm@patchwork.kernel.org
Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org
Received: from mail.kernel.org (mail.kernel.org [198.145.29.136])
by patchwork1.web.kernel.org (Postfix) with ESMTP id 4810C9F1AC
for ;
Mon, 13 Apr 2015 10:25:23 +0000 (UTC)
Received: from mail.kernel.org (localhost [127.0.0.1])
by mail.kernel.org (Postfix) with ESMTP id 6036120166
for ;
Mon, 13 Apr 2015 10:25:22 +0000 (UTC)
Received: from bombadil.infradead.org (bombadil.infradead.org
[198.137.202.9])
(using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits))
(No client certificate requested)
by mail.kernel.org (Postfix) with ESMTPS id 5B7402015A
for ;
Mon, 13 Apr 2015 10:25:21 +0000 (UTC)
Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org)
by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux))
id 1YhbWE-0003kW-LH; Mon, 13 Apr 2015 10:23:06 +0000
Received: from metis.ext.pengutronix.de
([2001:6f8:1178:4:290:27ff:fe1d:cc33])
by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat
Linux)) id 1YhbW2-0003VR-CF
for linux-arm-kernel@lists.infradead.org;
Mon, 13 Apr 2015 10:22:55 +0000
Received: from paszta.hi.pengutronix.de
([2001:67c:670:100:96de:80ff:fec2:9969] helo=paszta)
by metis.ext.pengutronix.de with esmtp (Exim 4.80)
(envelope-from )
id 1YhbVb-00017g-TR; Mon, 13 Apr 2015 12:22:27 +0200
Message-ID: <1428920545.3192.41.camel@pengutronix.de>
Subject: Re: [PATCH 1/2] ARM: dts: imx6qdl-sabrelite: add supported LVDS
displays
From: Philipp Zabel
To: Eric Nelson
Date: Mon, 13 Apr 2015 12:22:25 +0200
In-Reply-To: <5521E08F.3060407@boundarydevices.com>
References: <5521E08F.3060407@boundarydevices.com>
X-Mailer: Evolution 3.12.9-1+b1
Mime-Version: 1.0
X-SA-Exim-Connect-IP: 2001:67c:670:100:96de:80ff:fec2:9969
X-SA-Exim-Mail-From: p.zabel@pengutronix.de
X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de);
SAEximRunCond expanded to false
X-PTX-Original-Recipient: linux-arm-kernel@lists.infradead.org
X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3
X-CRM114-CacheID: sfid-20150413_032254_733022_97FF9E60
X-CRM114-Status: GOOD ( 24.85 )
X-Spam-Score: -0.0 (/)
Cc: "shawn.guo@linaro.org" ,
Russell King - ARM Linux ,
"linux-arm-kernel@lists.infradead.org"
,
Sascha Hauer
X-BeenThere: linux-arm-kernel@lists.infradead.org
X-Mailman-Version: 2.1.18-1
Precedence: list
List-Id:
List-Unsubscribe:
,
List-Archive:
List-Post:
List-Help:
List-Subscribe:
,
Sender: "linux-arm-kernel"
Errors-To:
linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org
X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED,
T_RP_MATCHES_RCVD,
UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org
X-Virus-Scanned: ClamAV using ClamSMTP
Hi Eric,
Am Sonntag, den 05.04.2015, 18:25 -0700 schrieb Eric Nelson:
> Hi Philipp,
>
> Sorry for the delayed response. I missed your reply and Shawn pointed
> it out.
[...]
> The use of simple panel seems to add and remove functionality:
> - adds backlight, regulators and enable GPIOs!
> - loses the ability to express timings in DT
For the simple panel driver Thierry preferred to have a panel database
in the driver and uniquely identify the panel by its compatible value.
This will also allow to infer the data mapping and width from
the panel, and the panel timings are available for the next hardware to
reuse the same panel (however likely that is).
The old method with display-timings will stay available, but for
mainline I think it is better to add the panel to the driver.
> > After:
> > ldb {
> > ...
> >
> > lvds-channel at 0 {
> > ...
> >
>
> Using port here to point at the panel seems to conflict
> with the use of ports to point at the IPU.
I'm sorry, I don't understand what you mean exactly. There are some
input ports (two on i.MX5, four on i.MX6) that are connected to the IPU,
and one output port that is connected to the panel, in that order by
convention. The port id 4 (reg = <4>) uniquely identifies the output
port on i.MX6.
> > port at 4 {
> > reg = <4>;
> >
> > lvds_out: endpoint {
> > remote_endpoint = <&panel_in>;
> > };
> > };
> > };
> > };
> >
> > panel {
> > compatible = "edt,etm0700g0dh6", "simple-panel";
> > ...
> >
>
> And why would the panel need to point back to the LVDS
> channel?
This is the way the bindings are defined right now in
Documentation/devicetree/bindings/graph.txt, section "Links between
endpoints". The panel driver itself doesn't use the backlink, but the
endpoint needs to exist anyway.
> > port {
> > panel_in: endpoint {
> > remote-endpoint = <&lvds_out>;
> > };
> > };
> > };
> >
>
> Do you have a working example of how this should be used?
>
> My attempts to follow the notes above results in a failure
> to find a crtc for the LVDS channel.
>
> Please advise,
I have used this patch to connect a HannStar HSD070PWW1 LVDS panel to a
Nitrogen6X board:
-----8<-----
----->8-----
regards
Philipp
diff --git a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
index 0821812..9e52adf 100644
--- a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
@@ -122,7 +122,7 @@
status = "okay";
};
- backlight_lvds {
+ backlight_lvds: backlight_lvds {
compatible = "pwm-backlight";
pwms = <&pwm4 0 5000000>;
brightness-levels = <0 4 8 16 32 64 128 255>;
@@ -130,6 +130,17 @@
power-supply = <®_3p3v>;
status = "okay";
};
+
+ panel {
+ compatible = "hannstar,hsd070pww1";
+ backlight = <&backlight_lvds>;
+
+ port {
+ panel_in: endpoint {
+ remote-endpoint = <&lvds0_out>;
+ };
+ };
+ };
};
&audmux {
@@ -379,18 +390,11 @@
fsl,data-width = <18>;
status = "okay";
- display-timings {
- native-mode = <&timing0>;
- timing0: hsd100pxn1 {
- clock-frequency = <65000000>;
- hactive = <1024>;
- vactive = <768>;
- hback-porch = <220>;
- hfront-porch = <40>;
- vback-porch = <21>;
- vfront-porch = <7>;
- hsync-len = <60>;
- vsync-len = <10>;
+ port@4 {
+ reg = <4>;
+
+ lvds0_out: endpoint {
+ remote-endpoint = <&panel_in>;
};
};
};