scsi: ipr: remove NULL check before freeing function
Subsystems (2)
PATCH 1/1 scsi: ipr: remove NULL check before freeing function
Fix the following coccicheck warning:
drivers/scsi/ipr.c:9533:2-18: WARNING: NULL check before some freeing functions is not needed.
Reported-by Hulk Robot <[email protected]>
Signed-off-by Jason Yan <[email protected]>
--- drivers/scsi/ipr.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/scsi/ipr.c +1 -2
@@ -9529,8 +9529,7 @@ static void ipr_free_cmd_blks(struct ipr_ioa_cfg *ioa_cfg) } } -if (ioa_cfg->ipr_cmd_pool) -dma_pool_destroy (ioa_cfg->ipr_cmd_pool); +dma_pool_destroy (ioa_cfg->ipr_cmd_pool);kfree (ioa_cfg->ipr_cmnd_list);kfree (ioa_cfg->ipr_cmnd_list_dma);
Signature · 1 line
2.21.1
Martin K. Petersen
AppliedQuoted 4 lines · Jason Yan
Fix the following coccicheck warning:
drivers/scsi/ipr.c:9533:2-18: WARNING: NULL check before some freeing functions is not needed.
Applied to 5.8/scsi-queue, thanks!
[1/1] scsi: ipr: Remove NULL check before freeing function
https://git.kernel.org/mkp/scsi/c/2e9ef0fcac01
Signature · 1 line
Martin K. Petersen Oracle Linux Engineering