]> Git Repo - qemu.git/blobdiff - hw/vga.c
eepro100: Simplify status handling
[qemu.git] / hw / vga.c
index 5b0c55e99ddea93f51259477ab0d10128d196061..6a1a0597d5c8a790a7c4d4a35a4f440d980a353d 100644 (file)
--- a/hw/vga.c
+++ b/hw/vga.c
@@ -1303,7 +1303,6 @@ static void vga_draw_text(VGACommonState *s, int full_update)
     line_offset = s->line_offset;
 
     vga_get_text_resolution(s, &width, &height, &cw, &cheight);
-    x_incr = cw * ((ds_get_bits_per_pixel(s->ds) + 7) >> 3);
     if ((height * width) > CH_ATTR_SIZE) {
         /* better than nothing: exit if transient size is too big */
         return;
@@ -1606,7 +1605,29 @@ void vga_dirty_log_start(VGACommonState *s)
         kvm_log_start(VBE_DISPI_LFB_PHYSICAL_ADDRESS, s->vram_size);
     }
 #endif
+}
+
+void vga_dirty_log_stop(VGACommonState *s)
+{
+    if (kvm_enabled() && s->map_addr)
+       kvm_log_stop(s->map_addr, s->map_end - s->map_addr);
+
+    if (kvm_enabled() && s->lfb_vram_mapped) {
+       kvm_log_stop(isa_mem_base + 0xa0000, 0x80000);
+       kvm_log_stop(isa_mem_base + 0xa8000, 0x80000);
+    }
 
+#ifdef CONFIG_BOCHS_VBE
+    if (kvm_enabled() && s->vbe_mapped) {
+       kvm_log_stop(VBE_DISPI_LFB_PHYSICAL_ADDRESS, s->vram_size);
+    }
+#endif
+}
+
+void vga_dirty_log_restart(VGACommonState *s)
+{
+    vga_dirty_log_stop(s);
+    vga_dirty_log_start(s);
 }
 
 /*
This page took 0.025684 seconds and 4 git commands to generate.