提交 dcd82c11 编写于 作者: A Alex Bennée 提交者: Peter Maydell

target-arm: don't hardcode mask values in arm_cpu_handle_mmu_fault

Otherwise we break quickly when we change TARGET_PAGE_SIZE.
Signed-off-by: NAlex Bennée <alex.bennee@linaro.org>
Message-id: 1406733627-24255-2-git-send-email-alex.bennee@linaro.org
Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
上级 cdcf1405
......@@ -4156,8 +4156,8 @@ int arm_cpu_handle_mmu_fault(CPUState *cs, vaddr address,
&page_size);
if (ret == 0) {
/* Map a single [sub]page. */
phys_addr &= ~(hwaddr)0x3ff;
address &= ~(target_ulong)0x3ff;
phys_addr &= TARGET_PAGE_MASK;
address &= TARGET_PAGE_MASK;
tlb_set_page(cs, address, phys_addr, prot, mmu_idx, page_size);
return 0;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册