Skip to content

Commit d7b77a0

Browse files
brooniewilldeacon
authored andcommitted
arm64/sme: Restore SMCR_EL1.EZT0 on exit from suspend
The fields in SMCR_EL1 reset to an architecturally UNKNOWN value. Since we do not otherwise manage the traps configured in this register at runtime we need to reconfigure them after a suspend in case nothing else was kind enough to preserve them for us. Do so for SMCR_EL1.EZT0. Fixes: d4913ee ("arm64/sme: Add basic enumeration for SME2") Reported-by: Jackson Cooper-Driver <Jackson.Cooper-Driver@arm.com> Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20240213-arm64-sme-resume-v3-2-17e05e493471@kernel.org Signed-off-by: Will Deacon <will@kernel.org>
1 parent 9533864 commit d7b77a0

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

arch/arm64/kernel/fpsimd.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1320,6 +1320,8 @@ void sme_suspend_exit(void)
13201320

13211321
if (system_supports_fa64())
13221322
smcr |= SMCR_ELx_FA64;
1323+
if (system_supports_sme2())
1324+
smcr |= SMCR_ELx_EZT0;
13231325

13241326
write_sysreg_s(smcr, SYS_SMCR_EL1);
13251327
write_sysreg_s(0, SYS_SMPRI_EL1);

0 commit comments

Comments
 (0)