aboutsummaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2020-10-26 10:30:27 -0400
committerPaolo Bonzini <pbonzini@redhat.com>2020-12-10 12:15:06 -0500
commit377ce9cb0f728270d8acbe2c04b68596a5b3be71 (patch)
tree8ef7dc7b8d1ebf4b0470d221a5da59a87077fd63 /hw
parent2893cad6b987fd4564b5793fee31c907c3638fa6 (diff)
sparc: remove bios_name
Cc: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20201026143028.3034018-15-pbonzini@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw')
-rw-r--r--hw/sparc/leon3.c4
-rw-r--r--hw/sparc/sun4m.c2
-rw-r--r--hw/sparc64/sun4u.c2
3 files changed, 3 insertions, 5 deletions
diff --git a/hw/sparc/leon3.c b/hw/sparc/leon3.c
index d40b7891f6..1c50b02f81 100644
--- a/hw/sparc/leon3.c
+++ b/hw/sparc/leon3.c
@@ -185,6 +185,7 @@ static void leon3_set_pil_in(void *opaque, int n, int level)
static void leon3_generic_hw_init(MachineState *machine)
{
ram_addr_t ram_size = machine->ram_size;
+ const char *bios_name = machine->firmware ?: LEON3_PROM_FILENAME;
const char *kernel_filename = machine->kernel_filename;
SPARCCPU *cpu;
CPUSPARCState *env;
@@ -259,9 +260,6 @@ static void leon3_generic_hw_init(MachineState *machine)
memory_region_add_subregion(address_space_mem, LEON3_PROM_OFFSET, prom);
/* Load boot prom */
- if (bios_name == NULL) {
- bios_name = LEON3_PROM_FILENAME;
- }
filename = qemu_find_file(QEMU_FILE_TYPE_BIOS, bios_name);
if (filename) {
diff --git a/hw/sparc/sun4m.c b/hw/sparc/sun4m.c
index 66fecb152a..0f9cd2bf52 100644
--- a/hw/sparc/sun4m.c
+++ b/hw/sparc/sun4m.c
@@ -882,7 +882,7 @@ static void sun4m_hw_init(const struct sun4m_hwdef *hwdef,
hwdef->max_mem - machine->ram_size);
}
- prom_init(hwdef->slavio_base, bios_name);
+ prom_init(hwdef->slavio_base, machine->firmware);
slavio_intctl = slavio_intctl_init(hwdef->intctl_base,
hwdef->intctl_base + 0x10000ULL,
diff --git a/hw/sparc64/sun4u.c b/hw/sparc64/sun4u.c
index 2f8fc670cf..22896b4c62 100644
--- a/hw/sparc64/sun4u.c
+++ b/hw/sparc64/sun4u.c
@@ -578,7 +578,7 @@ static void sun4uv_init(MemoryRegion *address_space_mem,
/* set up devices */
ram_init(0, machine->ram_size);
- prom_init(hwdef->prom_addr, bios_name);
+ prom_init(hwdef->prom_addr, machine->firmware);
/* Init sabre (PCI host bridge) */
sabre = SABRE(qdev_new(TYPE_SABRE));