diff options
author | Paolo Bonzini | 2020-10-28 11:24:22 +0100 |
---|---|---|
committer | Paolo Bonzini | 2020-12-10 18:15:10 +0100 |
commit | b326b6ea7998912d0bb0565ffef34efdfe9016dc (patch) | |
tree | 0c4dab1f43755ae5aee10d3a9257338ead2dc720 /hw/core/generic-loader.c | |
parent | sparc64: do not use ram_size global (diff) | |
download | qemu-b326b6ea7998912d0bb0565ffef34efdfe9016dc.tar.gz qemu-b326b6ea7998912d0bb0565ffef34efdfe9016dc.tar.xz qemu-b326b6ea7998912d0bb0565ffef34efdfe9016dc.zip |
make ram_size local to vl.c
Use the machine properties for the leftovers too.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/core/generic-loader.c')
-rw-r--r-- | hw/core/generic-loader.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/hw/core/generic-loader.c b/hw/core/generic-loader.c index a242c076f6..2b2a7b5e9a 100644 --- a/hw/core/generic-loader.c +++ b/hw/core/generic-loader.c @@ -35,6 +35,7 @@ #include "hw/sysbus.h" #include "sysemu/dma.h" #include "sysemu/reset.h" +#include "hw/boards.h" #include "hw/loader.h" #include "hw/qdev-properties.h" #include "qapi/error.h" @@ -154,7 +155,7 @@ static void generic_loader_realize(DeviceState *dev, Error **errp) if (size < 0 || s->force_raw) { /* Default to the maximum size being the machine's ram size */ - size = load_image_targphys_as(s->file, s->addr, ram_size, as); + size = load_image_targphys_as(s->file, s->addr, current_machine->ram_size, as); } else { s->addr = entry; } |