diff --git a/boards/arm/96b_aerocore2/96b_aerocore2.dts b/boards/arm/96b_aerocore2/96b_aerocore2.dts index b5d53dff968f7..640aa512838c1 100644 --- a/boards/arm/96b_aerocore2/96b_aerocore2.dts +++ b/boards/arm/96b_aerocore2/96b_aerocore2.dts @@ -64,30 +64,35 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pd5 &usart2_rx_pd6>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &uart7 { pinctrl-0 = <&uart7_tx_pe8 &uart7_rx_pe7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &uart8 { pinctrl-0 = <&uart8_tx_pe1 &uart8_rx_pe0>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/96b_aerocore2/96b_aerocore2_defconfig b/boards/arm/96b_aerocore2/96b_aerocore2_defconfig index 1d95860335660..58a0beb8f71ef 100644 --- a/boards/arm/96b_aerocore2/96b_aerocore2_defconfig +++ b/boards/arm/96b_aerocore2/96b_aerocore2_defconfig @@ -24,3 +24,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/96b_argonkey/96b_argonkey.dts b/boards/arm/96b_argonkey/96b_argonkey.dts index addd38c9cd2fc..188dff0ff5905 100644 --- a/boards/arm/96b_argonkey/96b_argonkey.dts +++ b/boards/arm/96b_argonkey/96b_argonkey.dts @@ -71,6 +71,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/96b_argonkey/96b_argonkey_defconfig b/boards/arm/96b_argonkey/96b_argonkey_defconfig index fba707e37485d..84d9c2682dc48 100644 --- a/boards/arm/96b_argonkey/96b_argonkey_defconfig +++ b/boards/arm/96b_argonkey/96b_argonkey_defconfig @@ -24,3 +24,6 @@ CONFIG_CLOCK_CONTROL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/96b_avenger96/96b_avenger96.dts b/boards/arm/96b_avenger96/96b_avenger96.dts index 83ce2b1fd0634..3accaae12a95a 100644 --- a/boards/arm/96b_avenger96/96b_avenger96.dts +++ b/boards/arm/96b_avenger96/96b_avenger96.dts @@ -59,12 +59,14 @@ &uart4 { pinctrl-0 = <&uart4_tx_pd1 &uart4_rx_pb2>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &uart7 { pinctrl-0 = <&uart7_tx_pe8 &uart7_rx_pe7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/96b_avenger96/96b_avenger96_defconfig b/boards/arm/96b_avenger96/96b_avenger96_defconfig index 2164509818623..b0dde178ffd58 100644 --- a/boards/arm/96b_avenger96/96b_avenger96_defconfig +++ b/boards/arm/96b_avenger96/96b_avenger96_defconfig @@ -27,3 +27,6 @@ CONFIG_RAM_CONSOLE_BUFFER_SIZE=1024 # uart console (overrides remote proc console) CONFIG_UART_CONSOLE=n + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/96b_carbon/96b_carbon.dts b/boards/arm/96b_carbon/96b_carbon.dts index cd792a49ff28e..6aa3aa09d33c5 100644 --- a/boards/arm/96b_carbon/96b_carbon.dts +++ b/boards/arm/96b_carbon/96b_carbon.dts @@ -77,18 +77,21 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pc6 &usart6_rx_pc7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/96b_carbon/96b_carbon_defconfig b/boards/arm/96b_carbon/96b_carbon_defconfig index ad3e793db8201..1cae00a6e87f4 100644 --- a/boards/arm/96b_carbon/96b_carbon_defconfig +++ b/boards/arm/96b_carbon/96b_carbon_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/96b_neonkey/96b_neonkey.dts b/boards/arm/96b_neonkey/96b_neonkey.dts index 5c4688f1cad80..e5a156b0883d3 100644 --- a/boards/arm/96b_neonkey/96b_neonkey.dts +++ b/boards/arm/96b_neonkey/96b_neonkey.dts @@ -78,6 +78,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/96b_neonkey/96b_neonkey_defconfig b/boards/arm/96b_neonkey/96b_neonkey_defconfig index 314da54468bf2..40931073c9602 100644 --- a/boards/arm/96b_neonkey/96b_neonkey_defconfig +++ b/boards/arm/96b_neonkey/96b_neonkey_defconfig @@ -24,3 +24,6 @@ CONFIG_CLOCK_CONTROL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/96b_stm32_sensor_mez/96b_stm32_sensor_mez.dts b/boards/arm/96b_stm32_sensor_mez/96b_stm32_sensor_mez.dts index fb2db7e795302..ec1f1bddb18bb 100644 --- a/boards/arm/96b_stm32_sensor_mez/96b_stm32_sensor_mez.dts +++ b/boards/arm/96b_stm32_sensor_mez/96b_stm32_sensor_mez.dts @@ -172,24 +172,28 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pd5 &usart2_rx_pd6>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &uart4 { pinctrl-0 = <&uart4_tx_pc10 &uart4_rx_pc11>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/96b_stm32_sensor_mez/96b_stm32_sensor_mez_defconfig b/boards/arm/96b_stm32_sensor_mez/96b_stm32_sensor_mez_defconfig index c24066443abd6..c606b05d714e4 100644 --- a/boards/arm/96b_stm32_sensor_mez/96b_stm32_sensor_mez_defconfig +++ b/boards/arm/96b_stm32_sensor_mez/96b_stm32_sensor_mez_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/96b_wistrio/96b_wistrio.dts b/boards/arm/96b_wistrio/96b_wistrio.dts index b902ef7d17530..efdefacdff61c 100644 --- a/boards/arm/96b_wistrio/96b_wistrio.dts +++ b/boards/arm/96b_wistrio/96b_wistrio.dts @@ -60,12 +60,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/96b_wistrio/96b_wistrio_defconfig b/boards/arm/96b_wistrio/96b_wistrio_defconfig index e2f2155fd4291..6d21400e06cd2 100644 --- a/boards/arm/96b_wistrio/96b_wistrio_defconfig +++ b/boards/arm/96b_wistrio/96b_wistrio_defconfig @@ -22,3 +22,6 @@ CONFIG_CLOCK_CONTROL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/adafruit_feather_stm32f405/adafruit_feather_stm32f405.dts b/boards/arm/adafruit_feather_stm32f405/adafruit_feather_stm32f405.dts index dceeb84cc90a6..8670a6c3352d4 100644 --- a/boards/arm/adafruit_feather_stm32f405/adafruit_feather_stm32f405.dts +++ b/boards/arm/adafruit_feather_stm32f405/adafruit_feather_stm32f405.dts @@ -58,6 +58,7 @@ &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb11>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/adafruit_feather_stm32f405/adafruit_feather_stm32f405_defconfig b/boards/arm/adafruit_feather_stm32f405/adafruit_feather_stm32f405_defconfig index ef6a1913d0823..bdcd05d7a8e61 100644 --- a/boards/arm/adafruit_feather_stm32f405/adafruit_feather_stm32f405_defconfig +++ b/boards/arm/adafruit_feather_stm32f405/adafruit_feather_stm32f405_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/b_l072z_lrwan1/b_l072z_lrwan1.dts b/boards/arm/b_l072z_lrwan1/b_l072z_lrwan1.dts index bf17f5fd485e3..4bd06546dd8db 100644 --- a/boards/arm/b_l072z_lrwan1/b_l072z_lrwan1.dts +++ b/boards/arm/b_l072z_lrwan1/b_l072z_lrwan1.dts @@ -100,12 +100,14 @@ arduino_i2c: &i2c1 {}; &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/b_l072z_lrwan1/b_l072z_lrwan1_defconfig b/boards/arm/b_l072z_lrwan1/b_l072z_lrwan1_defconfig index 0f2375fd2f53b..bf536d18f5d8e 100644 --- a/boards/arm/b_l072z_lrwan1/b_l072z_lrwan1_defconfig +++ b/boards/arm/b_l072z_lrwan1/b_l072z_lrwan1_defconfig @@ -25,3 +25,6 @@ CONFIG_PINMUX=y # GPIO Controller CONFIG_GPIO=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/b_l4s5i_iot01a/b_l4s5i_iot01a.dts b/boards/arm/b_l4s5i_iot01a/b_l4s5i_iot01a.dts index b295057229c26..30f53340f0844 100644 --- a/boards/arm/b_l4s5i_iot01a/b_l4s5i_iot01a.dts +++ b/boards/arm/b_l4s5i_iot01a/b_l4s5i_iot01a.dts @@ -69,12 +69,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &uart4 { pinctrl-0 = <&uart4_tx_pa0 &uart4_rx_pa1>; + pinctrl-names = "default"; current-speed = <115200>; }; diff --git a/boards/arm/b_l4s5i_iot01a/b_l4s5i_iot01a_defconfig b/boards/arm/b_l4s5i_iot01a/b_l4s5i_iot01a_defconfig index 0dffee21efe61..c110af291af13 100644 --- a/boards/arm/b_l4s5i_iot01a/b_l4s5i_iot01a_defconfig +++ b/boards/arm/b_l4s5i_iot01a/b_l4s5i_iot01a_defconfig @@ -18,3 +18,6 @@ CONFIG_CLOCK_CONTROL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/b_u585i_iot02a/b_u585i_iot02a_defconfig b/boards/arm/b_u585i_iot02a/b_u585i_iot02a_defconfig index 5ad1d1d662d34..34878cd231f6c 100644 --- a/boards/arm/b_u585i_iot02a/b_u585i_iot02a_defconfig +++ b/boards/arm/b_u585i_iot02a/b_u585i_iot02a_defconfig @@ -18,3 +18,6 @@ CONFIG_CLOCK_CONTROL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/black_f407ve/black_f407ve.dts b/boards/arm/black_f407ve/black_f407ve.dts index a452ab8dac32e..e58430bf688ab 100644 --- a/boards/arm/black_f407ve/black_f407ve.dts +++ b/boards/arm/black_f407ve/black_f407ve.dts @@ -80,12 +80,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/black_f407ve/black_f407ve_defconfig b/boards/arm/black_f407ve/black_f407ve_defconfig index 211bb64020394..218533ebfd210 100644 --- a/boards/arm/black_f407ve/black_f407ve_defconfig +++ b/boards/arm/black_f407ve/black_f407ve_defconfig @@ -24,3 +24,6 @@ CONFIG_CLOCK_CONTROL=y # Enable GPIO CONFIG_GPIO=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/black_f407zg_pro/black_f407zg_pro.dts b/boards/arm/black_f407zg_pro/black_f407zg_pro.dts index 3ee541de8ac5e..bd09187790d74 100644 --- a/boards/arm/black_f407zg_pro/black_f407zg_pro.dts +++ b/boards/arm/black_f407zg_pro/black_f407zg_pro.dts @@ -80,12 +80,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/black_f407zg_pro/black_f407zg_pro_defconfig b/boards/arm/black_f407zg_pro/black_f407zg_pro_defconfig index 24ba17ec41c67..b70fa783db486 100644 --- a/boards/arm/black_f407zg_pro/black_f407zg_pro_defconfig +++ b/boards/arm/black_f407zg_pro/black_f407zg_pro_defconfig @@ -24,3 +24,6 @@ CONFIG_CLOCK_CONTROL=y # Enable GPIO CONFIG_GPIO=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/blackpill_f401ce/blackpill_f401ce.dts b/boards/arm/blackpill_f401ce/blackpill_f401ce.dts index ee7747fc6d303..2132176d38534 100644 --- a/boards/arm/blackpill_f401ce/blackpill_f401ce.dts +++ b/boards/arm/blackpill_f401ce/blackpill_f401ce.dts @@ -86,6 +86,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; status = "okay"; current-speed = <115200>; }; diff --git a/boards/arm/blackpill_f401ce/blackpill_f401ce_defconfig b/boards/arm/blackpill_f401ce/blackpill_f401ce_defconfig index 14f574f20ade4..e9fcab6874554 100644 --- a/boards/arm/blackpill_f401ce/blackpill_f401ce_defconfig +++ b/boards/arm/blackpill_f401ce/blackpill_f401ce_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Clock configuration CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/blackpill_f411ce/blackpill_f411ce.dts b/boards/arm/blackpill_f411ce/blackpill_f411ce.dts index e9d6aa4b44a80..856a7a79c4598 100644 --- a/boards/arm/blackpill_f411ce/blackpill_f411ce.dts +++ b/boards/arm/blackpill_f411ce/blackpill_f411ce.dts @@ -87,6 +87,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; status = "okay"; current-speed = <115200>; }; diff --git a/boards/arm/blackpill_f411ce/blackpill_f411ce_defconfig b/boards/arm/blackpill_f411ce/blackpill_f411ce_defconfig index 4e004f6cefd4e..d5599bbcd800a 100644 --- a/boards/arm/blackpill_f411ce/blackpill_f411ce_defconfig +++ b/boards/arm/blackpill_f411ce/blackpill_f411ce_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Clock configuration CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/disco_l475_iot1/disco_l475_iot1.dts b/boards/arm/disco_l475_iot1/disco_l475_iot1.dts index 04fd16915af5f..b2e39a02ec3b1 100644 --- a/boards/arm/disco_l475_iot1/disco_l475_iot1.dts +++ b/boards/arm/disco_l475_iot1/disco_l475_iot1.dts @@ -76,11 +76,13 @@ current-speed = <115200>; pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; pinctrl-names = "default"; + pinctrl-names = "default"; status = "okay"; }; &uart4 { pinctrl-0 = <&uart4_tx_pa0 &uart4_rx_pa1>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/disco_l475_iot1/disco_l475_iot1_defconfig b/boards/arm/disco_l475_iot1/disco_l475_iot1_defconfig index ba967050a1da8..9ac5056faba72 100644 --- a/boards/arm/disco_l475_iot1/disco_l475_iot1_defconfig +++ b/boards/arm/disco_l475_iot1/disco_l475_iot1_defconfig @@ -26,3 +26,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/dragino_lsn50/dragino_lsn50.dts b/boards/arm/dragino_lsn50/dragino_lsn50.dts index 0806df7165684..6e7ab61f4844c 100644 --- a/boards/arm/dragino_lsn50/dragino_lsn50.dts +++ b/boards/arm/dragino_lsn50/dragino_lsn50.dts @@ -41,12 +41,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/dragino_lsn50/dragino_lsn50_defconfig b/boards/arm/dragino_lsn50/dragino_lsn50_defconfig index 6bc0f9c1edc28..536349ced9c60 100644 --- a/boards/arm/dragino_lsn50/dragino_lsn50_defconfig +++ b/boards/arm/dragino_lsn50/dragino_lsn50_defconfig @@ -22,3 +22,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/dragino_nbsn95/dragino_nbsn95.dts b/boards/arm/dragino_nbsn95/dragino_nbsn95.dts index 171a4158c3921..4838e3b0c28a7 100644 --- a/boards/arm/dragino_nbsn95/dragino_nbsn95.dts +++ b/boards/arm/dragino_nbsn95/dragino_nbsn95.dts @@ -53,12 +53,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/dragino_nbsn95/dragino_nbsn95_defconfig b/boards/arm/dragino_nbsn95/dragino_nbsn95_defconfig index 8b8cbb939c3e5..2add4a915064c 100644 --- a/boards/arm/dragino_nbsn95/dragino_nbsn95_defconfig +++ b/boards/arm/dragino_nbsn95/dragino_nbsn95_defconfig @@ -22,3 +22,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/google_kukui/google_kukui.dts b/boards/arm/google_kukui/google_kukui.dts index 4fcb0d24061f2..cad6f565636c5 100644 --- a/boards/arm/google_kukui/google_kukui.dts +++ b/boards/arm/google_kukui/google_kukui.dts @@ -33,6 +33,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/google_kukui/google_kukui_defconfig b/boards/arm/google_kukui/google_kukui_defconfig index 798bb6bc32f49..89ff341e8a3ec 100644 --- a/boards/arm/google_kukui/google_kukui_defconfig +++ b/boards/arm/google_kukui/google_kukui_defconfig @@ -26,3 +26,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/legend/legend.dts b/boards/arm/legend/legend.dts index 87d04152ba4e9..c134d4eda2827 100644 --- a/boards/arm/legend/legend.dts +++ b/boards/arm/legend/legend.dts @@ -42,6 +42,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/legend/legend_defconfig b/boards/arm/legend/legend_defconfig index 63720f0538f1b..9a2beaf76d03a 100644 --- a/boards/arm/legend/legend_defconfig +++ b/boards/arm/legend/legend_defconfig @@ -21,3 +21,6 @@ CONFIG_GPIO=y # Clock Control CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/lora_e5_dev_board/lora_e5_dev_board_defconfig b/boards/arm/lora_e5_dev_board/lora_e5_dev_board_defconfig index 0e9eb43b5addd..513b86a0223b2 100644 --- a/boards/arm/lora_e5_dev_board/lora_e5_dev_board_defconfig +++ b/boards/arm/lora_e5_dev_board/lora_e5_dev_board_defconfig @@ -25,3 +25,6 @@ CONFIG_HW_STACK_PROTECTION=y # Enable regulator for the power-rails CONFIG_REGULATOR=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/mikroe_clicker_2/mikroe_clicker_2.dts b/boards/arm/mikroe_clicker_2/mikroe_clicker_2.dts index 2dade5de17bf1..b6f1337ccf00b 100644 --- a/boards/arm/mikroe_clicker_2/mikroe_clicker_2.dts +++ b/boards/arm/mikroe_clicker_2/mikroe_clicker_2.dts @@ -76,18 +76,21 @@ &usart2 { pinctrl-0 = <&usart2_tx_pd5 &usart2_rx_pd6>; + pinctrl-names = "default"; current-speed = <9600>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <9600>; status = "okay"; }; &uart4 { pinctrl-0 = <&uart4_tx_pa0 &uart4_rx_pa1>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/mikroe_clicker_2/mikroe_clicker_2_defconfig b/boards/arm/mikroe_clicker_2/mikroe_clicker_2_defconfig index 83a35a4ba2b97..cfcd5c23037cc 100644 --- a/boards/arm/mikroe_clicker_2/mikroe_clicker_2_defconfig +++ b/boards/arm/mikroe_clicker_2/mikroe_clicker_2_defconfig @@ -18,3 +18,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/mikroe_mini_m4_for_stm32/mikroe_mini_m4_for_stm32.dts b/boards/arm/mikroe_mini_m4_for_stm32/mikroe_mini_m4_for_stm32.dts index 3057cc6e958d2..d5d61a4d5952b 100644 --- a/boards/arm/mikroe_mini_m4_for_stm32/mikroe_mini_m4_for_stm32.dts +++ b/boards/arm/mikroe_mini_m4_for_stm32/mikroe_mini_m4_for_stm32.dts @@ -62,6 +62,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/mikroe_mini_m4_for_stm32/mikroe_mini_m4_for_stm32_defconfig b/boards/arm/mikroe_mini_m4_for_stm32/mikroe_mini_m4_for_stm32_defconfig index 0bd64acca2a59..ce310a36de572 100644 --- a/boards/arm/mikroe_mini_m4_for_stm32/mikroe_mini_m4_for_stm32_defconfig +++ b/boards/arm/mikroe_mini_m4_for_stm32/mikroe_mini_m4_for_stm32_defconfig @@ -22,3 +22,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f030r8/nucleo_f030r8.dts b/boards/arm/nucleo_f030r8/nucleo_f030r8.dts index d6520ecd70145..6f4a076cf75ce 100644 --- a/boards/arm/nucleo_f030r8/nucleo_f030r8.dts +++ b/boards/arm/nucleo_f030r8/nucleo_f030r8.dts @@ -69,12 +69,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f030r8/nucleo_f030r8_defconfig b/boards/arm/nucleo_f030r8/nucleo_f030r8_defconfig index 8be75cf6abe43..1aca1d6eff5de 100644 --- a/boards/arm/nucleo_f030r8/nucleo_f030r8_defconfig +++ b/boards/arm/nucleo_f030r8/nucleo_f030r8_defconfig @@ -28,3 +28,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f031k6/nucleo_f031k6.dts b/boards/arm/nucleo_f031k6/nucleo_f031k6.dts index b1b85c4a27834..cbcc62cabf86a 100644 --- a/boards/arm/nucleo_f031k6/nucleo_f031k6.dts +++ b/boards/arm/nucleo_f031k6/nucleo_f031k6.dts @@ -74,6 +74,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa2 &usart1_rx_pa15>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f031k6/nucleo_f031k6_defconfig b/boards/arm/nucleo_f031k6/nucleo_f031k6_defconfig index 2e83111a72813..a937b41e055a9 100644 --- a/boards/arm/nucleo_f031k6/nucleo_f031k6_defconfig +++ b/boards/arm/nucleo_f031k6/nucleo_f031k6_defconfig @@ -27,3 +27,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f070rb/nucleo_f070rb.dts b/boards/arm/nucleo_f070rb/nucleo_f070rb.dts index 922657f03f099..1e26c0a7a8e78 100644 --- a/boards/arm/nucleo_f070rb/nucleo_f070rb.dts +++ b/boards/arm/nucleo_f070rb/nucleo_f070rb.dts @@ -64,12 +64,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f070rb/nucleo_f070rb_defconfig b/boards/arm/nucleo_f070rb/nucleo_f070rb_defconfig index bca68ac1f0e21..ae9a04ae8fff4 100644 --- a/boards/arm/nucleo_f070rb/nucleo_f070rb_defconfig +++ b/boards/arm/nucleo_f070rb/nucleo_f070rb_defconfig @@ -21,3 +21,6 @@ CONFIG_GPIO=y # Enable clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f091rc/nucleo_f091rc.dts b/boards/arm/nucleo_f091rc/nucleo_f091rc.dts index 5eeca19c85baf..accd5443f8602 100644 --- a/boards/arm/nucleo_f091rc/nucleo_f091rc.dts +++ b/boards/arm/nucleo_f091rc/nucleo_f091rc.dts @@ -64,11 +64,13 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f091rc/nucleo_f091rc_defconfig b/boards/arm/nucleo_f091rc/nucleo_f091rc_defconfig index 21ef50d9250df..4b8b49686b71c 100644 --- a/boards/arm/nucleo_f091rc/nucleo_f091rc_defconfig +++ b/boards/arm/nucleo_f091rc/nucleo_f091rc_defconfig @@ -21,3 +21,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f103rb/nucleo_f103rb.dts b/boards/arm/nucleo_f103rb/nucleo_f103rb.dts index 41462965bbafe..c5e48ad2b378a 100644 --- a/boards/arm/nucleo_f103rb/nucleo_f103rb.dts +++ b/boards/arm/nucleo_f103rb/nucleo_f103rb.dts @@ -64,18 +64,21 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb11>; + pinctrl-names = "default"; current-speed = <115200>; }; diff --git a/boards/arm/nucleo_f103rb/nucleo_f103rb_defconfig b/boards/arm/nucleo_f103rb/nucleo_f103rb_defconfig index 7ac7b8d213477..39fc1b6b8697a 100644 --- a/boards/arm/nucleo_f103rb/nucleo_f103rb_defconfig +++ b/boards/arm/nucleo_f103rb/nucleo_f103rb_defconfig @@ -17,3 +17,6 @@ CONFIG_GPIO=y # enable clock CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f207zg/nucleo_f207zg.dts b/boards/arm/nucleo_f207zg/nucleo_f207zg.dts index 98b9821dc52f7..8e1f8022623ae 100644 --- a/boards/arm/nucleo_f207zg/nucleo_f207zg.dts +++ b/boards/arm/nucleo_f207zg/nucleo_f207zg.dts @@ -89,12 +89,14 @@ &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pg9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f207zg/nucleo_f207zg_defconfig b/boards/arm/nucleo_f207zg/nucleo_f207zg_defconfig index 67c31bc45a2b9..a0d2acaeaa76b 100644 --- a/boards/arm/nucleo_f207zg/nucleo_f207zg_defconfig +++ b/boards/arm/nucleo_f207zg/nucleo_f207zg_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f302r8/nucleo_f302r8.dts b/boards/arm/nucleo_f302r8/nucleo_f302r8.dts index 34e64b2c5e108..7d797023d84be 100644 --- a/boards/arm/nucleo_f302r8/nucleo_f302r8.dts +++ b/boards/arm/nucleo_f302r8/nucleo_f302r8.dts @@ -77,16 +77,19 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pc10 &usart3_rx_pc11>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f302r8/nucleo_f302r8_defconfig b/boards/arm/nucleo_f302r8/nucleo_f302r8_defconfig index beea91851dba3..8ff3e679e5691 100644 --- a/boards/arm/nucleo_f302r8/nucleo_f302r8_defconfig +++ b/boards/arm/nucleo_f302r8/nucleo_f302r8_defconfig @@ -17,3 +17,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f303k8/nucleo_f303k8.dts b/boards/arm/nucleo_f303k8/nucleo_f303k8.dts index 27ce90f713af0..108d5ad85336d 100644 --- a/boards/arm/nucleo_f303k8/nucleo_f303k8.dts +++ b/boards/arm/nucleo_f303k8/nucleo_f303k8.dts @@ -70,6 +70,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa15>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f303k8/nucleo_f303k8_defconfig b/boards/arm/nucleo_f303k8/nucleo_f303k8_defconfig index c4f486c1f2c1b..07776add037cf 100644 --- a/boards/arm/nucleo_f303k8/nucleo_f303k8_defconfig +++ b/boards/arm/nucleo_f303k8/nucleo_f303k8_defconfig @@ -17,3 +17,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f303re/nucleo_f303re.dts b/boards/arm/nucleo_f303re/nucleo_f303re.dts index f53a2caa5bcda..8b3f4c146f768 100644 --- a/boards/arm/nucleo_f303re/nucleo_f303re.dts +++ b/boards/arm/nucleo_f303re/nucleo_f303re.dts @@ -66,12 +66,14 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f303re/nucleo_f303re_defconfig b/boards/arm/nucleo_f303re/nucleo_f303re_defconfig index 22686be206c92..c28b12a1ef227 100644 --- a/boards/arm/nucleo_f303re/nucleo_f303re_defconfig +++ b/boards/arm/nucleo_f303re/nucleo_f303re_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f334r8/nucleo_f334r8.dts b/boards/arm/nucleo_f334r8/nucleo_f334r8.dts index a30b1a378bdbf..05842f4a32f43 100644 --- a/boards/arm/nucleo_f334r8/nucleo_f334r8.dts +++ b/boards/arm/nucleo_f334r8/nucleo_f334r8.dts @@ -65,18 +65,21 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb11>; + pinctrl-names = "default"; current-speed = <115200>; }; diff --git a/boards/arm/nucleo_f334r8/nucleo_f334r8_defconfig b/boards/arm/nucleo_f334r8/nucleo_f334r8_defconfig index 3d8560733465f..fe6f3b39cdced 100644 --- a/boards/arm/nucleo_f334r8/nucleo_f334r8_defconfig +++ b/boards/arm/nucleo_f334r8/nucleo_f334r8_defconfig @@ -21,3 +21,6 @@ CONFIG_GPIO=y # Enable clock CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f401re/nucleo_f401re.dts b/boards/arm/nucleo_f401re/nucleo_f401re.dts index 62183e5e45e76..8e3b3e2f8c024 100644 --- a/boards/arm/nucleo_f401re/nucleo_f401re.dts +++ b/boards/arm/nucleo_f401re/nucleo_f401re.dts @@ -77,12 +77,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f401re/nucleo_f401re_defconfig b/boards/arm/nucleo_f401re/nucleo_f401re_defconfig index cd1a0cc71bae8..3ed6cd444ec31 100644 --- a/boards/arm/nucleo_f401re/nucleo_f401re_defconfig +++ b/boards/arm/nucleo_f401re/nucleo_f401re_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # clock configuration CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f410rb/nucleo_f410rb.dts b/boards/arm/nucleo_f410rb/nucleo_f410rb.dts index f17b6e01f8240..0eb3964fb2879 100644 --- a/boards/arm/nucleo_f410rb/nucleo_f410rb.dts +++ b/boards/arm/nucleo_f410rb/nucleo_f410rb.dts @@ -67,12 +67,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f410rb/nucleo_f410rb_defconfig b/boards/arm/nucleo_f410rb/nucleo_f410rb_defconfig index e60e783fd9b13..38f54a466070e 100644 --- a/boards/arm/nucleo_f410rb/nucleo_f410rb_defconfig +++ b/boards/arm/nucleo_f410rb/nucleo_f410rb_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f411re/nucleo_f411re.dts b/boards/arm/nucleo_f411re/nucleo_f411re.dts index fdc2f33e3a5d8..fd4f263f1ceb7 100644 --- a/boards/arm/nucleo_f411re/nucleo_f411re.dts +++ b/boards/arm/nucleo_f411re/nucleo_f411re.dts @@ -67,12 +67,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f411re/nucleo_f411re_defconfig b/boards/arm/nucleo_f411re/nucleo_f411re_defconfig index e5fa34d9a49d6..d64fe000bb1fb 100644 --- a/boards/arm/nucleo_f411re/nucleo_f411re_defconfig +++ b/boards/arm/nucleo_f411re/nucleo_f411re_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # clock configuration CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f412zg/nucleo_f412zg.dts b/boards/arm/nucleo_f412zg/nucleo_f412zg.dts index 51a77b255a365..02ee96fc72a09 100644 --- a/boards/arm/nucleo_f412zg/nucleo_f412zg.dts +++ b/boards/arm/nucleo_f412zg/nucleo_f412zg.dts @@ -77,12 +77,14 @@ &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pg9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f412zg/nucleo_f412zg_defconfig b/boards/arm/nucleo_f412zg/nucleo_f412zg_defconfig index 4db88dc1908bb..04f39b30ad648 100644 --- a/boards/arm/nucleo_f412zg/nucleo_f412zg_defconfig +++ b/boards/arm/nucleo_f412zg/nucleo_f412zg_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f413zh/nucleo_f413zh.dts b/boards/arm/nucleo_f413zh/nucleo_f413zh.dts index 396400896189e..53708094061d8 100644 --- a/boards/arm/nucleo_f413zh/nucleo_f413zh.dts +++ b/boards/arm/nucleo_f413zh/nucleo_f413zh.dts @@ -77,12 +77,14 @@ &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pg9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f413zh/nucleo_f413zh_defconfig b/boards/arm/nucleo_f413zh/nucleo_f413zh_defconfig index 742b36b03911a..3bf59bcdd53a3 100644 --- a/boards/arm/nucleo_f413zh/nucleo_f413zh_defconfig +++ b/boards/arm/nucleo_f413zh/nucleo_f413zh_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f429zi/nucleo_f429zi.dts b/boards/arm/nucleo_f429zi/nucleo_f429zi.dts index 7ded78741d989..0b1af9b2c69ee 100644 --- a/boards/arm/nucleo_f429zi/nucleo_f429zi.dts +++ b/boards/arm/nucleo_f429zi/nucleo_f429zi.dts @@ -101,11 +101,13 @@ &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pg9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f429zi/nucleo_f429zi_defconfig b/boards/arm/nucleo_f429zi/nucleo_f429zi_defconfig index 2d1cbac02a4e8..c69f6fd635132 100644 --- a/boards/arm/nucleo_f429zi/nucleo_f429zi_defconfig +++ b/boards/arm/nucleo_f429zi/nucleo_f429zi_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # clock configuration CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f446re/nucleo_f446re.dts b/boards/arm/nucleo_f446re/nucleo_f446re.dts index c598d08bd15d3..4e3816b6d9e3c 100644 --- a/boards/arm/nucleo_f446re/nucleo_f446re.dts +++ b/boards/arm/nucleo_f446re/nucleo_f446re.dts @@ -68,12 +68,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f446re/nucleo_f446re_defconfig b/boards/arm/nucleo_f446re/nucleo_f446re_defconfig index c24066443abd6..c606b05d714e4 100644 --- a/boards/arm/nucleo_f446re/nucleo_f446re_defconfig +++ b/boards/arm/nucleo_f446re/nucleo_f446re_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f446ze/nucleo_f446ze_defconfig b/boards/arm/nucleo_f446ze/nucleo_f446ze_defconfig index c24066443abd6..c606b05d714e4 100644 --- a/boards/arm/nucleo_f446ze/nucleo_f446ze_defconfig +++ b/boards/arm/nucleo_f446ze/nucleo_f446ze_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f746zg/nucleo_f746zg.dts b/boards/arm/nucleo_f746zg/nucleo_f746zg.dts index 474f7fcf3b6d7..b867e85e8166e 100644 --- a/boards/arm/nucleo_f746zg/nucleo_f746zg.dts +++ b/boards/arm/nucleo_f746zg/nucleo_f746zg.dts @@ -86,18 +86,21 @@ &usart2 { pinctrl-0 = <&usart2_tx_pd5 &usart2_rx_pd6 + pinctrl-names = "default"; &usart2_rts_pd4 &usart2_cts_pd3>; current-speed = <115200>; }; &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pg9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f746zg/nucleo_f746zg_defconfig b/boards/arm/nucleo_f746zg/nucleo_f746zg_defconfig index 0b93447e7fb79..ba8007c3bdd47 100644 --- a/boards/arm/nucleo_f746zg/nucleo_f746zg_defconfig +++ b/boards/arm/nucleo_f746zg/nucleo_f746zg_defconfig @@ -24,3 +24,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f756zg/nucleo_f756zg.dts b/boards/arm/nucleo_f756zg/nucleo_f756zg.dts index c6065c969e313..dd60e0857914b 100644 --- a/boards/arm/nucleo_f756zg/nucleo_f756zg.dts +++ b/boards/arm/nucleo_f756zg/nucleo_f756zg.dts @@ -85,6 +85,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pd5 &usart2_rx_pd6 + pinctrl-names = "default"; &usart2_rts_pd4 &usart2_cts_pd3>; current-speed = <115200>; status = "okay"; @@ -92,12 +93,14 @@ &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pg9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f756zg/nucleo_f756zg_defconfig b/boards/arm/nucleo_f756zg/nucleo_f756zg_defconfig index 033b35c412e3a..1b9af46419066 100644 --- a/boards/arm/nucleo_f756zg/nucleo_f756zg_defconfig +++ b/boards/arm/nucleo_f756zg/nucleo_f756zg_defconfig @@ -24,3 +24,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_f767zi/nucleo_f767zi.dts b/boards/arm/nucleo_f767zi/nucleo_f767zi.dts index 8a0f5177b6fd2..5340867f285a9 100644 --- a/boards/arm/nucleo_f767zi/nucleo_f767zi.dts +++ b/boards/arm/nucleo_f767zi/nucleo_f767zi.dts @@ -87,6 +87,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pd5 + pinctrl-names = "default"; &usart2_rx_pd6 &usart2_rts_pd4 &usart2_cts_pd3>; @@ -95,12 +96,14 @@ &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pg9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_f767zi/nucleo_f767zi_defconfig b/boards/arm/nucleo_f767zi/nucleo_f767zi_defconfig index 19a1c042c0e57..4e7024987605e 100644 --- a/boards/arm/nucleo_f767zi/nucleo_f767zi_defconfig +++ b/boards/arm/nucleo_f767zi/nucleo_f767zi_defconfig @@ -24,3 +24,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_g071rb/nucleo_g071rb.dts b/boards/arm/nucleo_g071rb/nucleo_g071rb.dts index 8169ffabcafcb..dc9664164587e 100644 --- a/boards/arm/nucleo_g071rb/nucleo_g071rb.dts +++ b/boards/arm/nucleo_g071rb/nucleo_g071rb.dts @@ -81,12 +81,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pc4 &usart1_rx_pc5>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_g071rb/nucleo_g071rb_defconfig b/boards/arm/nucleo_g071rb/nucleo_g071rb_defconfig index 2fa8573ed2e65..7a87f8244f96d 100644 --- a/boards/arm/nucleo_g071rb/nucleo_g071rb_defconfig +++ b/boards/arm/nucleo_g071rb/nucleo_g071rb_defconfig @@ -20,3 +20,6 @@ CONFIG_GPIO=y # Enables clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_g0b1re/nucleo_g0b1re.dts b/boards/arm/nucleo_g0b1re/nucleo_g0b1re.dts index 071bfbe75ed8c..0939085203cc0 100644 --- a/boards/arm/nucleo_g0b1re/nucleo_g0b1re.dts +++ b/boards/arm/nucleo_g0b1re/nucleo_g0b1re.dts @@ -87,12 +87,14 @@ zephyr_udc0: &usb { &usart1 { pinctrl-0 = <&usart1_tx_pc4 &usart1_rx_pc5>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_g0b1re/nucleo_g0b1re_defconfig b/boards/arm/nucleo_g0b1re/nucleo_g0b1re_defconfig index eae60eda42f97..8cced55c9ae5d 100644 --- a/boards/arm/nucleo_g0b1re/nucleo_g0b1re_defconfig +++ b/boards/arm/nucleo_g0b1re/nucleo_g0b1re_defconfig @@ -20,3 +20,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_g431rb/nucleo_g431rb.dts b/boards/arm/nucleo_g431rb/nucleo_g431rb.dts index 6f7319058ba7e..41e8b642096a8 100644 --- a/boards/arm/nucleo_g431rb/nucleo_g431rb.dts +++ b/boards/arm/nucleo_g431rb/nucleo_g431rb.dts @@ -76,12 +76,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pc4 &usart1_rx_pc5>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &lpuart1 { pinctrl-0 = <&lpuart1_tx_pa2 &lpuart1_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_g431rb/nucleo_g431rb_defconfig b/boards/arm/nucleo_g431rb/nucleo_g431rb_defconfig index 0892c157d6494..2bb4d0aa1d7b9 100644 --- a/boards/arm/nucleo_g431rb/nucleo_g431rb_defconfig +++ b/boards/arm/nucleo_g431rb/nucleo_g431rb_defconfig @@ -24,3 +24,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_g474re/nucleo_g474re.dts b/boards/arm/nucleo_g474re/nucleo_g474re.dts index 0ad600a7f58b9..9774250940f51 100644 --- a/boards/arm/nucleo_g474re/nucleo_g474re.dts +++ b/boards/arm/nucleo_g474re/nucleo_g474re.dts @@ -77,12 +77,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pc4 &usart1_rx_pc5>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &lpuart1 { pinctrl-0 = <&lpuart1_tx_pa2 &lpuart1_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_g474re/nucleo_g474re_defconfig b/boards/arm/nucleo_g474re/nucleo_g474re_defconfig index 12a32c0c2433a..d112c11602c0a 100644 --- a/boards/arm/nucleo_g474re/nucleo_g474re_defconfig +++ b/boards/arm/nucleo_g474re/nucleo_g474re_defconfig @@ -24,3 +24,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_h723zg/nucleo_h723zg.dts b/boards/arm/nucleo_h723zg/nucleo_h723zg.dts index 116a34d529ccc..7152f99b7dc12 100644 --- a/boards/arm/nucleo_h723zg/nucleo_h723zg.dts +++ b/boards/arm/nucleo_h723zg/nucleo_h723zg.dts @@ -91,12 +91,14 @@ &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pd5 &usart2_rx_pd6>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_h723zg/nucleo_h723zg_defconfig b/boards/arm/nucleo_h723zg/nucleo_h723zg_defconfig index ada15918faefb..4099c71cfa968 100644 --- a/boards/arm/nucleo_h723zg/nucleo_h723zg_defconfig +++ b/boards/arm/nucleo_h723zg/nucleo_h723zg_defconfig @@ -26,3 +26,6 @@ CONFIG_GPIO=y # Enable Clock CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_h743zi/nucleo_h743zi.dts b/boards/arm/nucleo_h743zi/nucleo_h743zi.dts index 372e121bae998..7efba0e136766 100644 --- a/boards/arm/nucleo_h743zi/nucleo_h743zi.dts +++ b/boards/arm/nucleo_h743zi/nucleo_h743zi.dts @@ -87,6 +87,7 @@ &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_h743zi/nucleo_h743zi_defconfig b/boards/arm/nucleo_h743zi/nucleo_h743zi_defconfig index fb77550d72855..4d5b0a1ec9a7f 100644 --- a/boards/arm/nucleo_h743zi/nucleo_h743zi_defconfig +++ b/boards/arm/nucleo_h743zi/nucleo_h743zi_defconfig @@ -24,3 +24,6 @@ CONFIG_GPIO=y # Enable clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m4.dts b/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m4.dts index 9eec31c4d7870..d4de60053acfd 100644 --- a/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m4.dts +++ b/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m4.dts @@ -27,6 +27,7 @@ &uart8 { pinctrl-0 = <&uart8_tx_pe1 &uart8_rx_pe0>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m4_defconfig b/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m4_defconfig index 86ede150076fb..220a69aeecbc7 100644 --- a/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m4_defconfig +++ b/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m4_defconfig @@ -23,3 +23,6 @@ CONFIG_CLOCK_CONTROL=y # Console #CONFIG_CONSOLE=y #CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m7.dts b/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m7.dts index 88fbf85b4cba2..6cb3af70b3721 100644 --- a/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m7.dts +++ b/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m7.dts @@ -68,6 +68,7 @@ &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m7_defconfig b/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m7_defconfig index d88458070e3d4..f96d095dbac8f 100644 --- a/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m7_defconfig +++ b/boards/arm/nucleo_h745zi_q/nucleo_h745zi_q_m7_defconfig @@ -27,3 +27,6 @@ CONFIG_GPIO=y # Enable Clock CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_h753zi/nucleo_h753zi.dts b/boards/arm/nucleo_h753zi/nucleo_h753zi.dts index 484466320a693..b694e601b0637 100644 --- a/boards/arm/nucleo_h753zi/nucleo_h753zi.dts +++ b/boards/arm/nucleo_h753zi/nucleo_h753zi.dts @@ -87,6 +87,7 @@ &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_h753zi/nucleo_h753zi_defconfig b/boards/arm/nucleo_h753zi/nucleo_h753zi_defconfig index 11649d95eb740..2385793223e9c 100644 --- a/boards/arm/nucleo_h753zi/nucleo_h753zi_defconfig +++ b/boards/arm/nucleo_h753zi/nucleo_h753zi_defconfig @@ -24,3 +24,6 @@ CONFIG_GPIO=y # Enable clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l011k4/nucleo_l011k4.dts b/boards/arm/nucleo_l011k4/nucleo_l011k4.dts index 949b99e2abd9e..46493a3942d66 100644 --- a/boards/arm/nucleo_l011k4/nucleo_l011k4.dts +++ b/boards/arm/nucleo_l011k4/nucleo_l011k4.dts @@ -62,6 +62,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa15>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_l011k4/nucleo_l011k4_defconfig b/boards/arm/nucleo_l011k4/nucleo_l011k4_defconfig index 2c0c8c38f324d..e89020b345db9 100644 --- a/boards/arm/nucleo_l011k4/nucleo_l011k4_defconfig +++ b/boards/arm/nucleo_l011k4/nucleo_l011k4_defconfig @@ -26,3 +26,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l031k6/nucleo_l031k6.dts b/boards/arm/nucleo_l031k6/nucleo_l031k6.dts index 8a8fd80a097f9..a8708695a3057 100644 --- a/boards/arm/nucleo_l031k6/nucleo_l031k6.dts +++ b/boards/arm/nucleo_l031k6/nucleo_l031k6.dts @@ -54,6 +54,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa15>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_l031k6/nucleo_l031k6_defconfig b/boards/arm/nucleo_l031k6/nucleo_l031k6_defconfig index 0a9f04d0540a4..5ddd36521b124 100644 --- a/boards/arm/nucleo_l031k6/nucleo_l031k6_defconfig +++ b/boards/arm/nucleo_l031k6/nucleo_l031k6_defconfig @@ -26,3 +26,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l053r8/nucleo_l053r8.dts b/boards/arm/nucleo_l053r8/nucleo_l053r8.dts index 9f6a3ec3b6820..51c334e166be6 100644 --- a/boards/arm/nucleo_l053r8/nucleo_l053r8.dts +++ b/boards/arm/nucleo_l053r8/nucleo_l053r8.dts @@ -71,11 +71,13 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_l053r8/nucleo_l053r8_defconfig b/boards/arm/nucleo_l053r8/nucleo_l053r8_defconfig index 76c1dfaa0b820..4ce09c75e9149 100644 --- a/boards/arm/nucleo_l053r8/nucleo_l053r8_defconfig +++ b/boards/arm/nucleo_l053r8/nucleo_l053r8_defconfig @@ -29,3 +29,6 @@ CONFIG_GPIO=y # Clock controller CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l073rz/nucleo_l073rz.dts b/boards/arm/nucleo_l073rz/nucleo_l073rz.dts index dcd82463df284..3b3a5793f5649 100644 --- a/boards/arm/nucleo_l073rz/nucleo_l073rz.dts +++ b/boards/arm/nucleo_l073rz/nucleo_l073rz.dts @@ -65,11 +65,13 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_l073rz/nucleo_l073rz_defconfig b/boards/arm/nucleo_l073rz/nucleo_l073rz_defconfig index c4bfc0de575d9..468f01732586a 100644 --- a/boards/arm/nucleo_l073rz/nucleo_l073rz_defconfig +++ b/boards/arm/nucleo_l073rz/nucleo_l073rz_defconfig @@ -24,3 +24,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l152re/nucleo_l152re.dts b/boards/arm/nucleo_l152re/nucleo_l152re.dts index 16829e34a2491..4eb26d52e8aea 100644 --- a/boards/arm/nucleo_l152re/nucleo_l152re.dts +++ b/boards/arm/nucleo_l152re/nucleo_l152re.dts @@ -64,6 +64,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_l152re/nucleo_l152re_defconfig b/boards/arm/nucleo_l152re/nucleo_l152re_defconfig index c21674daae02f..61e29487c4637 100644 --- a/boards/arm/nucleo_l152re/nucleo_l152re_defconfig +++ b/boards/arm/nucleo_l152re/nucleo_l152re_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l412rb_p/nucleo_l412rb_p.dts b/boards/arm/nucleo_l412rb_p/nucleo_l412rb_p.dts index 2da96cd176068..01c825359f6c4 100644 --- a/boards/arm/nucleo_l412rb_p/nucleo_l412rb_p.dts +++ b/boards/arm/nucleo_l412rb_p/nucleo_l412rb_p.dts @@ -65,12 +65,14 @@ &lpuart1 { pinctrl-0 = <&lpuart1_tx_pa2 &lpuart1_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; }; diff --git a/boards/arm/nucleo_l412rb_p/nucleo_l412rb_p_defconfig b/boards/arm/nucleo_l412rb_p/nucleo_l412rb_p_defconfig index 3477183dbe2ef..eebfc4d25e5b8 100644 --- a/boards/arm/nucleo_l412rb_p/nucleo_l412rb_p_defconfig +++ b/boards/arm/nucleo_l412rb_p/nucleo_l412rb_p_defconfig @@ -24,3 +24,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l432kc/nucleo_l432kc.dts b/boards/arm/nucleo_l432kc/nucleo_l432kc.dts index 4219402365a33..01a4316db72c3 100644 --- a/boards/arm/nucleo_l432kc/nucleo_l432kc.dts +++ b/boards/arm/nucleo_l432kc/nucleo_l432kc.dts @@ -57,11 +57,13 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa15>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_l432kc/nucleo_l432kc_defconfig b/boards/arm/nucleo_l432kc/nucleo_l432kc_defconfig index 8f54532c758b6..384549fd45871 100644 --- a/boards/arm/nucleo_l432kc/nucleo_l432kc_defconfig +++ b/boards/arm/nucleo_l432kc/nucleo_l432kc_defconfig @@ -24,3 +24,6 @@ CONFIG_CLOCK_CONTROL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l433rc_p/nucleo_l433rc_p.dts b/boards/arm/nucleo_l433rc_p/nucleo_l433rc_p.dts index 7c922b1d959f0..fead8ac858065 100644 --- a/boards/arm/nucleo_l433rc_p/nucleo_l433rc_p.dts +++ b/boards/arm/nucleo_l433rc_p/nucleo_l433rc_p.dts @@ -67,12 +67,14 @@ &lpuart1 { pinctrl-0 = <&lpuart1_tx_pa2 &lpuart1_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; }; diff --git a/boards/arm/nucleo_l433rc_p/nucleo_l433rc_p_defconfig b/boards/arm/nucleo_l433rc_p/nucleo_l433rc_p_defconfig index e936235d26162..5d3c1bf4637c2 100644 --- a/boards/arm/nucleo_l433rc_p/nucleo_l433rc_p_defconfig +++ b/boards/arm/nucleo_l433rc_p/nucleo_l433rc_p_defconfig @@ -24,3 +24,6 @@ CONFIG_CLOCK_CONTROL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l452re/nucleo_l452re_defconfig b/boards/arm/nucleo_l452re/nucleo_l452re_defconfig index ceeb7347825c3..4b3acdcf31ba0 100644 --- a/boards/arm/nucleo_l452re/nucleo_l452re_defconfig +++ b/boards/arm/nucleo_l452re/nucleo_l452re_defconfig @@ -24,3 +24,6 @@ CONFIG_CLOCK_CONTROL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l452re/nucleo_l452re_p_defconfig b/boards/arm/nucleo_l452re/nucleo_l452re_p_defconfig index ceeb7347825c3..4b3acdcf31ba0 100644 --- a/boards/arm/nucleo_l452re/nucleo_l452re_p_defconfig +++ b/boards/arm/nucleo_l452re/nucleo_l452re_p_defconfig @@ -24,3 +24,6 @@ CONFIG_CLOCK_CONTROL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l476rg/nucleo_l476rg.dts b/boards/arm/nucleo_l476rg/nucleo_l476rg.dts index f57619020443f..26b9aed16b98c 100644 --- a/boards/arm/nucleo_l476rg/nucleo_l476rg.dts +++ b/boards/arm/nucleo_l476rg/nucleo_l476rg.dts @@ -89,18 +89,21 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb11>; + pinctrl-names = "default"; current-speed = <115200>; }; diff --git a/boards/arm/nucleo_l476rg/nucleo_l476rg_defconfig b/boards/arm/nucleo_l476rg/nucleo_l476rg_defconfig index 5e4bba5f31485..2e6726e56789d 100644 --- a/boards/arm/nucleo_l476rg/nucleo_l476rg_defconfig +++ b/boards/arm/nucleo_l476rg/nucleo_l476rg_defconfig @@ -24,3 +24,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l496zg/nucleo_l496zg.dts b/boards/arm/nucleo_l496zg/nucleo_l496zg.dts index aa38dd3b6d446..6b0d43379a2b7 100644 --- a/boards/arm/nucleo_l496zg/nucleo_l496zg.dts +++ b/boards/arm/nucleo_l496zg/nucleo_l496zg.dts @@ -85,6 +85,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pd5 &usart2_rx_pd6>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; @@ -96,6 +97,7 @@ &lpuart1 { pinctrl-0 = <&lpuart1_tx_pg7 &lpuart1_rx_pg8>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_l496zg/nucleo_l496zg_defconfig b/boards/arm/nucleo_l496zg/nucleo_l496zg_defconfig index f0e9a804c7546..802c5c566e2c0 100644 --- a/boards/arm/nucleo_l496zg/nucleo_l496zg_defconfig +++ b/boards/arm/nucleo_l496zg/nucleo_l496zg_defconfig @@ -24,3 +24,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l4r5zi/nucleo_l4r5zi.dts b/boards/arm/nucleo_l4r5zi/nucleo_l4r5zi.dts index c1ca305bf8017..b99b0a88a1624 100644 --- a/boards/arm/nucleo_l4r5zi/nucleo_l4r5zi.dts +++ b/boards/arm/nucleo_l4r5zi/nucleo_l4r5zi.dts @@ -78,24 +78,28 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &lpuart1 { pinctrl-0 = <&lpuart1_tx_pg7 &lpuart1_rx_pg8>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_l4r5zi/nucleo_l4r5zi_defconfig b/boards/arm/nucleo_l4r5zi/nucleo_l4r5zi_defconfig index 8719d09a17888..efe07f0ca1de3 100644 --- a/boards/arm/nucleo_l4r5zi/nucleo_l4r5zi_defconfig +++ b/boards/arm/nucleo_l4r5zi/nucleo_l4r5zi_defconfig @@ -24,3 +24,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q.dts b/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q.dts index d9f0ed693438a..fa9fe350391b3 100644 --- a/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q.dts +++ b/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q.dts @@ -29,6 +29,7 @@ &lpuart1 { pinctrl-0 = <&lpuart1_tx_pg7 &lpuart1_rx_pg8>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q_defconfig b/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q_defconfig index a8cfbb0fd0fce..ebb518d055f7a 100644 --- a/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q_defconfig +++ b/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q_defconfig @@ -24,3 +24,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q_ns_defconfig b/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q_ns_defconfig index 10441298bfe66..e94204fe11dd7 100644 --- a/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q_ns_defconfig +++ b/boards/arm/nucleo_l552ze_q/nucleo_l552ze_q_ns_defconfig @@ -25,3 +25,6 @@ CONFIG_ARM_MPU=y CONFIG_ARM_TRUSTZONE_M=y CONFIG_RUNTIME_NMI=y CONFIG_TRUSTED_EXECUTION_NONSECURE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_u575zi_q/nucleo_u575zi_q.dts b/boards/arm/nucleo_u575zi_q/nucleo_u575zi_q.dts index 3557bd2c4e446..e7cddaf56ba41 100644 --- a/boards/arm/nucleo_u575zi_q/nucleo_u575zi_q.dts +++ b/boards/arm/nucleo_u575zi_q/nucleo_u575zi_q.dts @@ -29,6 +29,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_u575zi_q/nucleo_u575zi_q_defconfig b/boards/arm/nucleo_u575zi_q/nucleo_u575zi_q_defconfig index b5656b326af5f..a5280ef17f3b0 100644 --- a/boards/arm/nucleo_u575zi_q/nucleo_u575zi_q_defconfig +++ b/boards/arm/nucleo_u575zi_q/nucleo_u575zi_q_defconfig @@ -24,3 +24,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_wb55rg/nucleo_wb55rg.dts b/boards/arm/nucleo_wb55rg/nucleo_wb55rg.dts index b8122d6c1754b..e49a6655dcf96 100644 --- a/boards/arm/nucleo_wb55rg/nucleo_wb55rg.dts +++ b/boards/arm/nucleo_wb55rg/nucleo_wb55rg.dts @@ -107,6 +107,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; @@ -153,6 +154,7 @@ &lpuart1 { pinctrl-0 = <&lpuart1_tx_pa2 &lpuart1_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_wb55rg/nucleo_wb55rg_defconfig b/boards/arm/nucleo_wb55rg/nucleo_wb55rg_defconfig index 0095b6c1c3a5c..be154814f2811 100644 --- a/boards/arm/nucleo_wb55rg/nucleo_wb55rg_defconfig +++ b/boards/arm/nucleo_wb55rg/nucleo_wb55rg_defconfig @@ -22,3 +22,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/nucleo_wl55jc/nucleo_wl55jc.dts b/boards/arm/nucleo_wl55jc/nucleo_wl55jc.dts index 6863d7bed96ed..9303c5679a8b8 100644 --- a/boards/arm/nucleo_wl55jc/nucleo_wl55jc.dts +++ b/boards/arm/nucleo_wl55jc/nucleo_wl55jc.dts @@ -116,6 +116,7 @@ &lpuart1 { pinctrl-0 = <&lpuart1_tx_pa2 &lpuart1_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/nucleo_wl55jc/nucleo_wl55jc_defconfig b/boards/arm/nucleo_wl55jc/nucleo_wl55jc_defconfig index 460684e7c11f1..bf6638bbbee68 100644 --- a/boards/arm/nucleo_wl55jc/nucleo_wl55jc_defconfig +++ b/boards/arm/nucleo_wl55jc/nucleo_wl55jc_defconfig @@ -22,3 +22,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/olimex_stm32_e407/olimex_stm32_e407.dts b/boards/arm/olimex_stm32_e407/olimex_stm32_e407.dts index d69a679b0b6b2..4b38fc704b825 100644 --- a/boards/arm/olimex_stm32_e407/olimex_stm32_e407.dts +++ b/boards/arm/olimex_stm32_e407/olimex_stm32_e407.dts @@ -66,18 +66,21 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb11>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pc6 &usart6_rx_pc7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/olimex_stm32_e407/olimex_stm32_e407_defconfig b/boards/arm/olimex_stm32_e407/olimex_stm32_e407_defconfig index 984563e2cd9ef..9f6691812318a 100644 --- a/boards/arm/olimex_stm32_e407/olimex_stm32_e407_defconfig +++ b/boards/arm/olimex_stm32_e407/olimex_stm32_e407_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/olimex_stm32_h103/olimex_stm32_h103.dts b/boards/arm/olimex_stm32_h103/olimex_stm32_h103.dts index 056cc6d247dc9..f404dcfca3890 100644 --- a/boards/arm/olimex_stm32_h103/olimex_stm32_h103.dts +++ b/boards/arm/olimex_stm32_h103/olimex_stm32_h103.dts @@ -61,18 +61,21 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pc10 &usart3_rx_pc11>; + pinctrl-names = "default"; current-speed = <115200>; }; diff --git a/boards/arm/olimex_stm32_h103/olimex_stm32_h103_defconfig b/boards/arm/olimex_stm32_h103/olimex_stm32_h103_defconfig index 251368bce5fbb..65cf63ebfa972 100644 --- a/boards/arm/olimex_stm32_h103/olimex_stm32_h103_defconfig +++ b/boards/arm/olimex_stm32_h103/olimex_stm32_h103_defconfig @@ -17,3 +17,6 @@ CONFIG_GPIO=y # enable clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/olimex_stm32_h407/olimex_stm32_h407.dts b/boards/arm/olimex_stm32_h407/olimex_stm32_h407.dts index b77f965a69500..b7d8c89fb8cb1 100644 --- a/boards/arm/olimex_stm32_h407/olimex_stm32_h407.dts +++ b/boards/arm/olimex_stm32_h407/olimex_stm32_h407.dts @@ -66,18 +66,21 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb11>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pc6 &usart6_rx_pc7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/olimex_stm32_h407/olimex_stm32_h407_defconfig b/boards/arm/olimex_stm32_h407/olimex_stm32_h407_defconfig index 984563e2cd9ef..9f6691812318a 100644 --- a/boards/arm/olimex_stm32_h407/olimex_stm32_h407_defconfig +++ b/boards/arm/olimex_stm32_h407/olimex_stm32_h407_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/olimex_stm32_p405/olimex_stm32_p405.dts b/boards/arm/olimex_stm32_p405/olimex_stm32_p405.dts index 2f5882fb2573f..879d5b8a13025 100644 --- a/boards/arm/olimex_stm32_p405/olimex_stm32_p405.dts +++ b/boards/arm/olimex_stm32_p405/olimex_stm32_p405.dts @@ -67,6 +67,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/olimex_stm32_p405/olimex_stm32_p405_defconfig b/boards/arm/olimex_stm32_p405/olimex_stm32_p405_defconfig index e6773b619ed9c..c998d7f99fb61 100644 --- a/boards/arm/olimex_stm32_p405/olimex_stm32_p405_defconfig +++ b/boards/arm/olimex_stm32_p405/olimex_stm32_p405_defconfig @@ -25,3 +25,6 @@ CONFIG_GPIO=y CONFIG_CLOCK_CONTROL=y CONFIG_ENTROPY_GENERATOR=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/olimexino_stm32/olimexino_stm32.dts b/boards/arm/olimexino_stm32/olimexino_stm32.dts index c06d22cb14047..9d0a53cd2a32f 100644 --- a/boards/arm/olimexino_stm32/olimexino_stm32.dts +++ b/boards/arm/olimexino_stm32/olimexino_stm32.dts @@ -72,17 +72,20 @@ uext_serial: &usart1 {}; &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; }; &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb11>; + pinctrl-names = "default"; current-speed = <115200>; }; diff --git a/boards/arm/olimexino_stm32/olimexino_stm32_defconfig b/boards/arm/olimexino_stm32/olimexino_stm32_defconfig index cb38d407d605c..fa8fcba8a603a 100644 --- a/boards/arm/olimexino_stm32/olimexino_stm32_defconfig +++ b/boards/arm/olimexino_stm32/olimexino_stm32_defconfig @@ -24,3 +24,6 @@ CONFIG_GPIO=y # enable clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/ronoth_lodev/ronoth_lodev_defconfig b/boards/arm/ronoth_lodev/ronoth_lodev_defconfig index eb42f9c29b0c0..0bb04c2749531 100644 --- a/boards/arm/ronoth_lodev/ronoth_lodev_defconfig +++ b/boards/arm/ronoth_lodev/ronoth_lodev_defconfig @@ -26,3 +26,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/segger_trb_stm32f407/segger_trb_stm32f407_defconfig b/boards/arm/segger_trb_stm32f407/segger_trb_stm32f407_defconfig index c7ab6953785fb..0938e7b20493f 100644 --- a/boards/arm/segger_trb_stm32f407/segger_trb_stm32f407_defconfig +++ b/boards/arm/segger_trb_stm32f407/segger_trb_stm32f407_defconfig @@ -24,3 +24,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/sensortile_box/sensortile_box.dts b/boards/arm/sensortile_box/sensortile_box.dts index ae8c92c907d9a..1cc579da562d1 100644 --- a/boards/arm/sensortile_box/sensortile_box.dts +++ b/boards/arm/sensortile_box/sensortile_box.dts @@ -72,12 +72,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/sensortile_box/sensortile_box_defconfig b/boards/arm/sensortile_box/sensortile_box_defconfig index 8536a048c9e68..6dec55705b859 100644 --- a/boards/arm/sensortile_box/sensortile_box_defconfig +++ b/boards/arm/sensortile_box/sensortile_box_defconfig @@ -24,3 +24,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/steval_fcu001v1/steval_fcu001v1.dts b/boards/arm/steval_fcu001v1/steval_fcu001v1.dts index c6a9c1e491f57..9491ed357ec4d 100644 --- a/boards/arm/steval_fcu001v1/steval_fcu001v1.dts +++ b/boards/arm/steval_fcu001v1/steval_fcu001v1.dts @@ -68,6 +68,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/steval_fcu001v1/steval_fcu001v1_defconfig b/boards/arm/steval_fcu001v1/steval_fcu001v1_defconfig index be285322bbb60..4d204f93a3747 100644 --- a/boards/arm/steval_fcu001v1/steval_fcu001v1_defconfig +++ b/boards/arm/steval_fcu001v1/steval_fcu001v1_defconfig @@ -20,3 +20,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm3210c_eval/stm3210c_eval.dts b/boards/arm/stm3210c_eval/stm3210c_eval.dts index baa0b2359b41a..15942f60a4912 100644 --- a/boards/arm/stm3210c_eval/stm3210c_eval.dts +++ b/boards/arm/stm3210c_eval/stm3210c_eval.dts @@ -64,6 +64,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pd5 &usart2_rx_pd6>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm3210c_eval/stm3210c_eval_defconfig b/boards/arm/stm3210c_eval/stm3210c_eval_defconfig index d9d84620bf4bb..b964746fab5db 100644 --- a/boards/arm/stm3210c_eval/stm3210c_eval_defconfig +++ b/boards/arm/stm3210c_eval/stm3210c_eval_defconfig @@ -21,3 +21,6 @@ CONFIG_GPIO=y # RCC Controller CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32373c_eval/stm32373c_eval.dts b/boards/arm/stm32373c_eval/stm32373c_eval.dts index fa03fae4ce8c6..62426f31af0c8 100644 --- a/boards/arm/stm32373c_eval/stm32373c_eval.dts +++ b/boards/arm/stm32373c_eval/stm32373c_eval.dts @@ -63,6 +63,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pd5 &usart2_rx_pd6>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32373c_eval/stm32373c_eval_defconfig b/boards/arm/stm32373c_eval/stm32373c_eval_defconfig index dad51767bb5ee..0e6ee5a5eb0f4 100644 --- a/boards/arm/stm32373c_eval/stm32373c_eval_defconfig +++ b/boards/arm/stm32373c_eval/stm32373c_eval_defconfig @@ -30,3 +30,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32_min_dev/stm32_min_dev_black_defconfig b/boards/arm/stm32_min_dev/stm32_min_dev_black_defconfig index abd1788c783de..4cf7584024ba7 100644 --- a/boards/arm/stm32_min_dev/stm32_min_dev_black_defconfig +++ b/boards/arm/stm32_min_dev/stm32_min_dev_black_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # enable clock control CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32_min_dev/stm32_min_dev_blue_defconfig b/boards/arm/stm32_min_dev/stm32_min_dev_blue_defconfig index af3dbaea08e02..e7c4958da588e 100644 --- a/boards/arm/stm32_min_dev/stm32_min_dev_blue_defconfig +++ b/boards/arm/stm32_min_dev/stm32_min_dev_blue_defconfig @@ -18,3 +18,6 @@ CONFIG_GPIO=y # enable clock control CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f030_demo/stm32f030_demo.dts b/boards/arm/stm32f030_demo/stm32f030_demo.dts index b5e3a6962e1e6..465898cf30c2a 100644 --- a/boards/arm/stm32f030_demo/stm32f030_demo.dts +++ b/boards/arm/stm32f030_demo/stm32f030_demo.dts @@ -58,6 +58,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f030_demo/stm32f030_demo_defconfig b/boards/arm/stm32f030_demo/stm32f030_demo_defconfig index 3648606e10b46..1ccd20f529c06 100644 --- a/boards/arm/stm32f030_demo/stm32f030_demo_defconfig +++ b/boards/arm/stm32f030_demo/stm32f030_demo_defconfig @@ -28,3 +28,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f072_eval/stm32f072_eval.dts b/boards/arm/stm32f072_eval/stm32f072_eval.dts index cfe8f2f599ad1..853f61ce4759b 100644 --- a/boards/arm/stm32f072_eval/stm32f072_eval.dts +++ b/boards/arm/stm32f072_eval/stm32f072_eval.dts @@ -97,6 +97,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pd5 &usart2_rx_pd6>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f072_eval/stm32f072_eval_defconfig b/boards/arm/stm32f072_eval/stm32f072_eval_defconfig index f35b5705f4ebe..3174cbb377f22 100644 --- a/boards/arm/stm32f072_eval/stm32f072_eval_defconfig +++ b/boards/arm/stm32f072_eval/stm32f072_eval_defconfig @@ -21,3 +21,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f072b_disco/stm32f072b_disco.dts b/boards/arm/stm32f072b_disco/stm32f072b_disco.dts index d699b0220cd48..23db6159ef690 100644 --- a/boards/arm/stm32f072b_disco/stm32f072b_disco.dts +++ b/boards/arm/stm32f072b_disco/stm32f072b_disco.dts @@ -77,6 +77,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f072b_disco/stm32f072b_disco_defconfig b/boards/arm/stm32f072b_disco/stm32f072b_disco_defconfig index f35b5705f4ebe..3174cbb377f22 100644 --- a/boards/arm/stm32f072b_disco/stm32f072b_disco_defconfig +++ b/boards/arm/stm32f072b_disco/stm32f072b_disco_defconfig @@ -21,3 +21,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f0_disco/stm32f0_disco.dts b/boards/arm/stm32f0_disco/stm32f0_disco.dts index bd0273c9eba68..d8c9ea041cbfc 100644 --- a/boards/arm/stm32f0_disco/stm32f0_disco.dts +++ b/boards/arm/stm32f0_disco/stm32f0_disco.dts @@ -72,12 +72,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f0_disco/stm32f0_disco_defconfig b/boards/arm/stm32f0_disco/stm32f0_disco_defconfig index b2c7db6abec0c..310a3446058ee 100644 --- a/boards/arm/stm32f0_disco/stm32f0_disco_defconfig +++ b/boards/arm/stm32f0_disco/stm32f0_disco_defconfig @@ -28,3 +28,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f103_mini/stm32f103_mini.dts b/boards/arm/stm32f103_mini/stm32f103_mini.dts index 368682d1d9e0b..78a8b70c22f27 100644 --- a/boards/arm/stm32f103_mini/stm32f103_mini.dts +++ b/boards/arm/stm32f103_mini/stm32f103_mini.dts @@ -53,17 +53,20 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; }; &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb11>; + pinctrl-names = "default"; current-speed = <115200>; }; diff --git a/boards/arm/stm32f103_mini/stm32f103_mini_defconfig b/boards/arm/stm32f103_mini/stm32f103_mini_defconfig index e86eadbf22bbb..1ac0bc938422e 100644 --- a/boards/arm/stm32f103_mini/stm32f103_mini_defconfig +++ b/boards/arm/stm32f103_mini/stm32f103_mini_defconfig @@ -17,3 +17,6 @@ CONFIG_GPIO=y # enable clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f3_disco/stm32f3_disco.dts b/boards/arm/stm32f3_disco/stm32f3_disco.dts index 3c7a7e27ce168..582a3bc3d1c13 100644 --- a/boards/arm/stm32f3_disco/stm32f3_disco.dts +++ b/boards/arm/stm32f3_disco/stm32f3_disco.dts @@ -94,12 +94,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pc4 &usart1_rx_pc5>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f3_disco/stm32f3_disco_defconfig b/boards/arm/stm32f3_disco/stm32f3_disco_defconfig index 053239205af46..b4d28c9296d46 100644 --- a/boards/arm/stm32f3_disco/stm32f3_disco_defconfig +++ b/boards/arm/stm32f3_disco/stm32f3_disco_defconfig @@ -27,3 +27,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f411e_disco/stm32f411e_disco.dts b/boards/arm/stm32f411e_disco/stm32f411e_disco.dts index 8e3ef8c276bfa..46d96ef36dfc8 100644 --- a/boards/arm/stm32f411e_disco/stm32f411e_disco.dts +++ b/boards/arm/stm32f411e_disco/stm32f411e_disco.dts @@ -136,6 +136,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f411e_disco/stm32f411e_disco_defconfig b/boards/arm/stm32f411e_disco/stm32f411e_disco_defconfig index c3678dd5e19b6..1e0ba3fc67b21 100644 --- a/boards/arm/stm32f411e_disco/stm32f411e_disco_defconfig +++ b/boards/arm/stm32f411e_disco/stm32f411e_disco_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f412g_disco/stm32f412g_disco.dts b/boards/arm/stm32f412g_disco/stm32f412g_disco.dts index 94b9c552e7e84..b81974982ce89 100644 --- a/boards/arm/stm32f412g_disco/stm32f412g_disco.dts +++ b/boards/arm/stm32f412g_disco/stm32f412g_disco.dts @@ -98,12 +98,14 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pg9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f412g_disco/stm32f412g_disco_defconfig b/boards/arm/stm32f412g_disco/stm32f412g_disco_defconfig index efc980c8789e2..1b6bc70e866e6 100644 --- a/boards/arm/stm32f412g_disco/stm32f412g_disco_defconfig +++ b/boards/arm/stm32f412g_disco/stm32f412g_disco_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f429i_disc1/stm32f429i_disc1.dts b/boards/arm/stm32f429i_disc1/stm32f429i_disc1.dts index 412af74b0ce0e..944738582dd1e 100644 --- a/boards/arm/stm32f429i_disc1/stm32f429i_disc1.dts +++ b/boards/arm/stm32f429i_disc1/stm32f429i_disc1.dts @@ -75,6 +75,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f429i_disc1/stm32f429i_disc1_defconfig b/boards/arm/stm32f429i_disc1/stm32f429i_disc1_defconfig index 2d0275f88bddb..e3812091e1c1a 100644 --- a/boards/arm/stm32f429i_disc1/stm32f429i_disc1_defconfig +++ b/boards/arm/stm32f429i_disc1/stm32f429i_disc1_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f469i_disco/stm32f469i_disco.dts b/boards/arm/stm32f469i_disco/stm32f469i_disco.dts index 5d78a8cd1a68a..d861eab1cfaab 100644 --- a/boards/arm/stm32f469i_disco/stm32f469i_disco.dts +++ b/boards/arm/stm32f469i_disco/stm32f469i_disco.dts @@ -82,12 +82,14 @@ &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb11>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pg9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f469i_disco/stm32f469i_disco_defconfig b/boards/arm/stm32f469i_disco/stm32f469i_disco_defconfig index 9b20e78fa204d..9f20462225b1c 100644 --- a/boards/arm/stm32f469i_disco/stm32f469i_disco_defconfig +++ b/boards/arm/stm32f469i_disco/stm32f469i_disco_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f4_disco/stm32f4_disco.dts b/boards/arm/stm32f4_disco/stm32f4_disco.dts index f8b9f8da348ef..552c1e1c460d3 100644 --- a/boards/arm/stm32f4_disco/stm32f4_disco.dts +++ b/boards/arm/stm32f4_disco/stm32f4_disco.dts @@ -60,6 +60,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; @@ -88,6 +89,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f4_disco/stm32f4_disco_defconfig b/boards/arm/stm32f4_disco/stm32f4_disco_defconfig index 984563e2cd9ef..9f6691812318a 100644 --- a/boards/arm/stm32f4_disco/stm32f4_disco_defconfig +++ b/boards/arm/stm32f4_disco/stm32f4_disco_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f723e_disco/stm32f723e_disco.dts b/boards/arm/stm32f723e_disco/stm32f723e_disco.dts index d93265a16fe1a..0161306eb22c4 100644 --- a/boards/arm/stm32f723e_disco/stm32f723e_disco.dts +++ b/boards/arm/stm32f723e_disco/stm32f723e_disco.dts @@ -76,12 +76,14 @@ &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pc6 &usart6_rx_pc7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f723e_disco/stm32f723e_disco_defconfig b/boards/arm/stm32f723e_disco/stm32f723e_disco_defconfig index 14ef250b8d19b..e6ecbaf299ef7 100644 --- a/boards/arm/stm32f723e_disco/stm32f723e_disco_defconfig +++ b/boards/arm/stm32f723e_disco/stm32f723e_disco_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f746g_disco/stm32f746g_disco.dts b/boards/arm/stm32f746g_disco/stm32f746g_disco.dts index eeb16f7b65079..30e6056d62797 100644 --- a/boards/arm/stm32f746g_disco/stm32f746g_disco.dts +++ b/boards/arm/stm32f746g_disco/stm32f746g_disco.dts @@ -94,12 +94,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pc6 &usart6_rx_pc7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f746g_disco/stm32f746g_disco_defconfig b/boards/arm/stm32f746g_disco/stm32f746g_disco_defconfig index 1a5d7094fb118..cff0a3dfadeb5 100644 --- a/boards/arm/stm32f746g_disco/stm32f746g_disco_defconfig +++ b/boards/arm/stm32f746g_disco/stm32f746g_disco_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32f769i_disco/stm32f769i_disco.dts b/boards/arm/stm32f769i_disco/stm32f769i_disco.dts index 22f8bbda51ce5..9b80969280302 100644 --- a/boards/arm/stm32f769i_disco/stm32f769i_disco.dts +++ b/boards/arm/stm32f769i_disco/stm32f769i_disco.dts @@ -87,12 +87,14 @@ arduino_serial: &usart6 {}; &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart6 { pinctrl-0 = <&usart6_tx_pc6 &usart6_rx_pc7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32f769i_disco/stm32f769i_disco_defconfig b/boards/arm/stm32f769i_disco/stm32f769i_disco_defconfig index ac676424d1f03..aa72bc21ef6a7 100644 --- a/boards/arm/stm32f769i_disco/stm32f769i_disco_defconfig +++ b/boards/arm/stm32f769i_disco/stm32f769i_disco_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32g0316_disco/stm32g0316_disco.dts b/boards/arm/stm32g0316_disco/stm32g0316_disco.dts index 1e9d8b48912fd..24e3754d3d4e5 100644 --- a/boards/arm/stm32g0316_disco/stm32g0316_disco.dts +++ b/boards/arm/stm32g0316_disco/stm32g0316_disco.dts @@ -68,6 +68,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pb7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32g0316_disco/stm32g0316_disco_defconfig b/boards/arm/stm32g0316_disco/stm32g0316_disco_defconfig index 1d03ce1a7128d..bdc6fe626ca69 100644 --- a/boards/arm/stm32g0316_disco/stm32g0316_disco_defconfig +++ b/boards/arm/stm32g0316_disco/stm32g0316_disco_defconfig @@ -22,3 +22,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32g071b_disco/stm32g071b_disco.dts b/boards/arm/stm32g071b_disco/stm32g071b_disco.dts index 9c2b554be9412..a67d38d11f9eb 100644 --- a/boards/arm/stm32g071b_disco/stm32g071b_disco.dts +++ b/boards/arm/stm32g071b_disco/stm32g071b_disco.dts @@ -99,6 +99,7 @@ &usart3 { pinctrl-0 = <&usart3_tx_pc10 &usart3_rx_pc11>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32g071b_disco/stm32g071b_disco_defconfig b/boards/arm/stm32g071b_disco/stm32g071b_disco_defconfig index 6e2fb1a966c9d..a3d15e96b5459 100644 --- a/boards/arm/stm32g071b_disco/stm32g071b_disco_defconfig +++ b/boards/arm/stm32g071b_disco/stm32g071b_disco_defconfig @@ -21,3 +21,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32h735g_disco/stm32h735g_disco.dts b/boards/arm/stm32h735g_disco/stm32h735g_disco.dts index c09dccd85b31c..f6e61d47cce9c 100644 --- a/boards/arm/stm32h735g_disco/stm32h735g_disco.dts +++ b/boards/arm/stm32h735g_disco/stm32h735g_disco.dts @@ -74,12 +74,14 @@ &usart3 { pinctrl-0 = <&usart3_tx_pd8 &usart3_rx_pd9>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &uart7 { pinctrl-0 = <&uart7_tx_pf7 &uart7_rx_pf6>; + pinctrl-names = "default"; current-speed = <115200>; }; diff --git a/boards/arm/stm32h735g_disco/stm32h735g_disco_defconfig b/boards/arm/stm32h735g_disco/stm32h735g_disco_defconfig index 485f33baef7b0..f7a22eae53be6 100644 --- a/boards/arm/stm32h735g_disco/stm32h735g_disco_defconfig +++ b/boards/arm/stm32h735g_disco/stm32h735g_disco_defconfig @@ -23,3 +23,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32h747i_disco/stm32h747i_disco_m4_defconfig b/boards/arm/stm32h747i_disco/stm32h747i_disco_m4_defconfig index 49e3780ca13d2..fc2fe46ad3c08 100644 --- a/boards/arm/stm32h747i_disco/stm32h747i_disco_m4_defconfig +++ b/boards/arm/stm32h747i_disco/stm32h747i_disco_m4_defconfig @@ -27,3 +27,6 @@ CONFIG_SERIAL=y # By default CONSOLE is assigned to m7 #CONFIG_CONSOLE=y #CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32h747i_disco/stm32h747i_disco_m7_defconfig b/boards/arm/stm32h747i_disco/stm32h747i_disco_m7_defconfig index 9da952ab6ffd8..f4ec9693fd892 100644 --- a/boards/arm/stm32h747i_disco/stm32h747i_disco_m7_defconfig +++ b/boards/arm/stm32h747i_disco/stm32h747i_disco_m7_defconfig @@ -28,3 +28,6 @@ CONFIG_SERIAL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32l1_disco/stm32l1_disco.dts b/boards/arm/stm32l1_disco/stm32l1_disco.dts index f20723095c650..5f9662870d2c0 100644 --- a/boards/arm/stm32l1_disco/stm32l1_disco.dts +++ b/boards/arm/stm32l1_disco/stm32l1_disco.dts @@ -68,18 +68,21 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb11>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32l1_disco/stm32l1_disco_defconfig b/boards/arm/stm32l1_disco/stm32l1_disco_defconfig index 50b83601aafea..0173b5379fcf0 100644 --- a/boards/arm/stm32l1_disco/stm32l1_disco_defconfig +++ b/boards/arm/stm32l1_disco/stm32l1_disco_defconfig @@ -18,3 +18,6 @@ CONFIG_GPIO=y # Enable Clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32l476g_disco/stm32l476g_disco.dts b/boards/arm/stm32l476g_disco/stm32l476g_disco.dts index 6f6b311e6e7fb..ff06524845a4e 100644 --- a/boards/arm/stm32l476g_disco/stm32l476g_disco.dts +++ b/boards/arm/stm32l476g_disco/stm32l476g_disco.dts @@ -89,6 +89,7 @@ &usart2 { pinctrl-0 = <&usart2_tx_pd5 &usart2_rx_pd6>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32l476g_disco/stm32l476g_disco_defconfig b/boards/arm/stm32l476g_disco/stm32l476g_disco_defconfig index f1d5b8011ba4a..973bc710ea054 100644 --- a/boards/arm/stm32l476g_disco/stm32l476g_disco_defconfig +++ b/boards/arm/stm32l476g_disco/stm32l476g_disco_defconfig @@ -24,3 +24,6 @@ CONFIG_CLOCK_CONTROL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32l496g_disco/stm32l496g_disco.dts b/boards/arm/stm32l496g_disco/stm32l496g_disco.dts index dbbee2d0a24dc..42e6fdb6ccb27 100644 --- a/boards/arm/stm32l496g_disco/stm32l496g_disco.dts +++ b/boards/arm/stm32l496g_disco/stm32l496g_disco.dts @@ -87,18 +87,21 @@ &usart1 { pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pg10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pd6>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &lpuart1 { pinctrl-0 = <&lpuart1_tx_pg7 &lpuart1_rx_pg8>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32l496g_disco/stm32l496g_disco_defconfig b/boards/arm/stm32l496g_disco/stm32l496g_disco_defconfig index be068397cfb39..f4dd397919211 100644 --- a/boards/arm/stm32l496g_disco/stm32l496g_disco_defconfig +++ b/boards/arm/stm32l496g_disco/stm32l496g_disco_defconfig @@ -24,3 +24,6 @@ CONFIG_CLOCK_CONTROL=y # console CONFIG_CONSOLE=y CONFIG_UART_CONSOLE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32l562e_dk/stm32l562e_dk.dts b/boards/arm/stm32l562e_dk/stm32l562e_dk.dts index 8bb987504f477..7853cd0641d5f 100644 --- a/boards/arm/stm32l562e_dk/stm32l562e_dk.dts +++ b/boards/arm/stm32l562e_dk/stm32l562e_dk.dts @@ -33,6 +33,7 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; }; &lptim1 { diff --git a/boards/arm/stm32l562e_dk/stm32l562e_dk_defconfig b/boards/arm/stm32l562e_dk/stm32l562e_dk_defconfig index 3b64093e6c88b..6cc3f3b9edefc 100644 --- a/boards/arm/stm32l562e_dk/stm32l562e_dk_defconfig +++ b/boards/arm/stm32l562e_dk/stm32l562e_dk_defconfig @@ -24,3 +24,6 @@ CONFIG_ARM_MPU=y # Enable HW stack protection CONFIG_HW_STACK_PROTECTION=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32l562e_dk/stm32l562e_dk_ns_defconfig b/boards/arm/stm32l562e_dk/stm32l562e_dk_ns_defconfig index 6b9bb5dd413e0..133499a70902a 100644 --- a/boards/arm/stm32l562e_dk/stm32l562e_dk_ns_defconfig +++ b/boards/arm/stm32l562e_dk/stm32l562e_dk_ns_defconfig @@ -25,3 +25,6 @@ CONFIG_ARM_MPU=y CONFIG_ARM_TRUSTZONE_M=y CONFIG_RUNTIME_NMI=y CONFIG_TRUSTED_EXECUTION_NONSECURE=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2.dts b/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2.dts index 1c4b4474e9add..bdbf1c8c03273 100644 --- a/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2.dts +++ b/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2.dts @@ -71,12 +71,14 @@ &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb12>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &uart7 { pinctrl-0 = <&uart7_tx_pe8 &uart7_rx_pe7>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2_defconfig b/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2_defconfig index 9c8d92a3dccd4..12968c1194e13 100644 --- a/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2_defconfig +++ b/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2_defconfig @@ -27,3 +27,6 @@ CONFIG_RAM_CONSOLE_BUFFER_SIZE=1024 # uart console (overrides remote proc console) CONFIG_UART_CONSOLE=n + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/stm32vl_disco/stm32vl_disco.dts b/boards/arm/stm32vl_disco/stm32vl_disco.dts index 6a9d2388dd21d..dc6ae481aa1ce 100644 --- a/boards/arm/stm32vl_disco/stm32vl_disco.dts +++ b/boards/arm/stm32vl_disco/stm32vl_disco.dts @@ -66,18 +66,21 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart3 { pinctrl-0 = <&usart3_tx_pb10 &usart3_rx_pb11>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/stm32vl_disco/stm32vl_disco_defconfig b/boards/arm/stm32vl_disco/stm32vl_disco_defconfig index a0604379f5527..8c59a9cc92287 100644 --- a/boards/arm/stm32vl_disco/stm32vl_disco_defconfig +++ b/boards/arm/stm32vl_disco/stm32vl_disco_defconfig @@ -25,3 +25,6 @@ CONFIG_GPIO=y # enable clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/boards/arm/waveshare_open103z/waveshare_open103z.dts b/boards/arm/waveshare_open103z/waveshare_open103z.dts index 234d25e810e94..aa98677175844 100644 --- a/boards/arm/waveshare_open103z/waveshare_open103z.dts +++ b/boards/arm/waveshare_open103z/waveshare_open103z.dts @@ -98,12 +98,14 @@ &usart1 { pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; &usart2 { pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>; + pinctrl-names = "default"; current-speed = <115200>; status = "okay"; }; diff --git a/boards/arm/waveshare_open103z/waveshare_open103z_defconfig b/boards/arm/waveshare_open103z/waveshare_open103z_defconfig index e86eadbf22bbb..1ac0bc938422e 100644 --- a/boards/arm/waveshare_open103z/waveshare_open103z_defconfig +++ b/boards/arm/waveshare_open103z/waveshare_open103z_defconfig @@ -17,3 +17,6 @@ CONFIG_GPIO=y # enable clocks CONFIG_CLOCK_CONTROL=y + +# enable pin controller +CONFIG_PINCTRL=y diff --git a/drivers/pinctrl/CMakeLists.txt b/drivers/pinctrl/CMakeLists.txt index cd3eca95d8d74..503790522e1a6 100644 --- a/drivers/pinctrl/CMakeLists.txt +++ b/drivers/pinctrl/CMakeLists.txt @@ -3,3 +3,4 @@ zephyr_library() zephyr_library_sources(common.c) +zephyr_library_sources_ifdef(CONFIG_PINCTRL_STM32 pinctrl_stm32.c) diff --git a/drivers/pinctrl/Kconfig b/drivers/pinctrl/Kconfig index 7e1a67175b84c..7f1d501c16e2f 100644 --- a/drivers/pinctrl/Kconfig +++ b/drivers/pinctrl/Kconfig @@ -29,4 +29,6 @@ config PINCTRL_DYNAMIC runtime. This can be useful, for example, to change the pins assigned to a peripheral at early boot stages depending on a certain input. +source "drivers/pinctrl/Kconfig.stm32" + endif # PINCTRL diff --git a/drivers/pinctrl/Kconfig.stm32 b/drivers/pinctrl/Kconfig.stm32 new file mode 100644 index 0000000000000..b1f35675cd862 --- /dev/null +++ b/drivers/pinctrl/Kconfig.stm32 @@ -0,0 +1,17 @@ +# Copyright (c) 2021 Nordic Semiconductor ASA +# SPDX-License-Identifier: Apache-2.0 + +config PINCTRL_STM32 + bool "Pin controller driver for STM32 MCUs" + depends on SOC_FAMILY_STM32 + select PINCTRL_STORE_REG if SOC_SERIES_STM32F1X + default y + help + Enable pin controller driver for STM32 MCUs + +config PINCTRL_STM32_REMAP_INIT_PRIORITY + int "Remap initialization priority" + default 2 + help + Initialization priority for the routine in charge of configuring the + remap for pins PA11/12. diff --git a/drivers/pinctrl/pinctrl_stm32.c b/drivers/pinctrl/pinctrl_stm32.c new file mode 100644 index 0000000000000..715f4acf10bd9 --- /dev/null +++ b/drivers/pinctrl/pinctrl_stm32.c @@ -0,0 +1,461 @@ +/* + * Copyright (c) 2016 Open-RnD Sp. z o.o. + * Copyright (c) 2021 Linaro Limited + * Copyright (c) 2021 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: Apache-2.0 + */ + +#include +#include +#include +#include + +#include +#include + +/** + * @brief Array containing pointers to each GPIO port. + * + * Entries will be NULL if the GPIO port is not enabled. + */ +static const struct device * const gpio_ports[] = { + DEVICE_DT_GET_OR_NULL(DT_NODELABEL(gpioa)), + DEVICE_DT_GET_OR_NULL(DT_NODELABEL(gpiob)), + DEVICE_DT_GET_OR_NULL(DT_NODELABEL(gpioc)), + DEVICE_DT_GET_OR_NULL(DT_NODELABEL(gpiod)), + DEVICE_DT_GET_OR_NULL(DT_NODELABEL(gpioe)), + DEVICE_DT_GET_OR_NULL(DT_NODELABEL(gpiof)), + DEVICE_DT_GET_OR_NULL(DT_NODELABEL(gpiog)), + DEVICE_DT_GET_OR_NULL(DT_NODELABEL(gpioh)), + DEVICE_DT_GET_OR_NULL(DT_NODELABEL(gpioi)), + DEVICE_DT_GET_OR_NULL(DT_NODELABEL(gpioj)), + DEVICE_DT_GET_OR_NULL(DT_NODELABEL(gpiok)), +}; + +/** Number of GPIO ports. */ +static const size_t gpio_ports_cnt = ARRAY_SIZE(gpio_ports); + +#if DT_NODE_HAS_PROP(DT_NODELABEL(pinctrl), remap_pa11) +#define REMAP_PA11 DT_PROP(DT_NODELABEL(pinctrl), remap_pa11) +#endif +#if DT_NODE_HAS_PROP(DT_NODELABEL(pinctrl), remap_pa12) +#define REMAP_PA12 DT_PROP(DT_NODELABEL(pinctrl), remap_pa12) +#endif +#if DT_NODE_HAS_PROP(DT_NODELABEL(pinctrl), remap_pa11_pa12) +#define REMAP_PA11_PA12 DT_PROP(DT_NODELABEL(pinctrl), remap_pa11_pa12) +#endif + +#if REMAP_PA11 || REMAP_PA12 || REMAP_PA11_PA12 + +int stm32_pinmux_init_remap(const struct device *dev) +{ + ARG_UNUSED(dev); + +#if REMAP_PA11 || REMAP_PA12 + +#if !defined(CONFIG_SOC_SERIES_STM32G0X) +#error "Pin remap property available only on STM32G0 SoC series" +#endif + + LL_APB2_GRP1_EnableClock(LL_APB2_GRP1_PERIPH_SYSCFG); +#if REMAP_PA11 + LL_SYSCFG_EnablePinRemap(LL_SYSCFG_PIN_RMP_PA11); +#endif +#if REMAP_PA12 + LL_SYSCFG_EnablePinRemap(LL_SYSCFG_PIN_RMP_PA12); +#endif + +#elif REMAP_PA11_PA12 + +#if !defined(SYSCFG_CFGR1_PA11_PA12_RMP) +#error "Pin remap property available only on STM32F070x SoC series" +#endif + + LL_APB1_GRP2_EnableClock(LL_APB1_GRP2_PERIPH_SYSCFG); + LL_SYSCFG_EnablePinRemap(); + +#endif /* (REMAP_PA11 || REMAP_PA12) || REMAP_PA11_PA12 */ + + return 0; +} + +SYS_INIT(stm32_pinmux_init_remap, PRE_KERNEL_1, + CONFIG_PINCTRL_STM32_REMAP_INIT_PRIORITY); + +#endif /* REMAP_PA11 || REMAP_PA12 || REMAP_PA11_PA12 */ + +#if DT_HAS_COMPAT_STATUS_OKAY(st_stm32f1_pinctrl) +/* Z_AFIO_REMAP is keeping the value of AFIO_MAPR_SWJ_CFG_x */ +#if defined(CONFIG_GPIO_STM32_SWJ_ENABLE) +/* reset state */ +#define Z_AFIO_REMAP AFIO_MAPR_SWJ_CFG_RESET +#elif defined(CONFIG_GPIO_STM32_SWJ_NONJTRST) +/* released PB4 */ +#define Z_AFIO_REMAP AFIO_MAPR_SWJ_CFG_NOJNTRST +#elif defined(CONFIG_GPIO_STM32_SWJ_NOJTAG) +/* released PB4 PB3 PA15 */ +#define Z_AFIO_REMAP AFIO_MAPR_SWJ_CFG_JTAGDISABLE +#elif defined(CONFIG_GPIO_STM32_SWJ_DISABLE) +/* released PB4 PB3 PA13 PA14 PA15 */ +#define Z_AFIO_REMAP AFIO_MAPR_SWJ_CFG_DISABLE +#endif + +/* enable remap : modify MAPR and keep the AFIO_MAPR_SWJ_CFG_x */ +#define enable_remap(REMAP_PIN) MODIFY_REG(AFIO->MAPR,\ + (REMAP_PIN | AFIO_MAPR_SWJ_CFG), \ + (REMAP_PIN | Z_AFIO_REMAP)) + +/* enable partial remap : modify MAPR and keep the AFIO_MAPR_SWJ_CFG_x */ +#define enable_partial_remap(REMAP_PIN, PARTIAL_REMAP) \ + MODIFY_REG(AFIO->MAPR, \ + (REMAP_PIN | AFIO_MAPR_SWJ_CFG), \ + (PARTIAL_REMAP | Z_AFIO_REMAP)) + +/* disable remap : modify MAPR and keep the AFIO_MAPR_SWJ_CFG_x */ +#define disable_remap(REMAP_PIN) MODIFY_REG(AFIO->MAPR,\ + (REMAP_PIN | AFIO_MAPR_SWJ_CFG), \ + Z_AFIO_REMAP) + +/** + * @brief Helper function to check and apply provided pinctrl remap + * configuration. + * + * Check operation verifies that pin remapping configuration is the same on all + * pins. If configuration is valid AFIO clock is enabled and remap is applied + * + * @param pins List of pins to be configured. + * @param pin_cnt Number of pins. + * @param reg Device register address. + * + * @retval 0 If successful + * @retval -EINVAL If pins have an incompatible set of remaps. + */ +static int stm32_pins_remap(const pinctrl_soc_pin_t *pins, uint8_t pin_cnt, + uintptr_t reg) +{ + uint8_t remap; + + remap = (uint8_t)STM32_DT_PINMUX_REMAP(pinctrl[0].pinmux); + + for (size_t i = 1U; i < list_size; i++) { + if (STM32_DT_PINMUX_REMAP(pinctrl[i].pinmux) != remap) { + return -EINVAL; + } + } + + /* A valid remapping configuration is available */ + /* Apply remapping before proceeding with pin configuration */ + LL_APB2_GRP1_EnableClock(LL_APB2_GRP1_PERIPH_AFIO); + + switch (base) { +#if DT_NODE_HAS_STATUS(DT_NODELABEL(can1), okay) + case DT_REG_ADDR(DT_NODELABEL(can1)): + if (remap == REMAP_1) { + /* PB8/PB9 (CAN_REMAP = 0b10) */ + enable_partial_remap(AFIO_MAPR_CAN_REMAP, + AFIO_MAPR_CAN_REMAP_REMAP2); + } else if (remap == REMAP_2) { + /* PD0/PD1 (CAN_REMAP = 0b11) */ + enable_partial_remap(AFIO_MAPR_CAN_REMAP, + AFIO_MAPR_CAN_REMAP_REMAP3); + } else { + /* NO_REMAP: PA11/PA12 (CAN_REMAP = 0b00) */ + enable_partial_remap(AFIO_MAPR_CAN_REMAP, + AFIO_MAPR_CAN_REMAP_REMAP1); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(can2), okay) + case DT_REG_ADDR(DT_NODELABEL(can2)): + if (remap == REMAP_1) { + /* PB5/PB6 */ + enable_remap(AFIO_MAPR_CAN2_REMAP); + } else { + /* PB12/PB13 */ + disable_remap(AFIO_MAPR_CAN2_REMAP); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(i2c1), okay) + case DT_REG_ADDR(DT_NODELABEL(i2c1)): + if (remap == REMAP_1) { + enable_remap(AFIO_MAPR_I2C1_REMAP); + } else { + disable_remap(AFIO_MAPR_I2C1_REMAP); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers1), okay) + case DT_REG_ADDR(DT_NODELABEL(timers1)): + if (remap == REMAP_1) { + enable_partial_remap(AFIO_MAPR_TIM1_REMAP, + AFIO_MAPR_TIM1_REMAP_PARTIALREMAP); + } else if (remap == REMAP_2) { + enable_partial_remap(AFIO_MAPR_TIM1_REMAP, + AFIO_MAPR_TIM1_REMAP_FULLREMAP); + } else { + enable_partial_remap(AFIO_MAPR_TIM1_REMAP, + AFIO_MAPR_TIM1_REMAP_NOREMAP); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers2), okay) + case DT_REG_ADDR(DT_NODELABEL(timers2)): + if (remap == REMAP_1) { + enable_partial_remap(AFIO_MAPR_TIM2_REMAP, + AFIO_MAPR_TIM2_REMAP_PARTIALREMAP1); + } else if (remap == REMAP_2) { + enable_partial_remap(AFIO_MAPR_TIM2_REMAP, + AFIO_MAPR_TIM2_REMAP_PARTIALREMAP2); + } else if (remap == REMAP_FULL) { + enable_partial_remap(AFIO_MAPR_TIM2_REMAP, + AFIO_MAPR_TIM2_REMAP_FULLREMAP); + } else { + enable_partial_remap(AFIO_MAPR_TIM2_REMAP, + AFIO_MAPR_TIM2_REMAP_NOREMAP); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers3), okay) + case DT_REG_ADDR(DT_NODELABEL(timers3)): + if (remap == REMAP_1) { + enable_partial_remap(AFIO_MAPR_TIM3_REMAP, + AFIO_MAPR_TIM3_REMAP_PARTIALREMAP); + } else if (remap == REMAP_2) { + enable_partial_remap(AFIO_MAPR_TIM3_REMAP, + AFIO_MAPR_TIM3_REMAP_FULLREMAP); + } else { + enable_partial_remap(AFIO_MAPR_TIM3_REMAP, + AFIO_MAPR_TIM3_REMAP_NOREMAP); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers4), okay) + case DT_REG_ADDR(DT_NODELABEL(timers4)): + if (remap == REMAP_1) { + enable_remap(AFIO_MAPR_TIM4_REMAP); + } else { + disable_remap(AFIO_MAPR_TIM4_REMAP); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers9), okay) + case DT_REG_ADDR(DT_NODELABEL(timers9)): + if (remap == REMAP_1) { + LL_GPIO_AF_EnableRemap_TIM9(); + } else { + LL_GPIO_AF_DisableRemap_TIM9(); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers10), okay) + case DT_REG_ADDR(DT_NODELABEL(timers10)): + if (remap == REMAP_1) { + LL_GPIO_AF_EnableRemap_TIM10(); + } else { + LL_GPIO_AF_DisableRemap_TIM10(); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers11), okay) + case DT_REG_ADDR(DT_NODELABEL(timers11)): + if (remap == REMAP_1) { + LL_GPIO_AF_EnableRemap_TIM11(); + } else { + LL_GPIO_AF_DisableRemap_TIM11(); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers12), okay) + case DT_REG_ADDR(DT_NODELABEL(timers12)): + if (remap == REMAP_1) { + LL_GPIO_AF_EnableRemap_TIM12(); + } else { + LL_GPIO_AF_DisableRemap_TIM12(); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers13), okay) + case DT_REG_ADDR(DT_NODELABEL(timers13)): + if (remap == REMAP_1) { + LL_GPIO_AF_EnableRemap_TIM13(); + } else { + LL_GPIO_AF_DisableRemap_TIM13(); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers14), okay) + case DT_REG_ADDR(DT_NODELABEL(timers14)): + if (remap == REMAP_1) { + LL_GPIO_AF_EnableRemap_TIM14(); + } else { + LL_GPIO_AF_DisableRemap_TIM14(); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers15), okay) + case DT_REG_ADDR(DT_NODELABEL(timers15)): + if (remap == REMAP_1) { + LL_GPIO_AF_EnableRemap_TIM15(); + } else { + LL_GPIO_AF_DisableRemap_TIM15(); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers16), okay) + case DT_REG_ADDR(DT_NODELABEL(timers16)): + if (remap == REMAP_1) { + LL_GPIO_AF_EnableRemap_TIM16(); + } else { + LL_GPIO_AF_DisableRemap_TIM16(); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(timers17), okay) + case DT_REG_ADDR(DT_NODELABEL(timers17)): + if (remap == REMAP_1) { + LL_GPIO_AF_EnableRemap_TIM17(); + } else { + LL_GPIO_AF_DisableRemap_TIM17(); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(usart1), okay) + case DT_REG_ADDR(DT_NODELABEL(usart1)): + if (remap == REMAP_1) { + enable_remap(AFIO_MAPR_USART1_REMAP); + } else { + disable_remap(AFIO_MAPR_USART1_REMAP); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(usart2), okay) + case DT_REG_ADDR(DT_NODELABEL(usart2)): + if (remap == REMAP_1) { + enable_remap(AFIO_MAPR_USART2_REMAP); + } else { + disable_remap(AFIO_MAPR_USART2_REMAP); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(usart3), okay) + case DT_REG_ADDR(DT_NODELABEL(usart3)): + if (remap == REMAP_2) { + enable_partial_remap(AFIO_MAPR_USART3_REMAP, + AFIO_MAPR_USART3_REMAP_FULLREMAP); + } else if (remap == REMAP_1) { + enable_partial_remap(AFIO_MAPR_USART3_REMAP, + AFIO_MAPR_USART3_REMAP_PARTIALREMAP); + } else { + enable_partial_remap(AFIO_MAPR_USART3_REMAP, + AFIO_MAPR_USART3_REMAP_NOREMAP); + } + break; +#endif +#if DT_NODE_HAS_STATUS(DT_NODELABEL(spi1), okay) + case DT_REG_ADDR(DT_NODELABEL(spi1)): + if (remap == REMAP_1) { + enable_remap(AFIO_MAPR_SPI1_REMAP); + } else { + disable_remap(AFIO_MAPR_SPI1_REMAP); + } + break; +#endif + } + + return 0; +} +#endif /* DT_HAS_COMPAT_STATUS_OKAY(st_stm32f1_pinctrl) */ + +static int stm32_pin_configure(uint32_t pin, uint32_t func, uint32_t altf) +{ + const struct device *port_device; + int ret = 0; + + if (STM32_PORT(pin) >= gpio_ports_cnt) { + return -EINVAL; + } + + port_device = gpio_ports[STM32_PORT(pin)]; + + if ((port_device == NULL) || (!device_is_ready(port_device))) { + return -ENODEV; + } + +#ifdef CONFIG_PM_DEVICE_RUNTIME + ret = pm_device_get(port_device); + if (ret < 0) { + return ret; + } +#endif + + gpio_stm32_configure(port_device, STM32_PIN(pin), func, altf); + +#ifdef CONFIG_PM_DEVICE_RUNTIME + ret = pm_device_put(port_device); +#endif + + return ret; +} + +int pinctrl_configure_pins(const pinctrl_soc_pin_t *pins, uint8_t pin_cnt, + uintptr_t reg) +{ + uint32_t pin, mux; + uint32_t func = 0; + int ret = 0; + +#if DT_HAS_COMPAT_STATUS_OKAY(st_stm32f1_pinctrl) + ret = stm32_pins_remap(pins, pin_cnt, reg); + if (ret < 0) { + return ret; + } +#else + ARG_UNUSED(reg); +#endif /* DT_HAS_COMPAT_STATUS_OKAY(st_stm32f1_pinctrl) */ + + for (uint8_t i = 0U; i < pin_cnt; i++) { + mux = pins[i].pinmux; + +#if DT_HAS_COMPAT_STATUS_OKAY(st_stm32f1_pinctrl) + uint32_t pupd; + + if (STM32_DT_PINMUX_FUNC(mux) == ALTERNATE) { + func = pins[i].pincfg | STM32_MODE_OUTPUT | STM32_CNF_ALT_FUNC; + } else if (STM32_DT_PINMUX_FUNC(mux) == ANALOG) { + func = pins[i].pincfg | STM32_MODE_INPUT | STM32_CNF_IN_ANALOG; + } else if (STM32_DT_PINMUX_FUNC(mux) == GPIO_IN) { + func = pins[i].pincfg | STM32_MODE_INPUT; + pupd = func & (STM32_PUPD_MASK << STM32_PUPD_SHIFT); + if (pupd == STM32_PUPD_NO_PULL) { + func = func | STM32_CNF_IN_FLOAT; + } else { + func = func | STM32_CNF_IN_PUPD; + } + } else { + /* Not supported */ + __ASSERT_NO_MSG(STM32_DT_PINMUX_FUNC(mux)); + } +#else + if (STM32_DT_PINMUX_FUNC(mux) < STM32_ANALOG) { + func = pins[i].pincfg | STM32_MODER_ALT_MODE; + } else if (STM32_DT_PINMUX_FUNC(mux) == STM32_ANALOG) { + func = STM32_MODER_ANALOG_MODE; + } else { + /* Not supported */ + __ASSERT_NO_MSG(STM32_DT_PINMUX_FUNC(mux)); + } +#endif /* DT_HAS_COMPAT_STATUS_OKAY(st_stm32f1_pinctrl) */ + + pin = STM32PIN(STM32_DT_PINMUX_PORT(mux), + STM32_DT_PINMUX_LINE(mux)); + + ret = stm32_pin_configure(pin, func, STM32_DT_PINMUX_FUNC(mux)); + if (ret < 0) { + return ret; + } + } + + return 0; +} diff --git a/drivers/serial/uart_stm32.c b/drivers/serial/uart_stm32.c index fc06d1ebc43da..2e8c792f01fc7 100644 --- a/drivers/serial/uart_stm32.c +++ b/drivers/serial/uart_stm32.c @@ -20,8 +20,6 @@ #include #include #include -#include -#include #include #include @@ -1430,9 +1428,7 @@ static int uart_stm32_init(const struct device *dev) } /* Configure dt provided device signals when available */ - err = stm32_dt_pinctrl_configure(config->pinctrl_list, - config->pinctrl_list_size, - (uint32_t)UART_STRUCT(dev)); + err = pinctrl_apply_state(config->pcfg, PINCTRL_STATE_DEFAULT); if (err < 0) { return err; } @@ -1580,8 +1576,7 @@ static void uart_stm32_irq_config_func_##index(const struct device *dev) \ #define STM32_UART_INIT(index) \ STM32_UART_IRQ_HANDLER_DECL(index) \ \ -static const struct soc_gpio_pinctrl uart_pins_##index[] = \ - ST_STM32_DT_INST_PINCTRL(index, 0); \ +PINCTRL_DT_INST_DEFINE(index) \ \ static const struct uart_stm32_config uart_stm32_cfg_##index = { \ .uconf = { \ @@ -1593,9 +1588,8 @@ static const struct uart_stm32_config uart_stm32_cfg_##index = { \ }, \ .hw_flow_control = DT_INST_PROP(index, hw_flow_control), \ .parity = DT_ENUM_IDX_OR(DT_DRV_INST(index), parity, UART_CFG_PARITY_NONE), \ + .pcfg = PINCTRL_DT_INST_DEV_CONFIG_GET(index), \ STM32_UART_POLL_IRQ_HANDLER_FUNC(index) \ - .pinctrl_list = uart_pins_##index, \ - .pinctrl_list_size = ARRAY_SIZE(uart_pins_##index), \ }; \ \ static struct uart_stm32_data uart_stm32_data_##index = { \ diff --git a/drivers/serial/uart_stm32.h b/drivers/serial/uart_stm32.h index 85762a65fff3f..54935dbb1fc0f 100644 --- a/drivers/serial/uart_stm32.h +++ b/drivers/serial/uart_stm32.h @@ -12,7 +12,7 @@ #ifndef ZEPHYR_DRIVERS_SERIAL_UART_STM32_H_ #define ZEPHYR_DRIVERS_SERIAL_UART_STM32_H_ -#include +#include /* device config */ struct uart_stm32_config { @@ -23,8 +23,7 @@ struct uart_stm32_config { bool hw_flow_control; /* initial parity, 0 for none, 1 for odd, 2 for even */ int parity; - const struct soc_gpio_pinctrl *pinctrl_list; - size_t pinctrl_list_size; + const struct pinctrl_dev_config *pcfg; #if defined(CONFIG_PM) \ && !defined(CONFIG_UART_INTERRUPT_DRIVEN) \ && !defined(CONFIG_UART_ASYNC_API) diff --git a/dts/bindings/serial/st,stm32-lpuart.yaml b/dts/bindings/serial/st,stm32-lpuart.yaml index b2a44520a494f..bbf2903751661 100644 --- a/dts/bindings/serial/st,stm32-lpuart.yaml +++ b/dts/bindings/serial/st,stm32-lpuart.yaml @@ -2,7 +2,7 @@ description: STM32 LPUART compatible: "st,stm32-lpuart" -include: uart-controller.yaml +include: [uart-controller.yaml, pinctrl-device.yaml] properties: reg: @@ -13,13 +13,3 @@ properties: clocks: required: true - - pinctrl-0: - type: phandles - required: false - description: | - GPIO pin configuration for serial signals (RX, TX, RTS, CTS). We expect - that the phandles will reference pinctrl nodes. - - For example the USART1 would be - pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; diff --git a/dts/bindings/serial/st,stm32-uart.yaml b/dts/bindings/serial/st,stm32-uart.yaml index e7f77f0e46892..2816fd3e8679b 100644 --- a/dts/bindings/serial/st,stm32-uart.yaml +++ b/dts/bindings/serial/st,stm32-uart.yaml @@ -2,7 +2,7 @@ description: STM32 UART compatible: "st,stm32-uart" -include: uart-controller.yaml +include: [uart-controller.yaml, pinctrl-device.yaml] properties: reg: @@ -10,13 +10,3 @@ properties: interrupts: required: true - - pinctrl-0: - type: phandles - required: false - description: | - GPIO pin configuration for serial signals (RX, TX, RTS, CTS). We expect - that the phandles will reference pinctrl nodes. - - For example the USART1 would be - pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; diff --git a/dts/bindings/serial/st,stm32-usart.yaml b/dts/bindings/serial/st,stm32-usart.yaml index ba514cdc5f942..971815349a4d1 100644 --- a/dts/bindings/serial/st,stm32-usart.yaml +++ b/dts/bindings/serial/st,stm32-usart.yaml @@ -2,7 +2,7 @@ description: STM32 USART compatible: "st,stm32-usart" -include: uart-controller.yaml +include: [uart-controller.yaml, pinctrl-device.yaml] properties: reg: @@ -10,13 +10,3 @@ properties: interrupts: required: true - - pinctrl-0: - type: phandles - required: false - description: | - GPIO pin configuration for serial signals (RX, TX, RTS, CTS). We expect - that the phandles will reference pinctrl nodes. - - For example the USART1 would be - pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>; diff --git a/soc/arm/st_stm32/common/pinctrl_soc.h b/soc/arm/st_stm32/common/pinctrl_soc.h new file mode 100644 index 0000000000000..57e4cf0e5d33b --- /dev/null +++ b/soc/arm/st_stm32/common/pinctrl_soc.h @@ -0,0 +1,102 @@ +/* + * Copyright (c) 2020 Linaro Ltd. + * Copyright (c) 2021 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: Apache-2.0 + */ + +/** + * @file + * STM32 SoC specific helpers for pinctrl driver + */ + +#ifndef ZEPHYR_SOC_ARM_ST_STM32_COMMON_PINCTRL_SOC_H_ +#define ZEPHYR_SOC_ARM_ST_STM32_COMMON_PINCTRL_SOC_H_ + +#include +#include + +#ifdef CONFIG_SOC_SERIES_STM32F1X +#include +#else +#include +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** @cond INTERNAL_HIDDEN */ + +/** Type for STM32 pin. */ +typedef struct pinctrl_soc_pin { + /** Pinmux settings (port, pin and function). */ + uint32_t pinmux; + /** Pin configuration (bias, drive and slew rate). */ + uint32_t pincfg; +} pinctrl_soc_pin_t; + +/** + * @brief Utility macro to initialize pinmux field in #pinctrl_pin_t. + * + * @param node_id Node identifier. + */ +#define Z_PINCTRL_STM32_PINMUX_INIT(node_id) DT_PROP(node_id, pinmux) + +#ifdef CONFIG_SOC_SERIES_STM32F1X +/** + * @brief Utility macro to initialize pincfg field in #pinctrl_pin_t (F1). + * + * @param node_id Node identifier. + */ +#define Z_PINCTRL_STM32_PINCFG_INIT(node_id) \ + (((STM32_NO_PULL * DT_PROP(node_id, bias_disable)) << STM32_PUPD_SHIFT) | \ + ((STM32_PULL_UP * DT_PROP(node_id, bias_pull_up)) << STM32_PUPD_SHIFT) | \ + ((STM32_PULL_DOWN * DT_PROP(node_id, bias_pull_down)) << STM32_PUPD_SHIFT) | \ + ((STM32_PUSH_PULL * DT_PROP(node_id, drive_push_pull)) << STM32_CNF_OUT_0_SHIFT) | \ + ((STM32_OPEN_DRAIN * DT_PROP(node_id, drive_open_drain)) << STM32_CNF_OUT_0_SHIFT) | \ + (DT_ENUM_IDX(node_id, slew_rate) << STM32_MODE_OSPEED_SHIFT)) +#else +/** + * @brief Utility macro to initialize pincfg field in #pinctrl_pin_t (non-F1). + * + * @param node_id Node identifier. + */ +#define Z_PINCTRL_STM32_PINCFG_INIT(node_id) \ + (((STM32_NO_PULL * DT_PROP(node_id, bias_disable)) << STM32_PUPDR_SHIFT) | \ + ((STM32_PULL_UP * DT_PROP(node_id, bias_pull_up)) << STM32_PUPDR_SHIFT) | \ + ((STM32_PULL_DOWN * DT_PROP(node_id, bias_pull_down)) << STM32_PUPDR_SHIFT) | \ + ((STM32_PUSH_PULL * DT_PROP(node_id, drive_push_pull)) << STM32_OTYPER_SHIFT) | \ + ((STM32_OPEN_DRAIN * DT_PROP(node_id, drive_open_drain)) << STM32_OTYPER_SHIFT) | \ + (DT_ENUM_IDX(node_id, slew_rate) << STM32_OSPEEDR_SHIFT)) +#endif /* CONFIG_SOC_SERIES_STM32F1X */ + +/** + * @brief Utility macro to initialize each pin. + * + * @param node_id Node identifier. + * @param state_prop State property name. + * @param idx State property entry index. + */ +#define Z_PINCTRL_STATE_PIN_INIT(node_id, state_prop, idx) \ + { .pinmux = Z_PINCTRL_STM32_PINMUX_INIT( \ + DT_PROP_BY_IDX(node_id, state_prop, idx)), \ + .pincfg = Z_PINCTRL_STM32_PINCFG_INIT( \ + DT_PROP_BY_IDX(node_id, state_prop, idx)) }, + +/** + * @brief Utility macro to initialize state pins contained in a given property. + * + * @param node_id Node identifier. + * @param prop Property name describing state pins. + */ +#define Z_PINCTRL_STATE_PINS_INIT(node_id, prop) \ + {DT_FOREACH_PROP_ELEM(node_id, prop, Z_PINCTRL_STATE_PIN_INIT)} + +/** @endcond */ + +#ifdef __cplusplus +} +#endif + +#endif /* ZEPHYR_SOC_ARM_ST_STM32_COMMON_PINCTRL_SOC_H_ */