summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorShiji Yang2025-05-19 23:50:56 +0000
committerHauke Mehrtens2025-11-09 13:26:34 +0000
commit550fa37533ad7b089bdeac40da2ea9abefa53383 (patch)
tree0c499f36e0a78e6ed39d21dab19769446b625ca7
parent9837ae40023b22bcbd03ae823a5b3ce5c41005fa (diff)
downloadopenwrt-550fa37533ad7b089bdeac40da2ea9abefa53383.tar.gz
ramips: dts: adjust the power regulators of MMC controller
- Fix MMC bus IO voltage. The GPIO voltage of mt762x series SoCs is fixed 3.3V. There are no visible registers that can control the voltage level. Also add "no-1-8-v" property to indicate that MMC controller doesn't support 1.8V IO. - Drop useless property "enable-active-high". These dummy fixed voltage regulators are not controlled by the GPIO. We don't need to set the GPIO polarity. Signed-off-by: Shiji Yang <yangshiji66@outlook.com> Link: https://github.com/openwrt/openwrt/pull/18886 (cherry picked from commit afdf88b9a165710e6132fab6ec245a61f4394d6e) [rebased upon 24.10 branch] Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org> Link: https://github.com/openwrt/openwrt/pull/20258 Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
-rw-r--r--target/linux/ramips/dts/mt7620a.dtsi30
-rw-r--r--target/linux/ramips/dts/mt7620a_hiwifi_hc5861.dts10
-rw-r--r--target/linux/ramips/dts/mt7621.dtsi30
-rw-r--r--target/linux/ramips/dts/mt7628an.dtsi30
4 files changed, 37 insertions, 63 deletions
diff --git a/target/linux/ramips/dts/mt7620a.dtsi b/target/linux/ramips/dts/mt7620a.dtsi
index 0555674802..7542d43bae 100644
--- a/target/linux/ramips/dts/mt7620a.dtsi
+++ b/target/linux/ramips/dts/mt7620a.dtsi
@@ -32,26 +32,20 @@
compatible = "mti,cpu-interrupt-controller";
};
- mmc_reg_1v8: regulator-1v8 {
+ reg_vmmc: regulator-vmmc {
compatible = "regulator-fixed";
-
- enable-active-high;
-
regulator-always-on;
- regulator-max-microvolt = <1800000>;
- regulator-min-microvolt = <1800000>;
- regulator-name = "mmc_io";
+ regulator-max-microvolt = <3300000>;
+ regulator-min-microvolt = <3300000>;
+ regulator-name = "mmc_power";
};
- mmc_reg_3v3: regulator-3v3 {
+ reg_vqmmc: regulator-vqmmc {
compatible = "regulator-fixed";
-
- enable-active-high;
-
regulator-always-on;
regulator-max-microvolt = <3300000>;
regulator-min-microvolt = <3300000>;
- regulator-name = "mmc_power";
+ regulator-name = "mmc_io";
};
palmbus: palmbus@10000000 {
@@ -528,20 +522,18 @@
reg = <0x10130000 0x4000>;
bus-width = <4>;
-
+ max-frequency = <24000000>;
cap-mmc-highspeed;
cap-sd-highspeed;
+ disable-wp;
+ no-1-8-v;
clocks = <&sysc 15>, <&sysc 15>;
clock-names = "source", "hclk";
- disable-wp;
-
interrupt-parent = <&intc>;
interrupts = <14>;
- max-frequency = <24000000>;
-
pinctrl-names = "default", "state_uhs";
pinctrl-0 = <&sdhci_pins>;
pinctrl-1 = <&sdhci_pins>;
@@ -549,8 +541,8 @@
resets = <&sysc 30>;
reset-names = "hrst";
- vmmc-supply = <&mmc_reg_3v3>;
- vqmmc-supply = <&mmc_reg_1v8>;
+ vmmc-supply = <&reg_vmmc>;
+ vqmmc-supply = <&reg_vqmmc>;
status = "disabled";
};
diff --git a/target/linux/ramips/dts/mt7620a_hiwifi_hc5861.dts b/target/linux/ramips/dts/mt7620a_hiwifi_hc5861.dts
index 2cb7017972..a279ae3eb5 100644
--- a/target/linux/ramips/dts/mt7620a_hiwifi_hc5861.dts
+++ b/target/linux/ramips/dts/mt7620a_hiwifi_hc5861.dts
@@ -88,12 +88,6 @@
mediatek,ephy-base = /bits/ 8 <12>;
};
-&mmc_reg_3v3 {
- /delete-property/ enable-active-high;
-
- gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
-};
-
&pcie {
status = "okay";
};
@@ -108,6 +102,10 @@
};
};
+&reg_vmmc {
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
+};
+
&wmac {
pinctrl-names = "default", "pa_gpio";
pinctrl-0 = <&pa_pins>;
diff --git a/target/linux/ramips/dts/mt7621.dtsi b/target/linux/ramips/dts/mt7621.dtsi
index da03d47ff6..5730e83464 100644
--- a/target/linux/ramips/dts/mt7621.dtsi
+++ b/target/linux/ramips/dts/mt7621.dtsi
@@ -42,26 +42,20 @@
bootargs = "console=ttyS0,57600";
};
- mmc_reg_1v8: regulator-1v8 {
+ reg_vmmc: regulator-vmmc {
compatible = "regulator-fixed";
-
- enable-active-high;
-
regulator-always-on;
- regulator-max-microvolt = <1800000>;
- regulator-min-microvolt = <1800000>;
- regulator-name = "mmc_io";
+ regulator-max-microvolt = <3300000>;
+ regulator-min-microvolt = <3300000>;
+ regulator-name = "mmc_power";
};
- mmc_reg_3v3: regulator-3v3 {
+ reg_vqmmc: regulator-vqmmc {
compatible = "regulator-fixed";
-
- enable-active-high;
-
regulator-always-on;
regulator-max-microvolt = <3300000>;
regulator-min-microvolt = <3300000>;
- regulator-name = "mmc_power";
+ regulator-name = "mmc_io";
};
palmbus: palmbus@1e000000 {
@@ -353,20 +347,18 @@
reg = <0x1e130000 0x4000>;
bus-width = <4>;
-
+ max-frequency = <48000000>;
cap-mmc-highspeed;
cap-sd-highspeed;
+ disable-wp;
+ no-1-8-v;
clocks = <&sysc MT7621_CLK_SHXC>, <&sysc MT7621_CLK_SHXC>;
clock-names = "source", "hclk";
- disable-wp;
-
interrupt-parent = <&gic>;
interrupts = <GIC_SHARED 20 IRQ_TYPE_LEVEL_HIGH>;
- max-frequency = <48000000>;
-
pinctrl-names = "default", "state_uhs";
pinctrl-0 = <&sdhci_pins>;
pinctrl-1 = <&sdhci_pins>;
@@ -374,8 +366,8 @@
resets = <&sysc MT7621_RST_SDXC>;
reset-names = "hrst";
- vmmc-supply = <&mmc_reg_3v3>;
- vqmmc-supply = <&mmc_reg_1v8>;
+ vmmc-supply = <&reg_vmmc>;
+ vqmmc-supply = <&reg_vqmmc>;
status = "disabled";
};
diff --git a/target/linux/ramips/dts/mt7628an.dtsi b/target/linux/ramips/dts/mt7628an.dtsi
index 79763332b8..e705d46b1e 100644
--- a/target/linux/ramips/dts/mt7628an.dtsi
+++ b/target/linux/ramips/dts/mt7628an.dtsi
@@ -30,26 +30,20 @@
compatible = "mti,cpu-interrupt-controller";
};
- mmc_reg_1v8: regulator-1v8 {
+ reg_vmmc: regulator-vmmc {
compatible = "regulator-fixed";
-
- enable-active-high;
-
regulator-always-on;
- regulator-max-microvolt = <1800000>;
- regulator-min-microvolt = <1800000>;
- regulator-name = "mmc_io";
+ regulator-max-microvolt = <3300000>;
+ regulator-min-microvolt = <3300000>;
+ regulator-name = "mmc_power";
};
- mmc_reg_3v3: regulator-3v3 {
+ reg_vqmmc: regulator-vqmmc {
compatible = "regulator-fixed";
-
- enable-active-high;
-
regulator-always-on;
regulator-max-microvolt = <3300000>;
regulator-min-microvolt = <3300000>;
- regulator-name = "mmc_power";
+ regulator-name = "mmc_io";
};
palmbus: palmbus@10000000 {
@@ -382,20 +376,18 @@
reg = <0x10130000 0x4000>;
bus-width = <4>;
-
+ max-frequency = <24000000>;
cap-mmc-highspeed;
cap-sd-highspeed;
+ disable-wp;
+ no-1-8-v;
clocks = <&sysc 16>, <&sysc 16>;
clock-names = "source", "hclk";
- disable-wp;
-
interrupt-parent = <&intc>;
interrupts = <14>;
- max-frequency = <24000000>;
-
pinctrl-names = "default", "state_uhs";
pinctrl-0 = <&sdxc_pins>;
pinctrl-1 = <&sdxc_pins>;
@@ -403,8 +395,8 @@
resets = <&sysc 30>;
reset-names = "hrst";
- vmmc-supply = <&mmc_reg_3v3>;
- vqmmc-supply = <&mmc_reg_1v8>;
+ vmmc-supply = <&reg_vmmc>;
+ vqmmc-supply = <&reg_vqmmc>;
status = "disabled";
};