From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LiBq9-0003je-LD for qemu-devel@nongnu.org; Fri, 13 Mar 2009 14:10:37 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LiBq9-0003io-1W for qemu-devel@nongnu.org; Fri, 13 Mar 2009 14:10:37 -0400 Received: from [199.232.76.173] (port=57176 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LiBq8-0003iZ-R5 for qemu-devel@nongnu.org; Fri, 13 Mar 2009 14:10:36 -0400 Received: from savannah.gnu.org ([199.232.41.3]:37014 helo=sv.gnu.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LiBq8-0001v2-CT for qemu-devel@nongnu.org; Fri, 13 Mar 2009 14:10:36 -0400 Received: from cvs.savannah.gnu.org ([199.232.41.69]) by sv.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1LiBq7-0007lw-HR for qemu-devel@nongnu.org; Fri, 13 Mar 2009 18:10:35 +0000 Received: from aliguori by cvs.savannah.gnu.org with local (Exim 4.69) (envelope-from ) id 1LiBpy-0007lD-NJ for qemu-devel@nongnu.org; Fri, 13 Mar 2009 18:10:31 +0000 MIME-Version: 1.0 Errors-To: aliguori Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Anthony Liguori Message-Id: Date: Fri, 13 Mar 2009 18:10:26 +0000 Subject: [Qemu-devel] [6852] temporarily disable logging around pci config writes (Avi Kivity) Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Revision: 6852 http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=6852 Author: aliguori Date: 2009-03-13 18:10:13 +0000 (Fri, 13 Mar 2009) Log Message: ----------- temporarily disable logging around pci config writes (Avi Kivity) A pci config write may remap the vga linear frame buffer, confusing the memory slot dirty logging logic. Fixed Windows with -vga std. Signed-off-by: Avi Kivity Sigend-off-by: Anthony Liguori Modified Paths: -------------- trunk/hw/vga.c Modified: trunk/hw/vga.c =================================================================== --- trunk/hw/vga.c 2009-03-13 18:09:59 UTC (rev 6851) +++ trunk/hw/vga.c 2009-03-13 18:10:13 UTC (rev 6852) @@ -2481,6 +2481,17 @@ return 0; } +static void pci_vga_write_config(PCIDevice *d, + uint32_t address, uint32_t val, int len) +{ + PCIVGAState *pvs = container_of(d, PCIVGAState, dev); + VGAState *s = &pvs->vga_state; + + vga_dirty_log_stop(s); + pci_default_write_config(d, address, val, len); + vga_dirty_log_start(s); +} + int pci_vga_init(PCIBus *bus, uint8_t *vga_ram_base, unsigned long vga_ram_offset, int vga_ram_size, unsigned long vga_bios_offset, int vga_bios_size) @@ -2491,7 +2502,7 @@ d = (PCIVGAState *)pci_register_device(bus, "VGA", sizeof(PCIVGAState), - -1, NULL, NULL); + -1, NULL, pci_vga_write_config); if (!d) return -1; s = &d->vga_state;