d24ea8a733
Currently we use two bits in the vcpu pending_exceptions bitmap to indicate that an external interrupt is pending for the guest, one for "one-shot" interrupts that are cleared when delivered, and one for interrupts that persist until cleared by an explicit action of the OS (e.g. an acknowledge to an interrupt controller). The BOOK3S_IRQPRIO_EXTERNAL bit is used for one-shot interrupt requests and BOOK3S_IRQPRIO_EXTERNAL_LEVEL is used for persisting interrupts. In practice BOOK3S_IRQPRIO_EXTERNAL never gets used, because our Book3S platforms generally, and pseries in particular, expect external interrupt requests to persist until they are acknowledged at the interrupt controller. That combined with the confusion introduced by having two bits for what is essentially the same thing makes it attractive to simplify things by only using one bit. This patch does that. With this patch there is only BOOK3S_IRQPRIO_EXTERNAL, and by default it has the semantics of a persisting interrupt. In order to avoid breaking the ABI, we introduce a new "external_oneshot" flag which preserves the behaviour of the KVM_INTERRUPT ioctl with the KVM_INTERRUPT_SET argument. Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Paul Mackerras <paulus@ozlabs.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
33 lines
768 B
C
33 lines
768 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#if !defined(_TRACE_KVM_BOOK3S_H)
|
|
#define _TRACE_KVM_BOOK3S_H
|
|
|
|
/*
|
|
* Common defines used by the trace macros in trace_pr.h and trace_hv.h
|
|
*/
|
|
|
|
#define kvm_trace_symbol_exit \
|
|
{0x100, "SYSTEM_RESET"}, \
|
|
{0x200, "MACHINE_CHECK"}, \
|
|
{0x300, "DATA_STORAGE"}, \
|
|
{0x380, "DATA_SEGMENT"}, \
|
|
{0x400, "INST_STORAGE"}, \
|
|
{0x480, "INST_SEGMENT"}, \
|
|
{0x500, "EXTERNAL"}, \
|
|
{0x502, "EXTERNAL_HV"}, \
|
|
{0x600, "ALIGNMENT"}, \
|
|
{0x700, "PROGRAM"}, \
|
|
{0x800, "FP_UNAVAIL"}, \
|
|
{0x900, "DECREMENTER"}, \
|
|
{0x980, "HV_DECREMENTER"}, \
|
|
{0xc00, "SYSCALL"}, \
|
|
{0xd00, "TRACE"}, \
|
|
{0xe00, "H_DATA_STORAGE"}, \
|
|
{0xe20, "H_INST_STORAGE"}, \
|
|
{0xe40, "H_EMUL_ASSIST"}, \
|
|
{0xf00, "PERFMON"}, \
|
|
{0xf20, "ALTIVEC"}, \
|
|
{0xf40, "VSX"}
|
|
|
|
#endif
|