arm64: dts: renesas: spider-cpu: Enable eMMC0
authorWolfram Sang <wsa+renesas@sang-engineering.com>
Mon, 11 Jul 2022 13:46:56 +0000 (15:46 +0200)
committerGeert Uytterhoeven <geert+renesas@glider.be>
Mon, 15 Aug 2022 09:12:12 +0000 (11:12 +0200)
This enables the on-board eMMC on the Spider board. Switch SW3 has to be
in the default (neutral) position. Other settings will not be supported
upstream!

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Tested-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Link: https://lore.kernel.org/r/20220711134656.277730-4-wsa+renesas@sang-engineering.com
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
arch/arm64/boot/dts/renesas/r8a779f0-spider-cpu.dtsi

index 28fbf7bc1eb4df20f0d625ec3e197f10face202b..4a876d47f59b515eb87fd07e967c6d9715bd8a42 100644 (file)
                device_type = "memory";
                reg = <0x4 0x80000000 0x0 0x80000000>;
        };
+
+       reg_1p8v: regulator-1p8v {
+               compatible = "regulator-fixed";
+               regulator-name = "fixed-1.8V";
+               regulator-min-microvolt = <1800000>;
+               regulator-max-microvolt = <1800000>;
+               regulator-boot-on;
+               regulator-always-on;
+       };
+
+       reg_3p3v: regulator-3p3v {
+               compatible = "regulator-fixed";
+               regulator-name = "fixed-3.3V";
+               regulator-min-microvolt = <3300000>;
+               regulator-max-microvolt = <3300000>;
+               regulator-boot-on;
+               regulator-always-on;
+       };
 };
 
 &extal_clk {
        };
 };
 
+/*
+ * This board also has a microSD slot which we will not support upstream
+ * because we cannot directly switch voltages in software.
+ */
+&mmc0 {
+       pinctrl-0 = <&mmc_pins>;
+       pinctrl-1 = <&mmc_pins>;
+       pinctrl-names = "default", "state_uhs";
+
+       vmmc-supply = <&reg_3p3v>;
+       vqmmc-supply = <&reg_1p8v>;
+       mmc-hs200-1_8v;
+       mmc-hs400-1_8v;
+       bus-width = <8>;
+       no-sd;
+       no-sdio;
+       non-removable;
+       full-pwr-cycle-in-suspend;
+       status = "okay";
+};
+
 &pfc {
        pinctrl-0 = <&scif_clk_pins>;
        pinctrl-names = "default";
                function = "i2c4";
        };
 
+       mmc_pins: mmc {
+               groups = "mmc_data8", "mmc_ctrl", "mmc_ds";
+               function = "mmc";
+               power-source = <1800>;
+       };
+
        scif0_pins: scif0 {
                groups = "scif0_data", "scif0_ctrl";
                function = "scif0";