|
@@ -1031,18 +1031,11 @@ static inline void restore_sprs(struct thread_struct *old_thread,
|
|
|
#ifdef CONFIG_PPC_BOOK3S_64
|
|
|
if (cpu_has_feature(CPU_FTR_DSCR)) {
|
|
|
u64 dscr = get_paca()->dscr_default;
|
|
|
- u64 fscr = old_thread->fscr & ~FSCR_DSCR;
|
|
|
-
|
|
|
- if (new_thread->dscr_inherit) {
|
|
|
+ if (new_thread->dscr_inherit)
|
|
|
dscr = new_thread->dscr;
|
|
|
- fscr |= FSCR_DSCR;
|
|
|
- }
|
|
|
|
|
|
if (old_thread->dscr != dscr)
|
|
|
mtspr(SPRN_DSCR, dscr);
|
|
|
-
|
|
|
- if (old_thread->fscr != fscr)
|
|
|
- mtspr(SPRN_FSCR, fscr);
|
|
|
}
|
|
|
|
|
|
if (cpu_has_feature(CPU_FTR_ARCH_207S)) {
|
|
@@ -1053,6 +1046,9 @@ static inline void restore_sprs(struct thread_struct *old_thread,
|
|
|
if (old_thread->ebbrr != new_thread->ebbrr)
|
|
|
mtspr(SPRN_EBBRR, new_thread->ebbrr);
|
|
|
|
|
|
+ if (old_thread->fscr != new_thread->fscr)
|
|
|
+ mtspr(SPRN_FSCR, new_thread->fscr);
|
|
|
+
|
|
|
if (old_thread->tar != new_thread->tar)
|
|
|
mtspr(SPRN_TAR, new_thread->tar);
|
|
|
}
|