mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2026-11-09 08:37:58 +08:00
arm/xilinx-zynq: Initialize debug console once
This commit is contained in:
1 parent
bc31fb65d2
commit
5da3ff47df
1 file changed
+6
@@ -50,11 +50,17 @@ static void zynq_debug_console_out(char c)
|
||||
zynq_uart_write_polled(base, c);
|
||||
}
|
||||
|
||||
static void zynq_debug_console_early_init(char c);
|
||||
|
||||
static void zynq_debug_console_init(void)
|
||||
{
|
||||
rtems_termios_device_context *base =
|
||||
&zynq_uart_instances[BSP_CONSOLE_MINOR].base;
|
||||
|
||||
if (BSP_output_char != zynq_debug_console_early_init) {
|
||||
return;
|
||||
}
|
||||
|
||||
zynq_uart_initialize(base);
|
||||
BSP_output_char = zynq_debug_console_out;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user