arm64: Fix a MTE check

It should be for FEAT_MTE2 as the registers aren't implemented for
FEAT_MTE.

While here fix the style of the comment explaining the check.

Reported by:	markj
Fixes:		58de791536 ("arm64: mte: configure initial state for system registers")
Sponsored by:	Arm Ltd
This commit is contained in:
Andrew Turner
2026-04-29 12:34:49 +01:00
parent 01ff0fa77d
commit 2783fb7e73
+3 -3
View File
@@ -1065,10 +1065,10 @@ LENTRY(start_mmu)
ldr x2, mair
/*
* If MTE is supported, configure GCR_EL1 and clear the TFSR registers of
* any pending tag check faults
* If FEAT_MTE2 is supported, configure GCR_EL1 and clear the TFSR
* registers of any pending tag check faults
*/
CHECK_CPU_FEAT(x3, ID_AA64PFR1, MTE, MTE, 1f)
CHECK_CPU_FEAT(x3, ID_AA64PFR1, MTE, MTE2, 1f)
/* Set GCR_EL1, non-zero tags excluded by default */
mov x3, #(GCR_Exclude_MASK | GCR_RRND)