From: Dmitry Rokosov <ddrokosov@sberdevices.ru>
To: <neil.armstrong@linaro.org>, <jbrunet@baylibre.com>,
<mturquette@baylibre.com>, <sboyd@kernel.org>,
<robh+dt@kernel.org>, <krzysztof.kozlowski+dt@linaro.org>,
<khilman@baylibre.com>, <martin.blumenstingl@googlemail.com>,
<conor+dt@kernel.org>
Cc: <kernel@sberdevices.ru>, <sdfw_system_team@sberdevices.ru>,
<rockosov@gmail.com>, <linux-amlogic@lists.infradead.org>,
<linux-clk@vger.kernel.org>, <devicetree@vger.kernel.org>,
<linux-kernel@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>,
Jan Dakinevich <yvdakinevich@sberdevices.ru>,
Dmitry Rokosov <ddrokosov@sberdevices.ru>
Subject: [PATCH v1 6/6] arm64: dts: meson: a1: add eMMC controller and its pins
Date: Wed, 7 Jun 2023 23:16:41 +0300 [thread overview]
Message-ID: <20230607201641.20982-7-ddrokosov@sberdevices.ru> (raw)
In-Reply-To: <20230607201641.20982-1-ddrokosov@sberdevices.ru>
From: Jan Dakinevich <yvdakinevich@sberdevices.ru>
The definition is inspired by a similar one for AXG SoC family.
'sdio_pins' and 'sdio_clk_gate_pins' pinctrls are supposed to be used as
"default" and "clk-gate" in board-specific device trees.
'meson-gx' driver during initialization sets clock to safe low-frequency
value (400kHz). However, both source clocks ("clkin0" and "clkin1") are
high-frequency by default, and using of eMMC's internal divider is not
enough to achieve so low values. To provide low-frequency source,
reparent "sd_emmc_sel2" clock using 'assigned-clocks' property.
Signed-off-by: Jan Dakinevich <yvdakinevich@sberdevices.ru>
Signed-off-by: Dmitry Rokosov <ddrokosov@sberdevices.ru>
---
arch/arm64/boot/dts/amlogic/meson-a1.dtsi | 43 +++++++++++++++++++++++
1 file changed, 43 insertions(+)
diff --git a/arch/arm64/boot/dts/amlogic/meson-a1.dtsi b/arch/arm64/boot/dts/amlogic/meson-a1.dtsi
index 3eb6aa9c00e0..a25170c61462 100644
--- a/arch/arm64/boot/dts/amlogic/meson-a1.dtsi
+++ b/arch/arm64/boot/dts/amlogic/meson-a1.dtsi
@@ -134,6 +134,32 @@ mux {
bias-pull-down;
};
};
+
+ sdio_pins: sdio {
+ mux-0 {
+ groups = "sdcard_d0_x",
+ "sdcard_d1_x",
+ "sdcard_d2_x",
+ "sdcard_d3_x",
+ "sdcard_cmd_x";
+ function = "sdcard";
+ bias-pull-up;
+ };
+
+ mux-1 {
+ groups = "sdcard_clk_x";
+ function = "sdcard";
+ bias-disable;
+ };
+ };
+
+ sdio_clk_gate_pins: sdio_clk_gate {
+ mux {
+ groups = "sdcard_clk_x";
+ function = "sdcard";
+ bias-pull-down;
+ };
+ };
};
uart_AO: serial@1c00 {
@@ -200,6 +226,23 @@ usb2_phy1: phy@4000 {
#phy-cells = <0>;
power-domains = <&pwrc PWRC_USB_ID>;
};
+
+ sd_emmc: sd@10000 {
+ compatible = "amlogic,meson-axg-mmc";
+ reg = <0x0 0x10000 0x0 0x800>;
+ interrupts = <GIC_SPI 58 IRQ_TYPE_LEVEL_HIGH>;
+ clocks = <&clkc_periphs CLKID_SD_EMMC_A>,
+ <&clkc_periphs CLKID_SD_EMMC>,
+ <&clkc_pll CLKID_FCLK_DIV2>;
+ clock-names = "core",
+ "clkin0",
+ "clkin1";
+ assigned-clocks = <&clkc_periphs CLKID_SD_EMMC_SEL2>;
+ assigned-clock-parents = <&xtal>;
+ resets = <&reset RESET_SD_EMMC_A>;
+ power-domains = <&pwrc PWRC_SD_EMMC_ID>;
+ status = "disabled";
+ };
};
gic: interrupt-controller@ff901000 {
--
2.36.0
next prev parent reply other threads:[~2023-06-07 20:17 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-07 20:16 [PATCH v1 0/6] arm64: dts: meson: a1: introduce several peripheral IPs Dmitry Rokosov
2023-06-07 20:16 ` [PATCH v1 1/6] arm64: dts: meson: a1: introduce PLL and Peripherals clk controllers Dmitry Rokosov
2023-06-25 21:00 ` Martin Blumenstingl
2023-06-28 14:18 ` Dmitry Rokosov
2023-06-28 20:51 ` Martin Blumenstingl
2023-06-07 20:16 ` [PATCH v1 2/6] arm64: dts: meson: a1: support USB controller in OTG mode Dmitry Rokosov
2023-06-07 20:16 ` [PATCH v1 3/6] arm64: dts: meson: a1: enable efuse controller and setup its clk Dmitry Rokosov
2023-06-25 20:50 ` Martin Blumenstingl
2023-06-28 14:20 ` Dmitry Rokosov
2023-06-07 20:16 ` [PATCH v1 4/6] arm64: dts: meson: a1: introduce SPI Flash Controller Dmitry Rokosov
2023-06-25 21:03 ` Martin Blumenstingl
2023-06-28 14:23 ` Dmitry Rokosov
2023-06-07 20:16 ` [PATCH v1 5/6] arm64: dts: meson: a1: introduce UART_AO mux definitions Dmitry Rokosov
2023-06-25 21:07 ` Martin Blumenstingl
2023-06-26 13:34 ` neil.armstrong
2023-06-28 14:51 ` Dmitry Rokosov
2023-06-28 14:49 ` Dmitry Rokosov
2023-06-07 20:16 ` Dmitry Rokosov [this message]
2023-06-25 21:11 ` [PATCH v1 6/6] arm64: dts: meson: a1: add eMMC controller and its pins Martin Blumenstingl
2023-06-26 13:36 ` neil.armstrong
2023-06-28 14:28 ` Dmitry Rokosov
2023-06-23 8:22 ` [PATCH v1 0/6] arm64: dts: meson: a1: introduce several peripheral IPs Dmitry Rokosov
2023-06-23 8:49 ` Krzysztof Kozlowski
2023-06-23 11:23 ` Dmitry Rokosov
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=20230607201641.20982-7-ddrokosov@sberdevices.ru \
--to=ddrokosov@sberdevices.ru \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=jbrunet@baylibre.com \
--cc=kernel@sberdevices.ru \
--cc=khilman@baylibre.com \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-amlogic@lists.infradead.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-clk@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=martin.blumenstingl@googlemail.com \
--cc=mturquette@baylibre.com \
--cc=neil.armstrong@linaro.org \
--cc=robh+dt@kernel.org \
--cc=rockosov@gmail.com \
--cc=sboyd@kernel.org \
--cc=sdfw_system_team@sberdevices.ru \
--cc=yvdakinevich@sberdevices.ru \
/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).