Skip to content

Commit

Permalink
boot: zephyr: serial_adapter: Fail if USB CDC enabled with console
Browse files Browse the repository at this point in the history
This prevents MCUboot from successfully building if console and
serial recovery (USB CDC) are both enabled and they both point to
the same device

Signed-off-by: Jamie McCrae <[email protected]>
  • Loading branch information
nordicjm committed Nov 6, 2023
1 parent 4a1effb commit 2b1c5a8
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions boot/zephyr/serial_adapter.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
#endif

#if defined(CONFIG_BOOT_SERIAL_CDC_ACM) && \
defined(CONFIG_UART_CONSOLE) && !DT_HAS_CHOSEN(zephyr_uart_mcumgr)
defined(CONFIG_UART_CONSOLE) && (!DT_HAS_CHOSEN(zephyr_uart_mcumgr) || DT_SAME_NODE(DT_CHOSEN(zephyr_uart_mcumgr), DT_CHOSEN(zephyr_console)))
#error Zephyr UART console must been disabled if CDC ACM is enabled and MCUmgr \
has not been redirected to other UART with DTS chosen zephyr,uart-mcumgr.
#endif
Expand Down Expand Up @@ -199,7 +199,6 @@ boot_uart_fifo_getline(char **line)
static int
boot_uart_fifo_init(void)
{

#if defined(CONFIG_BOOT_SERIAL_UART)

#if DT_HAS_CHOSEN(zephyr_uart_mcumgr)
Expand Down

0 comments on commit 2b1c5a8

Please sign in to comment.