Re: [PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-07-08 Thread Li Zhong
On Fri, 2012-07-06 at 14:13 +0400, Glauber Costa wrote: > On 07/05/2012 01:29 PM, Li Zhong wrote: > > On Thu, 2012-07-05 at 12:23 +0400, Glauber Costa wrote: > >> On 07/05/2012 05:41 AM, Li Zhong wrote: > >>> On Wed, 2012-07-04 at 16:40 +0400, Glauber Costa wrote: > On 07/04/2012 01:00 PM, Li

Re: [PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-07-06 Thread Glauber Costa
On 07/05/2012 01:29 PM, Li Zhong wrote: > On Thu, 2012-07-05 at 12:23 +0400, Glauber Costa wrote: >> On 07/05/2012 05:41 AM, Li Zhong wrote: >>> On Wed, 2012-07-04 at 16:40 +0400, Glauber Costa wrote: On 07/04/2012 01:00 PM, Li Zhong wrote: > On Tue, 2012-07-03 at 15:36 -0500, Christoph La

Re: [PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-07-05 Thread Li Zhong
On Thu, 2012-07-05 at 12:23 +0400, Glauber Costa wrote: > On 07/05/2012 05:41 AM, Li Zhong wrote: > > On Wed, 2012-07-04 at 16:40 +0400, Glauber Costa wrote: > >> On 07/04/2012 01:00 PM, Li Zhong wrote: > >>> On Tue, 2012-07-03 at 15:36 -0500, Christoph Lameter wrote: > > Looking through the em

Re: [PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-07-05 Thread Glauber Costa
On 07/05/2012 05:41 AM, Li Zhong wrote: > On Wed, 2012-07-04 at 16:40 +0400, Glauber Costa wrote: >> On 07/04/2012 01:00 PM, Li Zhong wrote: >>> On Tue, 2012-07-03 at 15:36 -0500, Christoph Lameter wrote: > Looking through the emails it seems that there is an issue with alias > strings. >>

Re: [PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-07-04 Thread Li Zhong
On Wed, 2012-07-04 at 16:40 +0400, Glauber Costa wrote: > On 07/04/2012 01:00 PM, Li Zhong wrote: > > On Tue, 2012-07-03 at 15:36 -0500, Christoph Lameter wrote: > >> > Looking through the emails it seems that there is an issue with alias > >> > strings. > > To be more precise, there seems no big

Re: [PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-07-04 Thread Glauber Costa
On 07/04/2012 01:00 PM, Li Zhong wrote: > On Tue, 2012-07-03 at 15:36 -0500, Christoph Lameter wrote: >> > Looking through the emails it seems that there is an issue with alias >> > strings. > To be more precise, there seems no big issue currently. I just wanted to > make following usage of kmem_c

Re: [PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-07-04 Thread Li Zhong
On Tue, 2012-07-03 at 15:36 -0500, Christoph Lameter wrote: > Looking through the emails it seems that there is an issue with alias > strings. To be more precise, there seems no big issue currently. I just wanted to make following usage of kmem_cache_create (SLUB) possible: name = some s

Re: [PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-07-03 Thread Christoph Lameter
Looking through the emails it seems that there is an issue with alias strings. That can be solved by duping the name of the slab earlier in kmem_cache_create(). Does this patch fix the issue? Subject: slub: Dup name earlier in kmem_cache_create Dup the name earlier in kmem_cache_create so that a

Re: [PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-07-03 Thread Christoph Lameter
On Mon, 25 Jun 2012, Li Zhong wrote: > This patch tries to kfree the cache name of pgtables cache if SLUB is > used, as SLUB duplicates the cache name, and the original one is leaked. SLAB also does not free the name. Why would you have an #ifdef in there?

Re: [PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-06-28 Thread Zhong Li
On 06/29/2012 08:45 AM, Benjamin Herrenschmidt wrote: > On Mon, 2012-06-25 at 17:54 +0800, Li Zhong wrote: > >> diff --git a/arch/powerpc/mm/init_64.c b/arch/powerpc/mm/init_64.c >> index 620b7ac..c9d2a7f 100644 >> --- a/arch/powerpc/mm/init_64.c >> +++ b/arch/powerpc/mm/init_64.c >> @@ -130,6 +13

Re: [PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-06-28 Thread Benjamin Herrenschmidt
On Mon, 2012-06-25 at 17:54 +0800, Li Zhong wrote: > diff --git a/arch/powerpc/mm/init_64.c b/arch/powerpc/mm/init_64.c > index 620b7ac..c9d2a7f 100644 > --- a/arch/powerpc/mm/init_64.c > +++ b/arch/powerpc/mm/init_64.c > @@ -130,6 +130,9 @@ void pgtable_cache_add(unsigned shift, void > (*ctor)(vo

[PATCH powerpc 2/2] kfree the cache name of pgtable cache if SLUB is used

2012-06-25 Thread Li Zhong
This patch tries to kfree the cache name of pgtables cache if SLUB is used, as SLUB duplicates the cache name, and the original one is leaked. This patch depends on patch 1 -- (duplicate the cache name in saved_alias list) in this mail thread. As the pgtables cache might be merged to other caches.