]> git.proxmox.com Git - mirror_edk2.git/commit
ArmPkg/ArmMmuLib: support page tables in cacheable memory only
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Sun, 20 Nov 2016 17:12:50 +0000 (17:12 +0000)
committerLeif Lindholm <leif.lindholm@linaro.org>
Wed, 30 Nov 2016 16:12:20 +0000 (16:12 +0000)
commit35718840efe3a29c981b5b0f4d2f617f9a1f2c2e
tree4b57a2f6c515cf8c6c79bc7a5f60ece245b0fc25
parentbcc6a38f4c2419e704c99fa2d3dc01e1cb007a17
ArmPkg/ArmMmuLib: support page tables in cacheable memory only

Translation table walks are always cache coherent on ARMv8-A, so cache
maintenance on page tables is never needed. Since there is a risk of
loss of coherency when using mismatched attributes, and given that memory
is mapped cacheable except for extraordinary cases (such as non-coherent
DMA), restrict the page table walker to performing cacheable accesses to
the translation tables.

For DEBUG builds, retain some of the logic so that we can double check
that the memory holding the root translation table is indeed located in
memory that is mapped cacheable.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
ArmPkg/Library/ArmMmuLib/AArch64/ArmMmuLibCore.c