diff options
Diffstat (limited to 'hw/cirrus_vga.c')
-rw-r--r-- | hw/cirrus_vga.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/hw/cirrus_vga.c b/hw/cirrus_vga.c index dfbb59ad7..e79dd1765 100644 --- a/hw/cirrus_vga.c +++ b/hw/cirrus_vga.c @@ -1393,6 +1393,8 @@ cirrus_hook_write_sr(CirrusVGAState * s, unsigned reg_index, int reg_value) break; } + vga_update_resolution((VGAState *)s); + return CIRRUS_HOOK_HANDLED; } @@ -1420,6 +1422,7 @@ static void cirrus_write_hidden_dac(CirrusVGAState * s, int reg_value) #endif } s->cirrus_hidden_dac_lockindex = 0; + vga_update_resolution((VGAState *)s); } /*************************************** @@ -1706,6 +1709,8 @@ cirrus_hook_write_cr(CirrusVGAState * s, unsigned reg_index, int reg_value) break; } + vga_update_resolution((VGAState *)s); + return CIRRUS_HOOK_HANDLED; } @@ -2833,6 +2838,7 @@ static void vga_ioport_write(void *opaque, uint32_t addr, uint32_t val) if (s->ar_flip_flop == 0) { val &= 0x3f; s->ar_index = val; + vga_update_resolution((VGAState *)s); } else { index = s->ar_index & 0x1f; switch (index) { @@ -2926,6 +2932,7 @@ static void vga_ioport_write(void *opaque, uint32_t addr, uint32_t val) /* can always write bit 4 of CR7 */ if (s->cr_index == 7) s->cr[7] = (s->cr[7] & ~0x10) | (val & 0x10); + vga_update_resolution((VGAState *)s); return; } switch (s->cr_index) { @@ -2954,6 +2961,7 @@ static void vga_ioport_write(void *opaque, uint32_t addr, uint32_t val) s->update_retrace_info((VGAState *) s); break; } + vga_update_resolution((VGAState *)s); break; case 0x3ba: case 0x3da: @@ -3160,7 +3168,8 @@ static int cirrus_vga_load(QEMUFile *f, void *opaque, int version_id) cirrus_update_memory_access(s); /* force refresh */ - s->graphic_mode = -1; + vga_update_resolution((VGAState *)s); + s->want_full_update = 1; cirrus_update_bank_ptr(s, 0); cirrus_update_bank_ptr(s, 1); return 0; |