arm64: fix bug for reloading FPSIMD state after CPU hotplug.
Now FPSIMD don't handle HOTPLUG_CPU. This introduces bug after cpu down/up process. After cpu down/up process, the FPSMID hardware register is default value, not any process's fpsimd context. when CPU_DEAD set cpu's fpsimd_state to NULL, it will force to load the fpsimd context for the thread, to avoid the chance to skip to load the context. If process A is the last user process on CPU N before cpu down, and the first user process on the same CPU N after cpu up, A's fpsimd_state.cpu is the current cpu id, and per_cpu(fpsimd_last_state) points A's fpsimd_state, so kernel will not reload the context during it return to user space. Change-Id: Ia16d287748b5caa7a45c4bf5102e295722e8c166 Signed-off-by:Janet Liu <janet.liu@spreadtrum.com> Signed-off-by:
Xiongshan An <xiongshan.an@spreadtrum.com> Signed-off-by:
Chunyan Zhang <chunyan.zhang@spreadtrum.com> [catalin.marinas@arm.com: some mostly cosmetic clean-ups] Signed-off-by:
Catalin Marinas <catalin.marinas@arm.com> Git-commit: 32365e64a20edcc783137ad17fdd951ab814a2fe Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git Signed-off-by:
Se Wang (Patrick) Oh <sewango@codeaurora.org>
Loading
Please register or sign in to comment