[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 03/19] pc_init1: pass parameters just with types
From: |
Stefano Stabellini |
Subject: |
[Qemu-devel] [PULL 03/19] pc_init1: pass parameters just with types |
Date: |
Tue, 8 Sep 2015 18:21:04 +0100 |
From: Tiejun Chen <address@hidden>
Pass types to configure pc_init1().
Signed-off-by: Tiejun Chen <address@hidden>
Signed-off-by: Stefano Stabellini <address@hidden>
Acked-by: Michael S. Tsirkin <address@hidden>
---
hw/i386/pc_piix.c | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c
index aaf7cfb..626a19f 100644
--- a/hw/i386/pc_piix.c
+++ b/hw/i386/pc_piix.c
@@ -76,7 +76,8 @@ static bool has_reserved_memory = true;
static bool kvmclock_enabled = true;
/* PC hardware initialisation */
-static void pc_init1(MachineState *machine)
+static void pc_init1(MachineState *machine,
+ const char *host_type, const char *pci_type)
{
PCMachineState *pcms = PC_MACHINE(machine);
MemoryRegion *system_memory = get_system_memory();
@@ -196,8 +197,8 @@ static void pc_init1(MachineState *machine)
}
if (pci_enabled) {
- pci_bus = i440fx_init(TYPE_I440FX_PCI_HOST_BRIDGE,
- TYPE_I440FX_PCI_DEVICE,
+ pci_bus = i440fx_init(host_type,
+ pci_type,
&i440fx_state, &piix3_devfn, &isa_bus, gsi,
system_memory, system_io, machine->ram_size,
pcms->below_4g_mem_size,
@@ -416,7 +417,7 @@ static void pc_init_isa(MachineState *machine)
}
x86_cpu_compat_kvm_no_autoenable(FEAT_KVM, 1 << KVM_FEATURE_PV_EOI);
enable_compat_apic_id_mode();
- pc_init1(machine);
+ pc_init1(machine, TYPE_I440FX_PCI_HOST_BRIDGE, TYPE_I440FX_PCI_DEVICE);
}
#ifdef CONFIG_XEN
@@ -424,7 +425,7 @@ static void pc_xen_hvm_init(MachineState *machine)
{
PCIBus *bus;
- pc_init1(machine);
+ pc_init1(machine, TYPE_I440FX_PCI_HOST_BRIDGE, TYPE_I440FX_PCI_DEVICE);
bus = pci_find_primary_bus();
if (bus != NULL) {
@@ -440,7 +441,8 @@ static void pc_xen_hvm_init(MachineState *machine)
if (compat) { \
compat(machine); \
} \
- pc_init1(machine); \
+ pc_init1(machine, TYPE_I440FX_PCI_HOST_BRIDGE, \
+ TYPE_I440FX_PCI_DEVICE); \
} \
DEFINE_PC_MACHINE(suffix, name, pc_init_##suffix, optionfn)
--
1.7.10.4
- [Qemu-devel] [PULL 0/19] xen-2015-09-08-tag, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 04/19] piix: create host bridge to passthrough, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 10/19] xen, gfx passthrough: register host bridge specific to passthrough, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 03/19] pc_init1: pass parameters just with types,
Stefano Stabellini <=
- [Qemu-devel] [PULL 08/19] igd gfx passthrough: create a isa bridge, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 05/19] hw/pci-assign: split pci-assign.c, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 09/19] xen, gfx passthrough: register a isa bridge, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 01/19] xen-hvm: Add trace to ioreq, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 07/19] xen, gfx passthrough: retrieve VGA BIOS to work, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 02/19] i440fx: make types configurable at run-time, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 06/19] xen, gfx passthrough: basic graphics passthrough support, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 17/19] xen: use errno instead of rc for xc_domain_add_to_physmap, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 15/19] xen/pt: Make xen_pt_msi_set_enable static, Stefano Stabellini, 2015/09/08
- [Qemu-devel] [PULL 19/19] xen/pt: Use XEN_PT_LOG properly to guard against compiler warnings., Stefano Stabellini, 2015/09/08