diff options
author | Eduardo Habkost <ehabkost@redhat.com> | 2015-08-07 16:55:52 -0300 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2015-08-13 14:08:28 +0300 |
commit | b9cfc918ddcbbb5d3b8c1a47675b927cc25eb632 (patch) | |
tree | 80112c35abb842028671ea37e3bdade3f1e91ca0 /hw | |
parent | c0aa4e1ecbcad29bb9f1d654f930300b975c3ba8 (diff) |
pc: Use PCMachineState as pc_guest_info_init() argument
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw')
-rw-r--r-- | hw/i386/pc.c | 7 | ||||
-rw-r--r-- | hw/i386/pc_piix.c | 3 | ||||
-rw-r--r-- | hw/i386/pc_q35.c | 3 |
3 files changed, 5 insertions, 8 deletions
diff --git a/hw/i386/pc.c b/hw/i386/pc.c index a9a9cf4823..081ef835c1 100644 --- a/hw/i386/pc.c +++ b/hw/i386/pc.c @@ -1189,15 +1189,14 @@ void pc_guest_info_machine_done(Notifier *notifier, void *data) acpi_setup(&guest_info_state->info); } -PcGuestInfo *pc_guest_info_init(ram_addr_t below_4g_mem_size, - ram_addr_t above_4g_mem_size) +PcGuestInfo *pc_guest_info_init(PCMachineState *pcms) { PcGuestInfoState *guest_info_state = g_malloc0(sizeof *guest_info_state); PcGuestInfo *guest_info = &guest_info_state->info; int i, j; - guest_info->ram_size_below_4g = below_4g_mem_size; - guest_info->ram_size = below_4g_mem_size + above_4g_mem_size; + guest_info->ram_size_below_4g = pcms->below_4g_mem_size; + guest_info->ram_size = pcms->below_4g_mem_size + pcms->above_4g_mem_size; guest_info->apic_id_limit = pc_apic_id_limit(max_cpus); guest_info->apic_xrupt_override = kvm_allows_irq0_override(); guest_info->numa_nodes = nb_numa_nodes; diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c index 559f4e52b8..9364c47b1a 100644 --- a/hw/i386/pc_piix.c +++ b/hw/i386/pc_piix.c @@ -160,8 +160,7 @@ static void pc_init1(MachineState *machine) rom_memory = system_memory; } - guest_info = pc_guest_info_init(pcms->below_4g_mem_size, - pcms->above_4g_mem_size); + guest_info = pc_guest_info_init(pcms); guest_info->has_acpi_build = has_acpi_build; guest_info->legacy_acpi_table_size = legacy_acpi_table_size; diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c index 489dfcb55b..af5fd9f9d6 100644 --- a/hw/i386/pc_q35.c +++ b/hw/i386/pc_q35.c @@ -151,8 +151,7 @@ static void pc_q35_init(MachineState *machine) rom_memory = get_system_memory(); } - guest_info = pc_guest_info_init(pcms->below_4g_mem_size, - pcms->above_4g_mem_size); + guest_info = pc_guest_info_init(pcms); guest_info->isapc_ram_fw = false; guest_info->has_acpi_build = has_acpi_build; guest_info->has_reserved_memory = has_reserved_memory; |