scsi: lpfc: Remove redundant assignment to avoid memory leak
[ Upstream commit eea6cafb5890db488fce1c69d05464214616d800 ]
Remove the redundant assignment if kzalloc() succeeds to avoid memory
leak.
Fixes: bd2cdd5e40 ("scsi: lpfc: NVME Initiator: Add debugfs support")
Signed-off-by: Jiasheng Jiang <jiashengjiangcool@gmail.com>
Link: https://lore.kernel.org/r/20250801185202.42631-1-jiashengjiangcool@gmail.com
Reviewed-by: Justin Tee <justin.tee@broadcom.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
3128167d22
commit
8797e9a827
@@ -6104,7 +6104,6 @@ lpfc_debugfs_initialize(struct lpfc_vport *vport)
|
||||
}
|
||||
phba->nvmeio_trc_on = 1;
|
||||
phba->nvmeio_trc_output_idx = 0;
|
||||
phba->nvmeio_trc = NULL;
|
||||
} else {
|
||||
nvmeio_off:
|
||||
phba->nvmeio_trc_size = 0;
|
||||
|
||||
Reference in New Issue
Block a user