The RMM 1.0-eac1 relaxed the RSI_HOST_CALL alignment requirement from 4KB to 256B.
Therefore, update the alignment check for the address parameter of the RSI_HOST_CALL command to relax the alignment requirement to 256 bytes. Cc: Ard Biesheuvel <ardb+tianoc...@kernel.org> Cc: Leif Lindholm <quic_llind...@quicinc.com> Cc: Gerd Hoffmann <kra...@redhat.com> Signed-off-by: Sami Mujawar <sami.muja...@arm.com> --- ArmVirtPkg/Library/ArmCcaRsiLib/ArmCcaRsiLib.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ArmVirtPkg/Library/ArmCcaRsiLib/ArmCcaRsiLib.c b/ArmVirtPkg/Library/ArmCcaRsiLib/ArmCcaRsiLib.c index 59b9d7a12c82a534280595328347995f1ff51ee2..0280d8e42882ddfb02d0a40c47a6fba7855ba84f 100644 --- a/ArmVirtPkg/Library/ArmCcaRsiLib/ArmCcaRsiLib.c +++ b/ArmVirtPkg/Library/ArmCcaRsiLib/ArmCcaRsiLib.c @@ -11,7 +11,7 @@ - REM - Realm Extensible Measurement @par Reference(s): - - Realm Management Monitor (RMM) Specification, version 1.0-eac0 + - Realm Management Monitor (RMM) Specification, version 1.0-eac1 (https://developer.arm.com/documentation/den0137/) **/ @@ -512,7 +512,11 @@ RsiHostCall ( { ARM_SMC_ARGS SmcCmd; - if ((Args == NULL) || (!AddrIsGranuleAligned ((UINT64 *)Args))) { + // The RMM specification, version 1.0-eac1, relaxes the alignment + // requirement for RSI_HOST_CALL from 4KB to 256B. Also see RMM + // specification, sections B4.3.3 RSI_HOST_CALL command and + // section B4.3.3.2 Failure conditions. + if ((Args == NULL) || (((UINT64)Args & (0x100 - 1)) != 0)) { return RETURN_INVALID_PARAMETER; } -- 'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)' -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#117705): https://edk2.groups.io/g/devel/message/117705 Mute This Topic: https://groups.io/mt/105483448/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-