summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/csiostor
diff options
context:
space:
mode:
authorSaurav Girepunje <saurav.girepunje@gmail.com>2019-10-26 21:56:30 +0200
committerMartin K. Petersen <martin.petersen@oracle.com>2019-11-02 01:19:11 +0100
commit75a740e6e81c89e26a1bd2e628b84131ad90c997 (patch)
treea7e3f9d7106a565d08c2cd4567e7137f2153abab /drivers/scsi/csiostor
parentscsi: pm8001: Fix Use plain integer as NULL pointer (diff)
downloadlinux-75a740e6e81c89e26a1bd2e628b84131ad90c997.tar.xz
linux-75a740e6e81c89e26a1bd2e628b84131ad90c997.zip
scsi: csiostor: Fix NULL check before debugfs_remove_recursive
debugfs_remove_recursive() has taken the null pointer into account. Remove the null check before debugfs_remove_recursive(). Link: https://lore.kernel.org/r/20191026195625.GA22455@saurav Signed-off-by: Saurav Girepunje <saurav.girepunje@gmail.com> Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/csiostor')
-rw-r--r--drivers/scsi/csiostor/csio_init.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/scsi/csiostor/csio_init.c b/drivers/scsi/csiostor/csio_init.c
index a6dd704d7f2d..f98f36c0d6b7 100644
--- a/drivers/scsi/csiostor/csio_init.c
+++ b/drivers/scsi/csiostor/csio_init.c
@@ -157,8 +157,7 @@ csio_dfs_create(struct csio_hw *hw)
static int
csio_dfs_destroy(struct csio_hw *hw)
{
- if (hw->debugfs_root)
- debugfs_remove_recursive(hw->debugfs_root);
+ debugfs_remove_recursive(hw->debugfs_root);
return 0;
}