[source] ramips: use pinmux nodes from dtsi

LEDE Commits lede-commits at lists.infradead.org
Tue Nov 21 23:31:54 PST 2017


mkresin pushed a commit to source.git, branch master:
https://git.lede-project.org/aa82141d9be0bbac5bf7c8b82fe1b1581e679587

commit aa82141d9be0bbac5bf7c8b82fe1b1581e679587
Author: Mathias Kresin <dev at kresin.me>
AuthorDate: Sat Nov 18 22:05:16 2017 +0100

    ramips: use pinmux nodes from dtsi
    
    Use the pinmux nodes from the included dtsi file instead of adding
    duplicate nodes.
    
    Signed-off-by: Mathias Kresin <dev at kresin.me>
---
 target/linux/ramips/dts/ArcherC20.dts    |  7 ++-----
 target/linux/ramips/dts/ArcherC50.dts    |  7 ++-----
 target/linux/ramips/dts/DCH-M225.dts     | 17 +++-------------
 target/linux/ramips/dts/DIR-615-H1.dts   | 12 ++---------
 target/linux/ramips/dts/DIR-620-D1.dts   | 12 ++---------
 target/linux/ramips/dts/DUZUN-DM06.dts   | 16 +--------------
 target/linux/ramips/dts/HC5X61.dtsi      |  7 ++-----
 target/linux/ramips/dts/MIWIFI-MINI.dts  |  7 ++-----
 target/linux/ramips/dts/PSG1218A.dts     | 10 ++++-----
 target/linux/ramips/dts/WHR-300HP2.dts   |  7 ++-----
 target/linux/ramips/dts/WIZFI630A.dts    | 35 +-------------------------------
 target/linux/ramips/dts/WL-351.dts       |  6 ++----
 target/linux/ramips/dts/Y1.dtsi          |  7 ++-----
 target/linux/ramips/dts/ZBT-APE522II.dts |  7 ++-----
 target/linux/ramips/dts/ZBT-WR8305RT.dts |  7 ++-----
 15 files changed, 32 insertions(+), 132 deletions(-)

diff --git a/target/linux/ramips/dts/ArcherC20.dts b/target/linux/ramips/dts/ArcherC20.dts
index ba842d9..f0281c3 100644
--- a/target/linux/ramips/dts/ArcherC20.dts
+++ b/target/linux/ramips/dts/ArcherC20.dts
@@ -142,11 +142,6 @@
 			ralink,group = "i2c", "uartf", "wled", "ephy", "spi refclk", "wdt";
 			ralink,function = "gpio";
 		};
-
-		pa {
-			ralink,group = "pa";
-			ralink,function = "pa";
-		};
 	};
 };
 
@@ -172,6 +167,8 @@
 	ralink,mtd-eeprom = <&radio 0>;
 	mtd-mac-address = <&rom 0xf100>;
 	mtd-mac-address-increment = <(-2)>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pa_pins>;
 };
 
 &pcie {
diff --git a/target/linux/ramips/dts/ArcherC50.dts b/target/linux/ramips/dts/ArcherC50.dts
index e872923..88bd327 100644
--- a/target/linux/ramips/dts/ArcherC50.dts
+++ b/target/linux/ramips/dts/ArcherC50.dts
@@ -142,11 +142,6 @@
 			ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "ephy", "spi refclk", "mdio", "wdt", "nd_sd";
 			ralink,function = "gpio";
 		};
-
-		pa {
-			ralink,group = "pa";
-			ralink,function = "pa";
-		};
 	};
 };
 
@@ -172,6 +167,8 @@
 	ralink,mtd-eeprom = <&radio 0>;
 	mtd-mac-address = <&rom 0xf100>;
 	mtd-mac-address-increment = <(-2)>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pa_pins>;
 };
 
 &pcie {
diff --git a/target/linux/ramips/dts/DCH-M225.dts b/target/linux/ramips/dts/DCH-M225.dts
index 5856036..1aea908 100644
--- a/target/linux/ramips/dts/DCH-M225.dts
+++ b/target/linux/ramips/dts/DCH-M225.dts
@@ -90,7 +90,7 @@
 	#sound-dai-cells = <0>;
 	status = "okay";
 	pinctrl-names = "default";
-	pinctrl-0 = <&wm8960_mclk_pins>;
+	pinctrl-0 = <&mdio_refclk_pins>;
 };
 
 &spi0 {
@@ -162,18 +162,6 @@
 			ralink,group = "uartf";
 			ralink,function = "gpio i2s";
 		};
-
-		pa {
-			ralink,group = "pa";
-			ralink,function = "pa";
-		};
-
-		wm8960_mclk_pins: wm8960_mclk {
-			wm8960_mclk {
-				ralink,group = "mdio";
-				ralink,function = "refclk";
-			};
-		};
 	};
 };
 
@@ -187,5 +175,6 @@
 
 &wmac {
 	ralink,mtd-eeprom = <&factory 0>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pa_pins>;
 };
-
diff --git a/target/linux/ramips/dts/DIR-615-H1.dts b/target/linux/ramips/dts/DIR-615-H1.dts
index 9e8b86e..7d410f1 100644
--- a/target/linux/ramips/dts/DIR-615-H1.dts
+++ b/target/linux/ramips/dts/DIR-615-H1.dts
@@ -99,21 +99,13 @@
 			ralink,group = "i2c", "jtag", "uartf";
 			ralink,function = "gpio";
 		};
-
-		rgmii {
-			ralink,group = "rgmii";
-			ralink,function = "rgmii";
-		};
-
-		mdio {
-			ralink,group = "mdio";
-			ralink,function = "mdio";
-		};
 	};
 };
 
 &ethernet {
 	mtd-mac-address = <&factory 0x28>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&rgmii_pins &mdio_pins>;
 };
 
 &esw {
diff --git a/target/linux/ramips/dts/DIR-620-D1.dts b/target/linux/ramips/dts/DIR-620-D1.dts
index baf17e7..2def8aa 100644
--- a/target/linux/ramips/dts/DIR-620-D1.dts
+++ b/target/linux/ramips/dts/DIR-620-D1.dts
@@ -78,21 +78,13 @@
 			ralink,group = "i2c", "jtag", "uartf";
 			ralink,function = "gpio";
 		};
-
-		rgmii {
-			ralink,group = "rgmii";
-			ralink,function = "rgmii";
-		};
-
-		mdio {
-			ralink,group = "mdio";
-			ralink,function = "mdio";
-		};
 	};
 };
 
 &ethernet {
 	mtd-mac-address = <&factory 0x4>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&rgmii_pins &mdio_pins>;
 };
 
 &esw {
diff --git a/target/linux/ramips/dts/DUZUN-DM06.dts b/target/linux/ramips/dts/DUZUN-DM06.dts
index c529b34..b8261a5 100644
--- a/target/linux/ramips/dts/DUZUN-DM06.dts
+++ b/target/linux/ramips/dts/DUZUN-DM06.dts
@@ -63,20 +63,6 @@
 			ralink,function = "gpio";
 		};
 	};
-
-	i2s_pins: i2s {
-		i2s {
-			ralink,group = "i2s";
-			ralink,function = "i2s";
-		};
-	};
-
-	wm8960_mclk_pins: wm8960_mclk {
-		wm8960_mclk {
-			ralink,group = "refclk";
-			ralink,function = "refclk";
-		};
-	};
 };
 
 &gpio1 {
@@ -108,7 +94,7 @@
 	#sound-dai-cells = <0>;
 	status = "okay";
 	pinctrl-names = "default";
-	pinctrl-0 = <&i2s_pins>, <&wm8960_mclk_pins>;
+	pinctrl-0 = <&i2s_pins>, <&refclk_pins>;
 };
 
 &sdhci {
diff --git a/target/linux/ramips/dts/HC5X61.dtsi b/target/linux/ramips/dts/HC5X61.dtsi
index 1a5927d..f0b59ec 100644
--- a/target/linux/ramips/dts/HC5X61.dtsi
+++ b/target/linux/ramips/dts/HC5X61.dtsi
@@ -122,6 +122,8 @@
 
 &wmac {
 	ralink,mtd-eeprom = <&factory 0>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pa_pins>;
 };
 
 &pcie {
@@ -134,10 +136,5 @@
 			ralink,group = "uartf", "wled", "nd_sd";
 			ralink,function = "gpio";
 		};
-
-		pa {
-			ralink,group = "pa";
-			ralink,function = "pa";
-		};
 	};
 };
diff --git a/target/linux/ramips/dts/MIWIFI-MINI.dts b/target/linux/ramips/dts/MIWIFI-MINI.dts
index 9da5673..3da39c5 100644
--- a/target/linux/ramips/dts/MIWIFI-MINI.dts
+++ b/target/linux/ramips/dts/MIWIFI-MINI.dts
@@ -125,6 +125,8 @@
 
 &wmac {
 	ralink,mtd-eeprom = <&factory 0>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pa_pins>;
 };
 
 &pcie {
@@ -146,10 +148,5 @@
 			ralink,group = "i2c", "rgmii1";
 			ralink,function = "gpio";
 		};
-
-		pa {
-			ralink,group = "pa";
-			ralink,function = "pa";
-		};
 	};
 };
diff --git a/target/linux/ramips/dts/PSG1218A.dts b/target/linux/ramips/dts/PSG1218A.dts
index c63af58..d76abc3 100644
--- a/target/linux/ramips/dts/PSG1218A.dts
+++ b/target/linux/ramips/dts/PSG1218A.dts
@@ -31,11 +31,6 @@
 			ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "nd_sd";
 			ralink,function = "gpio";
 		};
-
-		pa {
-			ralink,group = "pa";
-			ralink,function = "pa";
-		};
 	};
 };
 
@@ -45,3 +40,8 @@
 	mtd-mac-address = <&factory 0x28>;
 	mediatek,portmap = "llllw";
 };
+
+&wmac {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pa_pins>;
+};
diff --git a/target/linux/ramips/dts/WHR-300HP2.dts b/target/linux/ramips/dts/WHR-300HP2.dts
index f74a0b8..d405686 100644
--- a/target/linux/ramips/dts/WHR-300HP2.dts
+++ b/target/linux/ramips/dts/WHR-300HP2.dts
@@ -127,11 +127,6 @@
 			ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "nd_sd";
 			ralink,function = "gpio";
 		};
-
-		pa {
-			ralink,group = "pa";
-			ralink,function = "pa";
-		};
 	};
 };
 
@@ -147,4 +142,6 @@
 
 &wmac {
 	ralink,mtd-eeprom = <&factory 0>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pa_pins>;
 };
diff --git a/target/linux/ramips/dts/WIZFI630A.dts b/target/linux/ramips/dts/WIZFI630A.dts
index 882086b..86ed197 100644
--- a/target/linux/ramips/dts/WIZFI630A.dts
+++ b/target/linux/ramips/dts/WIZFI630A.dts
@@ -118,28 +118,9 @@
 };
 
 &uart {
-	compatible = "ralink,mt7620a-uart", "ralink,rt2880-uart", "ns16550a";
-	reg = <0x500 0x100>;
-	resets = <&rstctrl 12>;
-	reset-names = "uart";
-	interrupt-parent = <&intc>;
-	interrupts = <5>;
-	reg-shift = <2>;
-	pinctrl-names = "default";
-	pinctrl-0 = <&uartf_pins>;
 	status = "okay";
-};
-
-&uartlite {
-	compatible = "ralink,mt7620a-uart", "ralink,rt2880-uart", "ns16550a";
-	reg = <0xc00 0x100>;
-	resets = <&rstctrl 19>;
-	reset-names = "uartl";
-	interrupt-parent = <&intc>;
-	interrupts = <12>;
-	reg-shift = <2>;
 	pinctrl-names = "default";
-	pinctrl-0 = <&uartlite_pins>;
+	pinctrl-0 = <&uartf_pins>;
 };
 
 &pinctrl {
@@ -149,20 +130,6 @@
 			ralink,function = "gpio";
 		};
 	};
-
-	uartf_gpio_pins: uartf_gpio {
-		uartf_gpio {
-			ralink,group = "uartf";
-			ralink,function = "uartf";
-		};
-	};
-
-	uartlite_pins: uartlite {
-		uart {
-			ralink,group = "uartlite";
-			ralink,function = "uartlite";
-		};
-	};
 };
 
 &ethernet {
diff --git a/target/linux/ramips/dts/WL-351.dts b/target/linux/ramips/dts/WL-351.dts
index e620f10..0dd596c 100644
--- a/target/linux/ramips/dts/WL-351.dts
+++ b/target/linux/ramips/dts/WL-351.dts
@@ -92,15 +92,13 @@
 			ralink,group = "spi", "i2c", "jtag", "mdio", "uartf";
 			ralink,function = "gpio";
 		};
-		rgmii {
-			ralink,group = "rgmii";
-			ralink,function = "rgmii";
-		};
 	};
 };
 
 &ethernet {
 	mtd-mac-address = <&factory 0x4>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&rgmii_pins>;
 };
 
 &esw {
diff --git a/target/linux/ramips/dts/Y1.dtsi b/target/linux/ramips/dts/Y1.dtsi
index 022b679..cc126f0 100644
--- a/target/linux/ramips/dts/Y1.dtsi
+++ b/target/linux/ramips/dts/Y1.dtsi
@@ -94,6 +94,8 @@
 	
 &wmac {
 	ralink,mtd-eeprom = <&factory 0>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pa_pins>;
 };
 
 &pinctrl {
@@ -102,10 +104,5 @@
 			ralink,group = "uartf", "wled", "nd_sd";
 			ralink,function = "gpio";
 		};
-
-		pa {
-			ralink,group = "pa";
-			ralink,function = "pa";
-		};
 	};
 };
diff --git a/target/linux/ramips/dts/ZBT-APE522II.dts b/target/linux/ramips/dts/ZBT-APE522II.dts
index 45fef66..05d053f 100644
--- a/target/linux/ramips/dts/ZBT-APE522II.dts
+++ b/target/linux/ramips/dts/ZBT-APE522II.dts
@@ -115,6 +115,8 @@
 
 &wmac {
 	ralink,mtd-eeprom = <&factory 0>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pa_pins>;
 };
 
 &pcie {
@@ -136,10 +138,5 @@
 			ralink,group = "wled", "i2c", "uartf", "wdt";
 			ralink,function = "gpio";
 		};
-
-		pa {
-			ralink,group = "pa";
-			ralink,function = "pa";
-		};
 	};
 };
diff --git a/target/linux/ramips/dts/ZBT-WR8305RT.dts b/target/linux/ramips/dts/ZBT-WR8305RT.dts
index 11911b9..52cac80 100644
--- a/target/linux/ramips/dts/ZBT-WR8305RT.dts
+++ b/target/linux/ramips/dts/ZBT-WR8305RT.dts
@@ -94,6 +94,8 @@
 };
 
 &ethernet {
+	pinctrl-names = "default";
+	pinctrl-0 = <&ephy_pins>;
 	mtd-mac-address = <&factory 0x4>;
 	mediatek,portmap = "llllw";
 };
@@ -104,11 +106,6 @@
 
 &pinctrl {
 	state_default: pinctrl0 {
-		ephy {
-			ralink,group = "ephy";
-			ralink,function = "ephy";
-		};
-
 		default {
 			ralink,group = "i2c", "uartf", "spi refclk", "wled";
 			ralink,function = "gpio";



More information about the lede-commits mailing list