From: Christoph Hellwig Date: Tue, 15 Apr 2014 10:24:55 +0000 (+0200) Subject: [SCSI] don't reference freed command in scsi_init_sgtable X-Git-Tag: omap-for-v3.16/pm-signed~51^2~5 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5e012aad85f2ee31d7de5c21d63ccd2702d63db2;p=pandora-kernel.git [SCSI] don't reference freed command in scsi_init_sgtable Patch commit 0479633686d370303e3430256ace4bd5f7f138dc Author: Christoph Hellwig Date: Thu Feb 20 14:20:55 2014 -0800 [SCSI] do not manipulate device reference counts in scsi_get/put_command Introduced a use after free: when scsi_init_io fails we have to release our device reference, but we do this trying to reference the just freed command. Add a local scsi_device pointer to fix this. Fixes: 0479633686d370303e3430256ace4bd5f7f138dc Reported-by: Sander Eikelenboom Signed-off-by: Christoph Hellwig Signed-off-by: James Bottomley --- Reading git-diff-tree failed