aboutsummaryrefslogtreecommitdiff
path: root/hw/ppc/e500.c
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2019-11-13 11:17:12 +0100
committerPaolo Bonzini <pbonzini@redhat.com>2019-12-17 19:32:45 +0100
commit4376c40dedb22530738eeb104a603e94ed03f719 (patch)
tree2749159f46643a7e1e2f74ecd9491f189976c93f /hw/ppc/e500.c
parent23b0898e4471f42e62aa1fea304f6a6e23d03310 (diff)
downloadqemu-4376c40dedb22530738eeb104a603e94ed03f719.zip
qemu-4376c40dedb22530738eeb104a603e94ed03f719.tar.gz
qemu-4376c40dedb22530738eeb104a603e94ed03f719.tar.bz2
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 'hw/ppc/e500.c')
-rw-r--r--hw/ppc/e500.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c
index 91cd4c2..12b6a5b 100644
--- a/hw/ppc/e500.c
+++ b/hw/ppc/e500.c
@@ -793,7 +793,6 @@ static DeviceState *ppce500_init_mpic(PPCE500MachineState *pms,
MemoryRegion *ccsr,
IrqLines *irqs)
{
- MachineState *machine = MACHINE(pms);
const PPCE500MachineClass *pmc = PPCE500_MACHINE_GET_CLASS(pms);
DeviceState *dev = NULL;
SysBusDevice *s;
@@ -801,10 +800,10 @@ static DeviceState *ppce500_init_mpic(PPCE500MachineState *pms,
if (kvm_enabled()) {
Error *err = NULL;
- if (machine_kernel_irqchip_allowed(machine)) {
+ if (kvm_kernel_irqchip_allowed()) {
dev = ppce500_init_mpic_kvm(pmc, irqs, &err);
}
- if (machine_kernel_irqchip_required(machine) && !dev) {
+ if (kvm_kernel_irqchip_required() && !dev) {
error_reportf_err(err,
"kernel_irqchip requested but unavailable: ");
exit(1);