Skip to content

Commit

Permalink
slob: handle SLAB_PANIC flag
Browse files Browse the repository at this point in the history
kmem_cache_create() for slob doesn't handle SLAB_PANIC.

Signed-off-by: Matt Mackall <[email protected]>
Signed-off-by: Akinobu Mita <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
mita authored and Linus Torvalds committed May 7, 2007
1 parent 3a2cba9 commit bc0055a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion mm/slob.c
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,8 @@ struct kmem_cache *kmem_cache_create(const char *name, size_t size,
c->align = (flags & SLAB_MUST_HWCACHE_ALIGN) ? SLOB_ALIGN : 0;
if (c->align < align)
c->align = align;
}
} else if (flags & SLAB_PANIC)
panic("Cannot create slab cache %s\n", name);

return c;
}
Expand Down

0 comments on commit bc0055a

Please sign in to comment.