/src/qemu/include/system/accel-irq.h
Line | Count | Source |
1 | | /* |
2 | | * Accelerated irqchip abstraction |
3 | | * |
4 | | * Copyright Microsoft, Corp. 2025 |
5 | | * |
6 | | * Authors: Ziqiao Zhou <ziqiaozhou@microsoft.com> |
7 | | * Magnus Kulke <magnuskulke@microsoft.com> |
8 | | * |
9 | | * SPDX-License-Identifier: GPL-2.0-or-later |
10 | | */ |
11 | | |
12 | | #ifndef SYSTEM_ACCEL_IRQ_H |
13 | | #define SYSTEM_ACCEL_IRQ_H |
14 | | #include "hw/pci/msi.h" |
15 | | #include "system/kvm.h" |
16 | | #include "system/mshv.h" |
17 | | |
18 | | static inline bool accel_msi_via_irqfd_enabled(void) |
19 | 115k | { |
20 | 115k | return mshv_msi_via_irqfd_enabled() || kvm_msi_via_irqfd_enabled(); |
21 | 115k | } Unexecuted instantiation: accel-irq.c:accel_msi_via_irqfd_enabled Unexecuted instantiation: ivshmem-pci.c:accel_msi_via_irqfd_enabled Unexecuted instantiation: pci.c:accel_msi_via_irqfd_enabled virtio-pci.c:accel_msi_via_irqfd_enabled Line | Count | Source | 19 | 115k | { | 20 | 115k | return mshv_msi_via_irqfd_enabled() || kvm_msi_via_irqfd_enabled(); | 21 | 115k | } |
Unexecuted instantiation: kvm.c:accel_msi_via_irqfd_enabled Unexecuted instantiation: ioapic.c:accel_msi_via_irqfd_enabled |
22 | | |
23 | | static inline bool accel_irqchip_is_split(void) |
24 | 5.54k | { |
25 | 5.54k | return mshv_msi_via_irqfd_enabled() || kvm_irqchip_is_split(); |
26 | 5.54k | } Unexecuted instantiation: accel-irq.c:accel_irqchip_is_split Unexecuted instantiation: ivshmem-pci.c:accel_irqchip_is_split Unexecuted instantiation: pci.c:accel_irqchip_is_split Unexecuted instantiation: virtio-pci.c:accel_irqchip_is_split Unexecuted instantiation: kvm.c:accel_irqchip_is_split ioapic.c:accel_irqchip_is_split Line | Count | Source | 24 | 5.54k | { | 25 | 5.54k | return mshv_msi_via_irqfd_enabled() || kvm_irqchip_is_split(); | 26 | 5.54k | } |
|
27 | | |
28 | | AccelRouteChange accel_irqchip_begin_route_changes(void); |
29 | | int accel_irqchip_add_msi_route(AccelRouteChange *c, int vector, |
30 | | PCIDevice *dev); |
31 | | int accel_irqchip_update_msi_route(int vector, MSIMessage msg, PCIDevice *dev); |
32 | | void accel_irqchip_commit_route_changes(AccelRouteChange *c); |
33 | | void accel_irqchip_commit_routes(void); |
34 | | void accel_irqchip_release_virq(int virq); |
35 | | int accel_irqchip_add_irqfd_notifier_gsi(EventNotifier *n, EventNotifier *rn, |
36 | | int virq); |
37 | | int accel_irqchip_remove_irqfd_notifier_gsi(EventNotifier *n, int virq); |
38 | | #endif |