ramips: improve support for HiWiFi HC5861 SDHC
authorShiji Yang <yangshiji66@qq.com>
Tue, 9 Jul 2024 17:26:52 +0000 (01:26 +0800)
committerNick Hainke <vincent@systemli.org>
Thu, 11 Jul 2024 16:57:42 +0000 (18:57 +0200)
1. Override max clock frequency to a stable value 24 MHz.
2. Use voltage regulator to control the power supply.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
target/linux/ramips/dts/mt7620a_hiwifi_hc5861.dts

index 83e5698d63d4498a395cd4e00faa3f6c56ccf900..29aff9958a8797ea5e573ea044289353b3575405 100644 (file)
                        gpio-export,output = <0>;
                        gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
                };
-
-               sdpower {
-                       gpio-export,name = "sdpower";
-                       gpio-export,output = <0>;
-                       gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
-               };
        };
 };
 
        mediatek,ephy-base = /bits/ 8 <12>;
 };
 
+&mmc_reg_3v3 {
+       /delete-property/ enable-active-high;
+
+       gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
+};
+
 &pcie {
        status = "okay";
 };
        };
 };
 
+&sdhci {
+       max-frequency = <24000000>;
+};
+
 &wmac {
        pinctrl-names = "default", "pa_gpio";
        pinctrl-0 = <&pa_pins>;