aboutsummaryrefslogtreecommitdiff
path: root/hw/i386/microvm.c
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2021-10-20 14:48:10 +0200
committerPaolo Bonzini <pbonzini@redhat.com>2021-11-02 15:57:27 +0100
commitf014c974595a1e3482c6afb57557a6e479b80328 (patch)
tree048b4cd4294cdf3002d84beb0a229da60cf40b38 /hw/i386/microvm.c
parent0b09d44164b54505490f1771854d0b87441a3e2f (diff)
target/i386: move linuxboot_dma_enabled to X86MachineState
This removes a parameter from x86_load_linux, and will avoid code duplication between the linux and multiboot cases once multiboot starts to support DMA. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/i386/microvm.c')
-rw-r--r--hw/i386/microvm.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/hw/i386/microvm.c b/hw/i386/microvm.c
index f257ec5a0b..837bafb64a 100644
--- a/hw/i386/microvm.c
+++ b/hw/i386/microvm.c
@@ -331,7 +331,7 @@ static void microvm_memory_init(MicrovmMachineState *mms)
rom_set_fw(fw_cfg);
if (machine->kernel_filename != NULL) {
- x86_load_linux(x86ms, fw_cfg, 0, true, true);
+ x86_load_linux(x86ms, fw_cfg, 0, true);
}
if (mms->option_roms) {
@@ -667,6 +667,7 @@ static void microvm_machine_initfn(Object *obj)
static void microvm_class_init(ObjectClass *oc, void *data)
{
+ X86MachineClass *x86mc = X86_MACHINE_CLASS(oc);
MachineClass *mc = MACHINE_CLASS(oc);
HotplugHandlerClass *hc = HOTPLUG_HANDLER_CLASS(oc);
@@ -697,6 +698,8 @@ static void microvm_class_init(ObjectClass *oc, void *data)
hc->unplug_request = microvm_device_unplug_request_cb;
hc->unplug = microvm_device_unplug_cb;
+ x86mc->fwcfg_dma_enabled = true;
+
object_class_property_add(oc, MICROVM_MACHINE_PIC, "OnOffAuto",
microvm_machine_get_pic,
microvm_machine_set_pic,