diff options
author | Joanna Farley <joanna.farley@arm.com> | 2023-09-27 09:49:01 +0200 |
---|---|---|
committer | TrustedFirmware Code Review <review@review.trustedfirmware.org> | 2023-09-27 09:49:01 +0200 |
commit | 4593e7cbe8ac00bd58801d3a6933950160eaa40f (patch) | |
tree | 6826f6063572e7eab9b5234dbdc093504b2ff6f2 /plat | |
parent | 0ef4103eb9d7612d7b34d2a2e1e3e8d3527145b2 (diff) | |
parent | 3e6b96e869238f21c8887b835c3bfed487dbe653 (diff) |
Merge changes from topic "xilinx-crash" into integration
* changes:
feat(xilinx): used console also as crash console
feat(versal-net): remove empty crash console setup
Diffstat (limited to 'plat')
-rw-r--r-- | plat/xilinx/versal/bl31_versal_setup.c | 2 | ||||
-rw-r--r-- | plat/xilinx/versal_net/aarch64/versal_net_helpers.S | 45 | ||||
-rw-r--r-- | plat/xilinx/versal_net/bl31_versal_net_setup.c | 2 | ||||
-rw-r--r-- | plat/xilinx/versal_net/include/versal_net_def.h | 2 | ||||
-rw-r--r-- | plat/xilinx/versal_net/platform.mk | 1 | ||||
-rw-r--r-- | plat/xilinx/zynqmp/bl31_zynqmp_setup.c | 3 |
6 files changed, 6 insertions, 49 deletions
diff --git a/plat/xilinx/versal/bl31_versal_setup.c b/plat/xilinx/versal/bl31_versal_setup.c index c50f06f65..99797b528 100644 --- a/plat/xilinx/versal/bl31_versal_setup.c +++ b/plat/xilinx/versal/bl31_versal_setup.c @@ -86,7 +86,7 @@ void bl31_early_platform_setup2(u_register_t arg0, u_register_t arg1, } console_set_scope(&versal_runtime_console, (uint32_t)(CONSOLE_FLAG_BOOT | - CONSOLE_FLAG_RUNTIME)); + CONSOLE_FLAG_RUNTIME | CONSOLE_FLAG_CRASH)); } else if (VERSAL_CONSOLE_IS(dcc)) { /* Initialize the dcc console for debug */ int32_t rc = console_dcc_register(); diff --git a/plat/xilinx/versal_net/aarch64/versal_net_helpers.S b/plat/xilinx/versal_net/aarch64/versal_net_helpers.S index ccebff24a..dab871795 100644 --- a/plat/xilinx/versal_net/aarch64/versal_net_helpers.S +++ b/plat/xilinx/versal_net/aarch64/versal_net_helpers.S @@ -1,7 +1,7 @@ /* * Copyright (c) 2018-2021, Arm Limited and Contributors. All rights reserved. * Copyright (c) 2018-2022, Xilinx, Inc. All rights reserved. - * Copyright (c) 2022, Advanced Micro Devices, Inc. All rights reserved. + * Copyright (c) 2022-2023, Advanced Micro Devices, Inc. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -16,9 +16,6 @@ .globl plat_is_my_cpu_primary .globl platform_mem_init .globl plat_my_core_pos - .globl plat_crash_console_init - .globl plat_crash_console_putc - .globl plat_crash_console_flush /* ----------------------------------------------------- * void plat_secondary_cold_boot_setup (void); @@ -69,43 +66,3 @@ endfunc plat_my_core_pos func platform_mem_init ret endfunc platform_mem_init - - - /* --------------------------------------------- - * int plat_crash_console_init(void) - * Function to initialize the crash console - * without a C Runtime to print crash report. - * Clobber list : x0, x1, x2 - * --------------------------------------------- - */ -func plat_crash_console_init -/* mov_imm x0, PLAT_VERSAL_NET_CRASH_UART_BASE - mov_imm x1, PLAT_VERSAL_NET_CRASH_UART_CLK_IN_HZ - mov_imm x2, VERSAL_NET_CONSOLE_BAUDRATE - b console_pl011_core_init */ -endfunc plat_crash_console_init - - /* --------------------------------------------- - * int plat_crash_console_putc(int c) - * Function to print a character on the crash - * console without a C Runtime. - * Clobber list : x1, x2 - * --------------------------------------------- - */ -func plat_crash_console_putc - mov_imm x1, PLAT_VERSAL_NET_CRASH_UART_BASE - b console_pl011_core_putc -endfunc plat_crash_console_putc - - /* --------------------------------------------- - * void plat_crash_console_flush() - * Function to force a write of all buffered - * data that hasn't been output. - * Out : void. - * Clobber list : x0, x1 - * --------------------------------------------- - */ -func plat_crash_console_flush - mov_imm x0, PLAT_VERSAL_NET_CRASH_UART_BASE - b console_pl011_core_flush -endfunc plat_crash_console_flush diff --git a/plat/xilinx/versal_net/bl31_versal_net_setup.c b/plat/xilinx/versal_net/bl31_versal_net_setup.c index d2b6c7bc0..91f9a46e5 100644 --- a/plat/xilinx/versal_net/bl31_versal_net_setup.c +++ b/plat/xilinx/versal_net/bl31_versal_net_setup.c @@ -113,7 +113,7 @@ void bl31_early_platform_setup2(u_register_t arg0, u_register_t arg1, } console_set_scope(&versal_net_runtime_console, CONSOLE_FLAG_BOOT | - CONSOLE_FLAG_RUNTIME); + CONSOLE_FLAG_RUNTIME | CONSOLE_FLAG_CRASH); } else if (VERSAL_NET_CONSOLE_IS(dcc)) { /* Initialize the dcc console for debug. * dcc is over jtag and does not configures uart0 or uart1. diff --git a/plat/xilinx/versal_net/include/versal_net_def.h b/plat/xilinx/versal_net/include/versal_net_def.h index 758882cd7..53eb2cd98 100644 --- a/plat/xilinx/versal_net/include/versal_net_def.h +++ b/plat/xilinx/versal_net/include/versal_net_def.h @@ -144,8 +144,6 @@ #define VERSAL_NET_UART_BASE VERSAL_NET_UART0_BASE #endif -#define PLAT_VERSAL_NET_CRASH_UART_BASE VERSAL_NET_UART_BASE -#define PLAT_VERSAL_NET_CRASH_UART_CLK_IN_HZ VERSAL_NET_UART_CLOCK #define VERSAL_NET_CONSOLE_BAUDRATE VERSAL_NET_UART_BAUDRATE /* Processor core device IDs */ diff --git a/plat/xilinx/versal_net/platform.mk b/plat/xilinx/versal_net/platform.mk index 9c4cfa0b6..9fa16fdee 100644 --- a/plat/xilinx/versal_net/platform.mk +++ b/plat/xilinx/versal_net/platform.mk @@ -86,6 +86,7 @@ PLAT_BL_COMMON_SOURCES := \ drivers/delay_timer/generic_delay_timer.c \ ${GICV3_SOURCES} \ drivers/arm/pl011/aarch64/pl011_console.S \ + plat/common/aarch64/crash_console_helpers.S \ plat/arm/common/arm_common.c \ plat/common/plat_gicv3.c \ ${PLAT_PATH}/aarch64/versal_net_helpers.S \ diff --git a/plat/xilinx/zynqmp/bl31_zynqmp_setup.c b/plat/xilinx/zynqmp/bl31_zynqmp_setup.c index 56d402fdf..f408992e7 100644 --- a/plat/xilinx/zynqmp/bl31_zynqmp_setup.c +++ b/plat/xilinx/zynqmp/bl31_zynqmp_setup.c @@ -81,7 +81,8 @@ void bl31_early_platform_setup2(u_register_t arg0, u_register_t arg1, ZYNQMP_UART_BAUDRATE, &bl31_boot_console); console_set_scope(&bl31_boot_console, - CONSOLE_FLAG_RUNTIME | CONSOLE_FLAG_BOOT); + CONSOLE_FLAG_RUNTIME | CONSOLE_FLAG_BOOT | + CONSOLE_FLAG_CRASH); } else if (ZYNQMP_CONSOLE_IS(dcc)) { /* Initialize the dcc console for debug */ int32_t rc = console_dcc_register(); |