This new option may be used to disable the virtio-balloon device.
Signed-off-by: Eduardo Habkost <address@hidden>
---
hw/pc.c | 2 +-
qemu-options.hx | 9 +++++++++
sysemu.h | 1 +
vl.c | 4 ++++
4 files changed, 15 insertions(+), 1 deletions(-)
diff --git a/hw/pc.c b/hw/pc.c
index 0934778..aa92576 100644
--- a/hw/pc.c
+++ b/hw/pc.c
@@ -1152,7 +1152,7 @@ static void pc_init1(ram_addr_t ram_size,
}
/* Add virtio balloon device */
- if (pci_enabled) {
+ if (pci_enabled && !no_virtio_balloon) {
pci_create_simple(pci_bus, -1, "virtio-balloon-pci");
}
diff --git a/qemu-options.hx b/qemu-options.hx
index fa549c3..cb68e2a 100644
--- a/qemu-options.hx
+++ b/qemu-options.hx
@@ -681,6 +681,15 @@ Disable HPET support.
ETEXI
#ifdef TARGET_I386
+DEF("no-virtio-balloon", 0, QEMU_OPTION_no_virtio_balloon,
+ "-no-virtio-baloon disable virtio balloon device\n")