diff options
author | Anthony Liguori <aliguori@us.ibm.com> | 2012-06-26 15:07:03 -0500 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2012-06-26 15:07:03 -0500 |
commit | 3aa42d329b4a26af6105ff199be1a785b9ddd461 (patch) | |
tree | 8cb011152af3a1d4e27aa5c8da15a806fc85b723 /hw/vmware_vga.c | |
parent | 675658d97e86c42278fc08f8fb4c9531a027b4e7 (diff) | |
parent | 9e56edcf8dd1d4bc7ba2b1efb3641f36c0fad8ba (diff) |
Merge remote-tracking branch 'spice/spice.v58' into staging
* spice/spice.v58:
vga: raise default vgamem size
add pc-1.2
qxl: add vgamem_size_mb and vgamem_size
vga: make vram size configurable
vga: raise xres+yres limits
qxl: reset current_async on qxl_soft_reset
hw/qxl: ignore guest from guestbug until reset
qxl: stop dirty loging when not in vga mode
hw/qxl: s/qxl_guest_bug/qxl_set_guest_bug/
ui/spice-display.c: add missing initialization for valgrind
Diffstat (limited to 'hw/vmware_vga.c')
-rw-r--r-- | hw/vmware_vga.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/hw/vmware_vga.c b/hw/vmware_vga.c index 142d9f4ea0..476dc89a0c 100644 --- a/hw/vmware_vga.c +++ b/hw/vmware_vga.c @@ -1078,7 +1078,7 @@ static const VMStateDescription vmstate_vmware_vga = { } }; -static void vmsvga_init(struct vmsvga_state_s *s, int vga_ram_size, +static void vmsvga_init(struct vmsvga_state_s *s, MemoryRegion *address_space, MemoryRegion *io) { s->scratch_size = SVGA_SCRATCH_SIZE; @@ -1095,7 +1095,7 @@ static void vmsvga_init(struct vmsvga_state_s *s, int vga_ram_size, vmstate_register_ram_global(&s->fifo_ram); s->fifo_ptr = memory_region_get_ram_ptr(&s->fifo_ram); - vga_common_init(&s->vga, vga_ram_size); + vga_common_init(&s->vga); vga_init(&s->vga, address_space, io, true); vmstate_register(NULL, 0, &vmstate_vga_common, &s->vga); @@ -1184,7 +1184,7 @@ static int pci_vmsvga_initfn(PCIDevice *dev) "vmsvga-io", 0x10); pci_register_bar(&s->card, 0, PCI_BASE_ADDRESS_SPACE_IO, &s->io_bar); - vmsvga_init(&s->chip, VGA_RAM_SIZE, pci_address_space(dev), + vmsvga_init(&s->chip, pci_address_space(dev), pci_address_space_io(dev)); pci_register_bar(&s->card, 1, PCI_BASE_ADDRESS_MEM_PREFETCH, iomem); @@ -1199,6 +1199,12 @@ static int pci_vmsvga_initfn(PCIDevice *dev) return 0; } +static Property vga_vmware_properties[] = { + DEFINE_PROP_UINT32("vgamem_mb", struct pci_vmsvga_state_s, + chip.vga.vram_size_mb, 16), + DEFINE_PROP_END_OF_LIST(), +}; + static void vmsvga_class_init(ObjectClass *klass, void *data) { DeviceClass *dc = DEVICE_CLASS(klass); @@ -1214,6 +1220,7 @@ static void vmsvga_class_init(ObjectClass *klass, void *data) k->subsystem_id = SVGA_PCI_DEVICE_ID; dc->reset = vmsvga_reset; dc->vmsd = &vmstate_vmware_vga; + dc->props = vga_vmware_properties; } static TypeInfo vmsvga_info = { |