aboutsummaryrefslogtreecommitdiff
path: root/hw/pc.c
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2010-01-08 15:25:40 +0100
committerAnthony Liguori <aliguori@us.ibm.com>2010-01-11 13:41:00 -0600
commit8832cb805dcb65009b979cd8e17d75ac4b03c7e4 (patch)
tree73af84c03b08927e5e4e8719d8beb212eed2926f /hw/pc.c
parentde9352bcaed2452af1d2b06b829748676c691794 (diff)
downloadqemu-8832cb805dcb65009b979cd8e17d75ac4b03c7e4.zip
qemu-8832cb805dcb65009b979cd8e17d75ac4b03c7e4.tar.gz
qemu-8832cb805dcb65009b979cd8e17d75ac4b03c7e4.tar.bz2
roms: rework rom loading via fw
This patch changes the way rom loading via fw_cfg is handled. Instead of having pc_init1() call a function which passed all roms to the firmware config we simply pass a pointer to fw_cfg to the rom loader. Advantage: loading roms via firmware works also for devices which are initialized after pc_init1(), i.e. everyting added via -device. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw/pc.c')
-rw-r--r--hw/pc.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/hw/pc.c b/hw/pc.c
index 7dc56e7..e32e574 100644
--- a/hw/pc.c
+++ b/hw/pc.c
@@ -866,6 +866,7 @@ static void pc_init1(ram_addr_t ram_size,
bios_size, bios_offset | IO_MEM_ROM);
fw_cfg = bochs_bios_init();
+ rom_set_fw(fw_cfg);
if (linux_boot) {
load_linux(fw_cfg, kernel_filename, initrd_filename, kernel_cmdline, below_4g_mem_size);
@@ -1026,8 +1027,6 @@ static void pc_init1(ram_addr_t ram_size,
}
}
}
-
- rom_load_fw(fw_cfg);
}
static void pc_init_pci(ram_addr_t ram_size,