[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <0aefd292-7980-434d-9c18-4ab9f6a0b40e@kwiboo.se>
Date: Sat, 1 Mar 2025 14:01:05 +0100
From: Jonas Karlman <jonas@...boo.se>
To: Yao Zi <ziyao@...root.org>
Cc: Ulf Hansson <ulf.hansson@...aro.org>, Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk+dt@...nel.org>, Conor Dooley
<conor+dt@...nel.org>, Heiko Stuebner <heiko@...ech.de>,
Michael Turquette <mturquette@...libre.com>, Stephen Boyd
<sboyd@...nel.org>, Frank Wang <frank.wang@...k-chips.com>,
Shresth Prasad <shresthprasad7@...il.com>,
Cristian Ciocaltea <cristian.ciocaltea@...labora.com>,
Detlev Casanova <detlev.casanova@...labora.com>, linux-mmc@...r.kernel.org,
devicetree@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-rockchip@...ts.infradead.org, linux-kernel@...r.kernel.org,
linux-clk@...r.kernel.org
Subject: Re: [PATCH 8/8] arm64: dts: rockchip: Enable SD-card interface on
Radxa E20C
Hi,
On 2025-03-01 11:48, Yao Zi wrote:
> SD-card is available on Radxa E20C board.
>
> Signed-off-by: Yao Zi <ziyao@...root.org>
> ---
> arch/arm64/boot/dts/rockchip/rk3528-radxa-e20c.dts | 14 ++++++++++++++
> 1 file changed, 14 insertions(+)
>
> diff --git a/arch/arm64/boot/dts/rockchip/rk3528-radxa-e20c.dts b/arch/arm64/boot/dts/rockchip/rk3528-radxa-e20c.dts
> index d2cdb63d4a9d..473065aa4228 100644
> --- a/arch/arm64/boot/dts/rockchip/rk3528-radxa-e20c.dts
> +++ b/arch/arm64/boot/dts/rockchip/rk3528-radxa-e20c.dts
> @@ -12,6 +12,10 @@ / {
> model = "Radxa E20C";
> compatible = "radxa,e20c", "rockchip,rk3528";
>
> + aliases {
> + mmc0 = &sdmmc;
Suggest using mmc1 for sd-card because the e20c typically have onboard
emmc, compared to removable sd-card.
> + };
> +
> chosen {
> stdout-path = "serial0:1500000n8";
> };
> @@ -20,3 +24,13 @@ chosen {
> &uart0 {
> status = "okay";
> };
> +
> +&sdmmc {
> + bus-width = <4>;
> + cap-mmc-highspeed;
> + cap-sd-highspeed;
> + disable-wp;
> + rockchip,default-sample-phase = <90>;
> + sd-uhs-sdr104;
Are you sure uhs-sdr104 works as is should? Vendor kernel use a
different "v2" tuning and this is also missing the vccio_sd vqmmc-supply
to switch between 3v3 and 1v8.
You could add following regulator for sdmmc:
vccio_sd: regulator-vccio-sd {
compatible = "regulator-gpio";
gpios = <&gpio4 RK_PB6 GPIO_ACTIVE_HIGH>;
pinctrl-names = "default";
pinctrl-0 = <&sdmmc_vol_ctrl_h>;
regulator-name = "vccio_sd";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <3300000>;
states = <1800000 0x0>, <3300000 0x1>;
};
and following pinctrl:
sdmmc {
sdmmc_vol_ctrl_h: sdmmc-vol-ctrl-h {
rockchip,pins = <4 RK_PB6 RK_FUNC_GPIO &pcfg_pull_none>;
};
};
add then the power supplies to the sdmmc node:
vmmc-supply = <&vcc_3v3>;
vqmmc-supply = <&vccio_sd>;
That matches the schematics for e20c, and works when testing non-uhs modes.
Regards,
Jonas
> + status = "okay";
> +};
Powered by blists - more mailing lists