From patchwork Thu Aug 20 11:29:12 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marcel Ziswiler X-Patchwork-Id: 509006 X-Patchwork-Delegate: twarren@nvidia.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 10B511401DA for ; Thu, 20 Aug 2015 21:35:24 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 515CB4B669; Thu, 20 Aug 2015 13:35:22 +0200 (CEST) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id SXR8zCMzjPgM; Thu, 20 Aug 2015 13:35:22 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id F0ED44B65D; Thu, 20 Aug 2015 13:33:58 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 3DBEB4B616 for ; Thu, 20 Aug 2015 13:30:12 +0200 (CEST) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id MkjKXq3THVaL for ; Thu, 20 Aug 2015 13:30:12 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mout.perfora.net (mout.perfora.net [74.208.4.194]) by theia.denx.de (Postfix) with ESMTPS id 41C534B624 for ; Thu, 20 Aug 2015 13:29:45 +0200 (CEST) Received: from localhost.localdomain ([46.140.72.82]) by mrelay.perfora.net (mreueus002) with ESMTPA (Nemesis) id 0MbQwc-1Z9lFw2YBY-00IjGH; Thu, 20 Aug 2015 13:29:41 +0200 From: Marcel Ziswiler To: u-boot@lists.denx.de Date: Thu, 20 Aug 2015 13:29:12 +0200 Message-Id: <1440070152-27094-6-git-send-email-marcel.ziswiler@toradex.com> X-Mailer: git-send-email 2.4.3 In-Reply-To: <1440070152-27094-1-git-send-email-marcel.ziswiler@toradex.com> References: <1440070152-27094-1-git-send-email-marcel.ziswiler@toradex.com> X-Provags-ID: V03:K0:LmjTVwBzTGj9TpQAR9qepDD8aT/PBJo2JgrKBAzyS2Z/+QVMKHD 9k31+deIDVRRHWv8eem82sH76Ne0zpHD37YpH6VnukeZRSwCY1YHal22pJ+LtZOWZo2OI/r kF9c14Hul3B+Xc32SLOYT+OuTFhApSiMGZCTLjI+f1aZibUNysvtL1xNcVewBheI6yDkUeS cchp79Oz6yUmDpEjw51ig== X-UI-Out-Filterresults: notjunk:1; V01:K0:7PafBItgzCk=:I3S/GD/j8ma5CgL31i0AMV 16y7fuVhH8PMCH/07xrNDb19HMdJA2YFGMZiohql3ujyJHJCKjO/SHJIFofF4fpQKqynSmwGw qXRQT/ztURj0D+E7dJS5iJKFSJj5zUAGUXiMuAYUjjs89e9jmKvnoXrLYRjalpdOBZ7oqD5AZ /x4OcZMOcRU1OLHVzi8vIYZ/DXBlki6oBbGp+0Rv7jnsTNVsFCODYnhlw9jC/P6pwLJg/0hK+ kZYZ90uYRlFwltbUmA6FBNo7Hws+VWU4Xeua/GJjfGLveJ1EDG03jvEp4idCdi1ikzCmdsgs8 sWP9yYjd4ZDQ+5zRDewJbwTHP+0XF2ABS823nT2pj0jm79FxrcRjNon8OfCbAUgAyImQ64gZ+ d+iQ4MAGI8iJswg7QFg+3jwPiEr771c6C5t/dJNi08/vZkhoQQcEgF9RRepSOAn0jBsIkGc8H OooeD8jMYS6MZKnkG+br+h0JTW++R4wKF8RlUYsmos6i8cw+060MLt/2sn8LFlysW4+SPS5er upa7iAtt/dQahaYfE/rFDOhHsjB8i394xKCREoMAN9Zg2Qsl6kYMipXiQfWblQs3QDp1yh6z1 BRu5LeWM1pU4aP0XqqFjrqI1oUi0lWUv8baAAhTNEcOPeezcbivqO1eAjD5x8JfB+jewV+K6F EGUHZq3n7sMU73itfMy5QymDL+Y9iqhpL20F190BysrzPizAPbPgV7lDlvdCHRqWi+3k= Cc: Tom Rini , Stephen Warren , Stefan Agner , Marcel Ziswiler , Tom Warren Subject: [U-Boot] [PATCH 5/5] apalis_t30: enable display driver X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.15 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Enable the display driver on Apalis T30. Unfortunately the PWM pin muxing wasn't any good neither which made that display stay dark. Signed-off-by: Marcel Ziswiler Reviewed-by: Simon Glass --- arch/arm/dts/tegra30-apalis.dts | 29 ++++++++++++++++++++++ .../toradex/apalis_t30/pinmux-config-apalis_t30.h | 9 ++++--- include/configs/apalis_t30.h | 10 ++++++++ 3 files changed, 44 insertions(+), 4 deletions(-) diff --git a/arch/arm/dts/tegra30-apalis.dts b/arch/arm/dts/tegra30-apalis.dts index 3e0545c..30e7880 100644 --- a/arch/arm/dts/tegra30-apalis.dts +++ b/arch/arm/dts/tegra30-apalis.dts @@ -27,6 +27,17 @@ usb2 = "/usb@7d008000"; }; + host1x { + status = "okay"; + dc@54200000 { + status = "okay"; + rgb { + status = "okay"; + nvidia,panel = <&lcd_panel>; + }; + }; + }; + memory { device_type = "memory"; reg = <0x80000000 0x40000000>; @@ -287,6 +298,24 @@ nvidia,vbus-gpio = <&gpio TEGRA_GPIO(DD, 1) GPIO_ACTIVE_HIGH>; }; + lcd_panel: panel { + clock = <25175000>; + xres = <640>; + yres = <480>; + left-margin = <48>; /* horizontal back porch */ + right-margin = <16>; /* horizontal front porch */ + hsync-len = <96>; + lower-margin = <11>; /* vertical front porch */ + upper-margin = <31>; /* vertical back porch */ + vsync-len = <2>; + hsync-active-high; + vsync-active-high; + nvidia,bits-per-pixel = <16>; + nvidia,pwm = <&pwm 0 0>; + nvidia,backlight-enable-gpios = <&gpio TEGRA_GPIO(V, 2) GPIO_ACTIVE_HIGH>; + nvidia,panel-timings = <0 0 0 0>; + }; + regulators { compatible = "simple-bus"; #address-cells = <1>; diff --git a/board/toradex/apalis_t30/pinmux-config-apalis_t30.h b/board/toradex/apalis_t30/pinmux-config-apalis_t30.h index c988d39..041697e 100644 --- a/board/toradex/apalis_t30/pinmux-config-apalis_t30.h +++ b/board/toradex/apalis_t30/pinmux-config-apalis_t30.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Marcel Ziswiler + * Copyright (c) 2014-2015, Marcel Ziswiler * * This program is free software; you can redistribute it and/or modify it * under the terms and conditions of the GNU General Public License, @@ -204,7 +204,8 @@ static struct pmux_pingrp_config tegra3_pinmux_common[] = { DEFAULT_PINMUX(UART2_CTS_N_PJ5, UARTB, DOWN, TRISTATE, OUTPUT), /* NC */ DEFAULT_PINMUX(UART3_TXD_PW6, UARTC, NORMAL, NORMAL, OUTPUT), DEFAULT_PINMUX(UART3_RXD_PW7, UARTC, NORMAL, NORMAL, INPUT), - DEFAULT_PINMUX(UART3_CTS_N_PA1, UARTC, NORMAL, NORMAL, INPUT), + /* disable BKL1_PWM_EN# (e.g. PMIC PWM backlight enable) for now */ + DEFAULT_PINMUX(UART3_CTS_N_PA1, RSVD1, UP, NORMAL, OUTPUT), DEFAULT_PINMUX(UART3_RTS_N_PC0, PWM0, NORMAL, NORMAL, OUTPUT), DEFAULT_PINMUX(PU0, RSVD1, DOWN, TRISTATE, OUTPUT), DEFAULT_PINMUX(PU1, RSVD1, DOWN, TRISTATE, OUTPUT), @@ -221,7 +222,7 @@ static struct pmux_pingrp_config tegra3_pinmux_common[] = { DEFAULT_PINMUX(CLK3_REQ_PEE1, DEV3, DOWN, TRISTATE, OUTPUT), /* NC */ DEFAULT_PINMUX(GMI_WP_N_PC7, GMI, DOWN, TRISTATE, OUTPUT), /* NC */ DEFAULT_PINMUX(GMI_CS2_N_PK3, RSVD1, DOWN, TRISTATE, OUTPUT), /* NC */ - DEFAULT_PINMUX(GMI_AD8_PH0, PWM0, DOWN, TRISTATE, OUTPUT), /* NC */ + DEFAULT_PINMUX(GMI_AD8_PH0, RSVD1, DOWN, TRISTATE, OUTPUT), /* NC */ DEFAULT_PINMUX(GMI_AD10_PH2, NAND, DOWN, TRISTATE, OUTPUT), /* NC */ DEFAULT_PINMUX(GMI_A16_PJ7, UARTD, DOWN, TRISTATE, OUTPUT), /* NC */ DEFAULT_PINMUX(GMI_A17_PB0, UARTD, DOWN, TRISTATE, OUTPUT), /* NC */ @@ -331,7 +332,7 @@ static struct pmux_pingrp_config unused_pins_lowpower[] = { DEFAULT_PINMUX(GMI_AD5_PG5, NAND, DOWN, TRISTATE, OUTPUT), DEFAULT_PINMUX(GMI_AD6_PG6, NAND, DOWN, TRISTATE, OUTPUT), DEFAULT_PINMUX(GMI_AD7_PG7, NAND, DOWN, TRISTATE, OUTPUT), - DEFAULT_PINMUX(GMI_AD9_PH1, PWM1, DOWN, TRISTATE, OUTPUT), + DEFAULT_PINMUX(GMI_AD9_PH1, RSVD1, DOWN, TRISTATE, OUTPUT), DEFAULT_PINMUX(GMI_AD11_PH3, NAND, DOWN, TRISTATE, OUTPUT), DEFAULT_PINMUX(GMI_AD13_PH5, NAND, DOWN, TRISTATE, OUTPUT), DEFAULT_PINMUX(GMI_WR_N_PI0, NAND, DOWN, TRISTATE, OUTPUT), diff --git a/include/configs/apalis_t30.h b/include/configs/apalis_t30.h index 6c0ae22..b2a695e 100644 --- a/include/configs/apalis_t30.h +++ b/include/configs/apalis_t30.h @@ -64,6 +64,16 @@ #define CONFIG_TFTP_BLOCKSIZE 16384 #define CONFIG_TFTP_TSIZE +/* LCD support */ +#define CONFIG_LCD +#define CONFIG_PWM_TEGRA +#define CONFIG_VIDEO_TEGRA +#define LCD_BPP LCD_COLOR16 +#define CONFIG_SYS_WHITE_ON_BLACK +#define CONFIG_CONSOLE_SCROLL_LINES 10 +#define CONFIG_CMD_BMP +#define CONFIG_LCD_LOGO + /* Miscellaneous commands */ #define CONFIG_FAT_WRITE