Skip to content

Commit 853772b

Browse files
Anshuman Khandualctmarinas
authored andcommitted
arm64/cpufeature: Add remaining feature bits in ID_AA64MMFR1 register
Enable ETS, TWED, XNX and SPECSEI features bits in ID_AA64MMFR1 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 bc67f10 commit 853772b

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

arch/arm64/include/asm/sysreg.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -737,6 +737,10 @@
737737
#endif
738738

739739
/* id_aa64mmfr1 */
740+
#define ID_AA64MMFR1_ETS_SHIFT 36
741+
#define ID_AA64MMFR1_TWED_SHIFT 32
742+
#define ID_AA64MMFR1_XNX_SHIFT 28
743+
#define ID_AA64MMFR1_SPECSEI_SHIFT 24
740744
#define ID_AA64MMFR1_PAN_SHIFT 20
741745
#define ID_AA64MMFR1_LOR_SHIFT 16
742746
#define ID_AA64MMFR1_HPD_SHIFT 12

arch/arm64/kernel/cpufeature.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -315,6 +315,10 @@ static const struct arm64_ftr_bits ftr_id_aa64mmfr0[] = {
315315
};
316316

317317
static const struct arm64_ftr_bits ftr_id_aa64mmfr1[] = {
318+
ARM64_FTR_BITS(FTR_HIDDEN, FTR_STRICT, FTR_LOWER_SAFE, ID_AA64MMFR1_ETS_SHIFT, 4, 0),
319+
ARM64_FTR_BITS(FTR_HIDDEN, FTR_STRICT, FTR_LOWER_SAFE, ID_AA64MMFR1_TWED_SHIFT, 4, 0),
320+
ARM64_FTR_BITS(FTR_HIDDEN, FTR_STRICT, FTR_LOWER_SAFE, ID_AA64MMFR1_XNX_SHIFT, 4, 0),
321+
ARM64_FTR_BITS(FTR_HIDDEN, FTR_STRICT, FTR_HIGHER_SAFE, ID_AA64MMFR1_SPECSEI_SHIFT, 4, 0),
318322
ARM64_FTR_BITS(FTR_HIDDEN, FTR_STRICT, FTR_LOWER_SAFE, ID_AA64MMFR1_PAN_SHIFT, 4, 0),
319323
ARM64_FTR_BITS(FTR_HIDDEN, FTR_STRICT, FTR_LOWER_SAFE, ID_AA64MMFR1_LOR_SHIFT, 4, 0),
320324
ARM64_FTR_BITS(FTR_HIDDEN, FTR_STRICT, FTR_LOWER_SAFE, ID_AA64MMFR1_HPD_SHIFT, 4, 0),

0 commit comments

Comments
 (0)