diff mbox series

[v2,07/16] realtek: rtl838x: replace pinctrl nodes

Message ID 95ea55333179f511751f3c686ed8ae514f11a867.1664830160.git.sander@svanheule.net
State Superseded
Delegated to: Sander Vanheule
Headers show
Series realtek: pinctrl and switch LED drivers | expand

Commit Message

Sander Vanheule Oct. 3, 2022, 8:52 p.m. UTC
Replace the current "pinctrl-single" nodes by the new
"realtek,maple-pinctrl" node. This allows users to specify pin groups
and features without having to dig into SoC documentation.

Signed-off-by: Sander Vanheule <sander@svanheule.net>
---
 target/linux/realtek/dts-5.10/rtl838x.dtsi | 43 ++++++++--------------
 1 file changed, 16 insertions(+), 27 deletions(-)
diff mbox series

Patch

diff --git a/target/linux/realtek/dts-5.10/rtl838x.dtsi b/target/linux/realtek/dts-5.10/rtl838x.dtsi
index 256efb1c059b..631cd0e8f733 100644
--- a/target/linux/realtek/dts-5.10/rtl838x.dtsi
+++ b/target/linux/realtek/dts-5.10/rtl838x.dtsi
@@ -216,33 +216,22 @@ 
 		};
 	};
 
-	pinmux: pinmux@1b001000 {
-		compatible = "pinctrl-single";
-		reg = <0x1b001000 0x4>;
-
-		pinctrl-single,bit-per-mux;
-		pinctrl-single,register-width = <32>;
-		pinctrl-single,function-mask = <0x1>;
-		#pinctrl-cells = <2>;
-
-		enable_uart1: pinmux_enable_uart1 {
-			pinctrl-single,bits = <0x0 0x10 0x10>;
-		};
-	};
-
-	/* LED_GLB_CTRL */
-	pinmux_led: pinmux@1b00a000 {
-		compatible = "pinctrl-single";
-		reg = <0x1b00a000 0x4>;
-
-		pinctrl-single,bit-per-mux;
-		pinctrl-single,register-width = <32>;
-		pinctrl-single,function-mask = <0x1>;
-		#pinctrl-cells = <2>;
-
-		/* enable GPIO 0 */
-		pinmux_disable_sys_led: disable_sys_led {
-			pinctrl-single,bits = <0x0 0x0 0x8000>;
+	switchcore: switchcore-bus@1b000000 {
+		compatible = "realtek,maple-switchcore", "syscon";
+		reg = <0x1b000000 0x10000>;
+
+		pinctrl {
+			compatible = "realtek,maple-pinctrl";
+
+			pinmux_disable_sys_led: pinmux-sys-led-gpio {
+				groups = "sys-led";
+				function = "gpio";
+			};
+
+			enable_uart1: pinmux-uart1 {
+				groups = "uart1";
+				function = "uart1";
+			};
 		};
 	};