diff options
author | Heiko Carstens <hca@linux.ibm.com> | 2024-02-03 11:45:09 +0100 |
---|---|---|
committer | Heiko Carstens <hca@linux.ibm.com> | 2024-02-16 14:30:15 +0100 |
commit | 419abc4d3828813b58d047da146f519eedaa395b (patch) | |
tree | b358423efb377ffd2c050aab1ab2e41740ba44ab /arch/s390/kernel/process.c | |
parent | 918c7cad66509c2170e38a088550fb4a525e0878 (diff) | |
download | linux-419abc4d3828813b58d047da146f519eedaa395b.tar.gz |
s390/fpu: convert FPU CIF flag to regular TIF flag
The FPU state, as represented by the CIF_FPU flag reflects the FPU state of
a task, not the CPU it is running on. Therefore convert the flag to a
regular TIF flag.
This removes the magic in switch_to() where a save_fpu_regs() call for the
currently (previous) running task sets the per-cpu CIF_FPU flag, which is
required to restore FPU register contents of the next task, when it returns
to user space.
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Diffstat (limited to 'arch/s390/kernel/process.c')
-rw-r--r-- | arch/s390/kernel/process.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/arch/s390/kernel/process.c b/arch/s390/kernel/process.c index b0578ea230e734..f4c355f080f2e4 100644 --- a/arch/s390/kernel/process.c +++ b/arch/s390/kernel/process.c @@ -88,7 +88,7 @@ int arch_dup_task_struct(struct task_struct *dst, struct task_struct *src) { /* * Save the floating-point or vector register state of the current - * task and set the CIF_FPU flag to lazy restore the FPU register + * task and set the TIF_FPU flag to lazy restore the FPU register * state when returning to user space. */ save_fpu_regs(); @@ -196,11 +196,6 @@ void execve_tail(void) struct task_struct *__switch_to(struct task_struct *prev, struct task_struct *next) { - /* - * save_fpu_regs() sets the CIF_FPU flag, which enforces - * a restore of the floating point / vector registers as - * soon as the next task returns to user space. - */ save_fpu_regs(); save_access_regs(&prev->thread.acrs[0]); save_ri_cb(prev->thread.ri_cb); |