]> git.baikalelectronics.ru Git - kernel.git/commit
mm/slab_common.c: initialize kmem_cache pointer to NULL
authorAlexandru Moise <00moses.alexander00@gmail.com>
Fri, 6 Nov 2015 02:45:43 +0000 (18:45 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 6 Nov 2015 03:34:48 +0000 (19:34 -0800)
commitba4408cfef5d7265944a39b08488f87945a7828d
tree28804bff5d9fe24393ff8cc391138122bbf61ac3
parentd25069a4d7b9b91d7e4fb7a95e481f54f4ec8e61
mm/slab_common.c: initialize kmem_cache pointer to NULL

The assignment to NULL within the error condition was written in a 2014
patch to suppress a compiler warning.  However it would be cleaner to just
initialize the kmem_cache to NULL and just return it in case of an error
condition.

Signed-off-by: Alexandru Moise <00moses.alexander00@gmail.com>
Acked-by: Christoph Lameter <cl@linux.com>
Cc: Pekka Enberg <penberg@kernel.org>
Acked-by: David Rientjes <rientjes@google.com>
Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/slab_common.c