All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gautham R Shenoy <ego@in.ibm.com>
To: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Thomas Gleixner <tglx@linutronix.de>, Ingo Molnar <mingo@elte.hu>,
	"H. Peter Anvin" <hpa@zytor.com>,
	linux-next@vger.kernel.org, Rusty Russell <rusty@rustcorp.com.au>
Subject: Re: linux-next: sched tree build warning
Date: Tue, 21 Apr 2009 08:40:49 +0530	[thread overview]
Message-ID: <20090421031049.GA4140@in.ibm.com> (raw)
In-Reply-To: <20090421102706.e19240a0.sfr@canb.auug.org.au>

On Tue, Apr 21, 2009 at 10:27:06AM +1000, Stephen Rothwell wrote:
> Hi all,
> 
> Today's linux-next build (powerpc ppc64_defconfig) produced this new
> warning:
> 
> kernel/sched.c: In function 'find_new_ilb':
> kernel/sched.c:4355: warning: passing argument 1 of '__first_cpu' from incompatible pointer type
> 
> Possibly caused by commit f711f6090a81cbd396b63de90f415d33f563af9b
> ("sched: Nominate idle load balancer from a semi-idle package") from the
> sched tree.  Should this call to first_cpu be cpumask_first?

Yes, it should be cpumask_first. Patch appended.

-->
sched: Replace first_cpu() with cpumask_first() in ILB nomination code.

From: Gautham R Shenoy <ego@in.ibm.com>

For !(CONFIG_SCHED_MC || CONFIG_SCHED_SMT), find_new_ilb() nominates the
Idle load balancer as the first cpu from the nohz.cpu_mask.

This code uses the older API first_cpu(). Replace it with cpumask_first(),
which is the correct API here.

Signed-off-by: Gautham R Shenoy <ego@in.ibm.com>
---

 kernel/sched.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)


diff --git a/kernel/sched.c b/kernel/sched.c
index bbf367d..6df8dd5 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -4344,7 +4344,7 @@ out_done:
 #else /*  (CONFIG_SCHED_MC || CONFIG_SCHED_SMT) */
 static inline int find_new_ilb(int call_cpu)
 {
-	return first_cpu(nohz.cpu_mask);
+	return cpumask_first(nohz.cpu_mask);
 }
 #endif
 

> 
> -- 
> Cheers,
> Stephen Rothwell                    sfr@canb.auug.org.au
> http://www.canb.auug.org.au/~sfr/



-- 
Thanks and Regards
gautham

  reply	other threads:[~2009-04-21  3:11 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-21  0:27 linux-next: sched tree build warning Stephen Rothwell
2009-04-21  3:10 ` Gautham R Shenoy [this message]
2009-04-21  3:28   ` Stephen Rothwell
2009-04-21  6:09   ` Ingo Molnar
2009-04-21  8:06   ` [tip:sched/core] sched: Replace first_cpu() with cpumask_first() in ILB nomination code tip-bot for Gautham R Shenoy
2009-04-21  6:21 ` linux-next: sched tree build warning Rusty Russell
  -- strict thread matches above, loose matches on Subject: below --
2009-05-07  1:21 Stephen Rothwell
2009-05-07  6:45 ` David Rientjes
2009-05-07  7:39   ` Ingo Molnar
2008-12-22  4:22 Stephen Rothwell
2008-12-22  6:47 ` Ingo Molnar
2008-12-22  6:49 ` Ken Chen
2008-12-22  7:04   ` Ingo Molnar
2008-12-22  7:19     ` Stephen Rothwell
2008-12-22  8:14     ` Paul Mackerras
2008-12-22  8:18       ` Ingo Molnar
2008-12-22  9:44         ` Paul Mackerras
2008-12-22 10:53           ` Ingo Molnar
2008-12-22 12:03             ` Paul Mackerras

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=20090421031049.GA4140@in.ibm.com \
    --to=ego@in.ibm.com \
    --cc=hpa@zytor.com \
    --cc=linux-next@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=rusty@rustcorp.com.au \
    --cc=sfr@canb.auug.org.au \
    --cc=tglx@linutronix.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.