Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753048AbbLFJ2j (ORCPT ); Sun, 6 Dec 2015 04:28:39 -0500 Received: from mail-wm0-f47.google.com ([74.125.82.47]:34366 "EHLO mail-wm0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752703AbbLFJ2d (ORCPT ); Sun, 6 Dec 2015 04:28:33 -0500 Subject: Re: [PATCH] arm: dts: berlin2q-marvell-dmp: add sdhci1 fully functionality To: Jisheng Zhang , robh+dt@kernel.org, pawel.moll@arm.com, mark.rutland@arm.com, ijc+devicetree@hellion.org.uk, galak@codeaurora.org, linux@arm.linux.org.uk References: <1448891679-7894-1-git-send-email-jszhang@marvell.com> Cc: linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org From: Sebastian Hesselbarth Message-ID: <5663FFBE.1070708@gmail.com> Date: Sun, 6 Dec 2015 10:28:30 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0 In-Reply-To: <1448891679-7894-1-git-send-email-jszhang@marvell.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2975 Lines: 102 On 30.11.2015 14:54, Jisheng Zhang wrote: > The sdhci1 on Marvell BG2Q DMP board is used as sdcard interface, we > have gpios for card detection, write-protect, vqmmc and vmmc. > > This patch adds pinmux for this sdcard interface, then adds regulators > for vmmc and vqmmc, lastly adds cd-gpios, wp-gpios properties. > > Signed-off-by: Jisheng Zhang Applied to berlin/dt. > --- > since v1: Please also increment the patch subject version next time. Thanks! Sebastian > - move sd1_pmux to soc dtsi > - remove cd-inverted and make cd-gpio GPIO_ACTIVE_LOW > > arch/arm/boot/dts/berlin2q-marvell-dmp.dts | 37 ++++++++++++++++++++++++++++-- > arch/arm/boot/dts/berlin2q.dtsi | 5 ++++ > 2 files changed, 40 insertions(+), 2 deletions(-) > > diff --git a/arch/arm/boot/dts/berlin2q-marvell-dmp.dts b/arch/arm/boot/dts/berlin2q-marvell-dmp.dts > index cdcf89b..33b2875 100644 > --- a/arch/arm/boot/dts/berlin2q-marvell-dmp.dts > +++ b/arch/arm/boot/dts/berlin2q-marvell-dmp.dts > @@ -84,12 +84,45 @@ > gpio = <&portb 12 GPIO_ACTIVE_HIGH>; > enable-active-high; > }; > + > + reg_sdio1_vmmc: regulator@3 { > + compatible = "regulator-fixed"; > + regulator-min-microvolt = <3300000>; > + regulator-max-microvolt = <3300000>; > + regulator-name = "sdio1_vmmc"; > + enable-active-high; > + regulator-boot-on; > + gpio = <&portb 21 GPIO_ACTIVE_HIGH>; > + }; > + > + reg_sdio1_vqmmc: regulator@4 { > + compatible = "regulator-gpio"; > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <3300000>; > + regulator-name = "sdio1_vqmmc"; > + regulator-type = "voltage"; > + enable-active-high; > + gpios = <&portb 16 GPIO_ACTIVE_HIGH>; > + states = <3300000 0x1 > + 1800000 0x0>; > + }; > + }; > +}; > + > +&soc_pinctrl { > + sd1gpio_pmux: sd1pwr-pmux { > + groups = "G23", "G32"; > + function = "gpio"; > }; > }; > > &sdhci1 { > - broken-cd; > - sdhci,wp-inverted; > + vmmc-supply = <®_sdio1_vmmc>; > + vqmmc-supply = <®_sdio1_vqmmc>; > + cd-gpios = <&portc 30 GPIO_ACTIVE_LOW>; > + wp-gpios = <&portd 0 GPIO_ACTIVE_HIGH>; > + pinctrl-0 = <&sd1gpio_pmux>, <&sd1_pmux>; > + pinctrl-names = "default"; > status = "okay"; > }; > > diff --git a/arch/arm/boot/dts/berlin2q.dtsi b/arch/arm/boot/dts/berlin2q.dtsi > index 8ea177f..73a9362 100644 > --- a/arch/arm/boot/dts/berlin2q.dtsi > +++ b/arch/arm/boot/dts/berlin2q.dtsi > @@ -417,6 +417,11 @@ > soc_pinctrl: pin-controller { > compatible = "marvell,berlin2q-soc-pinctrl"; > > + sd1_pmux: sd1-pmux { > + groups = "G31"; > + function = "sd1"; > + }; > + > twsi0_pmux: twsi0-pmux { > groups = "G6"; > function = "twsi0"; > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/