From 8b8d0c6584741845558eb066c8b1c393dc86bb29 Mon Sep 17 00:00:00 2001 From: Laszlo Ersek Date: Sat, 11 Jan 2014 17:59:53 +0100 Subject: [PATCH 03/22] memory: Replace open-coded memory_region_is_romd RH-Author: Laszlo Ersek Message-id: <1389463208-6278-4-git-send-email-lersek@redhat.com> Patchwork-id: 56616 O-Subject: [RHEL-7.0 qemu-kvm PATCH 03/18] memory: Replace open-coded memory_region_is_romd Bugzilla: 1032346 RH-Acked-by: Paolo Bonzini RH-Acked-by: Amos Kong RH-Acked-by: Andrew Jones RH-Acked-by: Kevin Wolf From: Jan Kiszka Improves readability. Reviewed-by: Peter Maydell Signed-off-by: Jan Kiszka (cherry picked from commit 4b81126e3399bfbcc47a4d696902c93401169f72) Signed-off-by: Laszlo Ersek --- translate-all.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Signed-off-by: Miroslav Rezanina --- translate-all.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/translate-all.c b/translate-all.c index da93608..0d84b0d 100644 --- a/translate-all.c +++ b/translate-all.c @@ -1359,7 +1359,7 @@ void tb_invalidate_phys_addr(hwaddr addr) section = phys_page_find(address_space_memory.dispatch, addr >> TARGET_PAGE_BITS); if (!(memory_region_is_ram(section->mr) - || (section->mr->rom_device && section->mr->readable))) { + || memory_region_is_romd(section->mr))) { return; } ram_addr = (memory_region_get_ram_addr(section->mr) & TARGET_PAGE_MASK) -- 1.7.1