summaryrefslogtreecommitdiffstats
path: root/ArmPkg/Library/ArmLib/AArch64/AArch64Lib.c
diff options
context:
space:
mode:
Diffstat (limited to 'ArmPkg/Library/ArmLib/AArch64/AArch64Lib.c')
-rw-r--r--ArmPkg/Library/ArmLib/AArch64/AArch64Lib.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/ArmPkg/Library/ArmLib/AArch64/AArch64Lib.c b/ArmPkg/Library/ArmLib/AArch64/AArch64Lib.c
index 3a46f360ef..8728546587 100644
--- a/ArmPkg/Library/ArmLib/AArch64/AArch64Lib.c
+++ b/ArmPkg/Library/ArmLib/AArch64/AArch64Lib.c
@@ -134,3 +134,19 @@ ArmHasTrbe (
{
return ((ArmReadIdAA64Dfr0 () & AARCH64_DFR0_TRBE) != 0);
}
+
+/**
+ Checks whether the CPU implements the Embedded Trace Extension.
+
+ @retval TRUE FEAT_ETE is implemented.
+ @retval FALSE FEAT_ETE is not mplemented.
+**/
+BOOLEAN
+EFIAPI
+ArmHasEte (
+ VOID
+ )
+{
+ // The ID_AA64DFR0_EL1.TraceVer field identifies the presence of FEAT_ETE.
+ return ((ArmReadIdAA64Dfr0 () & AARCH64_DFR0_TRACEVER) != 0);
+}