[PATCH] NULL check before calling kfree() is not needed.
Aananth Chellapa Natarajan
c.n.aananth at gmail.com
Sun Mar 15 08:42:28 UTC 2015
This patch eliminates a redundant check of argument before calling
kfree() and therefore reducing kernel image size.
Signed-off-by: Aananth Chellapa Natarajan <c.n.aananth at gmail.com>
---
drivers/block/skd_main.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/block/skd_main.c b/drivers/block/skd_main.c
index 1e46eb2..c4b0259 100644
--- a/drivers/block/skd_main.c
+++ b/drivers/block/skd_main.c
@@ -3998,8 +3998,7 @@ static int skd_acquire_msix(struct skd_device *skdev)
return 0;
msix_out:
- if (entries)
- kfree(entries);
+ kfree(entries);
skd_release_msix(skdev);
return rc;
}
--
1.9.1
More information about the devel
mailing list