arm64/fpsimd: Sync and zero pad FPSIMD state for streaming SVE
authorMark Brown <broonie@kernel.org>
Thu, 3 Aug 2023 18:33:23 +0000 (19:33 +0100)
committerCatalin Marinas <catalin.marinas@arm.com>
Fri, 4 Aug 2023 15:18:32 +0000 (16:18 +0100)
commit69af56ae56a48a2522aad906c4461c6c7c092737
tree89b6fdfdbc951cc816363cc02c0a3c3cdc255b57
parent507ea5dd92d23fcf10e4d1a68a443c86a49753ed
arm64/fpsimd: Sync and zero pad FPSIMD state for streaming SVE

We have a function sve_sync_from_fpsimd_zeropad() which is used by the
ptrace code to update the SVE state when the user writes to the the
FPSIMD register set.  Currently this checks that the task has SVE
enabled but this will miss updates for tasks which have streaming SVE
enabled if SVE has not been enabled for the thread, also do the
conversion if the task has streaming SVE enabled.

Fixes: e12310a0d30f ("arm64/sme: Implement ptrace support for streaming mode SVE registers")
Signed-off-by: Mark Brown <broonie@kernel.org>
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20230803-arm64-fix-ptrace-ssve-no-sve-v1-3-49df214bfb3e@kernel.org
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm64/kernel/fpsimd.c