From patchwork Thu Mar 21 18:57:26 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomasz Maciej Nowak X-Patchwork-Id: 1060398 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=o2.pl Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="HqF5Hpoo"; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=infradead.org header.i=@infradead.org header.b="GtOGFiCl"; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=o2.pl header.i=@o2.pl header.b="YwSl8qtm"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 44QGJP67mjz9sR9 for ; Fri, 22 Mar 2019 05:57:57 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Subject:MIME-Version:References: In-Reply-To:Message-Id:Date:To:From:Reply-To:Cc:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=v508WD0pSq1IAoWlC37jIqoHzWRQVwMjjIVXdpMzmTQ=; b=HqF5HpoogCQ9s138Sb/dVP9cJ0 kZTNkaBsp9r9SbMo8zhmu+C0Y7C56AdcjeV48LOsXUkaRJGGjS0xsJyJ4qTy/Q7ZRXTNoK0o+3ZnG 9qbk6DW4rWkoJodhU+jUAjBhsEyiLHzmLg0vxjgepcKicLZU8TQe4Cxtau91WPHZvv8GAARaxOCM7 hxRnXYPhyDlHMBrcHxQ8kXY34rNOLNlXFQ+ivo3KVURI5Mt5OmVHuhmci9KicUPVi1kWufLSWD07b PknkCD50bjNehJRjkgUQoTx9WAPJRX5WtAyZh6P/DXaeGaUOXdvg1JhlF0KF/VKkGFb2UkJteaFPH 4q28Ktbw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1h72sp-0005F5-Oa; Thu, 21 Mar 2019 18:57:43 +0000 Received: from merlin.infradead.org ([2001:8b0:10b:1231::1]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1h72sc-0004tq-Vu for openwrt-devel@bombadil.infradead.org; Thu, 21 Mar 2019 18:57:31 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=Content-Transfer-Encoding:MIME-Version: References:In-Reply-To:Message-Id:Date:Subject:To:From:Sender:Reply-To:Cc: Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=VifoH4ee2nisXbXoooqvW9OrapTGjxjxaR5GWxeb6b0=; b=GtOGFiClacwTN/wcPp3Xibxnl2 b5p+PXA5xBhcs7oeCOy7OXdvBvoVSLXzbulRHHiE0OXBdjFcdzckJjj66Lgb/qZzKa34Eq6DdA/0B fmrvllYhpImjXa0oulj8NUatm9oTJIRlIZi3z9Ti8sBx0GQgeKaF7gKUbQp2MAY9Aa5IBIzZKVBY9 Y4yH5GSD2WHtwZDor/rBfEINmPI1qc+tow1rLH6yBdAuioBgSEnHh1/qc/H6PnjoSibQAKRuVWB7G Wranm9n6FTXUo2j766S/ivT3Op1leLrcoD46bxIwHeazsxCZgUhlUNilU+1dlCSbWMSI+moCu5mK+ neCH2VsA==; Received: from mx-out.tlen.pl ([193.222.135.175]) by merlin.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1h72sX-0001mR-UO for openwrt-devel@lists.openwrt.org; Thu, 21 Mar 2019 18:57:28 +0000 Received: (wp-smtpd smtp.tlen.pl 27822 invoked from network); 21 Mar 2019 19:56:35 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=o2.pl; s=1024a; t=1553194595; bh=VifoH4ee2nisXbXoooqvW9OrapTGjxjxaR5GWxeb6b0=; h=From:To:Subject; b=YwSl8qtm50B8PxlvhdZ91Z0+kqq5+s50f5E2wOl56ZT3dKYzY7sHbnQI+lh4UEIGZ CdPpQ0BsCMyO0KM6/UkFtyTQ82DZQHRnILjrJx8/KaZtoeu3bebOyNGiXJej+FNVi3 Gn+2HCOkYxQVv4QnTf7p/yyAQQy4YK8XQB33YS+4= Received: from 131.ip-164-132-48.eu (HELO localhost.localdomain) (tomek_n@o2.pl@[164.132.48.131]) (envelope-sender ) by smtp.tlen.pl (WP-SMTPD) with ECDHE-RSA-AES256-GCM-SHA384 encrypted SMTP for ; 21 Mar 2019 19:56:35 +0100 From: Tomasz Maciej Nowak To: openwrt-devel@lists.openwrt.org Date: Thu, 21 Mar 2019 19:57:26 +0100 Message-Id: <20190321185727.3239-7-tomek_n@o2.pl> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190321185727.3239-1-tomek_n@o2.pl> References: <20190321185727.3239-1-tomek_n@o2.pl> MIME-Version: 1.0 X-WP-MailID: 7685f5e6ffde654870292700da735c47 X-WP-AV: skaner antywirusowy Poczty o2 X-WP-SPAM: NO 0000000 [AYNE] X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190321_145726_282563_C0237390 X-CRM114-Status: GOOD ( 15.94 ) X-Spam-Score: -0.2 (/) X-Spam-Report: SpamAssassin version 3.4.2 on merlin.infradead.org summary: Content analysis details: (-0.2 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [193.222.135.175 listed in wl.mailspike.net] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (tomek_n[at]o2.pl) -0.0 SPF_PASS SPF: sender matches SPF record 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain Subject: [OpenWrt-Devel] [PATCH 6/7] mvebu: espressobin: add node for eMMC in dts X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "openwrt-devel" Errors-To: openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org Some ESPRESSObin boards come with soldered eMMC flash, backport upstream patches adding this device and add patch to sync sdhci nodes order with U-Boot. Signed-off-by: Tomasz Maciej Nowak --- ...l-armada37xx-Add-emmc-sdio-pinctrl-d.patch | 40 +++++++ ...l-armada-37xx-Enable-emmc-on-espress.patch | 49 ++++++++ ...da-3720-espressobin-correct-spi-node.patch | 2 +- ...x-re-arrange-SDHCI-controllers-order.patch | 105 ++++++++++++++++++ 4 files changed, 195 insertions(+), 1 deletion(-) create mode 100644 target/linux/mvebu/patches-4.14/513-arm64-dts-marvell-armada37xx-Add-emmc-sdio-pinctrl-d.patch create mode 100644 target/linux/mvebu/patches-4.14/514-arm64-dts-marvell-armada-37xx-Enable-emmc-on-espress.patch create mode 100644 target/linux/mvebu/patches-4.14/522-arm64-dts-a37xx-re-arrange-SDHCI-controllers-order.patch diff --git a/target/linux/mvebu/patches-4.14/513-arm64-dts-marvell-armada37xx-Add-emmc-sdio-pinctrl-d.patch b/target/linux/mvebu/patches-4.14/513-arm64-dts-marvell-armada37xx-Add-emmc-sdio-pinctrl-d.patch new file mode 100644 index 0000000000..19702a61ed --- /dev/null +++ b/target/linux/mvebu/patches-4.14/513-arm64-dts-marvell-armada37xx-Add-emmc-sdio-pinctrl-d.patch @@ -0,0 +1,40 @@ +From eefe328439642101774f0f5c4ea0dc6ba1cfb687 Mon Sep 17 00:00:00 2001 +From: Ding Tao +Date: Fri, 26 Oct 2018 11:50:27 +0000 +Subject: [PATCH] arm64: dts: marvell: armada37xx: Add emmc/sdio pinctrl + definition + +Add emmc/sdio pinctrl definition for marvell armada37xx SoCs. + +Signed-off-by: Ding Tao +Signed-off-by: Gregory CLEMENT +--- + arch/arm64/boot/dts/marvell/armada-37xx.dtsi | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +--- a/arch/arm64/boot/dts/marvell/armada-37xx.dtsi ++++ b/arch/arm64/boot/dts/marvell/armada-37xx.dtsi +@@ -218,6 +218,11 @@ + groups = "uart2"; + function = "uart"; + }; ++ ++ mmc_pins: mmc-pins { ++ groups = "emmc_nb"; ++ function = "emmc"; ++ }; + }; + + nb_pm: syscon@14000 { +@@ -247,6 +252,11 @@ + function = "mii"; + }; + ++ sdio_pins: sdio-pins { ++ groups = "sdio_sb"; ++ function = "sdio"; ++ }; ++ + }; + + eth0: ethernet@30000 { diff --git a/target/linux/mvebu/patches-4.14/514-arm64-dts-marvell-armada-37xx-Enable-emmc-on-espress.patch b/target/linux/mvebu/patches-4.14/514-arm64-dts-marvell-armada-37xx-Enable-emmc-on-espress.patch new file mode 100644 index 0000000000..26d090f050 --- /dev/null +++ b/target/linux/mvebu/patches-4.14/514-arm64-dts-marvell-armada-37xx-Enable-emmc-on-espress.patch @@ -0,0 +1,49 @@ +From 43ebc7c1b3ed8198b9acf3019eca16e722f7331c Mon Sep 17 00:00:00 2001 +From: Ding Tao +Date: Fri, 26 Oct 2018 11:50:28 +0000 +Subject: [PATCH] arm64: dts: marvell: armada-37xx: Enable emmc on espressobin + +The ESPRESSObin board has a emmc interface available on U11: declare it +and let the bootloader enable it if the emmc is present. + +[gregory.clement@bootlin.com: disable the emmc by default] +Signed-off-by: Ding Tao +Signed-off-by: Gregory CLEMENT +--- + .../dts/marvell/armada-3720-espressobin.dts | 22 +++++++++++++++++++ + 1 file changed, 22 insertions(+) + +--- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts ++++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts +@@ -93,9 +93,31 @@ + cd-gpios = <&gpionb 3 GPIO_ACTIVE_LOW>; + marvell,pad-type = "sd"; + vqmmc-supply = <&vcc_sd_reg1>; ++ ++ pinctrl-names = "default"; ++ pinctrl-0 = <&sdio_pins>; + status = "okay"; + }; + ++/* U11 */ ++&sdhci0 { ++ non-removable; ++ bus-width = <8>; ++ mmc-ddr-1_8v; ++ mmc-hs400-1_8v; ++ marvell,xenon-emmc; ++ marvell,xenon-tun-count = <9>; ++ marvell,pad-type = "fixed-1-8v"; ++ ++ pinctrl-names = "default"; ++ pinctrl-0 = <&mmc_pins>; ++/* ++ * This eMMC is not populated on all boards, so disable it by ++ * default and let the bootloader enable it, if it is present ++ */ ++ status = "disabled"; ++}; ++ + &spi0 { + status = "okay"; + diff --git a/target/linux/mvebu/patches-4.14/521-arm64-dts-armada-3720-espressobin-correct-spi-node.patch b/target/linux/mvebu/patches-4.14/521-arm64-dts-armada-3720-espressobin-correct-spi-node.patch index 1d2bdfca75..fc7cb2af1e 100644 --- a/target/linux/mvebu/patches-4.14/521-arm64-dts-armada-3720-espressobin-correct-spi-node.patch +++ b/target/linux/mvebu/patches-4.14/521-arm64-dts-armada-3720-espressobin-correct-spi-node.patch @@ -29,7 +29,7 @@ Signed-off-by: Tomasz Maciej Nowak --- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts +++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts -@@ -101,25 +101,9 @@ +@@ -123,25 +123,9 @@ flash@0 { reg = <0>; diff --git a/target/linux/mvebu/patches-4.14/522-arm64-dts-a37xx-re-arrange-SDHCI-controllers-order.patch b/target/linux/mvebu/patches-4.14/522-arm64-dts-a37xx-re-arrange-SDHCI-controllers-order.patch new file mode 100644 index 0000000000..58962baeb7 --- /dev/null +++ b/target/linux/mvebu/patches-4.14/522-arm64-dts-a37xx-re-arrange-SDHCI-controllers-order.patch @@ -0,0 +1,105 @@ +From 9e34242f8817294ec1c2bef7f0c513417cac965e Mon Sep 17 00:00:00 2001 +From: Konstantin Porotchkin +Date: Sun, 25 Nov 2018 18:38:26 +0200 +Subject: [PATCH] arm64: dts: a37xx: re-arrange SDHCI controllers order + +Sync the controllers order with uboot settings: +sdhci-0 is @ 0xd000, sdhci-1 is @ 0xd800. + +Signed-off-by: Konstantin Porotchkin +Reviewed-by: Stefan Chulski +[adapt patch to mainline state] +Signed-off-by: Tomasz Maciej Nowak +--- + arch/arm64/boot/dts/marvell/armada-3720-db.dts | 10 +++++----- + .../boot/dts/marvell/armada-3720-espressobin.dts | 8 ++++---- + arch/arm64/boot/dts/marvell/armada-37xx.dtsi | 4 ++-- + 3 files changed, 11 insertions(+), 11 deletions(-) + +--- a/arch/arm64/boot/dts/marvell/armada-3720-db.dts ++++ b/arch/arm64/boot/dts/marvell/armada-3720-db.dts +@@ -81,9 +81,9 @@ + vcc-supply = <&exp_usb3_vbus>; + }; + +- vcc_sd_reg1: regulator { ++ vcc_sd_reg0: regulator { + compatible = "regulator-gpio"; +- regulator-name = "vcc_sd1"; ++ regulator-name = "vcc_sd0"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <3300000>; + regulator-boot-on; +@@ -163,7 +163,7 @@ + status = "okay"; + }; + +-&sdhci0 { ++&sdhci1 { + non-removable; + bus-width = <8>; + mmc-ddr-1_8v; +@@ -173,12 +173,12 @@ + }; + + /* SD slot module on CON14(V2.0)/CON15(V1.4) */ +-&sdhci1 { ++&sdhci0 { + wp-inverted; + cd-gpios = <&gpiosb 2 GPIO_ACTIVE_LOW>; + bus-width = <4>; + marvell,pad-type = "sd"; +- vqmmc-supply = <&vcc_sd_reg1>; ++ vqmmc-supply = <&vcc_sd_reg0>; + status = "okay"; + }; + +--- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts ++++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts +@@ -61,9 +61,9 @@ + reg = <0x00000000 0x00000000 0x00000000 0x20000000>; + }; + +- vcc_sd_reg1: regulator { ++ vcc_sd_reg0: regulator { + compatible = "regulator-gpio"; +- regulator-name = "vcc_sd1"; ++ regulator-name = "vcc_sd0"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <3300000>; + regulator-boot-on; +@@ -87,12 +87,12 @@ + }; + + /* J1 */ +-&sdhci1 { ++&sdhci0 { + wp-inverted; + bus-width = <4>; + cd-gpios = <&gpionb 3 GPIO_ACTIVE_LOW>; + marvell,pad-type = "sd"; +- vqmmc-supply = <&vcc_sd_reg1>; ++ vqmmc-supply = <&vcc_sd_reg0>; + + pinctrl-names = "default"; + pinctrl-0 = <&sdio_pins>; +--- a/arch/arm64/boot/dts/marvell/armada-37xx.dtsi ++++ b/arch/arm64/boot/dts/marvell/armada-37xx.dtsi +@@ -312,7 +312,7 @@ + }; + }; + +- sdhci1: sdhci@d0000 { ++ sdhci0: sdhci@d0000 { + compatible = "marvell,armada-3700-sdhci", + "marvell,sdhci-xenon"; + reg = <0xd0000 0x300>, +@@ -323,7 +323,7 @@ + status = "disabled"; + }; + +- sdhci0: sdhci@d8000 { ++ sdhci1: sdhci@d8000 { + compatible = "marvell,armada-3700-sdhci", + "marvell,sdhci-xenon"; + reg = <0xd8000 0x300>,