Commit b4fbd8798aeb7870221769576973aeed909d304b
1 parent
4efe2755
move vga_io_address to VGA State (Glauber Costa)
It'll be reused later by the vga optimization. Signed-off-by: Glauber Costa <glommer@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5791 c046a42c-6fe2-441c-8c8c-71466251a162
Showing
2 changed files
with
4 additions
and
3 deletions
hw/cirrus_vga.c
... | ... | @@ -3117,7 +3117,7 @@ static int cirrus_vga_load(QEMUFile *f, void *opaque, int version_id) |
3117 | 3117 | |
3118 | 3118 | static void cirrus_init_common(CirrusVGAState * s, int device_id, int is_pci) |
3119 | 3119 | { |
3120 | - int vga_io_memory, i; | |
3120 | + int i; | |
3121 | 3121 | static int inited; |
3122 | 3122 | |
3123 | 3123 | if (!inited) { |
... | ... | @@ -3156,10 +3156,10 @@ static void cirrus_init_common(CirrusVGAState * s, int device_id, int is_pci) |
3156 | 3156 | register_ioport_read(0x3ba, 1, 1, vga_ioport_read, s); |
3157 | 3157 | register_ioport_read(0x3da, 1, 1, vga_ioport_read, s); |
3158 | 3158 | |
3159 | - vga_io_memory = cpu_register_io_memory(0, cirrus_vga_mem_read, | |
3159 | + s->vga_io_memory = cpu_register_io_memory(0, cirrus_vga_mem_read, | |
3160 | 3160 | cirrus_vga_mem_write, s); |
3161 | 3161 | cpu_register_physical_memory(isa_mem_base + 0x000a0000, 0x20000, |
3162 | - vga_io_memory); | |
3162 | + s->vga_io_memory); | |
3163 | 3163 | |
3164 | 3164 | s->sr[0x06] = 0x0f; |
3165 | 3165 | if (device_id == CIRRUS_ID_CLGD5446) { | ... | ... |
hw/vga_int.h
... | ... | @@ -129,6 +129,7 @@ typedef void (* vga_update_retrace_info_fn)(struct VGAState *s); |
129 | 129 | int dac_8bit; \ |
130 | 130 | uint8_t palette[768]; \ |
131 | 131 | int32_t bank_offset; \ |
132 | + int vga_io_memory; \ | |
132 | 133 | int (*get_bpp)(struct VGAState *s); \ |
133 | 134 | void (*get_offsets)(struct VGAState *s, \ |
134 | 135 | uint32_t *pline_offset, \ | ... | ... |