Message ID | 20240111131558.31211-7-andy.chiu@sifive.com (mailing list archive) |
---|---|
State | Superseded |
Commit | 25a830944773d106cd58a1cb75cc2eda95ef8ebc |
Headers | show |
Series | riscv: support kernel-mode Vector | expand |
diff --git a/arch/riscv/include/asm/switch_to.h b/arch/riscv/include/asm/switch_to.h index f90d8e42f3c7..7efdb0584d47 100644 --- a/arch/riscv/include/asm/switch_to.h +++ b/arch/riscv/include/asm/switch_to.h @@ -53,8 +53,7 @@ static inline void __switch_to_fpu(struct task_struct *prev, struct pt_regs *regs; regs = task_pt_regs(prev); - if (unlikely(regs->status & SR_SD)) - fstate_save(prev, regs); + fstate_save(prev, regs); fstate_restore(next, task_pt_regs(next)); }