mirror of
https://github.com/raspberrypi/pico-sdk.git
synced 2025-12-10 07:14:36 +01:00
make panic loop back to breakpoint FWIW, and remove spurious header (#2062)
This commit is contained in:
parent
f3459a45d4
commit
31c1be5d5c
1 changed files with 4 additions and 5 deletions
|
|
@ -9,7 +9,6 @@
|
|||
#include <sys/cdefs.h>
|
||||
#include <unistd.h>
|
||||
#include "pico.h"
|
||||
#include "pico/platform/panic.h"
|
||||
|
||||
#if LIB_PICO_PRINTF_PICO
|
||||
#include "pico/printf.h"
|
||||
|
|
@ -38,8 +37,8 @@ void __attribute__((naked, noreturn)) __printflike(1, 0) panic(__unused const ch
|
|||
#if !PICO_PANIC_FUNCTION_EMPTY
|
||||
"jal " __XSTRING(PICO_PANIC_FUNCTION) "\n"
|
||||
#endif
|
||||
"ebreak\n"
|
||||
"1: j 1b\n"
|
||||
"1: ebreak\n"
|
||||
"j 1b\n"
|
||||
|
||||
#else
|
||||
|
||||
|
|
@ -47,8 +46,8 @@ void __attribute__((naked, noreturn)) __printflike(1, 0) panic(__unused const ch
|
|||
#if !PICO_PANIC_FUNCTION_EMPTY
|
||||
"bl " __XSTRING(PICO_PANIC_FUNCTION) "\n"
|
||||
#endif
|
||||
"bkpt #0\n"
|
||||
"1: b 1b\n" // loop for ever as we are no return
|
||||
"1: bkpt #0\n"
|
||||
"b 1b\n" // loop for ever as we are no return
|
||||
|
||||
#endif
|
||||
:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue