diff options
author | Pekka Enberg <penberg@kernel.org> | 2010-09-14 23:21:12 +0300 |
---|---|---|
committer | Pekka Enberg <penberg@kernel.org> | 2010-10-02 10:24:29 +0300 |
commit | 84c1cf62465e2fb0a692620dcfeb52323ab03d48 (patch) | |
tree | 704f4c7f7f0403aadd62be42d2e9d87abf2926fc /mm/bounce.c | |
parent | db210e70e5f191710a3b1d09f653b44885d397ea (diff) | |
download | blackbird-op-linux-84c1cf62465e2fb0a692620dcfeb52323ab03d48.tar.gz blackbird-op-linux-84c1cf62465e2fb0a692620dcfeb52323ab03d48.zip |
SLUB: Fix merged slab cache names
As explained by Linus "I'm Proud to be an American" Torvalds:
Looking at the merging code, I actually think it's totally
buggy. If you have something like this:
- load module A: create slab cache A
- load module B: create slab cache B that can merge with A
- unload module A
- "cat /proc/slabinfo": BOOM. Oops.
exactly because the name is not handled correctly, and you'll have
module B holding open a slab cache that has a name pointer that points
to module A that no longer exists.
This patch fixes the problem by using kstrdup() to allocate dynamic memory for
->name of "struct kmem_cache" as suggested by Christoph Lameter.
Acked-by: Christoph Lameter <cl@linux.com>
Cc: David Rientjes <rientjes@google.com>
Reported-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Pekka Enberg <penberg@kernel.org>
Conflicts:
mm/slub.c
Diffstat (limited to 'mm/bounce.c')
0 files changed, 0 insertions, 0 deletions