ppcmmu: Fix write accesses to read-only memory.

This commit is contained in:
joevt 2023-10-30 17:09:03 -07:00 committed by Maxim Poliakovski
parent 4d7204debc
commit c28e1fa0be
1 changed files with 1 additions and 1 deletions

View File

@ -616,7 +616,7 @@ static TLBEntry* dtlb2_refill(uint32_t guest_va, int is_write)
(phys_addr - rgn_desc->start);
if (rgn_desc->type == RT_ROM) {
// redirect writes to the dummy page for ROM regions
tlb_entry->host_va_offs_w = (int64_t)&dummy_page - guest_va;
tlb_entry->host_va_offs_w = (int64_t)&dummy_page - tag;
} else {
tlb_entry->host_va_offs_w = tlb_entry->host_va_offs_r;
}