Skip to content

Commit bc67f10

Browse files
Anshuman Khandualctmarinas
authored andcommitted
arm64/cpufeature: Add remaining feature bits in ID_AA64MMFR0 register
Enable EVC, FGT, EXS features bits in ID_AA64MMFR0 register as per ARM DDI 0487F.a specification. Suggested-by: Will Deacon <[email protected]> Signed-off-by: Anshuman Khandual <[email protected]> Reviewed-by: Suzuki K Poulose <[email protected]> Cc: Will Deacon <[email protected]> Cc: Mark Rutland <[email protected]> Cc: Suzuki K Poulose <[email protected]> Cc: [email protected] Cc: [email protected] Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Catalin Marinas <[email protected]>
1 parent 9ebcfad commit bc67f10

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

arch/arm64/include/asm/sysreg.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -706,6 +706,9 @@
706706
#define ID_AA64ZFR0_SVEVER_SVE2 0x1
707707

708708
/* id_aa64mmfr0 */
709+
#define ID_AA64MMFR0_ECV_SHIFT 60
710+
#define ID_AA64MMFR0_FGT_SHIFT 56
711+
#define ID_AA64MMFR0_EXS_SHIFT 44
709712
#define ID_AA64MMFR0_TGRAN4_2_SHIFT 40
710713
#define ID_AA64MMFR0_TGRAN64_2_SHIFT 36
711714
#define ID_AA64MMFR0_TGRAN16_2_SHIFT 32

arch/arm64/kernel/cpufeature.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -269,6 +269,9 @@ static const struct arm64_ftr_bits ftr_id_aa64zfr0[] = {
269269
};
270270

271271
static const struct arm64_ftr_bits ftr_id_aa64mmfr0[] = {
272+
ARM64_FTR_BITS(FTR_HIDDEN, FTR_STRICT, FTR_LOWER_SAFE, ID_AA64MMFR0_ECV_SHIFT, 4, 0),
273+
ARM64_FTR_BITS(FTR_HIDDEN, FTR_STRICT, FTR_LOWER_SAFE, ID_AA64MMFR0_FGT_SHIFT, 4, 0),
274+
ARM64_FTR_BITS(FTR_HIDDEN, FTR_STRICT, FTR_LOWER_SAFE, ID_AA64MMFR0_EXS_SHIFT, 4, 0),
272275
/*
273276
* Page size not being supported at Stage-2 is not fatal. You
274277
* just give up KVM if PAGE_SIZE isn't supported there. Go fix

0 commit comments

Comments
 (0)