mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 23:33:54 -06:00
memory: fix rom_device I/O mode
When adding a rom_device in I/O mode, we incorrectly masked off the low bits, resulting in a pure RAM map. Fix my masking off the high bits and IO_MEM_ROMD, yielding a pure I/O map. Signed-off-by: Avi Kivity <avi@redhat.com>
This commit is contained in:
parent
75f5941cb5
commit
b5fe14cc7e
1 changed files with 1 additions and 1 deletions
2
memory.c
2
memory.c
|
@ -304,7 +304,7 @@ static void as_memory_range_add(AddressSpace *as, FlatRange *fr)
|
|||
}
|
||||
|
||||
if (!fr->readable) {
|
||||
phys_offset &= TARGET_PAGE_MASK;
|
||||
phys_offset &= ~TARGET_PAGE_MASK & ~IO_MEM_ROMD;
|
||||
}
|
||||
|
||||
cpu_register_physical_memory_log(fr->addr.start,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue