Fix PPC crash

Because of a typo, structure field vga_bios_size was not initialized
properly and a bogus BAR6 for the nonexistent VGA BIOS appeared.

The bug was uncovered by c169998802.

Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
This commit is contained in:
Blue Swirl 2009-11-13 19:00:11 +00:00
parent c988bfadc9
commit bc90ff7742

View File

@ -119,7 +119,7 @@ int pci_vga_init(PCIBus *bus,
dev = pci_create(bus, -1, "VGA"); dev = pci_create(bus, -1, "VGA");
qdev_prop_set_uint32(&dev->qdev, "bios-offset", vga_bios_offset); qdev_prop_set_uint32(&dev->qdev, "bios-offset", vga_bios_offset);
qdev_prop_set_uint32(&dev->qdev, "bios-size", vga_bios_offset); qdev_prop_set_uint32(&dev->qdev, "bios-size", vga_bios_size);
qdev_init_nofail(&dev->qdev); qdev_init_nofail(&dev->qdev);
return 0; return 0;