fix(realm): fix calculation of Realm's REC index
This patch fixes the issues related to the calculation of
Realm's REC index based on the read value of MPIDR_EL1 register
and REC's mpidr parameter from the REC's index.
RMM reports MPIDR_EL1.Aff0 field matching RmiRecMpidr type
with [7:4] bits RES0, making MPIDR_EL1=0x80000100 represent
REC 16, but not 256 as it is implemented in the existing code.
The patch adds the following macros:
- RMI_REC_MPIDR(idx) which calculates RmiRecMpidr value based
on REC index.
- REC_IDX(mpidr) gets REC index from MPIDR_EL1.
Change-Id: Ieac473984f3a50d2815dcfe8d291d31bd70ebae7
Signed-off-by: AlexeiFedorov <Alexei.Fedorov@arm.com>
5 files changed