[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4FBCAD03.5010106@parallels.com>
Date: Wed, 23 May 2012 13:25:23 +0400
From: Glauber Costa <glommer@...allels.com>
To: David Rientjes <rientjes@...gle.com>
CC: Christoph Lameter <cl@...ux.com>, <linux-kernel@...r.kernel.org>,
<cgroups@...r.kernel.org>, <linux-mm@...ck.org>,
Pekka Enberg <penberg@...helsinki.fi>
Subject: Re: [PATCH v2] slab+slob: dup name string
On 05/23/2012 07:55 AM, David Rientjes wrote:
> I hate consistency patches like this because it could potentially fail a
> kmem_cache_create() from a sufficiently long cache name when it wouldn't
> have before, but I'm not really concerned since kmem_cache_create() will
> naturally be followed by kmem_cache_alloc() which is more likely to cause
> the oom anyway. But it's just another waste of memory for consistency
> sake.
>
> This is much easier to do, just statically allocate the const char *'s
> needed for the boot caches and then set their ->name's manually in
> kmem_cache_init() and then avoid the kfree() in kmem_cache_destroy() if
> the name is between&boot_cache_name[0] and&boot_cache_name[n].
That can be done.
I'll also revisit my memcg patches to see if I can rework it so it
doesn't care about this particular behavior. We're having a surprisingly
difficult time reaching consensus on this, so maybe it would be better
left untouched (if there is a way that makes sense to)
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists