745a40d78a
Set AP[2:0] and XN flags based on page attributes. PXN is not implemented as it seems to be available only in L1 descriptors on ARMv7. Set TEX, B, C flags based on memoryType: * B_MTR_UC is mapped to Strongly Ordered (TEX=0, B=0, C=0) * B_MTR_WC is mapped to Shareable Device Memory (TEX=0, B=1, C=0) * B_MTR_WT is mapped to Outer and Inner Write-Through, no Write-Allocate (TEX=0, B=0, C=1) * B_MTR_WB is mapped to Outer and Inner Write-Back, no Write-Allocate (TEx=0, B=1, C=1) * B_MTR_WP has no direct equivalent on the ARM so it's mapped as B_MTR_WB * default is Write-Back Implement ARMPagingMethod32Bit::AttributesToPageTableEntryFlags() for mapping from page attributes to AP[2:0] and XN flags. Implement ARMPagingMethod32Bit::PageTableEntryFlagsToAttributes() for the reverse mapping used in Query() and QueryInterrupt() i.e. recover page attributes from AP[2:0] and XN flags. Implement ARMPagingMethod32Bit::MemoryTypeToPageTableEntryFlags() fr mapping from memoryType to TEX, B, C flags. Implement ARMVMTranslationMap32Bit::Protect() which used to be commented out. Accessed and modified flags are not implemented yet, so no such flags are returned from Query() and QueryInterrupt(). Also because of this, we just invalidate TLB on any call to Protect() without checking whether the page has been accessed. Change-Id: I027af5c02bd6218d9f92a58044aeb26373e1956b Reviewed-on: https://review.haiku-os.org/c/haiku/+/5236 Reviewed-by: Adrien Destugues <pulkomandy@gmail.com> Reviewed-by: Fredrik Holmqvist <fredrik.holmqvist@gmail.com> Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org> |
||
---|---|---|
.. | ||
arch_atomic.h | ||
arch_cpu.h | ||
arch_debug.h | ||
arch_int.h | ||
arch_kernel_args.h | ||
arch_kernel.h | ||
arch_system_info.h | ||
arch_thread_types.h | ||
arch_thread.h | ||
arch_uart_8250_omap.h | ||
arch_uart_pl011.h | ||
arch_user_debugger.h | ||
arch_vm_translation_map.h | ||
arch_vm_types.h | ||
arch_vm.h | ||
arm920t.h | ||
arm_mmu.h | ||
bcm283X.h | ||
omap3.h | ||
pxa270.h | ||
reg.h |