arch-arm: Remove currOpMode utility function

This was used by the currEL function only. We are progressively
removing any interface referring to Armv7 concepts

Change-Id: I1d97b392d063e85562b9234c094b1f2166e75ac9
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/53623
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
Giacomo Travaglini
2021-12-03 10:13:25 +00:00
parent adaab745a3
commit 2d8996a3eb

View File

@@ -108,17 +108,12 @@ bool isSecure(ThreadContext *tc);
bool inAArch64(ThreadContext *tc);
static inline OperatingMode
currOpMode(const ThreadContext *tc)
{
CPSR cpsr = tc->readMiscRegNoEffect(MISCREG_CPSR);
return (OperatingMode) (uint8_t) cpsr.mode;
}
static inline ExceptionLevel
currEL(const ThreadContext *tc)
{
return opModeToEL(currOpMode(tc));
CPSR cpsr = tc->readMiscRegNoEffect(MISCREG_CPSR);
return opModeToEL((OperatingMode)(uint8_t)cpsr.mode);
}
inline ExceptionLevel