aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEwan D. Milne <emilne@redhat.com>2016-10-26 11:22:53 -0400
committerSasha Levin <alexander.levin@verizon.com>2016-11-23 23:05:32 -0500
commit103432f0b54a920c211f9d6c013f9ef7e0366d20 (patch)
tree3209056f8edbbdbc006a240b8dcea33b5dc814d4
parentc0e76eccb785d480713918366e4f63b0d480a5bd (diff)
downloadlinux-linaro-stable-103432f0b54a920c211f9d6c013f9ef7e0366d20.tar.gz
scsi: scsi_debug: Fix memory leak if LBP enabled and module is unloaded
[ Upstream commit 4d2b496f19f3c2cfaca1e8fa0710688b5ff3811d ] map_storep was not being vfree()'d in the module_exit call. Cc: <stable@vger.kernel.org> Signed-off-by: Ewan D. Milne <emilne@redhat.com> Reviewed-by: Laurence Oberman <loberman@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
-rw-r--r--drivers/scsi/scsi_debug.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/scsi/scsi_debug.c b/drivers/scsi/scsi_debug.c
index 238e06f13b8a..dda3a32743b5 100644
--- a/drivers/scsi/scsi_debug.c
+++ b/drivers/scsi/scsi_debug.c
@@ -3998,6 +3998,7 @@ static void __exit scsi_debug_exit(void)
if (dif_storep)
vfree(dif_storep);
+ vfree(map_storep);
vfree(fake_storep);
}