Commit 9cf5b54f authored by Dave Martin's avatar Dave Martin Committed by Will Deacon

arm64: fpsimd: Simplify uses of {set,clear}_ti_thread_flag()

The existing FPSIMD context switch code contains a couple of
instances of {set,clear}_ti_thread(task_thread_info(task)).  Since
there are thread flag manipulators that operate directly on
task_struct, this verbosity isn't strictly needed.

For consistency, this patch simplifies the affected calls.  This
should have no impact on behaviour.
Signed-off-by: default avatarDave Martin <Dave.Martin@arm.com>
Reviewed-by: default avatarAlex Bennée <alex.bennee@linaro.org>
Reviewed-by: default avatarCatalin Marinas <catalin.marinas@arm.com>
Acked-by: default avatarArd Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
parent 38b9aeb3
...@@ -160,11 +160,9 @@ void fpsimd_thread_switch(struct task_struct *next) ...@@ -160,11 +160,9 @@ void fpsimd_thread_switch(struct task_struct *next)
if (__this_cpu_read(fpsimd_last_state) == st if (__this_cpu_read(fpsimd_last_state) == st
&& st->cpu == smp_processor_id()) && st->cpu == smp_processor_id())
clear_ti_thread_flag(task_thread_info(next), clear_tsk_thread_flag(next, TIF_FOREIGN_FPSTATE);
TIF_FOREIGN_FPSTATE);
else else
set_ti_thread_flag(task_thread_info(next), set_tsk_thread_flag(next, TIF_FOREIGN_FPSTATE);
TIF_FOREIGN_FPSTATE);
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment