Skip to content
Commit 4a1cc2f7 authored by Quinn Tran's avatar Quinn Tran Committed by Greg Kroah-Hartman
Browse files

scsi: qla2xxx: Fix SRB leak on switch command timeout

[ Upstream commit af2a0c51 ]

when GPSC/GPDB switch command fails, driver just returns without doing a
proper cleanup. This patch fixes this memory leak by calling sp->free() in
the error path.

Link: https://lore.kernel.org/r/20191105150657.8092-4-hmadhani@marvell.com


Reviewed-by: default avatarEwan D. Milne <emilne@redhat.com>
Signed-off-by: default avatarQuinn Tran <qutran@marvell.com>
Signed-off-by: default avatarHimanshu Madhani <hmadhani@marvell.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent f110f9ee
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment