From c87b1520726f7ae1e698a41f07043d1b539ac88c Mon Sep 17 00:00:00 2001 From: Don Slutz Date: Thu, 19 Jun 2014 21:40:25 -0400 Subject: pc & q35: Add new machine opt max-ram-below-4g This is a pc & q35 only machine opt. If you add enough PCI devices then all mmio for them will not fit below 4G which may not be the layout the user wanted. This allows you to increase the below 4G address space that PCI devices can use (aka decrease ram below 4G) and therefore in more cases not have any mmio that is above 4G. For example using "-machine pc,max-ram-below-4g=2G" on the command line will limit the amount of ram that is below 4G to 2G. Note: this machine option cannot be used to increase the amount of ram below 4G. Signed-off-by: Don Slutz Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin MST: fix 32 bit --- include/hw/i386/pc.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include/hw/i386/pc.h') diff --git a/include/hw/i386/pc.h b/include/hw/i386/pc.h index 651971d..486e98f 100644 --- a/include/hw/i386/pc.h +++ b/include/hw/i386/pc.h @@ -33,10 +33,13 @@ struct PCMachineState { MemoryRegion hotplug_memory; HotplugHandler *acpi_dev; + + uint64_t max_ram_below_4g; }; #define PC_MACHINE_ACPI_DEVICE_PROP "acpi-device" #define PC_MACHINE_MEMHP_REGION_SIZE "hotplug-memory-region-size" +#define PC_MACHINE_MAX_RAM_BELOW_4G "max-ram-below-4g" /** * PCMachineClass: -- cgit v1.1