Oliver Swede | 8fed2fe | 2019-11-11 11:11:06 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2020, ARM Limited and Contributors. All rights reserved. |
| 3 | * |
| 4 | * SPDX-License-Identifier: BSD-3-Clause |
| 5 | */ |
| 6 | |
| 7 | #include <drivers/console.h> |
| 8 | #include <drivers/arm/pl011.h> |
| 9 | |
| 10 | #include <platform_def.h> |
| 11 | |
| 12 | static console_t console; |
| 13 | |
| 14 | void fpga_console_init(void) |
| 15 | { |
| 16 | (void)console_pl011_register(PLAT_FPGA_BOOT_UART_BASE, |
| 17 | PLAT_FPGA_BOOT_UART_CLK_IN_HZ, |
| 18 | PLAT_FPGA_CONSOLE_BAUDRATE, |
| 19 | &console); |
| 20 | |
| 21 | console_set_scope(&console, CONSOLE_FLAG_BOOT | |
| 22 | CONSOLE_FLAG_RUNTIME); |
| 23 | } |