From: Gregory Haskins <ghaskins@novell.com>
To: mingo@elte.hu, peterz@infradead.org, kravetz@us.ibm.com,
rostedt@goodmis.org
Cc: ghaskins@novell.com, linux-rt-users@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: [PATCH] RT: Fix special-case exception for preempting the local CPU
Date: Wed, 10 Oct 2007 10:49:35 -0400 [thread overview]
Message-ID: <20071010144824.21333.52155.stgit@novell1.haskins.net> (raw)
Applies to 2.6.23-rc9-rt2... This is another RTO related fix from the thread
two days ago.
---
RT: Fix special-case exception for preempting the local CPU
Check whether the local CPU is eligible to take the task before trying to
preempt it.
Signed-off-by: Gregory Haskins <ghaskins@novell.com>
---
kernel/sched.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/kernel/sched.c b/kernel/sched.c
index 3e75c62..b7f7a96 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -1869,7 +1869,8 @@ out_activate:
* extra locking in this particular case, because
* we are on the current CPU.)
*/
- if (TASK_PREEMPTS_CURR(p, this_rq))
+ if (TASK_PREEMPTS_CURR(p, this_rq)
+ && cpu_isset(this_cpu, p->cpus_allowed))
set_tsk_need_resched(this_rq->curr);
else
/*
next reply other threads:[~2007-10-10 15:03 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-10 14:49 Gregory Haskins [this message]
2007-10-10 16:22 ` mike kravetz
2007-10-11 10:51 ` Ankita Garg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20071010144824.21333.52155.stgit@novell1.haskins.net \
--to=ghaskins@novell.com \
--cc=kravetz@us.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rt-users@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=peterz@infradead.org \
--cc=rostedt@goodmis.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®