aboutsummaryrefslogtreecommitdiff
path: root/hw/i386/pc_q35.c
diff options
context:
space:
mode:
authorEric Auger <eric.auger@redhat.com>2019-03-08 19:20:53 +0100
committerEduardo Habkost <ehabkost@redhat.com>2019-03-11 10:44:25 -0300
commitf6a0d06ba72a0c493e1e05872caf2f3781af316d (patch)
tree19fd6ed21c17ef6bfe53733bbc4bdeb5169f23b4 /hw/i386/pc_q35.c
parentc1404bde9cb326a42327c892e25ecbfcce806a3d (diff)
downloadqemu-f6a0d06ba72a0c493e1e05872caf2f3781af316d.zip
qemu-f6a0d06ba72a0c493e1e05872caf2f3781af316d.tar.gz
qemu-f6a0d06ba72a0c493e1e05872caf2f3781af316d.tar.bz2
machine: Move nvdimms state into struct MachineState
As NVDIMM support is looming for ARM and SPAPR, let's move the acpi_nvdimm_state to the generic machine struct instead of duplicating the same code in several machines. It is also renamed into nvdimms_state and becomes a pointer. nvdimm and nvdimm-persistence become generic machine options. They become guarded by a nvdimm_supported machine class member. We also add a description for those options. Signed-off-by: Eric Auger <eric.auger@redhat.com> Suggested-by: Igor Mammedov <imammedo@redhat.com> Message-Id: <20190308182053.5487-3-eric.auger@redhat.com> Reviewed-by: Igor Mammedov <imammedo@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Diffstat (limited to 'hw/i386/pc_q35.c')
-rw-r--r--hw/i386/pc_q35.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
index cfb9043..372c6b7 100644
--- a/hw/i386/pc_q35.c
+++ b/hw/i386/pc_q35.c
@@ -329,8 +329,8 @@ static void pc_q35_init(MachineState *machine)
pc_vga_init(isa_bus, host_bus);
pc_nic_init(pcmc, isa_bus, host_bus);
- if (pcms->acpi_nvdimm_state.is_enabled) {
- nvdimm_init_acpi_state(&pcms->acpi_nvdimm_state, system_io,
+ if (machine->nvdimms_state->is_enabled) {
+ nvdimm_init_acpi_state(machine->nvdimms_state, system_io,
pcms->fw_cfg, OBJECT(pcms));
}
}