public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] 2.6.3 Posix scheduling violation for !SCHED_OTHER
@ 2004-03-23 23:35 Joe Korty
  2004-03-24  0:01 ` Ingo Molnar
  0 siblings, 1 reply; 2+ messages in thread
From: Joe Korty @ 2004-03-23 23:35 UTC (permalink / raw)
  To: akpm; +Cc: linux-kernel, mingo

Andrew,
 The following fixes a problem where a SCHED_FIFO task would on occasion
be moved to the end of its runqueue when returned to from a preemption.
Cause was do to some SCHED_OTHER code in schedule() which was being
run for tasks of every policy.

Regards,
Joe


--- 2.6.3/kernel/sched.c.orig	2004-02-17 22:59:10.000000000 -0500
+++ 2.6.3/kernel/sched.c	2004-03-23 18:34:19.000000000 -0500
@@ -1677,7 +1677,7 @@
 	queue = array->queue + idx;
 	next = list_entry(queue->next, task_t, run_list);
 
-	if (next->activated > 0) {
+	if (!rt_task(next) && next->activated > 0) {
 		unsigned long long delta = now - next->timestamp;
 
 		if (next->activated == 1)

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] 2.6.3 Posix scheduling violation for !SCHED_OTHER
  2004-03-23 23:35 [PATCH] 2.6.3 Posix scheduling violation for !SCHED_OTHER Joe Korty
@ 2004-03-24  0:01 ` Ingo Molnar
  0 siblings, 0 replies; 2+ messages in thread
From: Ingo Molnar @ 2004-03-24  0:01 UTC (permalink / raw)
  To: Joe Korty; +Cc: akpm, linux-kernel


* Joe Korty <joe.korty@ccur.com> wrote:

> Andrew,
>  The following fixes a problem where a SCHED_FIFO task would on
> occasion be moved to the end of its runqueue when returned to from a
> preemption. Cause was do to some SCHED_OTHER code in schedule() which
> was being run for tasks of every policy.

yes, indeed this is a bug.

> -	if (next->activated > 0) {
> +	if (!rt_task(next) && next->activated > 0) {

the patch looks good. Andrew, please apply.

	Ingo

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-03-24  0:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-03-23 23:35 [PATCH] 2.6.3 Posix scheduling violation for !SCHED_OTHER Joe Korty
2004-03-24  0:01 ` Ingo Molnar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox