[openwrt/openwrt] ramips: improve GPIO pin control for HC5x61

LEDE Commits lede-commits at lists.infradead.org
Fri Mar 19 00:25:41 GMT 2021


hauke pushed a commit to openwrt/openwrt.git, branch master:
https://git.openwrt.org/a94a20373ba0c817ddb03da0bf15af6c8d6a09ff

commit a94a20373ba0c817ddb03da0bf15af6c8d6a09ff
Author: Shiji Yang <yangshiji66 at qq.com>
AuthorDate: Mon Mar 1 14:35:12 2021 +0800

    ramips: improve GPIO pin control for HC5x61
    
    HC5661 does not have USB port, remove usb power control pin.
    HC5x61 do not have LAN LEDs, remove ethernet LED control pin.
    Only HC5861 has PA in 2.4G channel.
    
    Signed-off-by: Shiji Yang <yangshiji66 at qq.com>
---
 target/linux/ramips/dts/mt7620a_hiwifi_hc5761.dts  | 11 +++++++++++
 target/linux/ramips/dts/mt7620a_hiwifi_hc5861.dts  |  5 +++++
 target/linux/ramips/dts/mt7620a_hiwifi_hc5x61.dtsi | 22 ----------------------
 3 files changed, 16 insertions(+), 22 deletions(-)

diff --git a/target/linux/ramips/dts/mt7620a_hiwifi_hc5761.dts b/target/linux/ramips/dts/mt7620a_hiwifi_hc5761.dts
index 5b67779984..d1a7f69e17 100644
--- a/target/linux/ramips/dts/mt7620a_hiwifi_hc5761.dts
+++ b/target/linux/ramips/dts/mt7620a_hiwifi_hc5761.dts
@@ -36,6 +36,17 @@
 			linux,default-trigger = "phy0tpt";
 		};
 	};
+
+	gpio_export {
+		compatible = "gpio-export";
+		#size-cells = <0>;
+
+		usbpower {
+			gpio-export,name = "usbpower";
+			gpio-export,output = <1>;
+			gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
+		};
+	};
 };
 
 &ehci {
diff --git a/target/linux/ramips/dts/mt7620a_hiwifi_hc5861.dts b/target/linux/ramips/dts/mt7620a_hiwifi_hc5861.dts
index 08163e56ba..d77df2158c 100644
--- a/target/linux/ramips/dts/mt7620a_hiwifi_hc5861.dts
+++ b/target/linux/ramips/dts/mt7620a_hiwifi_hc5861.dts
@@ -104,3 +104,8 @@
 		ieee80211-freq-limit = <5000000 6000000>;
 	};
 };
+
+&wmac {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pa_pins>;
+};
diff --git a/target/linux/ramips/dts/mt7620a_hiwifi_hc5x61.dtsi b/target/linux/ramips/dts/mt7620a_hiwifi_hc5x61.dtsi
index 8d5d8e95ee..369e407319 100644
--- a/target/linux/ramips/dts/mt7620a_hiwifi_hc5x61.dtsi
+++ b/target/linux/ramips/dts/mt7620a_hiwifi_hc5x61.dtsi
@@ -19,23 +19,6 @@
 			linux,code = <KEY_RESTART>;
 		};
 	};
-
-	gpio_export {
-		compatible = "gpio-export";
-		#size-cells = <0>;
-
-		usbpower {
-			gpio-export,name = "usbpower";
-			gpio-export,output = <1>;
-			gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
-		};
-	};
-};
-
-&sysc {
-	ralink,gpiomux = "i2c", "jtag";
-	ralink,uartmux = "gpio";
-	ralink,wdtmux = <1>;
 };
 
 &gpio3 {
@@ -101,9 +84,6 @@
 };
 
 &ethernet {
-	pinctrl-names = "default";
-	pinctrl-0 = <&ephy_pins>;
-
 	mtd-mac-address = <&factory 0x4>;
 
 	mediatek,portmap = "wllll";
@@ -115,8 +95,6 @@
 
 &wmac {
 	ralink,mtd-eeprom = <&factory 0x0>;
-	pinctrl-names = "default";
-	pinctrl-0 = <&pa_pins>;
 };
 
 &state_default {



More information about the lede-commits mailing list