tftf(rme): check if RMM doesn't leak Realm contents in SVE registers
This test verifies that the Realm contents in SVE registers are not
seen by NS world once the Realm returns back to the host. This test
performs the below steps:
1. Set NS world SVE VQ to max and write a known pattern.
2. Set NS world ZCR_EL2 with VQ as 0 (128 bits).
3. Create Realm with max SVE VQ
4. Call Realm to fill in Z registers
5. Once Realm returns, NS sets ZCR_EL2 with max VQ and reads the
Z registers.
6. The upper bits of Z registers must be either 0 or the old values
filled by NS world at step 1.
Signed-off-by: Arunachalam Ganapathy <arunachalam.ganapathy@arm.com>
Change-Id: I8205190d1ce9c37b99d35cf5b15df21ca9b838c3
diff --git a/realm/realm_payload_main.c b/realm/realm_payload_main.c
index b13e0a1..f0ab087 100644
--- a/realm/realm_payload_main.c
+++ b/realm/realm_payload_main.c
@@ -105,6 +105,9 @@
case REALM_SVE_OPS:
test_succeed = test_realm_sve_ops();
break;
+ case REALM_SVE_FILL_REGS:
+ test_succeed = test_realm_sve_fill_regs();
+ break;
default:
realm_printf("%s() invalid cmd %u\n", __func__, cmd);
break;