linux-stable/arch/loongarch/include/uapi/asm
Bibo Mao 163e9fc695 LoongArch: KVM: Add software breakpoint support
When VM runs in kvm mode, system will not exit to host mode when
executing a general software breakpoint instruction such as INSN_BREAK,
trap exception happens in guest mode rather than host mode. In order to
debug guest kernel on host side, one mechanism should be used to let VM
exit to host mode.

Here a hypercall instruction with a special code is used for software
breakpoint usage. VM exits to host mode and kvm hypervisor identifies
the special hypercall code and sets exit_reason with KVM_EXIT_DEBUG. And
then let qemu handle it.

Idea comes from ppc kvm, one api KVM_REG_LOONGARCH_DEBUG_INST is added
to get the hypercall code. VMM needs get sw breakpoint instruction with
this api and set the corresponding sw break point for guest kernel.

Signed-off-by: Bibo Mao <maobibo@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
2024-05-06 22:00:47 +08:00
..
Kbuild
auxvec.h LoongArch: Add ELF and module support 2022-06-03 20:09:28 +08:00
bpf_perf_event.h LoongArch: Add BPF JIT support 2022-10-12 16:36:20 +08:00
break.h LoongArch: Add exception/interrupt handling 2022-06-03 20:09:28 +08:00
byteorder.h
hwcap.h LoongArch: Introduce hardware page table walker 2023-06-29 20:58:44 +08:00
kvm.h LoongArch: KVM: Add software breakpoint support 2024-05-06 22:00:47 +08:00
perf_regs.h LoongArch: Add perf events support 2022-10-12 16:36:14 +08:00
ptrace.h LoongArch: Add Loongson Binary Translation (LBT) extension support 2023-09-06 22:53:55 +08:00
reg.h
sigcontext.h LoongArch: Add Loongson Binary Translation (LBT) extension support 2023-09-06 22:53:55 +08:00
signal.h LoongArch: Add signal handling support 2022-06-03 20:09:28 +08:00
ucontext.h LoongArch: Add signal handling support 2022-06-03 20:09:28 +08:00
unistd.h LoongArch: Add system call support 2022-06-03 20:09:28 +08:00