From: Bhaktipriya Shridhar <bhaktipriya96@gmail.com>
To: Oleg Drokin <oleg.drokin@intel.com>,
Andreas Dilger <andreas.dilger@intel.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Dmitry Eremin <dmiter4ever@gmail.com>,
Bhumika Goyal <bhumirks@gmail.com>,
Julia Lawall <Julia.Lawall@lip6.fr>,
Cihangir Akturk <cakturk@gmail.com>,
Joe Perches <joe@perches.com>
Cc: lustre-devel@lists.lustre.org, devel@driverdev.osuosl.org,
linux-kernel@vger.kernel.org
Subject: [PATCH] staging: lusture: obdclass: Remove unnecessary NULL check
Date: Thu, 18 Feb 2016 20:55:39 +0530 [thread overview]
Message-ID: <20160218152539.GA28252@Karyakshetra> (raw)
NULL check before the debugfs_remove_recursive function is not needed.
This was detected using scripts/coccinelle/free/ifnullfree.cocci
Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com>
---
drivers/staging/lustre/lustre/obdclass/linux/linux-module.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c b/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c
index 1913f3e..2045621 100644
--- a/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c
+++ b/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c
@@ -454,8 +454,7 @@ out:
int class_procfs_clean(void)
{
- if (debugfs_lustre_root != NULL)
- debugfs_remove_recursive(debugfs_lustre_root);
+ debugfs_remove_recursive(debugfs_lustre_root);
debugfs_lustre_root = NULL;
--
2.1.4
next reply other threads:[~2016-02-18 15:25 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-18 15:25 Bhaktipriya Shridhar [this message]
2016-02-20 23:34 ` Greg Kroah-Hartman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160218152539.GA28252@Karyakshetra \
--to=bhaktipriya96@gmail.com \
--cc=Julia.Lawall@lip6.fr \
--cc=andreas.dilger@intel.com \
--cc=bhumirks@gmail.com \
--cc=cakturk@gmail.com \
--cc=devel@driverdev.osuosl.org \
--cc=dmiter4ever@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=joe@perches.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lustre-devel@lists.lustre.org \
--cc=oleg.drokin@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®