soc/add_uart: Improve error message for unsupported UART.

This commit is contained in:
Florent Kermarrec 2022-10-21 09:03:25 +02:00
parent 73d70cf594
commit 804a1a5b26
1 changed files with 2 additions and 2 deletions

View File

@ -1326,10 +1326,10 @@ class LiteXSoC(SoC):
"rx_fifo_depth": fifo_depth, "rx_fifo_depth": fifo_depth,
} }
if (uart_pads is None) and (uart_name not in supported_uarts): if (uart_pads is None) and (uart_name not in supported_uarts):
self.logger.error("{} UART {}, supported are: {}.".format( self.logger.error("{} UART {}, supported are: \n{}.".format(
colorer(uart_name), colorer(uart_name),
colorer("not supported/found on board", color="red"), colorer("not supported/found on board", color="red"),
colorer(", ".join(supported_uarts)))) colorer("- " + "\n- ".join(supported_uarts))))
raise SoCError() raise SoCError()
# Crossover. # Crossover.