diff options
author | Giacomo Travaglini <giacomo.travaglini@arm.com> | 2019-07-29 12:38:12 +0100 |
---|---|---|
committer | Giacomo Travaglini <giacomo.travaglini@arm.com> | 2019-08-05 15:50:57 +0000 |
commit | 361bc8b47260a55902764054d3ac25694ac93f8a (patch) | |
tree | e6929b787500aa227333b4fe90fc4047838ef8c0 /src/arch/arm/tlb.hh | |
parent | fd1a8bed393a2ef48d584fcabeee4d98eda0e3fa (diff) | |
download | gem5-361bc8b47260a55902764054d3ac25694ac93f8a.tar.xz |
arch-arm: Implement ARMv8.1-PAN, Privileged access never
ARMv8.1-PAN adds a new bit to PSTATE. When the value of this PAN state
bit is 1, any privileged data access from EL1 or EL2 to a virtual memory
address that is accessible at EL0 generates a Permission fault.
This feature is mandatory in ARMv8.1 implementations.
This feature is supported in AArch64 and AArch32 states.
The ID_AA64MMFR1_EL1.PAN, ID_MMFR3_EL1.PAN, and ID_MMFR3.PAN fields
identify the support for ARMv8.1-PAN.
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Change-Id: I94a76311711739dd2394c72944d88ba9321fd159
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/19729
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Diffstat (limited to 'src/arch/arm/tlb.hh')
-rw-r--r-- | src/arch/arm/tlb.hh | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/arch/arm/tlb.hh b/src/arch/arm/tlb.hh index a84e945f4..ea78a21b5 100644 --- a/src/arch/arm/tlb.hh +++ b/src/arch/arm/tlb.hh @@ -244,6 +244,8 @@ class TLB : public BaseTLB Fault checkPermissions(TlbEntry *te, const RequestPtr &req, Mode mode); Fault checkPermissions64(TlbEntry *te, const RequestPtr &req, Mode mode, ThreadContext *tc); + bool checkPAN(ThreadContext *tc, uint8_t ap, const RequestPtr &req, + Mode mode); /** Reset the entire TLB |