All of lore.kernel.org
 help / color / mirror / Atom feed
From: Simon Horman <horms+renesas@verge.net.au>
To: Wolfram Sang <wsa+renesas@sang-engineering.com>,
	Ulf Hansson <ulf.hansson@linaro.org>
Cc: Magnus Damm <magnus.damm@gmail.com>,
	linux-mmc@vger.kernel.org, linux-renesas-soc@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	Simon Horman <horms+renesas@verge.net.au>
Subject: [PATCH v7 09/11] arm64: dts: r8a7796: salvator-x: enable SDHI0 & 3
Date: Tue, 13 Sep 2016 12:57:06 +0200	[thread overview]
Message-ID: <1473764228-24768-10-git-send-email-horms+renesas@verge.net.au> (raw)
In-Reply-To: <1473764228-24768-1-git-send-email-horms+renesas@verge.net.au>

Enable the exposed SD card slots in the DT of the r8a7796/salvator-x.

Based on work for the r8a7795/salvator-x by Ai Kyuse.

Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 arch/arm64/boot/dts/renesas/r8a7796-salvator-x.dts | 84 ++++++++++++++++++++++
 1 file changed, 84 insertions(+)

diff --git a/arch/arm64/boot/dts/renesas/r8a7796-salvator-x.dts b/arch/arm64/boot/dts/renesas/r8a7796-salvator-x.dts
index 13db7d61c26c..a8373c248ad1 100644
--- a/arch/arm64/boot/dts/renesas/r8a7796-salvator-x.dts
+++ b/arch/arm64/boot/dts/renesas/r8a7796-salvator-x.dts
@@ -10,6 +10,7 @@
 
 /dts-v1/;
 #include "r8a7796.dtsi"
+#include <dt-bindings/gpio/gpio.h>
 
 / {
 	model = "Renesas Salvator-X board based on r8a7796";
@@ -29,6 +30,55 @@
 		/* first 128MB is reserved for secure area. */
 		reg = <0x0 0x48000000 0x0 0x78000000>;
 	};
+
+	vcc_sdhi0: regulator-vcc-sdhi0 {
+		compatible = "regulator-fixed";
+
+		regulator-name = "SDHI0 Vcc";
+		regulator-min-microvolt = <3300000>;
+		regulator-max-microvolt = <3300000>;
+
+		gpio = <&gpio5 2 GPIO_ACTIVE_HIGH>;
+		enable-active-high;
+	};
+
+	vccq_sdhi0: regulator-vccq-sdhi0 {
+		compatible = "regulator-gpio";
+
+		regulator-name = "SDHI0 VccQ";
+		regulator-min-microvolt = <1800000>;
+		regulator-max-microvolt = <3300000>;
+
+		gpios = <&gpio5 1 GPIO_ACTIVE_HIGH>;
+		gpios-states = <1>;
+		states = <3300000 1
+			  1800000 0>;
+	};
+
+	vcc_sdhi3: regulator-vcc-sdhi3 {
+		compatible = "regulator-fixed";
+
+		regulator-name = "SDHI3 Vcc";
+		regulator-min-microvolt = <3300000>;
+		regulator-max-microvolt = <3300000>;
+
+		gpio = <&gpio3 15 GPIO_ACTIVE_HIGH>;
+		enable-active-high;
+	};
+
+	vccq_sdhi3: regulator-vccq-sdhi3 {
+		compatible = "regulator-gpio";
+
+		regulator-name = "SDHI3 VccQ";
+		regulator-min-microvolt = <1800000>;
+		regulator-max-microvolt = <3300000>;
+
+		gpios = <&gpio3 14 GPIO_ACTIVE_HIGH>;
+		gpios-states = <1>;
+		states = <3300000 1
+			  1800000 0>;
+	};
+
 };
 
 &pfc {
@@ -43,12 +93,46 @@
 		groups = "scif_clk_a";
 		function = "scif_clk";
 	};
+
+	sdhi0_pins: sd0 {
+		groups = "sdhi0_data4", "sdhi0_ctrl";
+		function = "sdhi0";
+	};
+
+	sdhi3_pins: sd3 {
+		groups = "sdhi3_data4", "sdhi3_ctrl";
+		function = "sdhi3";
+	};
 };
 
 &extal_clk {
 	clock-frequency = <16666666>;
 };
 
+&sdhi0 {
+	pinctrl-0 = <&sdhi0_pins>;
+	pinctrl-names = "default";
+
+	vmmc-supply = <&vcc_sdhi0>;
+	vqmmc-supply = <&vccq_sdhi0>;
+	cd-gpios = <&gpio3 12 GPIO_ACTIVE_LOW>;
+	wp-gpios = <&gpio3 13 GPIO_ACTIVE_HIGH>;
+	bus-width = <4>;
+	status = "okay";
+};
+
+&sdhi3 {
+	pinctrl-0 = <&sdhi3_pins>;
+	pinctrl-names = "default";
+
+	vmmc-supply = <&vcc_sdhi3>;
+	vqmmc-supply = <&vccq_sdhi3>;
+	cd-gpios = <&gpio4 15 GPIO_ACTIVE_LOW>;
+	wp-gpios = <&gpio4 16 GPIO_ACTIVE_HIGH>;
+	bus-width = <4>;
+	status = "okay";
+};
+
 &scif2 {
 	pinctrl-0 = <&scif2_pins>;
 	pinctrl-names = "default";
-- 
2.7.0.rc3.207.g0ac5344

WARNING: multiple messages have this Message-ID (diff)
From: horms+renesas@verge.net.au (Simon Horman)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v7 09/11] arm64: dts: r8a7796: salvator-x: enable SDHI0 & 3
Date: Tue, 13 Sep 2016 12:57:06 +0200	[thread overview]
Message-ID: <1473764228-24768-10-git-send-email-horms+renesas@verge.net.au> (raw)
In-Reply-To: <1473764228-24768-1-git-send-email-horms+renesas@verge.net.au>

Enable the exposed SD card slots in the DT of the r8a7796/salvator-x.

Based on work for the r8a7795/salvator-x by Ai Kyuse.

Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 arch/arm64/boot/dts/renesas/r8a7796-salvator-x.dts | 84 ++++++++++++++++++++++
 1 file changed, 84 insertions(+)

diff --git a/arch/arm64/boot/dts/renesas/r8a7796-salvator-x.dts b/arch/arm64/boot/dts/renesas/r8a7796-salvator-x.dts
index 13db7d61c26c..a8373c248ad1 100644
--- a/arch/arm64/boot/dts/renesas/r8a7796-salvator-x.dts
+++ b/arch/arm64/boot/dts/renesas/r8a7796-salvator-x.dts
@@ -10,6 +10,7 @@
 
 /dts-v1/;
 #include "r8a7796.dtsi"
+#include <dt-bindings/gpio/gpio.h>
 
 / {
 	model = "Renesas Salvator-X board based on r8a7796";
@@ -29,6 +30,55 @@
 		/* first 128MB is reserved for secure area. */
 		reg = <0x0 0x48000000 0x0 0x78000000>;
 	};
+
+	vcc_sdhi0: regulator-vcc-sdhi0 {
+		compatible = "regulator-fixed";
+
+		regulator-name = "SDHI0 Vcc";
+		regulator-min-microvolt = <3300000>;
+		regulator-max-microvolt = <3300000>;
+
+		gpio = <&gpio5 2 GPIO_ACTIVE_HIGH>;
+		enable-active-high;
+	};
+
+	vccq_sdhi0: regulator-vccq-sdhi0 {
+		compatible = "regulator-gpio";
+
+		regulator-name = "SDHI0 VccQ";
+		regulator-min-microvolt = <1800000>;
+		regulator-max-microvolt = <3300000>;
+
+		gpios = <&gpio5 1 GPIO_ACTIVE_HIGH>;
+		gpios-states = <1>;
+		states = <3300000 1
+			  1800000 0>;
+	};
+
+	vcc_sdhi3: regulator-vcc-sdhi3 {
+		compatible = "regulator-fixed";
+
+		regulator-name = "SDHI3 Vcc";
+		regulator-min-microvolt = <3300000>;
+		regulator-max-microvolt = <3300000>;
+
+		gpio = <&gpio3 15 GPIO_ACTIVE_HIGH>;
+		enable-active-high;
+	};
+
+	vccq_sdhi3: regulator-vccq-sdhi3 {
+		compatible = "regulator-gpio";
+
+		regulator-name = "SDHI3 VccQ";
+		regulator-min-microvolt = <1800000>;
+		regulator-max-microvolt = <3300000>;
+
+		gpios = <&gpio3 14 GPIO_ACTIVE_HIGH>;
+		gpios-states = <1>;
+		states = <3300000 1
+			  1800000 0>;
+	};
+
 };
 
 &pfc {
@@ -43,12 +93,46 @@
 		groups = "scif_clk_a";
 		function = "scif_clk";
 	};
+
+	sdhi0_pins: sd0 {
+		groups = "sdhi0_data4", "sdhi0_ctrl";
+		function = "sdhi0";
+	};
+
+	sdhi3_pins: sd3 {
+		groups = "sdhi3_data4", "sdhi3_ctrl";
+		function = "sdhi3";
+	};
 };
 
 &extal_clk {
 	clock-frequency = <16666666>;
 };
 
+&sdhi0 {
+	pinctrl-0 = <&sdhi0_pins>;
+	pinctrl-names = "default";
+
+	vmmc-supply = <&vcc_sdhi0>;
+	vqmmc-supply = <&vccq_sdhi0>;
+	cd-gpios = <&gpio3 12 GPIO_ACTIVE_LOW>;
+	wp-gpios = <&gpio3 13 GPIO_ACTIVE_HIGH>;
+	bus-width = <4>;
+	status = "okay";
+};
+
+&sdhi3 {
+	pinctrl-0 = <&sdhi3_pins>;
+	pinctrl-names = "default";
+
+	vmmc-supply = <&vcc_sdhi3>;
+	vqmmc-supply = <&vccq_sdhi3>;
+	cd-gpios = <&gpio4 15 GPIO_ACTIVE_LOW>;
+	wp-gpios = <&gpio4 16 GPIO_ACTIVE_HIGH>;
+	bus-width = <4>;
+	status = "okay";
+};
+
 &scif2 {
 	pinctrl-0 = <&scif2_pins>;
 	pinctrl-names = "default";
-- 
2.7.0.rc3.207.g0ac5344

  parent reply	other threads:[~2016-09-13 10:57 UTC|newest]

Thread overview: 62+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-13 10:56 [PATCH v7 00/11] ARM, arm64: renesas: Enable UHS-I SDR-104 Simon Horman
2016-09-13 10:56 ` Simon Horman
2016-09-13 10:56 ` [PATCH v7 01/11] ARM: dts: lager: " Simon Horman
2016-09-13 10:56   ` Simon Horman
2016-09-13 10:56 ` [PATCH v7 02/11] arm64: dts: r8a7795: salvator-x: enable UHS for SDHI 0 & 3 Simon Horman
2016-09-13 10:56   ` Simon Horman
2016-09-16  9:55   ` Simon Horman
2016-09-16  9:55     ` Simon Horman
2016-09-16 10:22     ` Wolfram Sang
2016-09-16 10:22       ` Wolfram Sang
2016-09-13 10:57 ` [PATCH v7 03/11] arm64: dts: r8a7795: salvator-x: Enable UHS-I SDR-104 Simon Horman
2016-09-13 10:57   ` Simon Horman
2016-10-25 10:48   ` Geert Uytterhoeven
2016-10-25 10:48     ` Geert Uytterhoeven
2016-11-07 12:32     ` Simon Horman
2016-11-07 12:32       ` Simon Horman
2016-09-13 10:57 ` [PATCH v7 04/11] ARM: dts: r8a7791: set maximum frequency for SDHI clocks Simon Horman
2016-09-13 10:57   ` Simon Horman
2016-09-16  9:53   ` Simon Horman
2016-09-16  9:53     ` Simon Horman
2016-09-13 10:57 ` [PATCH v7 05/11] ARM: dts: koelsch: Enable UHS-I SDR-50 and SDR-104 Simon Horman
2016-09-13 10:57   ` Simon Horman
2016-09-16 10:00   ` Simon Horman
2016-09-16 10:00     ` Simon Horman
2016-09-16 10:23     ` Wolfram Sang
2016-09-16 10:23       ` Wolfram Sang
2016-09-13 10:57 ` [PATCH v7 06/11] ARM: dts: r8a7794: set maximum frequency for SDHI clocks Simon Horman
2016-09-13 10:57   ` Simon Horman
2016-09-16 10:26   ` Wolfram Sang
2016-09-16 10:26     ` Wolfram Sang
2016-09-13 10:57 ` [PATCH v7 07/11] ARM: dts: alt: Enable UHS-I SDR-50 and SDR-104 Simon Horman
2016-09-13 10:57   ` Simon Horman
2016-09-16 10:27   ` Wolfram Sang
2016-09-16 10:27     ` Wolfram Sang
2016-09-16 10:44     ` Simon Horman
2016-09-16 10:44       ` Simon Horman
2016-09-13 10:57 ` [PATCH v7 08/11] arm64: dts: r8a7796: add SDHI nodes Simon Horman
2016-09-13 10:57   ` Simon Horman
2016-09-16 10:30   ` Wolfram Sang
2016-09-16 10:30     ` Wolfram Sang
2016-09-16 10:53     ` Simon Horman
2016-09-16 10:53       ` Simon Horman
2016-10-20  9:19       ` Simon Horman
2016-10-20  9:19         ` Simon Horman
2016-09-13 10:57 ` Simon Horman [this message]
2016-09-13 10:57   ` [PATCH v7 09/11] arm64: dts: r8a7796: salvator-x: enable SDHI0 & 3 Simon Horman
2016-09-16 10:32   ` Wolfram Sang
2016-09-16 10:32     ` Wolfram Sang
2016-10-20  9:19     ` Simon Horman
2016-10-20  9:19       ` Simon Horman
2016-09-13 10:57 ` [PATCH v7 10/11] arm64: dts: r8a7796: salvator-x: enable UHS for SDHI 0 " Simon Horman
2016-09-13 10:57   ` Simon Horman
2016-09-16 10:33   ` Wolfram Sang
2016-09-16 10:33     ` Wolfram Sang
2016-10-20  9:19     ` Simon Horman
2016-10-20  9:19       ` Simon Horman
2016-09-13 10:57 ` [PATCH v7 11/11] arm64: dts: r8a7796: salvator-x: Enable UHS-I SDR-104 Simon Horman
2016-09-13 10:57   ` Simon Horman
2016-10-25 10:49   ` Geert Uytterhoeven
2016-10-25 10:49     ` Geert Uytterhoeven
2016-11-07 12:32     ` Simon Horman
2016-11-07 12:32       ` Simon Horman

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=1473764228-24768-10-git-send-email-horms+renesas@verge.net.au \
    --to=horms+renesas@verge.net.au \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=magnus.damm@gmail.com \
    --cc=ulf.hansson@linaro.org \
    --cc=wsa+renesas@sang-engineering.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.