public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] sched: Move level 'again' after get_cpu() in sched_exec.
@ 2010-01-12 10:42 Rakib Mullick
  2010-01-12 10:50 ` Peter Zijlstra
  0 siblings, 1 reply; 2+ messages in thread
From: Rakib Mullick @ 2010-01-12 10:42 UTC (permalink / raw)
  To: LKML; +Cc: Ingo Molnar, Peter Zijlstra

            sched: move level again after get_cpu().

 We can get this_cpu by calling get_cpu() once and it remains
same. We don't need to call it again.

Signed-off-by: Rakib Mullick <rakib.mullick@gmail.com>
---

--- linus/kernel/sched.c	2010-01-06 20:11:10.000000000 +0600
+++ rakib/kernel/sched.c	2010-01-12 16:01:54.000000000 +0600
@@ -3143,8 +3143,8 @@ void sched_exec(void)
 	unsigned long flags;
 	struct rq *rq;

-again:
 	this_cpu = get_cpu();
+again:
 	dest_cpu = select_task_rq(p, SD_BALANCE_EXEC, 0);
 	if (dest_cpu == this_cpu) {
 		put_cpu();

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

end of thread, other threads:[~2010-01-12 10:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-12 10:42 [PATCH] sched: Move level 'again' after get_cpu() in sched_exec Rakib Mullick
2010-01-12 10:50 ` Peter Zijlstra

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