Commit d2883fa1 authored by John David Anglin's avatar John David Anglin Committed by Helge Deller
Browse files

parisc: Optimize switch_mm



We only need to switch contexts when prev != next, and we don't need to
disable interrupts to do the check.

Signed-off-by: default avatarJohn David Anglin <dave.anglin@bell.net>
Signed-off-by: default avatarHelge Deller <deller@gmx.de>
parent 42593e70
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -63,6 +63,9 @@ static inline void switch_mm(struct mm_struct *prev,
{
	unsigned long flags;

	if (prev == next)
		return;

	local_irq_save(flags);
	switch_mm_irqs_off(prev, next, tsk);
	local_irq_restore(flags);