powerpc/mm: Abstraction for switch_mmu_context()

How we switch MMU context differs between hash and radix. For hash we
need to switch the SLB details and for radix we need to switch the PID
SPR.

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
This commit is contained in:
Aneesh Kumar K.V
2016-04-29 23:26:01 +10:00
committed by Michael Ellerman
parent d9225ad923
commit d2adba3fd1
5 changed files with 19 additions and 17 deletions

View File

@@ -31,6 +31,6 @@ void save_processor_state(void)
void restore_processor_state(void)
{
#ifdef CONFIG_PPC32
switch_mmu_context(current->active_mm, current->active_mm);
switch_mmu_context(current->active_mm, current->active_mm, NULL);
#endif
}