qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] microvm: turn off io reservations for pcie root ports
@ 2022-07-01  9:15 Gerd Hoffmann
  0 siblings, 0 replies; only message in thread
From: Gerd Hoffmann @ 2022-07-01  9:15 UTC (permalink / raw)
  To: qemu-devel
  Cc: Richard Henderson, Marcel Apfelbaum, Paolo Bonzini,
	Michael S. Tsirkin, Sergio Lopez, Eduardo Habkost, Gerd Hoffmann

The pcie host bridge has no io window on microvm,
so io reservations will not work.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
 hw/i386/microvm.c | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/hw/i386/microvm.c b/hw/i386/microvm.c
index 4b3b1dd262f1..06f779e1aaee 100644
--- a/hw/i386/microvm.c
+++ b/hw/i386/microvm.c
@@ -667,6 +667,14 @@ static void microvm_machine_initfn(Object *obj)
     qemu_register_powerdown_notifier(&mms->powerdown_req);
 }
 
+GlobalProperty microvm_properties[] = {
+    /*
+     * pcie host bridge (gpex) on microvm has no io address window,
+     * so reserving io space is not going to work.  Turn it off.
+     */
+    { "pcie-root-port", "io-reserve", "0" },
+};
+
 static void microvm_class_init(ObjectClass *oc, void *data)
 {
     X86MachineClass *x86mc = X86_MACHINE_CLASS(oc);
@@ -757,6 +765,9 @@ static void microvm_class_init(ObjectClass *oc, void *data)
         "Set off to disable adding virtio-mmio devices to the kernel cmdline");
 
     machine_class_allow_dynamic_sysbus_dev(mc, TYPE_RAMFB_DEVICE);
+
+    compat_props_add(mc->compat_props, microvm_properties,
+                     G_N_ELEMENTS(microvm_properties));
 }
 
 static const TypeInfo microvm_machine_info = {
-- 
2.36.1



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2022-07-01  9:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-07-01  9:15 [PATCH v2] microvm: turn off io reservations for pcie root ports Gerd Hoffmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).