[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 110/136] hw/riscv: Use memory_region_init_rom() with read-only reg
From: |
Paolo Bonzini |
Subject: |
[PULL 110/136] hw/riscv: Use memory_region_init_rom() with read-only regions |
Date: |
Tue, 25 Feb 2020 13:07:08 +0100 |
From: Philippe Mathieu-Daudé <address@hidden>
This commit was produced with the Coccinelle script
scripts/coccinelle/memory-region-housekeeping.cocci.
Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
Message-Id: <address@hidden>
Supersedes: <address@hidden>
---
hw/riscv/sifive_e.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/hw/riscv/sifive_e.c b/hw/riscv/sifive_e.c
index 8a6b034..6f6360a 100644
--- a/hw/riscv/sifive_e.c
+++ b/hw/riscv/sifive_e.c
@@ -208,9 +208,8 @@ static void riscv_sifive_e_soc_realize(DeviceState *dev,
Error **errp)
memmap[SIFIVE_E_PWM2].base, memmap[SIFIVE_E_PWM2].size);
/* Flash memory */
- memory_region_init_ram(&s->xip_mem, NULL, "riscv.sifive.e.xip",
- memmap[SIFIVE_E_XIP].size, &error_fatal);
- memory_region_set_readonly(&s->xip_mem, true);
+ memory_region_init_rom(&s->xip_mem, NULL, "riscv.sifive.e.xip",
+ memmap[SIFIVE_E_XIP].size, &error_fatal);
memory_region_add_subregion(sys_mem, memmap[SIFIVE_E_XIP].base,
&s->xip_mem);
}
--
1.8.3.1
- [PULL 102/136] scripts/cocci: Patch to replace memory_region_init_{ram, readonly -> rom}, (continued)
- [PULL 102/136] scripts/cocci: Patch to replace memory_region_init_{ram, readonly -> rom}, Paolo Bonzini, 2020/02/25
- [PULL 100/136] memory: Simplify memory_region_init_rom_nomigrate() to ease review, Paolo Bonzini, 2020/02/25
- [PULL 101/136] scripts/cocci: Rename memory-region-{init-ram -> housekeeping}, Paolo Bonzini, 2020/02/25
- [PULL 103/136] hw/arm: Use memory_region_init_rom() with read-only regions, Paolo Bonzini, 2020/02/25
- [PULL 104/136] hw/display: Use memory_region_init_rom() with read-only regions, Paolo Bonzini, 2020/02/25
- [PULL 103/136] hw/arm: Use memory_region_init_rom() with read-only regions, Paolo Bonzini, 2020/02/25
- [PULL 105/136] hw/mips: Use memory_region_init_rom() with read-only regions, Paolo Bonzini, 2020/02/25
- [PULL 106/136] hw/m68k: Use memory_region_init_rom() with read-only regions, Paolo Bonzini, 2020/02/25
- [PULL 107/136] hw/net: Use memory_region_init_rom() with read-only regions, Paolo Bonzini, 2020/02/25
- [PULL 108/136] hw/pci-host: Use memory_region_init_rom() with read-only regions, Paolo Bonzini, 2020/02/25
- [PULL 110/136] hw/riscv: Use memory_region_init_rom() with read-only regions,
Paolo Bonzini <=
- [PULL 113/136] scripts/cocci: Patch to detect potential use of memory_region_init_rom, Paolo Bonzini, 2020/02/25
- [PULL 112/136] hw/sparc: Use memory_region_init_rom() with read-only regions, Paolo Bonzini, 2020/02/25
- [PULL 111/136] hw/sh4: Use memory_region_init_rom() with read-only regions, Paolo Bonzini, 2020/02/25
- [PULL 109/136] hw/ppc: Use memory_region_init_rom() with read-only regions, Paolo Bonzini, 2020/02/25
- [PULL 114/136] hw/arm/stm32: Use memory_region_init_rom() with read-only regions, Paolo Bonzini, 2020/02/25
- [PULL 116/136] hw/i386/pc_sysfw: Simplify using memory_region_init_alias(), Paolo Bonzini, 2020/02/25
- [PULL 117/136] hw/i386/pc_sysfw: Remove unused 'ram_size' argument, Paolo Bonzini, 2020/02/25
- [PULL 118/136] scripts/cocci: Patch to remove unnecessary memory_region_set_readonly(), Paolo Bonzini, 2020/02/25
- [PULL 119/136] hw/arm: Remove unnecessary memory_region_set_readonly() on ROM alias, Paolo Bonzini, 2020/02/25
- [PULL 122/136] hw/char: Let devices own the MemoryRegion they create, Paolo Bonzini, 2020/02/25