Commit 05b98791 authored by Christophe Leroy's avatar Christophe Leroy Committed by Michael Ellerman

powerpc: Replace current_thread_info()->task with current

We have a few places that use current_thread_info()->task to access
current. This won't work with THREAD_INFO_IN_TASK so fix them now.
Signed-off-by: default avatarChristophe Leroy <christophe.leroy@c-s.fr>
Reviewed-by: default avatarNicholas Piggin <npiggin@gmail.com>
[mpe: Split out of larger patch]
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
parent 7306e83c
......@@ -1231,8 +1231,8 @@ struct task_struct *__switch_to(struct task_struct *prev,
batch->active = 1;
}
if (current_thread_info()->task->thread.regs) {
restore_math(current_thread_info()->task->thread.regs);
if (current->thread.regs) {
restore_math(current->thread.regs);
/*
* The copy-paste buffer can only store into foreign real
......@@ -1242,7 +1242,7 @@ struct task_struct *__switch_to(struct task_struct *prev,
* mappings, we must issue a cp_abort to clear any state and
* prevent snooping, corruption or a covert channel.
*/
if (current_thread_info()->task->thread.used_vas)
if (current->thread.used_vas)
asm volatile(PPC_CP_ABORT);
}
#endif /* CONFIG_PPC_BOOK3S_64 */
......
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