diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2019-11-13 11:17:12 +0100 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2019-12-17 19:32:45 +0100 |
commit | 4376c40dedb22530738eeb104a603e94ed03f719 (patch) | |
tree | 2749159f46643a7e1e2f74ecd9491f189976c93f /target | |
parent | 23b0898e4471f42e62aa1fea304f6a6e23d03310 (diff) |
kvm: introduce kvm_kernel_irqchip_* functions
The KVMState struct is opaque, so provide accessors for the fields
that will be moved from current_machine to the accelerator. For now
they just forward to the machine object, but this will change.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'target')
-rw-r--r-- | target/arm/kvm.c | 8 | ||||
-rw-r--r-- | target/i386/kvm.c | 4 | ||||
-rw-r--r-- | target/mips/kvm.c | 2 | ||||
-rw-r--r-- | target/ppc/kvm.c | 2 | ||||
-rw-r--r-- | target/s390x/kvm.c | 2 |
5 files changed, 9 insertions, 9 deletions
diff --git a/target/arm/kvm.c b/target/arm/kvm.c index 5b82cefef6..b87b59a02a 100644 --- a/target/arm/kvm.c +++ b/target/arm/kvm.c @@ -741,11 +741,11 @@ void kvm_arch_init_irq_routing(KVMState *s) { } -int kvm_arch_irqchip_create(MachineState *ms, KVMState *s) +int kvm_arch_irqchip_create(KVMState *s) { - if (machine_kernel_irqchip_split(ms)) { - perror("-machine kernel_irqchip=split is not supported on ARM."); - exit(1); + if (kvm_kernel_irqchip_split()) { + perror("-machine kernel_irqchip=split is not supported on ARM."); + exit(1); } /* If we can create the VGIC using the newer device control API, we diff --git a/target/i386/kvm.c b/target/i386/kvm.c index 62ce681a96..ef63f3a5a6 100644 --- a/target/i386/kvm.c +++ b/target/i386/kvm.c @@ -4494,10 +4494,10 @@ void kvm_arch_init_irq_routing(KVMState *s) } } -int kvm_arch_irqchip_create(MachineState *ms, KVMState *s) +int kvm_arch_irqchip_create(KVMState *s) { int ret; - if (machine_kernel_irqchip_split(ms)) { + if (kvm_kernel_irqchip_split()) { ret = kvm_vm_enable_cap(s, KVM_CAP_SPLIT_IRQCHIP, 0, 24); if (ret) { error_report("Could not enable split irqchip mode: %s", diff --git a/target/mips/kvm.c b/target/mips/kvm.c index 578bc14625..de3e26ef1f 100644 --- a/target/mips/kvm.c +++ b/target/mips/kvm.c @@ -57,7 +57,7 @@ int kvm_arch_init(MachineState *ms, KVMState *s) return 0; } -int kvm_arch_irqchip_create(MachineState *ms, KVMState *s) +int kvm_arch_irqchip_create(KVMState *s) { return 0; } diff --git a/target/ppc/kvm.c b/target/ppc/kvm.c index 7406d18945..f7e187c961 100644 --- a/target/ppc/kvm.c +++ b/target/ppc/kvm.c @@ -152,7 +152,7 @@ int kvm_arch_init(MachineState *ms, KVMState *s) return 0; } -int kvm_arch_irqchip_create(MachineState *ms, KVMState *s) +int kvm_arch_irqchip_create(KVMState *s) { return 0; } diff --git a/target/s390x/kvm.c b/target/s390x/kvm.c index ad6e38c876..15260aeb9a 100644 --- a/target/s390x/kvm.c +++ b/target/s390x/kvm.c @@ -374,7 +374,7 @@ int kvm_arch_init(MachineState *ms, KVMState *s) return 0; } -int kvm_arch_irqchip_create(MachineState *ms, KVMState *s) +int kvm_arch_irqchip_create(KVMState *s) { return 0; } |