boot: Fix gdb support for RISC-V
This will also allow debugging systemd-boot easily on RISC-V.
Note that the following much simpler variant won't work, as we might be missing
the optional 'zihintpause' extension:
asm volatile("pause");
Signed-off-by: Marcel Ziswiler <marcel.ziswiler@codethink.co.uk>
This commit is contained in:
committed by
Yu Watanabe
parent
4290607eae
commit
f620216633
@@ -402,6 +402,8 @@ __attribute__((noinline)) void notify_debugger(const char *identity, volatile bo
|
||||
asm volatile("pause");
|
||||
# elif defined(__aarch64__)
|
||||
asm volatile("wfi");
|
||||
# elif defined(__riscv)
|
||||
asm volatile(".insn i 0x0F, 0, x0, x0, 0x010");
|
||||
# else
|
||||
BS->Stall(5000);
|
||||
# endif
|
||||
|
||||
Reference in New Issue
Block a user