Re: [Qemu-devel] [PATCH 5/5] vga-cirrus: Workaround during restore when using Xen.

2011-11-25 Thread Anthony PERARD
On Fri, Nov 25, 2011 at 11:51, Stefano Stabellini wrote: >> On Thu, Nov 24, 2011 at 18:30, Stefano Stabellini >> wrote: >> > >> >> @@ -2784,9 +2796,11 @@ static void cirrus_reset(void *opaque) >> >>      } >> >>      s->vga.cr[0x27] = s->device_id; >> >> >> >> -    /* Win2K seems to assume that t

Re: [Qemu-devel] [PATCH 5/5] vga-cirrus: Workaround during restore when using Xen.

2011-11-25 Thread Stefano Stabellini
> On Thu, Nov 24, 2011 at 18:30, Stefano Stabellini > wrote: > > > >> @@ -2784,9 +2796,11 @@ static void cirrus_reset(void *opaque) > >>      } > >>      s->vga.cr[0x27] = s->device_id; > >> > >> -    /* Win2K seems to assume that the pattern buffer is at 0xff > >> -       initially ! *

Re: [Qemu-devel] [PATCH 5/5] vga-cirrus: Workaround during restore when using Xen.

2011-11-24 Thread Anthony PERARD
On Thu, Nov 24, 2011 at 18:30, Stefano Stabellini wrote: > >> @@ -2784,9 +2796,11 @@ static void cirrus_reset(void *opaque) >>      } >>      s->vga.cr[0x27] = s->device_id; >> >> -    /* Win2K seems to assume that the pattern buffer is at 0xff >> -       initially ! */ >> -    memset(s->vga.vram_

Re: [Qemu-devel] [PATCH 5/5] vga-cirrus: Workaround during restore when using Xen.

2011-11-24 Thread Stefano Stabellini
On Thu, 24 Nov 2011, Anthony PERARD wrote: > During the initialisation of the machine at restore time, the access to the > VRAM will fail because QEMU does not know yet the right guest address to map, > so the vram_ptr is NULL. > > So this patch avoid using a NULL pointer during initialisation, an

[Qemu-devel] [PATCH 5/5] vga-cirrus: Workaround during restore when using Xen.

2011-11-24 Thread Anthony PERARD
During the initialisation of the machine at restore time, the access to the VRAM will fail because QEMU does not know yet the right guest address to map, so the vram_ptr is NULL. So this patch avoid using a NULL pointer during initialisation, and try to get another vram_ptr if the call failed the