Browse Source

ramips: simplify palmbus/{i2c,spi} in device DTS files

As the node is already defined and labeled in SoC DTSI file, we can refer to it
outside of root node and reduce redundancy.

While at it, remove unused pcf8563 label.

Signed-off-by: Sungbo Eo <[email protected]>
Sungbo Eo 5 years ago
parent
commit
fa9e7ca466

+ 4 - 6
target/linux/ramips/dts/mt7621_asus_rt-acx5p.dtsi

@@ -17,12 +17,6 @@
 		bootargs = "console=ttyS0,57600";
 	};
 
-	palmbus: palmbus@1E000000 {
-		i2c@900 {
-			status = "okay";
-		};
-	};
-
 	keys {
 		compatible = "gpio-keys";
 
@@ -60,6 +54,10 @@
 	};
 };
 
+&i2c {
+	status = "okay";
+};
+
 &sdhci {
 	status = "okay";
 };

+ 10 - 12
target/linux/ramips/dts/mt7621_d-team_pbr-m1.dts

@@ -20,18 +20,6 @@
 		bootargs = "console=ttyS0,115200";
 	};
 
-	palmbus: palmbus@1E000000 {
-		i2c: i2c@900 {
-			status = "okay";
-
-			pcf8563: rtc@51 {
-				status = "okay";
-				compatible = "nxp,pcf8563";
-				reg = <0x51>;
-			};
-		};
-	};
-
 	leds {
 		compatible = "gpio-leds";
 
@@ -101,6 +89,16 @@
 	};
 };
 
+&i2c {
+	status = "okay";
+
+	rtc@51 {
+		status = "okay";
+		compatible = "nxp,pcf8563";
+		reg = <0x51>;
+	};
+};
+
 &sdhci {
 	status = "okay";
 };

+ 10 - 12
target/linux/ramips/dts/mt7621_mqmaker_witi.dts

@@ -13,18 +13,6 @@
 		bootargs = "console=ttyS0,57600";
 	};
 
-	palmbus: palmbus@1E000000 {
-		i2c@900 {
-			status = "okay";
-
-			pcf8563: rtc@51 {
-				status = "okay";
-				compatible = "nxp,pcf8563";
-				reg = <0x51>;
-			};
-		};
-	};
-
 	keys {
 		compatible = "gpio-keys";
 
@@ -36,6 +24,16 @@
 	};
 };
 
+&i2c {
+	status = "okay";
+
+	rtc@51 {
+		status = "okay";
+		compatible = "nxp,pcf8563";
+		reg = <0x51>;
+	};
+};
+
 &sdhci {
 	status = "okay";
 };

+ 4 - 6
target/linux/ramips/dts/mt7621_zbtlink_zbt-we3526.dts

@@ -13,12 +13,6 @@
 		bootargs = "console=ttyS0,115200";
 	};
 
-	palmbus: palmbus@1E000000 {
-		i2c@900 {
-			status = "okay";
-		};
-	};
-
 	keys {
 		compatible = "gpio-keys";
 
@@ -30,6 +24,10 @@
 	};
 };
 
+&i2c {
+	status = "okay";
+};
+
 &sdhci {
 	status = "okay";
 };

+ 4 - 6
target/linux/ramips/dts/mt7621_zbtlink_zbt-wg2626.dts

@@ -20,12 +20,6 @@
 		bootargs = "console=ttyS0,115200";
 	};
 
-	palmbus: palmbus@1E000000 {
-		i2c@900 {
-			status = "okay";
-		};
-	};
-
 	keys {
 		compatible = "gpio-keys";
 
@@ -46,6 +40,10 @@
 	};
 };
 
+&i2c {
+	status = "okay";
+};
+
 &sdhci {
 	status = "okay";
 };

+ 4 - 6
target/linux/ramips/dts/mt7621_zbtlink_zbt-wg3526.dtsi

@@ -18,12 +18,6 @@
 		bootargs = "console=ttyS0,115200";
 	};
 
-	palmbus: palmbus@1E000000 {
-		i2c@900 {
-			status = "okay";
-		};
-	};
-
 	keys {
 		compatible = "gpio-keys";
 
@@ -44,6 +38,10 @@
 	};
 };
 
+&i2c {
+	status = "okay";
+};
+
 &sdhci {
 	status = "okay";
 };

+ 40 - 41
target/linux/ramips/dts/rt3352_zyxel_nbg-419n-v2.dts

@@ -16,47 +16,6 @@
 		led-upgrade = &led_power;
 	};
 
-	palmbus@10000000 {
-		spi@b00 {
-			status = "okay";
-			m25p80@0 {
-				compatible = "jedec,spi-nor";
-				reg = <0 0>;
-				spi-max-frequency = <10000000>;
-
-				partitions {
-					compatible = "fixed-partitions";
-					#address-cells = <1>;
-					#size-cells = <1>;
-
-					partition@0 {
-						label = "u-boot";
-						reg = <0x0 0x30000>;
-						read-only;
-					};
-
-					partition@30000 {
-						label = "u-boot-env";
-						reg = <0x30000 0x10000>;
-						read-only;
-					};
-
-					factory: partition@40000 {
-						label = "factory";
-						reg = <0x40000 0x10000>;
-						read-only;
-					};
-
-					partition@50000 {
-						compatible = "denx,uimage";
-						label = "firmware";
-						reg = <0x50000 0x7b0000>;
-					};
-				};
-			};
-		};
-	};
-
 	leds {
 		compatible = "gpio-leds";
 
@@ -100,6 +59,46 @@
 	};
 };
 
+&spi0 {
+	status = "okay";
+
+	m25p80@0 {
+		compatible = "jedec,spi-nor";
+		reg = <0 0>;
+		spi-max-frequency = <10000000>;
+
+		partitions {
+			compatible = "fixed-partitions";
+			#address-cells = <1>;
+			#size-cells = <1>;
+
+			partition@0 {
+				label = "u-boot";
+				reg = <0x0 0x30000>;
+				read-only;
+			};
+
+			partition@30000 {
+				label = "u-boot-env";
+				reg = <0x30000 0x10000>;
+				read-only;
+			};
+
+			factory: partition@40000 {
+				label = "factory";
+				reg = <0x40000 0x10000>;
+				read-only;
+			};
+
+			partition@50000 {
+				compatible = "denx,uimage";
+				label = "firmware";
+				reg = <0x50000 0x7b0000>;
+			};
+		};
+	};
+};
+
 &state_default {
 	gpio {
 		groups = "i2c", "jtag", "rgmii", "mdio", "uartf";