Commit 0330581a authored by Tang Yuantian's avatar Tang Yuantian Committed by Benjamin Herrenschmidt

powerpc/mm: Fix the call trace when resumed from hibernation

	In SMP mode, the kernel would produce call trace when resumed
	from hibernation. The reason is when the function destroy_context
	is called to drop the resuming mm context, the mm->context.active
	is 1 which is wrong and should be zero.
	We pass the current->active_mm as previous mm context to function
	switch_mmu_context to decrease the context.active by 1.

	In UP mode, there is no effect.
Signed-off-by: default avatarTang Yuantian <b29983@freescale.com>
Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
parent 9c57a32b
......@@ -33,6 +33,6 @@ void save_processor_state(void)
void restore_processor_state(void)
{
#ifdef CONFIG_PPC32
switch_mmu_context(NULL, current->active_mm);
switch_mmu_context(current->active_mm, current->active_mm);
#endif
}
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