aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvi Kivity <avi@redhat.com>2009-12-22 11:57:02 +0200
committerAurelien Jarno <aurelien@aurel32.net>2009-12-24 19:35:24 +0100
commitdcc0da8297bd610e582b851d1b3f9c62c335a6d2 (patch)
tree6d6cc31e7b9b1e4a29c2a4546323bd235f51b925
parent41193c50fac2b6d78122514826770b43318dca8d (diff)
Don't load options roms intended to be loaded by the bios in qemu
The first such option rom will load at address 0, which isn't very nice, and the second will report a conflict and abort, which is horrible. Signed-off-by: Avi Kivity <avi@redhat.com> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net> (cherry picked from commit e405a2ba91b68817cae2a428de55fe9616a4cf37)
-rw-r--r--hw/loader.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/hw/loader.c b/hw/loader.c
index 2ceb8eba48..eef385eb51 100644
--- a/hw/loader.c
+++ b/hw/loader.c
@@ -636,6 +636,9 @@ static void rom_reset(void *unused)
Rom *rom;
QTAILQ_FOREACH(rom, &roms, next) {
+ if (rom->fw_file) {
+ continue;
+ }
if (rom->data == NULL)
continue;
cpu_physical_memory_write_rom(rom->addr, rom->data, rom->romsize);
@@ -654,6 +657,9 @@ int rom_load_all(void)
Rom *rom;
QTAILQ_FOREACH(rom, &roms, next) {
+ if (rom->fw_file) {
+ continue;
+ }
if (addr > rom->addr) {
fprintf(stderr, "rom: requested regions overlap "
"(rom %s. free=0x" TARGET_FMT_plx
@@ -752,7 +758,7 @@ void do_info_roms(Monitor *mon)
Rom *rom;
QTAILQ_FOREACH(rom, &roms, next) {
- if (rom->addr) {
+ if (!rom->fw_file) {
monitor_printf(mon, "addr=" TARGET_FMT_plx
" size=0x%06zx mem=%s name=\"%s\" \n",
rom->addr, rom->romsize,