diff --git a/bl31/aarch64/crash_reporting.S b/bl31/aarch64/crash_reporting.S index 2c41029..f2c1296 100644 --- a/bl31/aarch64/crash_reporting.S +++ b/bl31/aarch64/crash_reporting.S @@ -62,14 +62,6 @@ .asciz "Unhandled Interrupt Exception in EL3.\nx30" /* - * Helper function to print newline to console. - */ -func print_newline - mov x0, '\n' - b plat_crash_console_putc -endfunc print_newline - - /* * Helper function to print from crash buf. * The print loop is controlled by the buf size and * ascii reg name list which is passed in x6. The @@ -101,7 +93,7 @@ bl print_alignment ldr x4, [x7], #REGSZ bl asm_print_hex - bl print_newline + bl asm_print_newline b test_size_list exit_size_print: mov x30, sp @@ -253,7 +245,7 @@ /* report x30 first from the crash buf */ ldr x4, [x0, #REGSZ * 7] bl asm_print_hex - bl print_newline + bl asm_print_newline /* Load the crash buf address */ mrs x0, tpidr_el3 /* Now mov x7 into crash buf */ diff --git a/common/aarch64/debug.S b/common/aarch64/debug.S index ac47cbe..e6e3298 100644 --- a/common/aarch64/debug.S +++ b/common/aarch64/debug.S @@ -11,6 +11,7 @@ .globl asm_print_str .globl asm_print_hex .globl asm_print_hex_bits + .globl asm_print_newline .globl asm_assert .globl do_panic @@ -130,6 +131,15 @@ ret x3 endfunc asm_print_hex +/* + * Helper function to print newline to console + * Clobber: x0 + */ +func asm_print_newline + mov x0, '\n' + b plat_crash_console_putc +endfunc asm_print_newline + /*********************************************************** * The common implementation of do_panic for all BL stages ***********************************************************/