feat(trf): add trace filter control registers access test

Added a test to read trace filter control registers to ensure that EL3
is giving permission to non-secure EL2 to access these registers.

Signed-off-by: Manish V Badarkhe <Manish.Badarkhe@arm.com>
Change-Id: I9354d8592bd187206add717b9d3b0206382a06d3
diff --git a/include/lib/aarch64/arch_features.h b/include/lib/aarch64/arch_features.h
index d2665b4..fc8ac33 100644
--- a/include/lib/aarch64/arch_features.h
+++ b/include/lib/aarch64/arch_features.h
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2020, Arm Limited. All rights reserved.
+ * Copyright (c) 2020-2021, Arm Limited. All rights reserved.
  *
  * SPDX-License-Identifier: BSD-3-Clause
  */
@@ -99,4 +99,11 @@
 		ID_AA64DFR0_TRACEBUFFER_SUPPORTED;
 }
 
+static inline bool get_armv8_4_trf_support(void)
+{
+        return ((read_id_aa64dfr0_el1() >> ID_AA64DFR0_TRACEFILT_SHIFT) &
+		ID_AA64DFR0_TRACEFILT_MASK) ==
+		ID_AA64DFR0_TRACEFILT_SUPPORTED;
+}
+
 #endif /* ARCH_FEATURES_H */