Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1356030

Re: [PATCH v4 5/7] mm, kasan: Stackdepot implementation. Enable stackdepot for SLAB

From Steven Rostedt <rostedt@goodmis.org>
Newsgroups linux.kernel
Subject Re: [PATCH v4 5/7] mm, kasan: Stackdepot implementation. Enable stackdepot for SLAB
Date 2016-03-11 17:20 +0100
Message-ID <rbxXc-mR-17@gated-at.bofh.it> (permalink)
References (4 earlier) <r7R87-dU-21@gated-at.bofh.it> <raojg-hv-1@gated-at.bofh.it> <rbc6m-1nU-7@gated-at.bofh.it> <rbtgS-5hR-21@gated-at.bofh.it> <rbtJV-5CI-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, 11 Mar 2016 14:43:45 +0300
Andrey Ryabinin <ryabinin.a.a@gmail.com> wrote:


> >> This is not about size, this about fragmentation. vmalloc allows to
> >> utilize available low-order pages,
> >> hence reduce the fragmentation.  
> > I've attempted to add __vmalloc(STACK_ALLOC_SIZE, alloc_flags,
> > PAGE_KERNEL) (also tried vmalloc(STACK_ALLOC_SIZE)) instead of
> > page_alloc() and am now getting a crash in
> > kmem_cache_alloc_node_trace() in mm/slab.c, because it doesn't allow
> > the kmem_cache pointer to be NULL (it's dereferenced when calling
> > trace_kmalloc_node()).
> > 
> > Steven, do you know if this because of my code violating some contract
> > (e.g. I'm calling vmalloc() too early, when kmalloc_caches[] haven't
> > been initialized),   
> 
> Probably. kmem_cache_init() goes before vmalloc_init().

Agreed, that function can not be called with cachep NULL, nor can it be
called before kmem_cache is set up to point to kmem_cache_boot.

-- Steve

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Re: [PATCH v4 5/7] mm, kasan: Stackdepot implementation. Enable  stackdepot for SLAB Alexander Potapenko <glider@google.com> - 2016-03-08 12:50 +0100
  Re: [PATCH v4 5/7] mm, kasan: Stackdepot implementation. Enable  stackdepot for SLAB Andrey Ryabinin <ryabinin.a.a@gmail.com> - 2016-03-10 18:00 +0100
    Re: [PATCH v4 5/7] mm, kasan: Stackdepot implementation. Enable  stackdepot for SLAB Alexander Potapenko <glider@google.com> - 2016-03-11 12:20 +0100
      Re: [PATCH v4 5/7] mm, kasan: Stackdepot implementation. Enable  stackdepot for SLAB Andrey Ryabinin <ryabinin.a.a@gmail.com> - 2016-03-11 12:50 +0100
        Re: [PATCH v4 5/7] mm, kasan: Stackdepot implementation. Enable  stackdepot for SLAB Alexander Potapenko <glider@google.com> - 2016-03-11 16:00 +0100
        Re: [PATCH v4 5/7] mm, kasan: Stackdepot implementation. Enable  stackdepot for SLAB Steven Rostedt <rostedt@goodmis.org> - 2016-03-11 17:20 +0100

csiph-web