devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] arm64: dts: st: add usart nodes for stm32mp25
@ 2024-05-20 14:00 Valentin Caron
  2024-05-20 14:00 ` [PATCH 1/3] arm64: dts: st: add usart nodes on stm32mp25 Valentin Caron
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Valentin Caron @ 2024-05-20 14:00 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Alexandre Torgue
  Cc: devicetree, linux-stm32, linux-arm-kernel, linux-kernel,
	Valentin Caron

STM32MP25 got the same serial hardware block as STM32MP1x but with two improvements:
 - TX and RX FIFO have been extended to 64 bytes.
 - one instance more than in STM32MP1x series (4x usart and 5x uart).
 
STM32MP257F-EV1 board has one usart used by console and one usart on IO port.

Valentin Caron (3):
  arm64: dts: st: add usart nodes on stm32mp25
  arm64: dts: st: add usart6 pinctrl used on stm32mp257f-ev1 board
  arm64: dts: st: add usart6 on stm32mp257f-ev1 board

 arch/arm64/boot/dts/st/stm32mp25-pinctrl.dtsi | 41 +++++++++++
 arch/arm64/boot/dts/st/stm32mp251.dtsi        | 72 +++++++++++++++++++
 arch/arm64/boot/dts/st/stm32mp257f-ev1.dts    | 10 +++
 3 files changed, 123 insertions(+)

-- 
2.25.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH 1/3] arm64: dts: st: add usart nodes on stm32mp25
  2024-05-20 14:00 [PATCH 0/3] arm64: dts: st: add usart nodes for stm32mp25 Valentin Caron
@ 2024-05-20 14:00 ` Valentin Caron
  2024-05-20 14:00 ` [PATCH 2/3] arm64: dts: st: add usart6 pinctrl used on stm32mp257f-ev1 board Valentin Caron
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Valentin Caron @ 2024-05-20 14:00 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Alexandre Torgue
  Cc: devicetree, linux-stm32, linux-arm-kernel, linux-kernel,
	Valentin Caron

Update device-tree stm32mp251.dtsi to add some USART features.

Add u(s)art 1, 3, 4, 5, 6, 7, 8, 9 nodes and compatible, interrupts,
clocks, access-controllers properties.

Signed-off-by: Valentin Caron <valentin.caron@foss.st.com>
---
 arch/arm64/boot/dts/st/stm32mp251.dtsi | 72 ++++++++++++++++++++++++++
 1 file changed, 72 insertions(+)

diff --git a/arch/arm64/boot/dts/st/stm32mp251.dtsi b/arch/arm64/boot/dts/st/stm32mp251.dtsi
index 4b48e4ed2d284..ca60b6bc7834c 100644
--- a/arch/arm64/boot/dts/st/stm32mp251.dtsi
+++ b/arch/arm64/boot/dts/st/stm32mp251.dtsi
@@ -148,6 +148,33 @@ usart2: serial@400e0000 {
 				status = "disabled";
 			};
 
+			usart3: serial@400f0000 {
+				compatible = "st,stm32h7-uart";
+				reg = <0x400f0000 0x400>;
+				interrupts = <GIC_SPI 116 IRQ_TYPE_LEVEL_HIGH>;
+				clocks = <&rcc CK_KER_USART3>;
+				access-controllers = <&rifsc 33>;
+				status = "disabled";
+			};
+
+			uart4: serial@40100000 {
+				compatible = "st,stm32h7-uart";
+				reg = <0x40100000 0x400>;
+				interrupts = <GIC_SPI 126 IRQ_TYPE_LEVEL_HIGH>;
+				clocks = <&rcc CK_KER_UART4>;
+				access-controllers = <&rifsc 34>;
+				status = "disabled";
+			};
+
+			uart5: serial@40110000 {
+				compatible = "st,stm32h7-uart";
+				reg = <0x40110000 0x400>;
+				interrupts = <GIC_SPI 127 IRQ_TYPE_LEVEL_HIGH>;
+				clocks = <&rcc CK_KER_UART5>;
+				access-controllers = <&rifsc 35>;
+				status = "disabled";
+			};
+
 			i2c1: i2c@40120000 {
 				compatible = "st,stm32mp25-i2c";
 				reg = <0x40120000 0x400>;
@@ -239,6 +266,15 @@ i2c7: i2c@40180000 {
 				status = "disabled";
 			};
 
+			usart6: serial@40220000 {
+				compatible = "st,stm32h7-uart";
+				reg = <0x40220000 0x400>;
+				interrupts = <GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>;
+				clocks = <&rcc CK_KER_USART6>;
+				access-controllers = <&rifsc 36>;
+				status = "disabled";
+			};
+
 			spi1: spi@40230000 {
 				#address-cells = <1>;
 				#size-cells = <0>;
@@ -275,6 +311,24 @@ spi5: spi@40280000 {
 				status = "disabled";
 			};
 
+			uart9: serial@402c0000 {
+				compatible = "st,stm32h7-uart";
+				reg = <0x402c0000 0x400>;
+				interrupts = <GIC_SPI 150 IRQ_TYPE_LEVEL_HIGH>;
+				clocks = <&rcc CK_KER_UART9>;
+				access-controllers = <&rifsc 39>;
+				status = "disabled";
+			};
+
+			usart1: serial@40330000 {
+				compatible = "st,stm32h7-uart";
+				reg = <0x40330000 0x400>;
+				interrupts = <GIC_SPI 114 IRQ_TYPE_LEVEL_HIGH>;
+				clocks = <&rcc CK_KER_USART1>;
+				access-controllers = <&rifsc 31>;
+				status = "disabled";
+			};
+
 			spi6: spi@40350000 {
 				#address-cells = <1>;
 				#size-cells = <0>;
@@ -299,6 +353,24 @@ spi7: spi@40360000 {
 				status = "disabled";
 			};
 
+			uart7: serial@40370000 {
+				compatible = "st,stm32h7-uart";
+				reg = <0x40370000 0x400>;
+				interrupts = <GIC_SPI 148 IRQ_TYPE_LEVEL_HIGH>;
+				clocks = <&rcc CK_KER_UART7>;
+				access-controllers = <&rifsc 37>;
+				status = "disabled";
+			};
+
+			uart8: serial@40380000 {
+				compatible = "st,stm32h7-uart";
+				reg = <0x40380000 0x400>;
+				interrupts = <GIC_SPI 149 IRQ_TYPE_LEVEL_HIGH>;
+				clocks = <&rcc CK_KER_UART8>;
+				access-controllers = <&rifsc 38>;
+				status = "disabled";
+			};
+
 			spi8: spi@46020000 {
 				#address-cells = <1>;
 				#size-cells = <0>;
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 2/3] arm64: dts: st: add usart6 pinctrl used on stm32mp257f-ev1 board
  2024-05-20 14:00 [PATCH 0/3] arm64: dts: st: add usart nodes for stm32mp25 Valentin Caron
  2024-05-20 14:00 ` [PATCH 1/3] arm64: dts: st: add usart nodes on stm32mp25 Valentin Caron
@ 2024-05-20 14:00 ` Valentin Caron
  2024-05-20 14:00 ` [PATCH 3/3] arm64: dts: st: add usart6 " Valentin Caron
  2024-06-05  7:38 ` [PATCH 0/3] arm64: dts: st: add usart nodes for stm32mp25 Alexandre TORGUE
  3 siblings, 0 replies; 5+ messages in thread
From: Valentin Caron @ 2024-05-20 14:00 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Alexandre Torgue
  Cc: devicetree, linux-stm32, linux-arm-kernel, linux-kernel,
	Valentin Caron

Add pins for USART6 on GPIO connector on stm32mp257f-ev1 board.

Signed-off-by: Valentin Caron <valentin.caron@foss.st.com>
---
 arch/arm64/boot/dts/st/stm32mp25-pinctrl.dtsi | 41 +++++++++++++++++++
 1 file changed, 41 insertions(+)

diff --git a/arch/arm64/boot/dts/st/stm32mp25-pinctrl.dtsi b/arch/arm64/boot/dts/st/stm32mp25-pinctrl.dtsi
index 7a82896dcbf60..4e677e64c406f 100644
--- a/arch/arm64/boot/dts/st/stm32mp25-pinctrl.dtsi
+++ b/arch/arm64/boot/dts/st/stm32mp25-pinctrl.dtsi
@@ -128,6 +128,47 @@ pins {
 				 <STM32_PINMUX('A', 8, ANALOG)>; /* USART2_RX */
 		};
 	};
+
+	usart6_pins_a: usart6-0 {
+		pins1 {
+			pinmux = <STM32_PINMUX('F', 13, AF3)>, /* USART6_TX */
+				 <STM32_PINMUX('G', 5, AF3)>;  /* USART6_RTS */
+			bias-disable;
+			drive-push-pull;
+			slew-rate = <0>;
+		};
+		pins2 {
+			pinmux = <STM32_PINMUX('F', 14, AF3)>, /* USART6_RX */
+				 <STM32_PINMUX('F', 15, AF3)>; /* USART6_CTS_NSS */
+			bias-pull-up;
+		};
+	};
+
+	usart6_idle_pins_a: usart6-idle-0 {
+		pins1 {
+			pinmux = <STM32_PINMUX('F', 13, ANALOG)>, /* USART6_TX */
+				 <STM32_PINMUX('F', 15, ANALOG)>; /* USART6_CTS_NSS */
+		};
+		pins2 {
+			pinmux = <STM32_PINMUX('G', 5, AF3)>; /* USART6_RTS */
+			bias-disable;
+			drive-push-pull;
+			slew-rate = <0>;
+		};
+		pins3 {
+			pinmux = <STM32_PINMUX('F', 14, AF3)>; /* USART6_RX */
+			bias-pull-up;
+		};
+	};
+
+	usart6_sleep_pins_a: usart6-sleep-0 {
+		pins {
+			pinmux = <STM32_PINMUX('F', 13, ANALOG)>, /* USART6_TX */
+				 <STM32_PINMUX('G', 5, ANALOG)>,  /* USART6_RTS */
+				 <STM32_PINMUX('F', 15, ANALOG)>, /* USART6_CTS_NSS */
+				 <STM32_PINMUX('F', 14, ANALOG)>; /* USART6_RX */
+		};
+	};
 };
 
 &pinctrl_z {
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 3/3] arm64: dts: st: add usart6 on stm32mp257f-ev1 board
  2024-05-20 14:00 [PATCH 0/3] arm64: dts: st: add usart nodes for stm32mp25 Valentin Caron
  2024-05-20 14:00 ` [PATCH 1/3] arm64: dts: st: add usart nodes on stm32mp25 Valentin Caron
  2024-05-20 14:00 ` [PATCH 2/3] arm64: dts: st: add usart6 pinctrl used on stm32mp257f-ev1 board Valentin Caron
@ 2024-05-20 14:00 ` Valentin Caron
  2024-06-05  7:38 ` [PATCH 0/3] arm64: dts: st: add usart nodes for stm32mp25 Alexandre TORGUE
  3 siblings, 0 replies; 5+ messages in thread
From: Valentin Caron @ 2024-05-20 14:00 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Alexandre Torgue
  Cc: devicetree, linux-stm32, linux-arm-kernel, linux-kernel,
	Valentin Caron

Add node for USART6 on stm32mp257f-ev1 board.

Signed-off-by: Valentin Caron <valentin.caron@foss.st.com>
---
 arch/arm64/boot/dts/st/stm32mp257f-ev1.dts | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/arch/arm64/boot/dts/st/stm32mp257f-ev1.dts b/arch/arm64/boot/dts/st/stm32mp257f-ev1.dts
index 27b7360e5dbaf..18c6266532b29 100644
--- a/arch/arm64/boot/dts/st/stm32mp257f-ev1.dts
+++ b/arch/arm64/boot/dts/st/stm32mp257f-ev1.dts
@@ -18,6 +18,7 @@ / {
 
 	aliases {
 		serial0 = &usart2;
+		serial1 = &usart6;
 	};
 
 	chosen {
@@ -109,3 +110,12 @@ &usart2 {
 	pinctrl-2 = <&usart2_sleep_pins_a>;
 	status = "okay";
 };
+
+&usart6 {
+	pinctrl-names = "default", "idle", "sleep";
+	pinctrl-0 = <&usart6_pins_a>;
+	pinctrl-1 = <&usart6_idle_pins_a>;
+	pinctrl-2 = <&usart6_sleep_pins_a>;
+	uart-has-rtscts;
+	status = "disabled";
+};
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH 0/3] arm64: dts: st: add usart nodes for stm32mp25
  2024-05-20 14:00 [PATCH 0/3] arm64: dts: st: add usart nodes for stm32mp25 Valentin Caron
                   ` (2 preceding siblings ...)
  2024-05-20 14:00 ` [PATCH 3/3] arm64: dts: st: add usart6 " Valentin Caron
@ 2024-06-05  7:38 ` Alexandre TORGUE
  3 siblings, 0 replies; 5+ messages in thread
From: Alexandre TORGUE @ 2024-06-05  7:38 UTC (permalink / raw)
  To: Valentin Caron, Rob Herring, Krzysztof Kozlowski, Conor Dooley
  Cc: devicetree, linux-stm32, linux-arm-kernel, linux-kernel

Hi

On 5/20/24 16:00, Valentin Caron wrote:
> STM32MP25 got the same serial hardware block as STM32MP1x but with two improvements:
>   - TX and RX FIFO have been extended to 64 bytes.
>   - one instance more than in STM32MP1x series (4x usart and 5x uart).
>   
> STM32MP257F-EV1 board has one usart used by console and one usart on IO port.
> 
> Valentin Caron (3):
>    arm64: dts: st: add usart nodes on stm32mp25
>    arm64: dts: st: add usart6 pinctrl used on stm32mp257f-ev1 board
>    arm64: dts: st: add usart6 on stm32mp257f-ev1 board
> 
>   arch/arm64/boot/dts/st/stm32mp25-pinctrl.dtsi | 41 +++++++++++
>   arch/arm64/boot/dts/st/stm32mp251.dtsi        | 72 +++++++++++++++++++
>   arch/arm64/boot/dts/st/stm32mp257f-ev1.dts    | 10 +++
>   3 files changed, 123 insertions(+)
> 

Series applied on stm32-next.

thanks!!

Alex

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2024-06-05  7:39 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-20 14:00 [PATCH 0/3] arm64: dts: st: add usart nodes for stm32mp25 Valentin Caron
2024-05-20 14:00 ` [PATCH 1/3] arm64: dts: st: add usart nodes on stm32mp25 Valentin Caron
2024-05-20 14:00 ` [PATCH 2/3] arm64: dts: st: add usart6 pinctrl used on stm32mp257f-ev1 board Valentin Caron
2024-05-20 14:00 ` [PATCH 3/3] arm64: dts: st: add usart6 " Valentin Caron
2024-06-05  7:38 ` [PATCH 0/3] arm64: dts: st: add usart nodes for stm32mp25 Alexandre TORGUE

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).