From: Simon Glass <sjg-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
To: U-Boot Mailing List <u-boot-0aAXYlwwYIKGBzrmiIFOJg@public.gmane.org>
Cc: Devicetree Discuss
<devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org>,
Tom Warren <twarren-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>,
Jerry Van Baren
<vanbaren-He//nVnquyzQT0dZR+AlfA@public.gmane.org>
Subject: [PATCH 05/17] tegra: fdt: Add LCD definitions for Tegra
Date: Sat, 14 Jan 2012 16:47:17 -0800 [thread overview]
Message-ID: <1326588449-1794-6-git-send-email-sjg@chromium.org> (raw)
In-Reply-To: <1326588449-1794-1-git-send-email-sjg-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
Add LCD definitions and also a proposed binding for LCD displays.
The PWFM is in progress on the device-tree-discuss list, so only a
very basic binding is offered here.
Signed-off-by: Simon Glass <sjg-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
---
arch/arm/dts/tegra20.dtsi | 25 ++++++
doc/device-tree-bindings/video/nvidia-video.txt | 92 +++++++++++++++++++++++
2 files changed, 117 insertions(+), 0 deletions(-)
create mode 100644 doc/device-tree-bindings/video/nvidia-video.txt
diff --git a/arch/arm/dts/tegra20.dtsi b/arch/arm/dts/tegra20.dtsi
index 3d435aa..85c8bf6 100644
--- a/arch/arm/dts/tegra20.dtsi
+++ b/arch/arm/dts/tegra20.dtsi
@@ -221,4 +221,29 @@
compatible = "nvidia,tegra20-kbc";
reg = <0x7000e200 0x0078>;
};
+
+ pwfm0: pwm@7000a000 {
+ compatible = "nvidia,tegra20-pwfm";
+ reg = <0x7000a000 0x4>;
+ };
+
+ pwfm1: pwm@7000a010 {
+ compatible = "nvidia,tegra20-pwfm";
+ reg = <0x7000a010 0x4>;
+ };
+
+ pwfm2: pwm@7000a020 {
+ compatible = "nvidia,tegra20-pwfm";
+ reg = <0x7000a020 0x4>;
+ };
+
+ pwfm3: pwm@7000a030 {
+ compatible = "nvidia,tegra20-pwfm";
+ reg = <0x7000a030 0x4>;
+ };
+
+ display1: display@0x54200000 {
+ compatible = "nvidia,tegra20-display";
+ reg = <0x54200000 0x40000>;
+ };
};
diff --git a/doc/device-tree-bindings/video/nvidia-video.txt b/doc/device-tree-bindings/video/nvidia-video.txt
new file mode 100644
index 0000000..ede9260
--- /dev/null
+++ b/doc/device-tree-bindings/video/nvidia-video.txt
@@ -0,0 +1,92 @@
+LCD Display
+-----------
+
+(there isn't yet a generic binding in Linux, so this describes what is in
+U-Boot)
+
+The device node for a display device is as described in the document
+"Open Firmware Recommended Practice : Universal Serial Bus" with the
+following modifications and additions :
+
+Required properties :
+ - compatible : Should be "nvidia,tegra20-display"
+ - pwfm: phandle of PWFM to use for backlight
+
+Note: This is just a phande and provides no information, nor a backlight
+node. The PWM is still under discussion I think:
+ http://patchwork.ozlabs.org/patch/132386/
+
+We don't support any parameters as yet - the setting is hard-coded.
+
+ - width: width of display in pixels
+ - height: height of display in pixels
+ - bits-per-pixel: number of bits per pixel (depth)
+ - pixel-clock : Pixel clock in Hz
+ - horiz-timing; horizontal timing: ref_to_sync, sync_width. back_porch,
+ front_porch
+ - vert-timing; vertical timing: ref_to_sync, sync_width. back_porch,
+ front_porch
+
+This node should sit inside its controller.
+
+
+Nvidia Tegra2x Display Controller
+---------------------------------
+
+The device node for a NAND flash controller is as described in the document
+"Open Firmware Recommended Practice : Universal Serial Bus" with the
+following modifications and additions :
+
+Required properties:
+ - compatible: should be "tegra20-display"
+ - panel-timings: 4 cells containing required timings in ms:
+ * delay between panel_vdd-rise and data-rise
+ * delay between data-rise and backlight_vdd-rise
+ * delay between backlight_vdd and pwm-rise
+ * delay between pwm-rise and backlight_en-rise
+
+(should we use us here, or perhaps call it panel-timings-ms?)
+
+Optional properties:
+ - frame-buffer: address of frame buffer (if omitted it will be calculated)
+ - This may be useful to share an address between U-Boot and Linux and
+ avoid boot-time corruption / flicker
+
+Optional GPIO properies all have (phandle, GPIO number, flags):
+ - backlight-enable-gpio: backlight enable GPIO
+ - lvds-shutdown-gpio: LVDS power shutdown GPIO
+ - backlight-vdd-gpio: backlight power GPIO
+ - panel-vdd-gpio: panel power GPIO
+
+(should those have an "nvidia," prefix? Perhap use polariy bit so that
+lvds-shutdown becomes lvds-enable?)
+
+I have put these into the display controller since I don't think they are
+generic enough to go in the lcd node.
+
+Example:
+
+display@0x54200000 {
+ pwfm = <&pwfm2>;
+
+ /* frame-buffer location to share with Linux */
+ frame-buffer = <0x2f680000>;
+
+ /* Parameter 3 bit 0:1=output, 0=input; bit 1:1=high, 0=low */
+ backlight-enable = <&gpio 28 0>; /* PD4 */
+ lvds-shutdown = <&gpio 10 0>; /* PB2 */
+ backlight-vdd = <&gpio 176 0>; /* PW0 */
+ panel-vdd = <&gpio 22 0>; /* PC6 */
+ panel-timings = <4 203 17 15>;
+
+ lcd {
+ compatible = "generic,lcd";
+ width = <1366>;
+ height = <768>;
+ bits-per-pixel = <16>;
+ pixel-clock = <70600000>;
+
+ horiz-timing = <11 58 58 58>;
+ vert-timing = <1 4 4 4>;
+ };
+};
--
1.7.7.3
next prev parent reply other threads:[~2012-01-15 0:47 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1326588449-1794-1-git-send-email-sjg@chromium.org>
[not found] ` <1326588449-1794-1-git-send-email-sjg-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2012-01-15 0:47 ` [PATCH 01/17] fdt: Add function to look up a phandle's register address Simon Glass
2012-01-15 0:47 ` [PATCH 02/17] fdt: Add header guard to fdtdec.h Simon Glass
2012-01-15 0:47 ` [PATCH 03/17] fdt: Correct GPIO name access in fdtdec Simon Glass
2012-01-15 0:47 ` Simon Glass [this message]
2012-01-15 0:47 ` [PATCH 15/17] tegra: fdt: Add LCD definitions for Seaboard Simon Glass
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=1326588449-1794-6-git-send-email-sjg@chromium.org \
--to=sjg-f7+t8e8rja9g9huczpvpmw@public.gmane.org \
--cc=devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org \
--cc=twarren-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org \
--cc=u-boot-0aAXYlwwYIKGBzrmiIFOJg@public.gmane.org \
--cc=vanbaren-He//nVnquyzQT0dZR+AlfA@public.gmane.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;
as well as URLs for NNTP newsgroup(s).