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 <avi@redhat.com> Sigend-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6852 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
		
							parent
							
								
									8a93e519f3
								
							
						
					
					
						commit
						92a3ecda67
					
				
							
								
								
									
										13
									
								
								hw/vga.c
									
									
									
									
									
								
							
							
						
						
									
										13
									
								
								hw/vga.c
									
									
									
									
									
								
							@ -2481,6 +2481,17 @@ int isa_vga_mm_init(uint8_t *vga_ram_base,
 | 
				
			|||||||
    return 0;
 | 
					    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,
 | 
					int pci_vga_init(PCIBus *bus, uint8_t *vga_ram_base,
 | 
				
			||||||
                 unsigned long vga_ram_offset, int vga_ram_size,
 | 
					                 unsigned long vga_ram_offset, int vga_ram_size,
 | 
				
			||||||
                 unsigned long vga_bios_offset, int vga_bios_size)
 | 
					                 unsigned long vga_bios_offset, int vga_bios_size)
 | 
				
			||||||
@ -2491,7 +2502,7 @@ int pci_vga_init(PCIBus *bus, uint8_t *vga_ram_base,
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    d = (PCIVGAState *)pci_register_device(bus, "VGA",
 | 
					    d = (PCIVGAState *)pci_register_device(bus, "VGA",
 | 
				
			||||||
                                           sizeof(PCIVGAState),
 | 
					                                           sizeof(PCIVGAState),
 | 
				
			||||||
                                           -1, NULL, NULL);
 | 
					                                           -1, NULL, pci_vga_write_config);
 | 
				
			||||||
    if (!d)
 | 
					    if (!d)
 | 
				
			||||||
        return -1;
 | 
					        return -1;
 | 
				
			||||||
    s = &d->vga_state;
 | 
					    s = &d->vga_state;
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user