From patchwork Wed Apr 17 11:57:14 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: linux-kernel-dev X-Patchwork-Id: 1086928 X-Patchwork-Delegate: agust@denx.de Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=beckhoff.com Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 44kgkw2k6Jz9s3q for ; Wed, 17 Apr 2019 21:59:18 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id 2F092C21EC3; Wed, 17 Apr 2019 11:58:51 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 97DE4C21E4F; Wed, 17 Apr 2019 11:57:47 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 8EE62C21C6A; Wed, 17 Apr 2019 11:57:45 +0000 (UTC) Received: from Netsrv01.beckhoff.com (netsrv01.beckhoff.com [62.159.14.10]) by lists.denx.de (Postfix) with ESMTPS id 383FBC21DD7 for ; Wed, 17 Apr 2019 11:57:45 +0000 (UTC) Received: from std-laptop.beckhoff.com (172.17.66.103) by NT-Mail06.beckhoff.com (10.1.0.30) with Microsoft SMTP Server (TLS) id 14.3.301.0; Wed, 17 Apr 2019 13:57:41 +0200 From: To: Date: Wed, 17 Apr 2019 13:57:14 +0200 Message-ID: <20190417115719.22407-2-linux-kernel-dev@beckhoff.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> References: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> MIME-Version: 1.0 X-Originating-IP: [172.17.66.103] X-OLX-Disclaimer: Done Cc: Tom Rini , u-boot@steffen.cc, Patrick Bruenn , s.dirkwinkel@beckhoff.com Subject: [U-Boot] [PATCH v1 1/6] dm: arm: imx: cx9020: enable DM_GPIO X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" From: Steffen Dirkwinkel Switch to DM_GPIO and add gpio_request where necessary. This is needed for DM_VIDEO and fixes an issue with sd card detection which was introduced by the combination of these commits: commit 7a0425dd969c ("mmc: fsl_esdhc: make get_cd work well in dm_mmc_ops") commit 7e04b4c751a1 ("dm: arm: imx: migrate cx9020 to CONFIG_DM_MMC") Acked-by: Patrick Bruenn Signed-off-by: Steffen Dirkwinkel --- board/beckhoff/mx53cx9020/mx53cx9020.c | 25 ++++++++++++++++---- board/beckhoff/mx53cx9020/mx53cx9020_video.c | 1 + configs/mx53cx9020_defconfig | 2 ++ 3 files changed, 24 insertions(+), 4 deletions(-) diff --git a/board/beckhoff/mx53cx9020/mx53cx9020.c b/board/beckhoff/mx53cx9020/mx53cx9020.c index 79d8a62cf1b..79ea4560283 100644 --- a/board/beckhoff/mx53cx9020/mx53cx9020.c +++ b/board/beckhoff/mx53cx9020/mx53cx9020.c @@ -91,6 +91,9 @@ void weim_cs0_settings(u32 mode) static void setup_gpio_eim(void) { + gpio_request(GPIO_C3_STATUS, "GPIO_C3_STATUS"); + gpio_request(GPIO_C3_DONE, "GPIO_C3_DONE"); + gpio_request(GPIO_C3_CONFIG, "GPIO_C3_CONFIG"); gpio_direction_input(GPIO_C3_STATUS); gpio_direction_input(GPIO_C3_DONE); gpio_direction_output(GPIO_C3_CONFIG, 1); @@ -100,6 +103,7 @@ static void setup_gpio_eim(void) static void setup_gpio_sups(void) { + gpio_request(GPIO_SUPS_INT, "GPIO_SUPS_INT"); gpio_direction_input(GPIO_SUPS_INT); static const int BLINK_INTERVALL = 50000; @@ -116,6 +120,16 @@ static void setup_gpio_sups(void) static void setup_gpio_leds(void) { + gpio_request(GPIO_LED_SD2_R, "GPIO_LED_SD2_R"); + gpio_request(GPIO_LED_SD2_B, "GPIO_LED_SD2_B"); + gpio_request(GPIO_LED_SD2_G, "GPIO_LED_SD2_G"); + gpio_request(GPIO_LED_SD1_R, "GPIO_LED_SD1_R"); + gpio_request(GPIO_LED_SD1_B, "GPIO_LED_SD1_B"); + gpio_request(GPIO_LED_SD1_G, "GPIO_LED_SD1_G"); + gpio_request(GPIO_LED_PWR_R, "GPIO_LED_PWR_R"); + gpio_request(GPIO_LED_PWR_B, "GPIO_LED_PWR_B"); + gpio_request(GPIO_LED_PWR_G, "GPIO_LED_PWR_G"); + gpio_direction_output(GPIO_LED_SD2_R, 0); gpio_direction_output(GPIO_LED_SD2_B, 0); gpio_direction_output(GPIO_LED_SD2_G, 0); @@ -147,6 +161,8 @@ int board_mmc_getcd(struct mmc *mmc) struct fsl_esdhc_cfg *cfg = (struct fsl_esdhc_cfg *)mmc->priv; int ret; + gpio_request(GPIO_SD1_CD, "GPIO_SD1_CD"); + gpio_request(GPIO_SD2_CD, "GPIO_SD2_CD"); gpio_direction_input(GPIO_SD1_CD); gpio_direction_input(GPIO_SD2_CD); @@ -212,10 +228,6 @@ static void clock_1GHz(void) int board_early_init_f(void) { - setup_gpio_leds(); - setup_gpio_sups(); - setup_gpio_eim(); - setup_iomux_lcd(); return 0; } @@ -235,6 +247,11 @@ int board_init(void) mxc_set_sata_internal_clock(); + setup_gpio_leds(); + setup_gpio_sups(); + setup_gpio_eim(); + setup_iomux_lcd(); + return 0; } diff --git a/board/beckhoff/mx53cx9020/mx53cx9020_video.c b/board/beckhoff/mx53cx9020/mx53cx9020_video.c index 4055bccc2b7..85f1cdae8af 100644 --- a/board/beckhoff/mx53cx9020/mx53cx9020_video.c +++ b/board/beckhoff/mx53cx9020/mx53cx9020_video.c @@ -36,6 +36,7 @@ void setup_iomux_lcd(void) { /* Turn on DVI_PWD */ imx_iomux_v3_setup_pad(MX53_PAD_CSI0_DAT15__GPIO6_1); + gpio_request(CX9020_DVI_PWD, "CX9020_DVI_PWD"); gpio_direction_output(CX9020_DVI_PWD, 1); } diff --git a/configs/mx53cx9020_defconfig b/configs/mx53cx9020_defconfig index 831d50925f3..93c113aba73 100644 --- a/configs/mx53cx9020_defconfig +++ b/configs/mx53cx9020_defconfig @@ -24,7 +24,9 @@ CONFIG_DEFAULT_DEVICE_TREE="imx53-cx9020" CONFIG_ENV_IS_IN_MMC=y CONFIG_FPGA_ALTERA=y CONFIG_FPGA_CYCLON2=y +CONFIG_DM=y CONFIG_DM_MMC=y +CONFIG_DM_GPIO=y CONFIG_FSL_ESDHC=y CONFIG_FEC_MXC=y CONFIG_MII=y From patchwork Wed Apr 17 11:57:15 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: linux-kernel-dev X-Patchwork-Id: 1086927 X-Patchwork-Delegate: agust@denx.de Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=beckhoff.com Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 44kgjx4xRmz9s3q for ; Wed, 17 Apr 2019 21:58:29 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id 6223DC21C6A; Wed, 17 Apr 2019 11:58:22 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 1B7D4C21E1B; Wed, 17 Apr 2019 11:57:47 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 7A83EC21DED; Wed, 17 Apr 2019 11:57:45 +0000 (UTC) Received: from Internet2.beckhoff.com (internet2.beckhoff.com [194.25.186.210]) by lists.denx.de (Postfix) with ESMTPS id 2B23CC21C6A for ; Wed, 17 Apr 2019 11:57:45 +0000 (UTC) Received: from std-laptop.beckhoff.com (172.17.66.103) by NT-Mail06.beckhoff.com (10.1.0.30) with Microsoft SMTP Server (TLS) id 14.3.301.0; Wed, 17 Apr 2019 13:57:42 +0200 From: To: Date: Wed, 17 Apr 2019 13:57:15 +0200 Message-ID: <20190417115719.22407-3-linux-kernel-dev@beckhoff.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> References: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> MIME-Version: 1.0 X-Originating-IP: [172.17.66.103] X-OLX-Disclaimer: Done Cc: u-boot@steffen.cc, Tom Rini , s.dirkwinkel@beckhoff.com Subject: [U-Boot] [PATCH v1 2/6] dm: arm: imx: video: add compatible for imx53-ipu X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" From: Steffen Dirkwinkel This code also works with imx53 ipus so we can enable it for them. Signed-off-by: Steffen Dirkwinkel --- drivers/video/imx/mxc_ipuv3_fb.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/video/imx/mxc_ipuv3_fb.c b/drivers/video/imx/mxc_ipuv3_fb.c index 3e38d4bdcc3..1aca9eba228 100644 --- a/drivers/video/imx/mxc_ipuv3_fb.c +++ b/drivers/video/imx/mxc_ipuv3_fb.c @@ -685,6 +685,7 @@ static int ipuv3_video_bind(struct udevice *dev) static const struct udevice_id ipuv3_video_ids[] = { { .compatible = "fsl,imx6q-ipu" }, + { .compatible = "fsl,imx53-ipu" }, { } }; From patchwork Wed Apr 17 11:57:16 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: linux-kernel-dev X-Patchwork-Id: 1086929 X-Patchwork-Delegate: agust@denx.de Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=beckhoff.com Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 44kgl54KNPz9s3q for ; Wed, 17 Apr 2019 21:59:29 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id 48F5AC21EE0; Wed, 17 Apr 2019 11:59:09 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 1C32AC21E76; Wed, 17 Apr 2019 11:57:48 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 48A33C21DD7; Wed, 17 Apr 2019 11:57:46 +0000 (UTC) Received: from Netsrv01.beckhoff.com (netsrv01.beckhoff.com [62.159.14.10]) by lists.denx.de (Postfix) with ESMTPS id 0DE8EC21C6A for ; Wed, 17 Apr 2019 11:57:46 +0000 (UTC) Received: from std-laptop.beckhoff.com (172.17.66.103) by NT-Mail06.beckhoff.com (10.1.0.30) with Microsoft SMTP Server (TLS) id 14.3.301.0; Wed, 17 Apr 2019 13:57:45 +0200 From: To: Date: Wed, 17 Apr 2019 13:57:16 +0200 Message-ID: <20190417115719.22407-4-linux-kernel-dev@beckhoff.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> References: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> MIME-Version: 1.0 X-Originating-IP: [172.17.66.103] X-OLX-Disclaimer: Done Cc: u-boot@steffen.cc, Patrick Bruenn , Tom Rini , Ian Ray , s.dirkwinkel@beckhoff.com Subject: [U-Boot] [PATCH v1 3/6] arm: imx: add ipu to imx53.dts and set dm-pre-reloc X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" From: Steffen Dirkwinkel The ipu node in imx53 is needed for DM_VIDEO. We also need to set u-boot,dm-pre-reloc to initialize before relocation. Signed-off-by: Steffen Dirkwinkel --- arch/arm/dts/imx53.dtsi | 137 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 137 insertions(+) diff --git a/arch/arm/dts/imx53.dtsi b/arch/arm/dts/imx53.dtsi index 0fd4acc6f53..7a47602b53d 100644 --- a/arch/arm/dts/imx53.dtsi +++ b/arch/arm/dts/imx53.dtsi @@ -31,6 +31,7 @@ i2c0 = &i2c1; i2c1 = &i2c2; i2c2 = &i2c3; + ipu0 = &ipu; mmc0 = &esdhc1; mmc1 = &esdhc2; mmc2 = &esdhc3; @@ -50,6 +51,7 @@ compatible = "simple-bus"; interrupt-parent = <&tzic>; ranges; + u-boot,dm-pre-reloc; aips@50000000 { /* AIPS1 */ compatible = "fsl,aips-bus", "simple-bus"; @@ -273,5 +275,140 @@ status = "disabled"; }; }; + + ipu: ipu@18000000 { + #address-cells = <1>; + #size-cells = <0>; + compatible = "fsl,imx53-ipu"; + reg = <0x18000000 0x08000000>; + interrupts = <11 10>; + clocks = <&clks IMX5_CLK_IPU_GATE>, + <&clks IMX5_CLK_IPU_DI0_GATE>, + <&clks IMX5_CLK_IPU_DI1_GATE>; + clock-names = "bus", "di0", "di1"; + resets = <&src 2>; + u-boot,dm-pre-reloc; + + ipu_csi0: port@0 { + reg = <0>; + }; + + ipu_csi1: port@1 { + reg = <1>; + }; + + ipu_di0: port@2 { + #address-cells = <1>; + #size-cells = <0>; + reg = <2>; + + ipu_di0_disp0: endpoint@0 { + reg = <0>; + }; + + ipu_di0_lvds0: endpoint@1 { + reg = <1>; + remote-endpoint = <&lvds0_in>; + }; + }; + + ipu_di1: port@3 { + #address-cells = <1>; + #size-cells = <0>; + reg = <3>; + + ipu_di1_disp1: endpoint@0 { + reg = <0>; + }; + + ipu_di1_lvds1: endpoint@1 { + reg = <1>; + remote-endpoint = <&lvds1_in>; + }; + + ipu_di1_tve: endpoint@2 { + reg = <2>; + remote-endpoint = <&tve_in>; + }; + }; + }; + + tve: tve@63ff0000 { + compatible = "fsl,imx53-tve"; + reg = <0x63ff0000 0x1000>; + interrupts = <92>; + clocks = <&clks IMX5_CLK_TVE_GATE>, + <&clks IMX5_CLK_IPU_DI1_SEL>; + clock-names = "tve", "di_sel"; + status = "disabled"; + + port { + tve_in: endpoint { + remote-endpoint = <&ipu_di1_tve>; + }; + }; + }; + + src: src@53fd0000 { + compatible = "fsl,imx53-src", "fsl,imx51-src"; + reg = <0x53fd0000 0x4000>; + #reset-cells = <1>; + }; + + ldb: ldb@53fa8008 { + #address-cells = <1>; + #size-cells = <0>; + compatible = "fsl,imx53-ldb"; + reg = <0x53fa8008 0x4>; + gpr = <&gpr>; + clocks = <&clks IMX5_CLK_LDB_DI0_SEL>, + <&clks IMX5_CLK_LDB_DI1_SEL>, + <&clks IMX5_CLK_IPU_DI0_SEL>, + <&clks IMX5_CLK_IPU_DI1_SEL>, + <&clks IMX5_CLK_LDB_DI0_GATE>, + <&clks IMX5_CLK_LDB_DI1_GATE>; + clock-names = "di0_pll", "di1_pll", + "di0_sel", "di1_sel", + "di0", "di1"; + status = "disabled"; + + lvds-channel@0 { + #address-cells = <1>; + #size-cells = <0>; + reg = <0>; + status = "disabled"; + + port@0 { + reg = <0>; + + lvds0_in: endpoint { + remote-endpoint = <&ipu_di0_lvds0>; + }; + }; + + port@2 { + reg = <2>; + }; + }; + + lvds-channel@1 { + #address-cells = <1>; + #size-cells = <0>; + reg = <1>; + status = "disabled"; + + port@1 { + reg = <1>; + + lvds1_in: endpoint { + remote-endpoint = <&ipu_di1_lvds1>; + }; + }; + + port@2 { + reg = <2>; + }; + }; + }; }; }; From patchwork Wed Apr 17 11:57:17 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: linux-kernel-dev X-Patchwork-Id: 1086930 X-Patchwork-Delegate: agust@denx.de Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=beckhoff.com Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 44kgp129vjz9s3q for ; Wed, 17 Apr 2019 22:02:01 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id C3914C21E6A; Wed, 17 Apr 2019 12:01:59 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 84042C21ECF; Wed, 17 Apr 2019 11:57:59 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id B35DBC21EC3; Wed, 17 Apr 2019 11:57:51 +0000 (UTC) Received: from Internet2.beckhoff.com (internet2.beckhoff.com [194.25.186.210]) by lists.denx.de (Postfix) with ESMTPS id EFDA0C21E73 for ; Wed, 17 Apr 2019 11:57:47 +0000 (UTC) Received: from std-laptop.beckhoff.com (172.17.66.103) by NT-Mail06.beckhoff.com (10.1.0.30) with Microsoft SMTP Server (TLS) id 14.3.301.0; Wed, 17 Apr 2019 13:57:46 +0200 From: To: Date: Wed, 17 Apr 2019 13:57:17 +0200 Message-ID: <20190417115719.22407-5-linux-kernel-dev@beckhoff.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> References: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> MIME-Version: 1.0 X-Originating-IP: [172.17.66.103] X-OLX-Disclaimer: Done Cc: Tom Rini , u-boot@steffen.cc, Patrick Bruenn , s.dirkwinkel@beckhoff.com Subject: [U-Boot] [PATCH v1 4/6] dm: arm: imx: cx9020: migrate to dm_video X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" From: Steffen Dirkwinkel Enable DM_VIDEO in config and don't overwrite console so it can be set from environment Acked-by: Patrick Bruenn Signed-off-by: Steffen Dirkwinkel --- board/beckhoff/mx53cx9020/Makefile | 2 +- board/beckhoff/mx53cx9020/mx53cx9020.c | 11 ----- board/beckhoff/mx53cx9020/mx53cx9020_video.c | 51 +++++++++----------- configs/mx53cx9020_defconfig | 5 +- include/configs/mx53cx9020.h | 6 +-- 5 files changed, 28 insertions(+), 47 deletions(-) diff --git a/board/beckhoff/mx53cx9020/Makefile b/board/beckhoff/mx53cx9020/Makefile index 423a5532ca6..7f15fc5746d 100644 --- a/board/beckhoff/mx53cx9020/Makefile +++ b/board/beckhoff/mx53cx9020/Makefile @@ -4,4 +4,4 @@ # Patrick Bruenn obj-y += mx53cx9020.o -obj-$(CONFIG_VIDEO) += mx53cx9020_video.o +obj-$(CONFIG_DM_VIDEO) += mx53cx9020_video.o diff --git a/board/beckhoff/mx53cx9020/mx53cx9020.c b/board/beckhoff/mx53cx9020/mx53cx9020.c index 79ea4560283..fdef4477d9a 100644 --- a/board/beckhoff/mx53cx9020/mx53cx9020.c +++ b/board/beckhoff/mx53cx9020/mx53cx9020.c @@ -23,8 +23,6 @@ #include #include #include -#include -#include #include #include #include @@ -232,15 +230,6 @@ int board_early_init_f(void) return 0; } -/* - * Do not overwrite the console - * Use always serial for U-Boot console - */ -int overwrite_console(void) -{ - return 1; -} - int board_init(void) { gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100; diff --git a/board/beckhoff/mx53cx9020/mx53cx9020_video.c b/board/beckhoff/mx53cx9020/mx53cx9020_video.c index 85f1cdae8af..bf472902562 100644 --- a/board/beckhoff/mx53cx9020/mx53cx9020_video.c +++ b/board/beckhoff/mx53cx9020/mx53cx9020_video.c @@ -8,29 +8,34 @@ */ #include -#include -#include #include -#include -#include +#include +#include #define CX9020_DVI_PWD IMX_GPIO_NR(6, 1) -static struct fb_videomode const vga_640x480 = { - .name = "VESA_VGA_640x480", - .refresh = 60, - .xres = 640, - .yres = 480, - .pixclock = 39721, /* picosecond (25.175 MHz) */ - .left_margin = 40, - .right_margin = 60, - .upper_margin = 10, - .lower_margin = 10, - .hsync_len = 20, - .vsync_len = 10, - .sync = 0, - .vmode = FB_VMODE_NONINTERLACED -}; +struct display_info_t const displays[] = {{ + .bus = -1, + .addr = 0, + .pixfmt = IPU_PIX_FMT_RGB24, + .detect = NULL, + .enable = NULL, + .mode = { + .name = "DVI", + .refresh = 60, + .xres = 640, + .yres = 480, + .pixclock = 39721, /* picosecond (25.175 MHz) */ + .left_margin = 40, + .right_margin = 60, + .upper_margin = 10, + .lower_margin = 10, + .hsync_len = 20, + .vsync_len = 10, + .sync = 0, + .vmode = FB_VMODE_NONINTERLACED +} } }; +size_t display_count = ARRAY_SIZE(displays); void setup_iomux_lcd(void) { @@ -39,11 +44,3 @@ void setup_iomux_lcd(void) gpio_request(CX9020_DVI_PWD, "CX9020_DVI_PWD"); gpio_direction_output(CX9020_DVI_PWD, 1); } - -int board_video_skip(void) -{ - const int ret = ipuv3_fb_init(&vga_640x480, 0, IPU_PIX_FMT_RGB24); - if (ret) - printf("VESA VG 640x480 cannot be configured: %d\n", ret); - return ret; -} diff --git a/configs/mx53cx9020_defconfig b/configs/mx53cx9020_defconfig index 93c113aba73..11b414f790e 100644 --- a/configs/mx53cx9020_defconfig +++ b/configs/mx53cx9020_defconfig @@ -33,6 +33,5 @@ CONFIG_MII=y CONFIG_PINCTRL=y CONFIG_PINCTRL_IMX5=y CONFIG_MXC_UART=y -CONFIG_VIDEO=y -CONFIG_VIDEO_IPUV3=y -# CONFIG_VIDEO_SW_CURSOR is not set +CONFIG_DM_VIDEO=y +CONFIG_VIDEO_IPUV3=y \ No newline at end of file diff --git a/include/configs/mx53cx9020.h b/include/configs/mx53cx9020.h index 1e3ea88b77a..66a0f319c45 100644 --- a/include/configs/mx53cx9020.h +++ b/include/configs/mx53cx9020.h @@ -160,11 +160,7 @@ #define CONFIG_SYS_MMC_ENV_DEV 0 /* Framebuffer and LCD */ +#define CONFIG_IMX_VIDEO_SKIP #define CONFIG_PREBOOT -#define CONFIG_SYS_CONSOLE_OVERWRITE_ROUTINE -#define CONFIG_VIDEO_BMP_RLE8 -#define CONFIG_SPLASH_SCREEN -#define CONFIG_BMP_16BPP -#define CONFIG_VIDEO_LOGO #endif /* __CONFIG_H */ From patchwork Wed Apr 17 11:57:18 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: linux-kernel-dev X-Patchwork-Id: 1086932 X-Patchwork-Delegate: agust@denx.de Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=beckhoff.com Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 44kgqs6q5zz9s3q for ; Wed, 17 Apr 2019 22:03:37 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id 9508EC21EAE; Wed, 17 Apr 2019 12:02:30 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 8DC59C21EB4; Wed, 17 Apr 2019 11:58:02 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id AD9EDC21EB4; Wed, 17 Apr 2019 11:57:52 +0000 (UTC) Received: from Netsrv01.beckhoff.com (netsrv01.beckhoff.com [62.159.14.10]) by lists.denx.de (Postfix) with ESMTPS id 23408C21E0B for ; Wed, 17 Apr 2019 11:57:49 +0000 (UTC) Received: from std-laptop.beckhoff.com (172.17.66.103) by NT-Mail06.beckhoff.com (10.1.0.30) with Microsoft SMTP Server (TLS) id 14.3.301.0; Wed, 17 Apr 2019 13:57:47 +0200 From: To: Date: Wed, 17 Apr 2019 13:57:18 +0200 Message-ID: <20190417115719.22407-6-linux-kernel-dev@beckhoff.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> References: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> MIME-Version: 1.0 X-Originating-IP: [172.17.66.103] X-OLX-Disclaimer: Done Cc: Tom Rini , u-boot@steffen.cc, Patrick Bruenn , s.dirkwinkel@beckhoff.com Subject: [U-Boot] [PATCH v1 5/6] dm: arm: imx: cx9020: remove unused mmc functions X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" From: Steffen Dirkwinkel These mmc functions were not used anymore since DM_MMC was introduced. Acked-by: Patrick Bruenn Signed-off-by: Steffen Dirkwinkel --- board/beckhoff/mx53cx9020/mx53cx9020.c | 55 -------------------------- 1 file changed, 55 deletions(-) diff --git a/board/beckhoff/mx53cx9020/mx53cx9020.c b/board/beckhoff/mx53cx9020/mx53cx9020.c index fdef4477d9a..de1d85f1518 100644 --- a/board/beckhoff/mx53cx9020/mx53cx9020.c +++ b/board/beckhoff/mx53cx9020/mx53cx9020.c @@ -9,7 +9,6 @@ #include #include -#include #include #include #include @@ -20,11 +19,8 @@ #include #include #include -#include -#include #include #include -#include #include enum LED_GPIOS { @@ -148,57 +144,6 @@ int board_ehci_hcd_init(int port) } #endif -#ifdef CONFIG_FSL_ESDHC -struct fsl_esdhc_cfg esdhc_cfg[2] = { - {MMC_SDHC1_BASE_ADDR}, - {MMC_SDHC2_BASE_ADDR}, -}; - -int board_mmc_getcd(struct mmc *mmc) -{ - struct fsl_esdhc_cfg *cfg = (struct fsl_esdhc_cfg *)mmc->priv; - int ret; - - gpio_request(GPIO_SD1_CD, "GPIO_SD1_CD"); - gpio_request(GPIO_SD2_CD, "GPIO_SD2_CD"); - gpio_direction_input(GPIO_SD1_CD); - gpio_direction_input(GPIO_SD2_CD); - - if (cfg->esdhc_base == MMC_SDHC1_BASE_ADDR) - ret = !gpio_get_value(GPIO_SD1_CD); - else - ret = !gpio_get_value(GPIO_SD2_CD); - - return ret; -} - -int board_mmc_init(bd_t *bis) -{ - u32 index; - int ret; - - esdhc_cfg[0].sdhc_clk = mxc_get_clock(MXC_ESDHC_CLK); - esdhc_cfg[1].sdhc_clk = mxc_get_clock(MXC_ESDHC2_CLK); - - for (index = 0; index < CONFIG_SYS_FSL_ESDHC_NUM; index++) { - switch (index) { - case 0: - break; - case 1: - break; - default: - printf("Warning: you configured more ESDHC controller(%d) as supported by the board(2)\n", - CONFIG_SYS_FSL_ESDHC_NUM); - return -EINVAL; - } - ret = fsl_esdhc_initialize(bis, &esdhc_cfg[index]); - if (ret) - return ret; - } - - return 0; -} -#endif static int power_init(void) { From patchwork Wed Apr 17 11:57:19 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: linux-kernel-dev X-Patchwork-Id: 1086931 X-Patchwork-Delegate: agust@denx.de Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=beckhoff.com Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 44kgq95SCCz9s4V for ; Wed, 17 Apr 2019 22:03:01 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id 55B39C21E0B; Wed, 17 Apr 2019 12:02:16 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 1CB7EC21DD7; Wed, 17 Apr 2019 11:58:00 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id C5DEBC21EBD; Wed, 17 Apr 2019 11:57:53 +0000 (UTC) Received: from Internet2.beckhoff.com (internet2.beckhoff.com [194.25.186.210]) by lists.denx.de (Postfix) with ESMTPS id E0AC8C21E96 for ; Wed, 17 Apr 2019 11:57:49 +0000 (UTC) Received: from std-laptop.beckhoff.com (172.17.66.103) by NT-Mail06.beckhoff.com (10.1.0.30) with Microsoft SMTP Server (TLS) id 14.3.301.0; Wed, 17 Apr 2019 13:57:48 +0200 From: To: Date: Wed, 17 Apr 2019 13:57:19 +0200 Message-ID: <20190417115719.22407-7-linux-kernel-dev@beckhoff.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> References: <20190417115719.22407-1-linux-kernel-dev@beckhoff.com> MIME-Version: 1.0 X-Originating-IP: [172.17.66.103] X-OLX-Disclaimer: Done Cc: u-boot@steffen.cc, Patrick Bruenn , Tom Rini , s.dirkwinkel@beckhoff.com Subject: [U-Boot] [PATCH v1 6/6] arm: imx: cx9020: remove unnecessary includes X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" From: Steffen Dirkwinkel There are several includes in mx53cx9020.c which are not required anymore. Acked-by: Patrick Bruenn Signed-off-by: Steffen Dirkwinkel --- board/beckhoff/mx53cx9020/mx53cx9020.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/board/beckhoff/mx53cx9020/mx53cx9020.c b/board/beckhoff/mx53cx9020/mx53cx9020.c index de1d85f1518..9450d925f6f 100644 --- a/board/beckhoff/mx53cx9020/mx53cx9020.c +++ b/board/beckhoff/mx53cx9020/mx53cx9020.c @@ -8,20 +8,12 @@ */ #include -#include -#include #include -#include #include #include -#include #include #include -#include -#include #include -#include -#include enum LED_GPIOS { GPIO_SD1_CD = IMX_GPIO_NR(1, 1),