Adding tests for Realm payload
This testing patch has the following test scenarios for realm payload:
1. Query the RMI Version on a single CPU.
2. Multi CPU version query.
3. Test to delegate and undelegate a buffer using RMI Delegate and
Undelegate commands.
Signed-off-by: Mark Dykes <mark.dykes@arm.com>
Change-Id: I3404b903b5b4f044a91ce824a408e7cf355a7589
diff --git a/include/lib/aarch64/arch_features.h b/include/lib/aarch64/arch_features.h
index edc40f0..1002936 100644
--- a/include/lib/aarch64/arch_features.h
+++ b/include/lib/aarch64/arch_features.h
@@ -125,4 +125,15 @@
ID_AA64DFR0_TRACEVER_SUPPORTED;
}
+static inline unsigned int get_armv9_2_feat_rme_support(void)
+{
+ /*
+ * Return the RME version, zero if not supported. This function can be
+ * used as both an integer value for the RME version or compared to zero
+ * to detect RME presence.
+ */
+ return (unsigned int)(read_id_aa64pfr0_el1() >>
+ ID_AA64PFR0_FEAT_RME_SHIFT) & ID_AA64PFR0_FEAT_RME_MASK;
+}
+
#endif /* ARCH_FEATURES_H */