From: Paolo Bonzini Date: Mon, 22 Jul 2013 13:54:17 +0000 (+0200) Subject: mips_r4k: do not use isa_mmio X-Git-Tag: Tizen_Studio_1.3_Release_p2.3.1~524^2~3^2~379 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3959496874e7d1ee84e3428ddf1a10dfef972c1d;p=sdk%2Femulator%2Fqemu.git mips_r4k: do not use isa_mmio This fixes endianness bugs in I/O port access. Signed-off-by: Paolo Bonzini Reviewed-by: Anthony Liguori Message-id: 1374501278-31549-8-git-send-email-pbonzini@redhat.com Signed-off-by: Anthony Liguori --- diff --git a/hw/mips/mips_r4k.c b/hw/mips/mips_r4k.c index 22beb0a67c..4bc2e3fa7a 100644 --- a/hw/mips/mips_r4k.c +++ b/hw/mips/mips_r4k.c @@ -164,6 +164,7 @@ void mips_r4k_init(QEMUMachineInitArgs *args) MemoryRegion *ram = g_new(MemoryRegion, 1); MemoryRegion *bios; MemoryRegion *iomem = g_new(MemoryRegion, 1); + MemoryRegion *isa = g_new(MemoryRegion, 1); int bios_size; MIPSCPU *cpu; CPUMIPSState *env; @@ -273,7 +274,10 @@ void mips_r4k_init(QEMUMachineInitArgs *args) rtc_init(isa_bus, 2000, NULL); /* Register 64 KB of ISA IO space at 0x14000000 */ - isa_mmio_init(0x14000000, 0x00010000); + memory_region_init_alias(isa, NULL, "isa_mmio", + get_system_io(), 0, 0x00010000); + memory_region_add_subregion(get_system_memory(), 0x14000000, isa); + isa_mem_base = 0x10000000; pit = pit_init(isa_bus, 0x40, 0, NULL);