ARM: dts: rockchip: Add SDIO0 node for VMARC SOM
authorJagan Teki <jagan@amarulasolutions.com>
Fri, 23 Oct 2020 18:18:14 +0000 (23:48 +0530)
committerHeiko Stuebner <heiko@sntech.de>
Mon, 30 Nov 2020 13:30:56 +0000 (14:30 +0100)
Rockchip RK3288 and RK3399Pro based VMARC SOM has sdio0 for
connecting WiFi/BT devices as a pluggable card via M.2 E-Key.

Add associated sdio0 nodes, properties.

Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Link: https://lore.kernel.org/r/20201023181814.220974-2-jagan@amarulasolutions.com
[moved the unrelated rtc addition to a separate patch]
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
arch/arm/boot/dts/rk3288-vmarc-som.dtsi
arch/arm/boot/dts/rockchip-radxa-dalang-carrier.dtsi
arch/arm64/boot/dts/rockchip/rk3399pro-vmarc-som.dtsi

index da80bfd5f2d5c7abbf7fbcd76906bc3fcd262ba0..0ae2bd150e37287902b29fdb02155b0dcbf9d072 100644 (file)
        gpio1830-supply = <&vcc_18>;
        gpio30-supply = <&vcc_io>;
        sdcard-supply = <&vccio_sd>;
+       wifi-supply = <&vcc_wl>;
        status = "okay";
 };
 
                };
        };
 
+       sdio-pwrseq {
+               wifi_enable_h: wifi-enable-h {
+                       rockchip,pins = <4 RK_PD4 RK_FUNC_GPIO &pcfg_pull_none>;
+               };
+       };
+
        sdmmc {
                sdmmc_bus4: sdmmc-bus4 {
                        rockchip,pins =
        };
 };
 
+&sdio_pwrseq {
+       /*
+        * On the module itself this is one of these (depending
+        * on the actual card populated):
+        * - SDIO_RESET_L_WL_REG_ON
+        * - PDN (power down when low)
+        */
+       reset-gpios = <&gpio4 RK_PD4 GPIO_ACTIVE_LOW>;  /* WIFI_REG_ON */
+};
+
 &usbphy {
        status = "okay";
 };
index 26b53eac470688dcc8f7a1eed38a87ac881e156c..da1d548b7330cd8d4cf97f36b7c305f6c527ecff 100644 (file)
                #clock-cells = <0>;
        };
 
+       sdio_pwrseq: sdio-pwrseq {
+               compatible = "mmc-pwrseq-simple";
+               clocks = <&hym8563>;
+               clock-names = "ext_clock";
+               pinctrl-names = "default";
+               pinctrl-0 = <&wifi_enable_h>;
+       };
+
        vcc12v_dcin: vcc12v-dcin-regulator {
                compatible = "regulator-fixed";
                regulator-name = "vcc12v_dcin";
        status = "okay";
 };
 
+&sdio0 {
+       bus-width = <4>;
+       cap-sd-highspeed;
+       cap-sdio-irq;
+       keep-power-in-suspend;
+       mmc-pwrseq = <&sdio_pwrseq>;
+       non-removable;
+       pinctrl-names = "default";
+       pinctrl-0 = <&sdio0_bus4 &sdio0_cmd &sdio0_clk>;
+       sd-uhs-sdr104;
+       status = "okay";
+};
+
 &sdmmc {
        bus-width = <4>;
        cap-mmc-highspeed;
index 5d087be04af8a741057485979f296cb3691e158c..7257494d28318899b93a7b109eb5b15c2a05eeb0 100644 (file)
                };
        };
 
+       sdio-pwrseq {
+               wifi_enable_h: wifi-enable-h {
+                       rockchip,pins = <2 RK_PD3 RK_FUNC_GPIO &pcfg_pull_none>;
+               };
+       };
+
        vbus_host {
                usb1_en_oc: usb1-en-oc {
                        rockchip,pins = <4 RK_PD1 RK_FUNC_GPIO &pcfg_pull_up>;
        pmu1830-supply = <&vcc_1v8>;
 };
 
+&sdio_pwrseq {
+       /*
+        * On the module itself this is one of these (depending
+        * on the actual card populated):
+        * - SDIO_RESET_L_WL_REG_ON
+        * - PDN (power down when low)
+        */
+       reset-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_LOW>;
+};
+
 &sdhci {
        bus-width = <8>;
        mmc-hs400-1_8v;