feat(rmm): update API of RSI_IPA_STATE_SET command

This patch makes the changes listed below:
- API of RSI_IPA_STATE_SET command is updated as
  per RMM Specification 1.0-eac2 by adding "flags"
  parameter passed in X4;
- Added "change_destroyed" member in "set_ripas"
  structure;
- Removed *rtt_level parameter of realm_ipa_get_ripas()
  function, which now returns WALK_FAIL if
  the entry does not have a valid ripas value.
- Function handle_rsi_ipa_state_get() always
  returns to Realm for all cases of ripas values,
  including RIPAS_DESTROYED.

Signed-off-by: AlexeiFedorov <Alexei.Fedorov@arm.com>
Change-Id: I60d9be4aba17819ccd4af69dc8c19434f3b13ae2
diff --git a/lib/realm/include/ripas.h b/lib/realm/include/ripas.h
index 53350c5..2143d8f 100644
--- a/lib/realm/include/ripas.h
+++ b/lib/realm/include/ripas.h
@@ -7,6 +7,7 @@
 #define RIPAS_H
 
 #include <smc-rmi.h>
+#include <smc-rsi.h>
 
 /*
  * The RmmRipas enumeration represents realm IPA state.
@@ -19,4 +20,19 @@
 	RIPAS_DESTROYED = RMI_DESTROYED	/* IPA is inaccessible to the Realm */
 };
 
+/*
+ * The RmmRipasChangeDestroyed enumeration represents whether a RIPAS change
+ * from DESTROYED should be permitted.
+ *
+ * Map RmmRipasChangeDestroyed to RsiRipasChangeDestroyed to simplify check
+ * operation.
+ */
+enum ripas_change_destroyed {
+	/* A RIPAS change from DESTROYED should not be permitted */
+	NO_CHANGE_DESTROYED = RSI_NO_CHANGE_DESTROYED,
+
+	/* A RIPAS change from DESTROYED should be permitted */
+	CHANGE_DESTROYED = RSI_CHANGE_DESTROYED
+};
+
 #endif /* RIPAS_H */