* [PATCH][DOC] kernelnewbies helpful hint #1
@ 2002-10-16 19:30 Rik van Riel
2002-10-16 19:35 ` Arnaldo Carvalho de Melo
0 siblings, 1 reply; 2+ messages in thread
From: Rik van Riel @ 2002-10-16 19:30 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo; +Cc: Kernel Mailing List
Hi,
this little patch documents a point in the scheduler where many people
seem to get confused.
===== kernel/sched.c 1.140 vs edited =====
--- 1.140/kernel/sched.c Mon Oct 14 10:30:06 2002
+++ edited/kernel/sched.c Wed Oct 16 17:28:29 2002
@@ -1035,6 +1035,12 @@
prepare_arch_switch(rq, next);
prev = context_switch(prev, next);
+ /*
+ * Kernelnewbies hint: at this point the current process
+ * has switched from prev to next. Prev is sitting on the
+ * run queue and next unlocks the runqueue, either here or
+ * in ret_from_fork (for newly forked processes).
+ */
barrier();
rq = this_rq();
finish_arch_switch(rq, prev);
Rik
--
Bravely reimplemented by the knights who say "NIH".
http://www.surriel.com/ http://distro.conectiva.com/
Current spamtrap: <a href=mailto:"october@surriel.com">october@surriel.com</a>
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH][DOC] kernelnewbies helpful hint #1
2002-10-16 19:30 [PATCH][DOC] kernelnewbies helpful hint #1 Rik van Riel
@ 2002-10-16 19:35 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 2+ messages in thread
From: Arnaldo Carvalho de Melo @ 2002-10-16 19:35 UTC (permalink / raw)
To: Rik van Riel; +Cc: Kernel Mailing List
Em Wed, Oct 16, 2002 at 05:30:04PM -0200, Rik van Riel escreveu:
> this little patch documents a point in the scheduler where many people
> seem to get confused.
Thanks a lot.
- Arnaldo
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-10-16 19:29 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-10-16 19:30 [PATCH][DOC] kernelnewbies helpful hint #1 Rik van Riel
2002-10-16 19:35 ` Arnaldo Carvalho de Melo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox