]> Git Repo - qemu.git/commitdiff
qxl: always update displaysurface on resize
authorGerd Hoffmann <[email protected]>
Fri, 14 Sep 2012 20:09:23 +0000 (22:09 +0200)
committerGerd Hoffmann <[email protected]>
Mon, 8 Oct 2012 05:37:10 +0000 (07:37 +0200)
Don't try to be clever and skip displaysurface reinitialization in case
the size hasn't changed.  Other parameters might have changed
nevertheless, for example depth or stride, resulting in rendering being
broken then.

Trigger: boot linux guest with vesafb, start X11, make sure both vesafb
and X11 use the display same resolution.  Then watch X11 screen being
upside down.

Signed-off-by: Gerd Hoffmann <[email protected]>
hw/qxl-render.c

index e2e3fe2d370b3187a02c354ad0ec7b1a19ba2265..b66c168ef676891d5b9c76a814cd936f6d8b397a 100644 (file)
@@ -99,7 +99,6 @@ static void qxl_render_update_area_unlocked(PCIQXLDevice *qxl)
 {
     VGACommonState *vga = &qxl->vga;
     int i;
-    DisplaySurface *surface = vga->ds->surface;
 
     if (qxl->guest_primary.resized) {
         qxl->guest_primary.resized = 0;
@@ -112,9 +111,6 @@ static void qxl_render_update_area_unlocked(PCIQXLDevice *qxl)
                qxl->guest_primary.qxl_stride,
                qxl->guest_primary.bytes_pp,
                qxl->guest_primary.bits_pp);
-    }
-    if (surface->width != qxl->guest_primary.surface.width ||
-        surface->height != qxl->guest_primary.surface.height) {
         if (qxl->guest_primary.qxl_stride > 0) {
             qemu_free_displaysurface(vga->ds);
             qemu_create_displaysurface_from(qxl->guest_primary.surface.width,
This page took 0.027016 seconds and 4 git commands to generate.