diff options
author | Richard Henderson <rth@twiddle.net> | 2011-08-11 16:07:16 -0700 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2011-10-02 16:14:02 +0200 |
commit | 39186d8ab8af8937cee4743cc1956bdc28923ac9 (patch) | |
tree | 24c3d9953aa8900f96aae4086799a4795502de43 /hw/ppce500_mpc8544ds.c | |
parent | 2ff0c7c3c2251e7e81e90c9556dda64261d033ec (diff) |
serial: Add MemoryRegion parameter to serial_mm_init
Remove the get_system_memory() call from serial_mm_init, pushing
it back into the callers. In many cases we already have the
system memory region available.
Signed-off-by: Richard Henderson <rth@twiddle.net>
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'hw/ppce500_mpc8544ds.c')
-rw-r--r-- | hw/ppce500_mpc8544ds.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/hw/ppce500_mpc8544ds.c b/hw/ppce500_mpc8544ds.c index fc46991e8a..274b37c7e9 100644 --- a/hw/ppce500_mpc8544ds.c +++ b/hw/ppce500_mpc8544ds.c @@ -32,6 +32,7 @@ #include "loader.h" #include "elf.h" #include "sysbus.h" +#include "exec-memory.h" #define BINARY_DEVICE_TREE_FILE "mpc8544ds.dtb" #define UIMAGE_LOAD_BASE 0 @@ -225,6 +226,7 @@ static void mpc8544ds_init(ram_addr_t ram_size, const char *initrd_filename, const char *cpu_model) { + MemoryRegion *address_space_mem = get_system_memory(); PCIBus *pci_bus; CPUState *env; uint64_t elf_entry; @@ -274,13 +276,13 @@ static void mpc8544ds_init(ram_addr_t ram_size, /* Serial */ if (serial_hds[0]) { - serial_mm_init(MPC8544_SERIAL0_REGS_BASE, + serial_mm_init(address_space_mem, MPC8544_SERIAL0_REGS_BASE, 0, mpic[12+26], 399193, serial_hds[0], DEVICE_BIG_ENDIAN); } if (serial_hds[1]) { - serial_mm_init(MPC8544_SERIAL1_REGS_BASE, + serial_mm_init(address_space_mem, MPC8544_SERIAL1_REGS_BASE, 0, mpic[12+26], 399193, serial_hds[0], DEVICE_BIG_ENDIAN); } |