RE: [PATCH v3] mm/slab_common: Support the slub_debug boot option on specific object size

2015-04-24 Thread Daniel Sanders
> This patch conflicts significantly with Daniel's "slab: correct > size_index table before replacing the bootstrap kmem_cache_node". I've > reworked Daniel's patch as below. Please review? Your revised version of my patch looks good to me. I've also re-tested LLVMLinux with Gavin's and my (revi

Re: [PATCH v3] mm/slab_common: Support the slub_debug boot option on specific object size

2015-04-24 Thread Christoph Lameter
On Thu, 23 Apr 2015, Andrew Morton wrote: > > > > + if (i == 2) > > + i = (KMALLOC_SHIFT_LOW - 1); > > Can we get rid of this by using something like Nope index is a ilog2 value of the size. The table changes would not preserve the mapping of the index to the power of t

Re: [PATCH v3] mm/slab_common: Support the slub_debug boot option on specific object size

2015-04-23 Thread Andrew Morton
On Thu, 23 Apr 2015 21:26:00 +0800 Gavin Guo wrote: > The slub_debug=PU,kmalloc-xx cannot work because in the > create_kmalloc_caches() the s->name is created after the > create_kmalloc_cache() is called. The name is NULL in the > create_kmalloc_cache() so the kmem_cache_flags() would not set the

Re: [PATCH v3] mm/slab_common: Support the slub_debug boot option on specific object size

2015-04-23 Thread Andrew Morton
On Thu, 23 Apr 2015 21:26:00 +0800 Gavin Guo wrote: > The slub_debug=PU,kmalloc-xx cannot work because in the > create_kmalloc_caches() the s->name is created after the > create_kmalloc_cache() is called. The name is NULL in the > create_kmalloc_cache() so the kmem_cache_flags() would not set the

Re: [PATCH v3] mm/slab_common: Support the slub_debug boot option on specific object size

2015-04-23 Thread Christoph Lameter
On Thu, 23 Apr 2015, Gavin Guo wrote: > - if (KMALLOC_MIN_SIZE <= 64 && !kmalloc_caches[2] && i == 7) > - kmalloc_caches[2] = create_kmalloc_cache(NULL, 192, > flags); > + if (i == 2) > + i = (KMALLOC_SHIFT_LOW - 1); > } Ok th

[PATCH v3] mm/slab_common: Support the slub_debug boot option on specific object size

2015-04-23 Thread Gavin Guo
The slub_debug=PU,kmalloc-xx cannot work because in the create_kmalloc_caches() the s->name is created after the create_kmalloc_cache() is called. The name is NULL in the create_kmalloc_cache() so the kmem_cache_flags() would not set the slub_debug flags to the s->flags. The fix here set up a kmall