]> git.proxmox.com Git - mirror_qemu.git/blame - kvm-stub.c
cpu: Make kvm-stub.o available outside softmmu
[mirror_qemu.git] / kvm-stub.c
CommitLineData
98c8573e
PB
1/*
2 * QEMU KVM stub
3 *
4 * Copyright Red Hat, Inc. 2010
5 *
6 * Author: Paolo Bonzini <pbonzini@redhat.com>
7 *
8 * This work is licensed under the terms of the GNU GPL, version 2 or later.
9 * See the COPYING file in the top-level directory.
10 *
11 */
12
13#include "qemu-common.h"
98c8573e 14#include "hw/hw.h"
2b41f10e 15#include "cpu.h"
9c17d615 16#include "sysemu/kvm.h"
98c8573e 17
c4cfef5e
IM
18#ifndef CONFIG_USER_ONLY
19#include "hw/pci/msi.h"
20#endif
21
92b4e489 22KVMState *kvm_state;
bbf3b804 23bool kvm_kernel_irqchip;
7ae26bd4 24bool kvm_async_interrupts_allowed;
cc7e0ddf 25bool kvm_irqfds_allowed;
614e41bc 26bool kvm_msi_via_irqfd_allowed;
f3e1bed8 27bool kvm_gsi_routing_allowed;
92b4e489 28
504134d2 29int kvm_init_vcpu(CPUState *cpu)
98c8573e
PB
30{
31 return -ENOSYS;
32}
33
cad1e282 34int kvm_init(void)
98c8573e
PB
35{
36 return -ENOSYS;
37}
38
39void kvm_flush_coalesced_mmio_buffer(void)
40{
41}
42
9349b4f9 43void kvm_cpu_synchronize_state(CPUArchState *env)
98c8573e
PB
44{
45}
46
3f24a58f 47void kvm_cpu_synchronize_post_reset(CPUState *cpu)
98c8573e
PB
48{
49}
50
3f24a58f 51void kvm_cpu_synchronize_post_init(CPUState *cpu)
98c8573e
PB
52{
53}
54
9349b4f9 55int kvm_cpu_exec(CPUArchState *env)
98c8573e
PB
56{
57 abort ();
58}
59
60int kvm_has_sync_mmu(void)
61{
62 return 0;
63}
64
d2f2b8a7
SH
65int kvm_has_many_ioeventfds(void)
66{
67 return 0;
68}
69
8a7c7393
JK
70int kvm_has_pit_state2(void)
71{
72 return 0;
73}
74
98c8573e
PB
75void kvm_setup_guest_memory(void *start, size_t size)
76{
77}
78
9349b4f9 79int kvm_update_guest_debug(CPUArchState *env, unsigned long reinject_trap)
98c8573e 80{
4bef75b5 81 return -ENOSYS;
98c8573e
PB
82}
83
9349b4f9 84int kvm_insert_breakpoint(CPUArchState *current_env, target_ulong addr,
98c8573e
PB
85 target_ulong len, int type)
86{
87 return -EINVAL;
88}
89
9349b4f9 90int kvm_remove_breakpoint(CPUArchState *current_env, target_ulong addr,
98c8573e
PB
91 target_ulong len, int type)
92{
93 return -EINVAL;
94}
95
9349b4f9 96void kvm_remove_all_breakpoints(CPUArchState *current_env)
98c8573e
PB
97{
98}
99
100#ifndef _WIN32
9349b4f9 101int kvm_set_signal_mask(CPUArchState *env, const sigset_t *sigset)
98c8573e
PB
102{
103 abort();
104}
105#endif
106
290adf38 107int kvm_on_sigbus_vcpu(CPUState *cpu, int code, void *addr)
a1b87fe0
JK
108{
109 return 1;
110}
111
c0532a76
MT
112int kvm_on_sigbus(int code, void *addr)
113{
114 return 1;
115}
92b4e489 116
c4cfef5e 117#ifndef CONFIG_USER_ONLY
92b4e489
JK
118int kvm_irqchip_add_msi_route(KVMState *s, MSIMessage msg)
119{
120 return -ENOSYS;
121}
1e2aa8be
JK
122
123void kvm_irqchip_release_virq(KVMState *s, int virq)
124{
125}
39853bbc 126
078bbb50
MT
127int kvm_irqchip_update_msi_route(KVMState *s, int virq, MSIMessage msg)
128{
129 return -ENOSYS;
130}
131
b131c74a 132int kvm_irqchip_add_irqfd_notifier(KVMState *s, EventNotifier *n, int virq)
39853bbc
JK
133{
134 return -ENOSYS;
135}
136
b131c74a 137int kvm_irqchip_remove_irqfd_notifier(KVMState *s, EventNotifier *n, int virq)
15b2bd18
PB
138{
139 return -ENOSYS;
140}
c4cfef5e 141#endif