qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH 10/22] exec: expect mr->ops to be initialized for RO


From: Paolo Bonzini
Subject: [Qemu-devel] [PATCH 10/22] exec: expect mr->ops to be initialized for ROM
Date: Fri, 24 May 2013 19:05:45 +0200

There is no need anymore to use the special phys_section_rom section.

Signed-off-by: Paolo Bonzini <address@hidden>
---
 exec.c | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/exec.c b/exec.c
index 613bbd7..411a224 100644
--- a/exec.c
+++ b/exec.c
@@ -2332,9 +2332,6 @@ void stl_phys_notdirty(hwaddr addr, uint32_t val)
     section = address_space_translate(&address_space_memory, addr, &addr1, &l,
                                       true);
     if (l < 4 || !memory_region_is_ram(section->mr) || section->readonly) {
-        if (memory_region_is_ram(section->mr)) {
-            section = &phys_sections[phys_section_rom];
-        }
         io_mem_write(section->mr, addr1, val, 4);
     } else {
         addr1 += memory_region_get_ram_addr(section->mr) & TARGET_PAGE_MASK;
@@ -2365,9 +2362,6 @@ static inline void stl_phys_internal(hwaddr addr, 
uint32_t val,
     section = address_space_translate(&address_space_memory, addr, &addr1, &l,
                                       true);
     if (l < 4 || !memory_region_is_ram(section->mr) || section->readonly) {
-        if (memory_region_is_ram(section->mr)) {
-            section = &phys_sections[phys_section_rom];
-        }
 #if defined(TARGET_WORDS_BIGENDIAN)
         if (endian == DEVICE_LITTLE_ENDIAN) {
             val = bswap32(val);
@@ -2431,9 +2425,6 @@ static inline void stw_phys_internal(hwaddr addr, 
uint32_t val,
     section = address_space_translate(&address_space_memory, addr, &addr1, &l,
                                       true);
     if (l < 2 || !memory_region_is_ram(section->mr) || section->readonly) {
-        if (memory_region_is_ram(section->mr)) {
-            section = &phys_sections[phys_section_rom];
-        }
 #if defined(TARGET_WORDS_BIGENDIAN)
         if (endian == DEVICE_LITTLE_ENDIAN) {
             val = bswap16(val);
-- 
1.8.1.4





reply via email to

[Prev in Thread] Current Thread [Next in Thread]