LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: David Rientjes <rientjes@google.com>
To: Paul Jackson <pj@sgi.com>
Cc: akpm@linux-foundation.org, clameter@sgi.com,
	Lee.Schermerhorn@hp.com, ak@suse.de,
	linux-kernel@vger.kernel.org
Subject: Re: [patch -mm 2/2] mempolicy: use default_policy mode instead of MPOL_DEFAULT
Date: Fri, 7 Mar 2008 17:33:06 -0800 (PST)	[thread overview]
Message-ID: <alpine.DEB.1.00.0803071730340.6241@chino.kir.corp.google.com> (raw)
In-Reply-To: <20080307192845.0492c6f9.pj@sgi.com>

On Fri, 7 Mar 2008, Paul Jackson wrote:

> > So instead of checking for comparisons against a mempolicy's mode to
> > MPOL_DEFAULT or falling back stricly to MPOL_DEFAULT throughout the code,
> > we should use the mode that is defined in this struct.
> 
> Is this just a stylistic choice?  That is, is the same machine
> code produced either way?
> 
> If that's the case, could you briefly explain why you prefer
> one style (default_policy.policy) over the other (MPOL_DEFAULT)?
> 

Very fast response!

Yes, the same code is generated since default_policy.policy is statically 
declared as MPOL_DEFAULT.

I chose this because checks in mpol_new() to return NULL if the mode is 
MPOL_DEFAULT is purely based on the fact that, as the default system 
policy, policy task or VMA pointers are set to &default_policy.

  reply	other threads:[~2008-03-08  1:33 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-08  1:24 [patch -mm 1/2] mempolicy: disallow static or relative flags for local preferred mode David Rientjes
2008-03-08  1:24 ` [patch -mm 2/2] mempolicy: use default_policy mode instead of MPOL_DEFAULT David Rientjes
2008-03-08  1:28   ` Paul Jackson
2008-03-08  1:33     ` David Rientjes [this message]
2008-03-08  1:35       ` Paul Jackson
2008-03-08  1:59         ` Christoph Lameter
2008-03-08  2:14           ` David Rientjes
2008-03-08 19:13       ` Lee Schermerhorn
2008-03-08 22:20         ` David Rientjes
2008-03-08 23:19           ` Andi Kleen
2008-03-10 13:48             ` Lee Schermerhorn
2008-03-10 19:09 ` [patch -mm 1/2] mempolicy: disallow static or relative flags for local preferred mode Andrew Morton

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=alpine.DEB.1.00.0803071730340.6241@chino.kir.corp.google.com \
    --to=rientjes@google.com \
    --cc=Lee.Schermerhorn@hp.com \
    --cc=ak@suse.de \
    --cc=akpm@linux-foundation.org \
    --cc=clameter@sgi.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pj@sgi.com \
    --subject='Re: [patch -mm 2/2] mempolicy: use default_policy mode instead of MPOL_DEFAULT' \
    /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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).