From 13ca82515d512a4fb9bbc5cdd9ea1dd0803e9ad5 Mon Sep 17 00:00:00 2001 From: Alastair Reid Date: Mon, 23 Jul 2018 17:31:25 +0100 Subject: AArch64 patches: EL2 secure not implemented Several v8.4 tests were failing because they attempted to enter EL2 secure mode (which is supported on v8.4 but not on v8.3). This test detects an attempt to enter EL2 secure and reports an easily diagnosed error message. --- aarch64/elfmain.sail | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/aarch64/elfmain.sail b/aarch64/elfmain.sail index 24579b79..ad564108 100644 --- a/aarch64/elfmain.sail +++ b/aarch64/elfmain.sail @@ -98,6 +98,13 @@ function Step_CPU() = { "\n"))); exit() }; + // test for ERET instruction from EL3_Secure - only supported in v8.4 + if (__currentInstr == 0xd69f_03e0) & (PSTATE.EL == EL3) & (SCR_EL3[0] == bitzero) then { + print(concat_str("UNIMPLEMENTED: EL2_Secure support (v8.4 feature) ", + concat_str(HexStr(UInt(__currentInstr)), + "\n"))); + exit() + }; try { __PC_changed = false; ShouldAdvanceIT = (PSTATE.nRW == [bitone]) & (PSTATE.T == [bitone]); -- cgit v1.2.3