Pekka Enberg 84c1cf6246 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
2010-10-02 10:24:29 +03:00
..
2009-04-01 08:59:13 -07:00
2010-08-08 21:57:23 +01:00
2010-09-09 18:57:24 -07:00
2010-07-14 17:14:00 +10:00
2010-09-20 10:44:37 -07:00
2009-09-22 07:17:35 -07:00
2010-05-25 08:06:58 -07:00
2010-09-09 09:05:06 -07:00
2010-03-24 16:31:21 -07:00
2010-05-21 18:31:21 -04:00
2010-08-21 08:49:21 -07:00
2010-09-21 08:12:25 +02:00
2007-10-20 01:27:18 +02:00
2010-05-25 08:07:00 -07:00
2010-10-02 10:24:29 +03:00
2010-05-25 15:06:06 +02:00
2009-06-23 12:50:05 -07:00
2010-08-09 20:44:54 -07:00