]> git.proxmox.com Git - mirror_qemu.git/blobdiff - hw/vga-isa-mm.c
vga: make vram size configurable
[mirror_qemu.git] / hw / vga-isa-mm.c
index f8984c62cb3f55f93a5d4c44d478944a11fc9d1f..44ae7d92c8ce527f16dfcaa14366d3d34a2b5316 100644 (file)
@@ -28,6 +28,8 @@
 #include "pixel_ops.h"
 #include "qemu-timer.h"
 
+#define VGA_RAM_SIZE (8192 * 1024)
+
 typedef struct ISAVGAMMState {
     VGACommonState vga;
     int it_shift;
@@ -128,7 +130,8 @@ int isa_vga_mm_init(target_phys_addr_t vram_base,
 
     s = g_malloc0(sizeof(*s));
 
-    vga_common_init(&s->vga, VGA_RAM_SIZE);
+    s->vga.vram_size_mb = VGA_RAM_SIZE >> 20;
+    vga_common_init(&s->vga);
     vga_mm_init(s, vram_base, ctrl_base, it_shift, address_space);
 
     s->vga.ds = graphic_console_init(s->vga.update, s->vga.invalidate,