diff options
author | Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> | 2017-04-05 09:02:46 +0100 |
---|---|---|
committer | Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> | 2017-04-21 09:01:49 +0100 |
commit | 8c95e1f20c18007f30bdba6a60e99aea37cc473b (patch) | |
tree | d413f0f539531875b09d5924ea2950a1eca041ea /hw/display/cg3.c | |
parent | be4221d993cc15d3a14ca01181818ba5c41d5ab5 (diff) |
cg3: switch to load_image_mr() and remove prom-addr hack
Previous to the existence of load_image_mr(), the only way to load in the
FCode ROM image was to pass in its physical address via qdev properties
and use load_image_targphys().
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Diffstat (limited to 'hw/display/cg3.c')
-rw-r--r-- | hw/display/cg3.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/hw/display/cg3.c b/hw/display/cg3.c index b42f60e201..03d9197f71 100644 --- a/hw/display/cg3.c +++ b/hw/display/cg3.c @@ -303,8 +303,7 @@ static void cg3_realizefn(DeviceState *dev, Error **errp) vmstate_register_ram_global(&s->rom); fcode_filename = qemu_find_file(QEMU_FILE_TYPE_BIOS, CG3_ROM_FILE); if (fcode_filename) { - ret = load_image_targphys(fcode_filename, s->prom_addr, - FCODE_MAX_ROM_SIZE); + ret = load_image_mr(fcode_filename, &s->rom); g_free(fcode_filename); if (ret < 0 || ret > FCODE_MAX_ROM_SIZE) { error_report("cg3: could not load prom '%s'", CG3_ROM_FILE); @@ -369,7 +368,6 @@ static Property cg3_properties[] = { DEFINE_PROP_UINT16("width", CG3State, width, -1), DEFINE_PROP_UINT16("height", CG3State, height, -1), DEFINE_PROP_UINT16("depth", CG3State, depth, -1), - DEFINE_PROP_UINT64("prom-addr", CG3State, prom_addr, -1), DEFINE_PROP_END_OF_LIST(), }; |