From: Ryan Chen <ryanchen.aspeed@gmail.com>
To: openbmc@lists.ozlabs.org
Cc: Ryan Chen <ryanchen.aspeed@gmail.com>,
joel@jms.id.au, andrew@aj.id.au, ryan_chen@aspeedtech.com,
benh@kernel.crashing.org, mine260309@gmail.com
Subject: [PATCH linux dev-4.17 6/7] dts: Aspeed: Add devicetree for Aspeed sdhci
Date: Wed, 11 Jul 2018 13:17:09 +0800 [thread overview]
Message-ID: <1531286230-28453-7-git-send-email-ryanchen.aspeed@gmail.com> (raw)
In-Reply-To: <1531286230-28453-1-git-send-email-ryanchen.aspeed@gmail.com>
Add devicetree for Aspeed's sdhci
Signed-off-by: Ryan Chen <ryanchen.aspeed@gmail.com>
---
.../bindings/mmc/aspeed,aspeed-sdhci.txt | 42 ++++++++++++++++++++++
arch/arm/boot/dts/aspeed-ast2500-evb.dts | 14 ++++++++
arch/arm/boot/dts/aspeed-g4.dtsi | 20 +++++++++++
arch/arm/boot/dts/aspeed-g5.dtsi | 20 +++++++++++
4 files changed, 96 insertions(+)
create mode 100644 Documentation/devicetree/bindings/mmc/aspeed,aspeed-sdhci.txt
diff --git a/Documentation/devicetree/bindings/mmc/aspeed,aspeed-sdhci.txt b/Documentation/devicetree/bindings/mmc/aspeed,aspeed-sdhci.txt
new file mode 100644
index 0000000..c7cb985
--- /dev/null
+++ b/Documentation/devicetree/bindings/mmc/aspeed,aspeed-sdhci.txt
@@ -0,0 +1,42 @@
+Device Tree Bindings for the ASPEED SoC SDHCI Controller
+
+This file documents differences between the core properties in mmc.txt
+and the properties present in the ASPEED SDHCI
+
+Required properties:
+- compatible : should be "aspeed,ast2500-sdhci" or "aspeed,ast2400-sdhci"
+- clocks : phandle + clock specifier pair of the external clock
+- interrupts : interrupt number
+- interrupt-parent : interrupt controller for bus, should reference a
+ aspeed,aspeed-sdhci-ic interrupt controller
+
+Example:
+
+sdhci {
+ compatible = "simple-bus";
+ #address-cells = <1>;
+ #size-cells = <1>;
+ ranges = <0 0x1e740000 0x1000>;
+
+ sdhci_ic: interrupt-controller@0 {
+ #interrupt-cells = <1>;
+ compatible = "aspeed,aspeed-sdhci-irq";
+ reg = <0x0 0x100>;
+ interrupts = <26>;
+ interrupt-controller;
+ clocks = <&syscon ASPEED_CLK_GATE_SDCLKCLK>;
+ clock-names = "sdclk", "sd_extclk";
+ };
+
+ sdhci_slot0: sdhci_slot0@100 {
+ compatible = "aspeed,sdhci-ast2500";
+ reg = <0x100 0x100>;
+ interrupts = <0>;
+ interrupt-parent = <&sdhci_ic>;
+ slot = <0>;
+ sdhci,auto-cmd12;
+ clocks = <&syscon ASPEED_CLK_SDIO>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pinctrl_sd1_default>;
+ };
+};
diff --git a/arch/arm/boot/dts/aspeed-ast2500-evb.dts b/arch/arm/boot/dts/aspeed-ast2500-evb.dts
index 5dbb33c..5578ae0 100644
--- a/arch/arm/boot/dts/aspeed-ast2500-evb.dts
+++ b/arch/arm/boot/dts/aspeed-ast2500-evb.dts
@@ -97,6 +97,20 @@
};
};
+&sdhci_slot0 {
+ status = "okay";
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&pinctrl_sd1_default>;
+};
+
+&sdhci_slot1 {
+ status = "okay";
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&pinctrl_sd2_default>;
+};
+
/*
* Enable port A as device (via the virtual hub) and port B as
* host by default on the eval board. This can be easily changed
diff --git a/arch/arm/boot/dts/aspeed-g4.dtsi b/arch/arm/boot/dts/aspeed-g4.dtsi
index 7ad646d..f4a8d7d 100644
--- a/arch/arm/boot/dts/aspeed-g4.dtsi
+++ b/arch/arm/boot/dts/aspeed-g4.dtsi
@@ -387,6 +387,26 @@
clocks = <&syscon ASPEED_CLK_GATE_SDCLKCLK>;
};
+ sdhci_slot0: sdhci_slot0@100 {
+ compatible = "aspeed,sdhci-ast2400";
+ reg = <0x100 0x100>;
+ interrupts = <0>;
+ interrupt-parent = <&sdhci_ic>;
+ sdhci,auto-cmd12;
+ clocks = <&syscon ASPEED_CLK_SDIO>;
+ status = "disabled";
+ };
+
+ sdhci_slot1: sdhci_slot1@200 {
+ compatible = "aspeed,sdhci-ast2400";
+ reg = <0x200 0x100>;
+ interrupts = <1>;
+ interrupt-parent = <&sdhci_ic>;
+ sdhci,auto-cmd12;
+ clocks = <&syscon ASPEED_CLK_SDIO>;
+ status = "disabled";
+ };
+
};
&i2c {
diff --git a/arch/arm/boot/dts/aspeed-g5.dtsi b/arch/arm/boot/dts/aspeed-g5.dtsi
index ba850ca..effe631 100644
--- a/arch/arm/boot/dts/aspeed-g5.dtsi
+++ b/arch/arm/boot/dts/aspeed-g5.dtsi
@@ -464,6 +464,26 @@
clocks = <&syscon ASPEED_CLK_GATE_SDCLKCLK>;
};
+ sdhci_slot0: sdhci_slot0@100 {
+ compatible = "aspeed,sdhci-ast2500";
+ reg = <0x100 0x100>;
+ interrupts = <0>;
+ interrupt-parent = <&sdhci_ic>;
+ sdhci,auto-cmd12;
+ clocks = <&syscon ASPEED_CLK_SDIO>;
+ status = "disabled";
+ };
+
+ sdhci_slot1: sdhci_slot1@200 {
+ compatible = "aspeed,sdhci-ast2500";
+ reg = <0x200 0x100>;
+ interrupts = <1>;
+ interrupt-parent = <&sdhci_ic>;
+ sdhci,auto-cmd12;
+ clocks = <&syscon ASPEED_CLK_SDIO>;
+ status = "disabled";
+ };
+
};
&i2c {
--
2.7.4
next prev parent reply other threads:[~2018-07-11 5:18 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-11 5:17 [PATCH linux dev-4.17 0/7] drivers/mmc/host: Add Aspeed SDIO driver Ryan Chen
2018-07-11 5:17 ` [PATCH linux dev-4.17 1/7] clk: Aspeed: Modify clk-aspeed.c driver probe sequence Ryan Chen
2018-07-11 5:47 ` Benjamin Herrenschmidt
2018-07-17 6:04 ` Ryan Chen
2018-07-17 9:45 ` Benjamin Herrenschmidt
2018-07-18 6:37 ` Joel Stanley
2018-07-18 7:16 ` Ryan Chen
2018-07-11 5:17 ` [PATCH linux dev-4.17 2/7] clk: Aspeed: Add sdhci reset and clock Ryan Chen
2018-07-11 5:26 ` Joel Stanley
2018-07-11 5:49 ` Benjamin Herrenschmidt
2018-07-11 5:17 ` [PATCH linux dev-4.17 3/7] irqchip: Aspeed: Add Aspeed sdhci irq driver Ryan Chen
2018-07-11 5:29 ` Joel Stanley
2018-07-11 5:17 ` [PATCH linux dev-4.17 4/7] dts: Aspeed: Add Aspeed sdhci dts document Ryan Chen
2018-07-11 5:30 ` Joel Stanley
2018-07-11 5:17 ` [PATCH linux dev-4.17 5/7] mmc: Aspeed: Add driver for Aspeed sdhci Ryan Chen
2018-07-11 5:32 ` Joel Stanley
2018-07-11 5:17 ` Ryan Chen [this message]
2018-07-11 5:17 ` [PATCH linux dev-4.17 7/7] configs: Aspeed: enable mmc host in defconfig Ryan Chen
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=1531286230-28453-7-git-send-email-ryanchen.aspeed@gmail.com \
--to=ryanchen.aspeed@gmail.com \
--cc=andrew@aj.id.au \
--cc=benh@kernel.crashing.org \
--cc=joel@jms.id.au \
--cc=mine260309@gmail.com \
--cc=openbmc@lists.ozlabs.org \
--cc=ryan_chen@aspeedtech.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).