]> git.proxmox.com Git - qemu.git/commitdiff
exec: make io_mem_unassigned private
authorPaolo Bonzini <pbonzini@redhat.com>
Fri, 24 May 2013 12:37:28 +0000 (14:37 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 29 May 2013 14:26:41 +0000 (16:26 +0200)
There is no reason to avoid a recompile before accessing unassigned
memory.  In the end it will be treated as MMIO anyway.

Reviewed-by: Richard Henderson <rth@twiddle.net>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
exec.c
include/exec/cpu-common.h
include/exec/softmmu_template.h

diff --git a/exec.c b/exec.c
index 7728ea38cb473294d5246a9d6407c0c3b137d4cd..7e22980e778225c5adce91309c1e9e70a8ad7563 100644 (file)
--- a/exec.c
+++ b/exec.c
@@ -66,8 +66,8 @@ AddressSpace address_space_io;
 AddressSpace address_space_memory;
 DMAContext dma_context_memory;
 
-MemoryRegion io_mem_rom, io_mem_unassigned, io_mem_notdirty;
-static MemoryRegion io_mem_subpage_ram;
+MemoryRegion io_mem_rom, io_mem_notdirty;
+static MemoryRegion io_mem_unassigned, io_mem_subpage_ram;
 
 #endif
 
index 1686b8f546df8536224fe652702af3b8a9e6db8b..e061e2109389a50e4e1063bf19b82c32c01cb279 100644 (file)
@@ -111,7 +111,6 @@ void cpu_physical_memory_write_rom(hwaddr addr,
                                    const uint8_t *buf, int len);
 
 extern struct MemoryRegion io_mem_rom;
-extern struct MemoryRegion io_mem_unassigned;
 extern struct MemoryRegion io_mem_notdirty;
 
 #endif
index 4501dacad12e186f9761579abf0792401e609866..ca91fd0b2202db273fca2475a0b5ca8b35e97c18 100644 (file)
@@ -68,10 +68,7 @@ static inline DATA_TYPE glue(io_read, SUFFIX)(CPUArchState *env,
 
     physaddr = (physaddr & TARGET_PAGE_MASK) + addr;
     env->mem_io_pc = retaddr;
-    if (mr != &io_mem_rom
-        && mr != &io_mem_unassigned
-        && mr != &io_mem_notdirty
-            && !can_do_io(env)) {
+    if (mr != &io_mem_rom && mr != &io_mem_notdirty && !can_do_io(env)) {
         cpu_io_recompile(env, retaddr);
     }
 
@@ -218,10 +215,7 @@ static inline void glue(io_write, SUFFIX)(CPUArchState *env,
     MemoryRegion *mr = iotlb_to_region(physaddr);
 
     physaddr = (physaddr & TARGET_PAGE_MASK) + addr;
-    if (mr != &io_mem_rom
-        && mr != &io_mem_unassigned
-        && mr != &io_mem_notdirty
-            && !can_do_io(env)) {
+    if (mr != &io_mem_rom && mr != &io_mem_notdirty && !can_do_io(env)) {
         cpu_io_recompile(env, retaddr);
     }