summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/lpfc
diff options
context:
space:
mode:
authorSaurav Girepunje <saurav.girepunje@gmail.com>2019-10-26 21:47:17 +0200
committerMartin K. Petersen <martin.petersen@oracle.com>2019-10-29 02:52:38 +0100
commitc3e5aac3e2f501ad4fcb03fed0e32a6f009faea2 (patch)
treedb5683e98555a8a4d6193a9514dfd1140130b103 /drivers/scsi/lpfc
parentscsi: lpfc: fix spelling error in MAGIC_NUMER_xxx (diff)
downloadlinux-c3e5aac3e2f501ad4fcb03fed0e32a6f009faea2.tar.xz
linux-c3e5aac3e2f501ad4fcb03fed0e32a6f009faea2.zip
scsi: lpfc: Fix NULL check before mempool_destroy is not needed
mempool_destroy has taken null pointer check into account. Remove the redundant check. Link: https://lore.kernel.org/r/20191026194712.GA22249@saurav Signed-off-by: Saurav Girepunje <saurav.girepunje@gmail.com> Reviewed-by: James Smart <james.smart@broadcom.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/lpfc')
-rw-r--r--drivers/scsi/lpfc/lpfc_init.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init.c
index 9536ad3cc4ee..ec9dbc042a41 100644
--- a/drivers/scsi/lpfc/lpfc_init.c
+++ b/drivers/scsi/lpfc/lpfc_init.c
@@ -13464,8 +13464,7 @@ lpfc_sli4_oas_verify(struct lpfc_hba *phba)
phba->cfg_fof = 1;
} else {
phba->cfg_fof = 0;
- if (phba->device_data_mem_pool)
- mempool_destroy(phba->device_data_mem_pool);
+ mempool_destroy(phba->device_data_mem_pool);
phba->device_data_mem_pool = NULL;
}