linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: David Rientjes <rientjes@google.com>
To: Glauber Costa <glommer@parallels.com>
Cc: Pekka Enberg <penberg@kernel.org>,
	Christoph Lameter <cl@linux.com>,
	linux-mm@kvack.org, linux-kernel@vger.kernel.org,
	Andrew Morton <akpm@linux-foundation.org>,
	Pekka Enberg <penberg@cs.helsinki.fi>
Subject: Re: [PATCH v3] slab: Ignore internal flags in cache creation
Date: Tue, 2 Oct 2012 12:54:17 -0700 (PDT)	[thread overview]
Message-ID: <alpine.DEB.2.00.1210021251330.7383@chino.kir.corp.google.com> (raw)
In-Reply-To: <1349171968-19243-1-git-send-email-glommer@parallels.com>

On Tue, 2 Oct 2012, Glauber Costa wrote:

> diff --git a/mm/slab_common.c b/mm/slab_common.c
> index 9c21725..79be32e 100644
> --- a/mm/slab_common.c
> +++ b/mm/slab_common.c
> @@ -107,6 +107,13 @@ struct kmem_cache *kmem_cache_create(const char *name, size_t size, size_t align
>  	if (!kmem_cache_sanity_check(name, size) == 0)
>  		goto out_locked;
>  
> +	/*
> +	 * Some allocators will constraint the set of valid flags to a subset
> +	 * of all flags. We expect them to define CACHE_CREATE_MASK in this

s/CACHE_CREATE_MASK/SLAB_AVAILABLE_FLAGS/

I don't think SLAB_AVAILABLE_FLAGS is the best name we can come up with, I 
think it should be at least something like CACHE_ALLOWED_FLAGS, but I'm 
fine with whatever it turns out to be.

> +	 * case, and we'll just provide them with a sanitized version of the
> +	 * passed flags.
> +	 */
> +	flags &= SLAB_AVAILABLE_FLAGS;
>  
>  	s = __kmem_cache_alias(name, size, align, flags, ctor);
>  	if (s)

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

      parent reply	other threads:[~2012-10-02 19:54 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-02  9:59 Glauber Costa
2012-10-02 18:11 ` Christoph Lameter
2012-10-02 19:54 ` David Rientjes [this message]

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.2.00.1210021251330.7383@chino.kir.corp.google.com \
    --to=rientjes@google.com \
    --cc=akpm@linux-foundation.org \
    --cc=cl@linux.com \
    --cc=glommer@parallels.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=penberg@cs.helsinki.fi \
    --cc=penberg@kernel.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