public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@elte.hu>
To: "Siddha, Suresh B" <suresh.b.siddha@intel.com>
Cc: Andrew Morton <akpm@osdl.org>,
	mbligh@mbligh.org, linux-kernel@vger.kernel.org,
	apw@shadowen.org
Subject: Re: [patch] sched: fix macro -> inline function conversion bug
Date: Wed, 5 Jul 2006 23:17:02 +0200	[thread overview]
Message-ID: <20060705211702.GA24961@elte.hu> (raw)
In-Reply-To: <20060705140948.B7271@unix-os.sc.intel.com>


* Siddha, Suresh B <suresh.b.siddha@intel.com> wrote:

> On Wed, Jul 05, 2006 at 10:02:45PM +0200, Ingo Molnar wrote:
> > 
> > * Siddha, Suresh B <suresh.b.siddha@intel.com> wrote:
> > 
> > > -		if (sd && sd->flags & flag)
> > > +		if (sd && !(sd->flags & flag))
> > 
> > use test_sd_flag() here, as i did in my fix patch.
> > 
> > > -#define test_sd_flag(sd, flag)	((sd && sd->flags & flag) ? 1 : 0)
> > > +#define test_sd_flag(sd, flag)	((sd && (sd->flags & flag)) ? 1 : 0)
> > 
> > remove the 'sd' check in test_sd_flag. In the other cases we know that 
> > there's an sd. (it's usually a sign of spaghetti code if tests like this 
> > include a check for the existence of the object checked)
> 
> In other cases, we are passing sd->parent as the first argument to 
> test_sd_flag(). We know that there is a 'sd' but not sure about 
> sd->parent or sd->child.

ok. But the first issue above should be fixed.

	Ingo

  reply	other threads:[~2006-07-05 21:21 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-02 23:27 2.6.17-mm5 Martin J. Bligh
2006-07-02 23:41 ` 2.6.17-mm5 Andrew Morton
2006-07-03  5:25   ` [patch] sched: fix macro -> inline function conversion bug Ingo Molnar
2006-07-03  5:42     ` Andrew Morton
2006-07-03  6:03       ` Ingo Molnar
2006-07-03  6:08         ` Ingo Molnar
2006-07-05 19:36           ` Siddha, Suresh B
2006-07-05 20:02             ` Ingo Molnar
2006-07-05 21:09               ` Siddha, Suresh B
2006-07-05 21:17                 ` Ingo Molnar [this message]
2006-07-05 21:21                   ` Siddha, Suresh B
2006-07-06  8:27             ` Andy Whitcroft
2006-07-03  6:06       ` Peter Williams
2006-07-03  8:23   ` 2.6.17-mm5 Andy Whitcroft
2006-07-03 14:19     ` 2.6.17-mm5 Andy Whitcroft

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=20060705211702.GA24961@elte.hu \
    --to=mingo@elte.hu \
    --cc=akpm@osdl.org \
    --cc=apw@shadowen.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mbligh@mbligh.org \
    --cc=suresh.b.siddha@intel.com \
    /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