We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 80c7c36 commit afdfd93Copy full SHA for afdfd93
arch/arm64/kernel/entry.S
@@ -168,15 +168,11 @@ alternative_else_nop_endif
168
#endif
169
.endm
170
171
- .macro mte_set_gcr, tmp, tmp2
+ .macro mte_set_gcr, mte_ctrl, tmp
172
#ifdef CONFIG_ARM64_MTE
173
- /*
174
- * Calculate and set the exclude mask preserving
175
- * the RRND (bit[16]) setting.
176
- */
177
- mrs_s \tmp2, SYS_GCR_EL1
178
- bfxil \tmp2, \tmp, #MTE_CTRL_GCR_USER_EXCL_SHIFT, #16
179
- msr_s SYS_GCR_EL1, \tmp2
+ ubfx \tmp, \mte_ctrl, #MTE_CTRL_GCR_USER_EXCL_SHIFT, #16
+ orr \tmp, \tmp, #SYS_GCR_EL1_RRND
+ msr_s SYS_GCR_EL1, \tmp
180
181
182
0 commit comments