From 0ed777da08d81dc1c246177a5295d96f63279b19 Mon Sep 17 00:00:00 2001 From: Himanshu Madhani Date: Thu, 1 Aug 2019 15:56:06 -0400 Subject: [PATCH 106/124] [scsi] scsi: qla2xxx: Remove unnecessary null check Message-id: <20190801155618.12650-107-hmadhani@redhat.com> Patchwork-id: 267875 O-Subject: [RHEL 7.8 e-stor PATCH 106/118] scsi: qla2xxx: Remove unnecessary null check Bugzilla: 1729270 RH-Acked-by: Jarod Wilson RH-Acked-by: Tony Camuso From: YueHaibing Bugzilla 1729270 A null check before dma_pool_destroy is redundant, so remove it. This is detected by coccinelle. Signed-off-by: YueHaibing Acked-by: Himanshu Madhani Signed-off-by: Martin K. Petersen (cherry picked from commit 0b3b6fe299c471e44ed8713b7a602882626e693f) Signed-off-by: Himanshu Madhani Signed-off-by: Jan Stancek --- drivers/scsi/qla2xxx/qla_os.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c index 5009c5e4b276..c98ba0cd5183 100644 --- a/drivers/scsi/qla2xxx/qla_os.c +++ b/drivers/scsi/qla2xxx/qla_os.c @@ -4866,8 +4866,7 @@ qla2x00_mem_free(struct qla_hw_data *ha) } } - if (ha->dif_bundl_pool) - dma_pool_destroy(ha->dif_bundl_pool); + dma_pool_destroy(ha->dif_bundl_pool); ha->dif_bundl_pool = NULL; qlt_mem_free(ha); -- 2.13.6