-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Loading status checks…
add a patch for zephyr
Showing
2 changed files
with
138 additions
and
0 deletions.
There are no files selected for viewing
137 changes: 137 additions & 0 deletions
137
patches/zephyr/0001-boards-arm-enable-UART-console-for-various-boards.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,137 @@ | ||
From 69d87a1bb7ffe6816d58076d889b156192ed0447 Mon Sep 17 00:00:00 2001 | ||
From: Filip Kokosinski <[email protected]> | ||
Date: Wed, 2 Aug 2023 11:41:00 +0200 | ||
Subject: [PATCH] boards/arm: enable UART console for various boards | ||
|
||
Some boards don't have UART console enabled by default, or `zephyr,console` | ||
and `zephyr,shell-uart` aliases set in the devicetree. This is required for | ||
all samples that use UART. | ||
|
||
Signed-off-by: Filip Kokosinski <[email protected]> | ||
--- | ||
boards/arm/96b_avenger96/96b_avenger96.dts | 2 ++ | ||
boards/arm/96b_avenger96/96b_avenger96_defconfig | 6 +++--- | ||
boards/arm/hexiwear_kw40z/hexiwear_kw40z.dts | 2 ++ | ||
boards/arm/stm32h747i_disco/stm32h747i_disco_m4.dts | 4 +++- | ||
boards/arm/stm32h747i_disco/stm32h747i_disco_m4_defconfig | 4 ++-- | ||
boards/arm/stm32mp157c_dk2/stm32mp157c_dk2.dts | 2 ++ | ||
boards/arm/stm32mp157c_dk2/stm32mp157c_dk2_defconfig | 6 +++--- | ||
7 files changed, 17 insertions(+), 9 deletions(-) | ||
|
||
diff --git a/boards/arm/96b_avenger96/96b_avenger96.dts b/boards/arm/96b_avenger96/96b_avenger96.dts | ||
index 3accaae12a..533f174d25 100644 | ||
--- a/boards/arm/96b_avenger96/96b_avenger96.dts | ||
+++ b/boards/arm/96b_avenger96/96b_avenger96.dts | ||
@@ -22,6 +22,8 @@ | ||
* zephyr,console = &uart7; | ||
* zephyr,shell-uart = &uart7; | ||
*/ | ||
+ zephyr,console = &uart7; | ||
+ zephyr,shell-uart = &uart7; | ||
zephyr,flash = &retram; | ||
zephyr,sram = &mcusram; | ||
}; | ||
diff --git a/boards/arm/96b_avenger96/96b_avenger96_defconfig b/boards/arm/96b_avenger96/96b_avenger96_defconfig | ||
index 05be01fbb3..d48a8dbae6 100644 | ||
--- a/boards/arm/96b_avenger96/96b_avenger96_defconfig | ||
+++ b/boards/arm/96b_avenger96/96b_avenger96_defconfig | ||
@@ -19,11 +19,11 @@ CONFIG_CLOCK_CONTROL=y | ||
|
||
# console (remote proc console by default) | ||
CONFIG_CONSOLE=y | ||
-CONFIG_RAM_CONSOLE=y | ||
-CONFIG_RAM_CONSOLE_BUFFER_SIZE=1024 | ||
+#CONFIG_RAM_CONSOLE=y | ||
+#CONFIG_RAM_CONSOLE_BUFFER_SIZE=1024 | ||
|
||
# uart console (overrides remote proc console) | ||
-CONFIG_UART_CONSOLE=n | ||
+CONFIG_UART_CONSOLE=y | ||
|
||
# enable pin controller | ||
CONFIG_PINCTRL=y | ||
diff --git a/boards/arm/hexiwear_kw40z/hexiwear_kw40z.dts b/boards/arm/hexiwear_kw40z/hexiwear_kw40z.dts | ||
index 2b64e0bafd..9ef32696bd 100644 | ||
--- a/boards/arm/hexiwear_kw40z/hexiwear_kw40z.dts | ||
+++ b/boards/arm/hexiwear_kw40z/hexiwear_kw40z.dts | ||
@@ -10,6 +10,8 @@ | ||
compatible = "nxp,kw40z", "nxp,mkw40z4"; | ||
|
||
chosen { | ||
+ zephyr,console = &lpuart0; | ||
+ zephyr,shell-uart = &lpuart0; | ||
zephyr,sram = &sram0; | ||
zephyr,flash = &flash0; | ||
}; | ||
diff --git a/boards/arm/stm32h747i_disco/stm32h747i_disco_m4.dts b/boards/arm/stm32h747i_disco/stm32h747i_disco_m4.dts | ||
index 74681a8829..00078ec23b 100644 | ||
--- a/boards/arm/stm32h747i_disco/stm32h747i_disco_m4.dts | ||
+++ b/boards/arm/stm32h747i_disco/stm32h747i_disco_m4.dts | ||
@@ -17,6 +17,8 @@ | ||
chosen { | ||
/* zephyr,console = &usart1; */ | ||
/* zephyr,shell-uart = &usart1; */ | ||
+ zephyr,console = &usart1; | ||
+ zephyr,shell-uart = &usart1; | ||
zephyr,sram = &sram1; | ||
zephyr,flash = &flash1; | ||
}; | ||
@@ -48,7 +50,7 @@ | ||
}; | ||
|
||
&usart1 { | ||
- /* status = "okay"; */ | ||
+ status = "okay"; | ||
}; | ||
|
||
&uart8 { | ||
diff --git a/boards/arm/stm32h747i_disco/stm32h747i_disco_m4_defconfig b/boards/arm/stm32h747i_disco/stm32h747i_disco_m4_defconfig | ||
index 2f437301c8..045743dfb3 100644 | ||
--- a/boards/arm/stm32h747i_disco/stm32h747i_disco_m4_defconfig | ||
+++ b/boards/arm/stm32h747i_disco/stm32h747i_disco_m4_defconfig | ||
@@ -22,8 +22,8 @@ CONFIG_HW_STACK_PROTECTION=y | ||
CONFIG_SERIAL=y | ||
|
||
# By default CONSOLE is assigned to m7 | ||
-#CONFIG_CONSOLE=y | ||
-#CONFIG_UART_CONSOLE=y | ||
+CONFIG_CONSOLE=y | ||
+CONFIG_UART_CONSOLE=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 2704451697..339ed78d16 100644 | ||
--- a/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2.dts | ||
+++ b/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2.dts | ||
@@ -22,6 +22,8 @@ | ||
* zephyr,console = &usart3; | ||
* zephyr,shell-uart = &usart3; | ||
*/ | ||
+ zephyr,console = &usart3; | ||
+ zephyr,shell-uart = &usart3; | ||
zephyr,flash = &retram; | ||
zephyr,sram = &mcusram; | ||
}; | ||
diff --git a/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2_defconfig b/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2_defconfig | ||
index 66503dc240..7962e99399 100644 | ||
--- a/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2_defconfig | ||
+++ b/boards/arm/stm32mp157c_dk2/stm32mp157c_dk2_defconfig | ||
@@ -19,11 +19,11 @@ CONFIG_CLOCK_CONTROL=y | ||
|
||
# console (remote proc console by default) | ||
CONFIG_CONSOLE=y | ||
-CONFIG_RAM_CONSOLE=y | ||
-CONFIG_RAM_CONSOLE_BUFFER_SIZE=1024 | ||
+#CONFIG_RAM_CONSOLE=y | ||
+#CONFIG_RAM_CONSOLE_BUFFER_SIZE=1024 | ||
|
||
# uart console (overrides remote proc console) | ||
-CONFIG_UART_CONSOLE=n | ||
+CONFIG_UART_CONSOLE=y | ||
|
||
# enable pin controller | ||
CONFIG_PINCTRL=y | ||
-- | ||
2.34.1 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters