@@ -29,6 +29,8 @@
#define RSI_ABI_VERSION ((RSI_ABI_VERSION_MAJOR << 16) | \
RSI_ABI_VERSION_MINOR)
+#define RSI_LEGACY_ABI_VERSION 0xc0000
+
#define RSI_ABI_VERSION_GET_MAJOR(_version) ((_version) >> 16)
#define RSI_ABI_VERSION_GET_MINOR(_version) ((_version) & 0xFFFF)
@@ -41,6 +41,11 @@ static bool rsi_version_matches(void)
RSI_ABI_VERSION_GET_MAJOR(ver),
RSI_ABI_VERSION_GET_MINOR(ver));
+#ifdef CONFIG_RME_USE_PROTOTYPE_HACKS
+ if (ver == RSI_LEGACY_ABI_VERSION)
+ return true;
+#endif
+
return (ver >= RSI_ABI_VERSION &&
RSI_ABI_VERSION_GET_MAJOR(ver) == RSI_ABI_VERSION_MAJOR);
}
@@ -58,6 +58,14 @@ config NVHE_EL2_DEBUG
If unsure, say N.
+config RME_USE_PROTOTYPE_HACKS
+ bool "Allow RMM prototype version numbers"
+ default y
+ help
+ For compatibility with the the current RMM code allow versions
+ numbers from a prototype implementation as well as the expected
+ version number from the RMM specification.
+
config PROTECTED_NVHE_STACKTRACE
bool "Protected KVM hypervisor stacktraces"
depends on NVHE_EL2_DEBUG
The upstream RMM currently advertises the major version of an internal prototype (v12.0) rather than the expected version from the RMM architecture specification (v1.0). Add a config option to enable support for the prototype RSI v12.0. Signed-off-by: Steven Price <steven.price@arm.com> --- arch/arm64/include/asm/rsi_smc.h | 2 ++ arch/arm64/kernel/rsi.c | 5 +++++ arch/arm64/kvm/Kconfig | 8 ++++++++ 3 files changed, 15 insertions(+)