staging: lustre: drop null test before destroy functions
authorJulia Lawall <Julia.Lawall@lip6.fr>
Sun, 13 Sep 2015 12:15:06 +0000 (14:15 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 14 Sep 2015 15:50:44 +0000 (08:50 -0700)
commitce85ed4d15b44f6a3216f0e0b3ce464aecd44c3c
treef15259c01907381f6965a6cde4fff8dde82ad25a
parent910b551c85ae599201428e6ac110a222d0da4c50
staging: lustre: drop null test before destroy functions

Remove unneeded NULL test.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@
expression x;
@@

-if (x != NULL)
  \(kmem_cache_destroy\|mempool_destroy\|dma_pool_destroy\)(x);

@@
expression x;
@@

-if (x != NULL) {
  \(kmem_cache_destroy\|mempool_destroy\|dma_pool_destroy\)(x);
  x = NULL;
-}
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/llite/super25.c
drivers/staging/lustre/lustre/obdclass/genops.c
drivers/staging/lustre/lustre/obdclass/lu_object.c