diff options
author | Aurelien Jarno <aurelien@aurel32.net> | 2010-06-30 19:39:45 +0200 |
---|---|---|
committer | Aurelien Jarno <aurelien@aurel32.net> | 2010-06-30 19:39:45 +0200 |
commit | 33dd298323c36ec2de7a21b85d29bfd9ba255d72 (patch) | |
tree | 7891349b6e239037dfa1b09600678c87b73a51b6 | |
parent | aa8f40090ab94877b49a256069077e1476607e35 (diff) |
MIPS: fix fulong bios loading
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
-rw-r--r-- | hw/mips_fulong2e.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/hw/mips_fulong2e.c b/hw/mips_fulong2e.c index 509bf002e3..d85240a006 100644 --- a/hw/mips_fulong2e.c +++ b/hw/mips_fulong2e.c @@ -256,7 +256,6 @@ static void mips_fulong2e_init(ram_addr_t ram_size, const char *boot_device, const char *initrd_filename, const char *cpu_model) { char *filename; - char buf[1024]; unsigned long ram_offset, bios_offset; unsigned long bios_size; int64_t kernel_entry; @@ -311,8 +310,8 @@ static void mips_fulong2e_init(ram_addr_t ram_size, const char *boot_device, kernel_entry = load_kernel (env); write_bootloader(env, qemu_get_ram_ptr(bios_offset), kernel_entry); } else { - if (bios_name == NULL) { - bios_name = FULONG_BIOSNAME; + if (bios_name == NULL) { + bios_name = FULONG_BIOSNAME; } filename = qemu_find_file(QEMU_FILE_TYPE_BIOS, bios_name); if (filename) { @@ -323,10 +322,10 @@ static void mips_fulong2e_init(ram_addr_t ram_size, const char *boot_device, bios_size = -1; } - if ((bios_size < 0 || bios_size > BIOS_SIZE) && !kernel_filename) { - fprintf(stderr, "qemu: Could not load MIPS bios '%s'\n", buf); + if ((bios_size < 0 || bios_size > BIOS_SIZE) && !kernel_filename) { + fprintf(stderr, "qemu: Could not load MIPS bios '%s'\n", bios_name); exit(1); - } + } } /* Init internal devices */ |