patch-2.3.13 linux/kernel/sched.c

Next file: linux/kernel/sysctl.c
Previous file: linux/kernel/resource.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.12/linux/kernel/sched.c linux/kernel/sched.c
@@ -779,6 +779,7 @@
 	 * but prev is set to (the just run) 'last' process by switch_to().
 	 * This might sound slightly confusing but makes tons of sense.
 	 */
+	prepare_to_switch();
 	{
 		struct mm_struct *mm = next->mm;
 		struct mm_struct *oldmm = prev->active_mm;
@@ -788,7 +789,7 @@
 			atomic_inc(&oldmm->mm_count);
 		} else {
 			if (next->active_mm != mm) BUG();
-			switch_mm(oldmm, mm, this_cpu);
+			switch_mm(oldmm, mm, next, this_cpu);
 		}
 
 		if (!prev->mm) {

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)