aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/scsi_sysfs.c
diff options
context:
space:
mode:
authorJames Bottomley <JBottomley@Parallels.com>2014-01-21 07:01:41 -0800
committerJames Bottomley <JBottomley@Parallels.com>2014-03-15 10:18:59 -0700
commitf2495e228fce9f9cec84367547813cbb0d6db15a (patch)
treee9d1e5de350659994f7b420571deb7fed9200198 /drivers/scsi/scsi_sysfs.c
parent[SCSI] fix our current target reap infrastructure (diff)
downloadlinux-dev-f2495e228fce9f9cec84367547813cbb0d6db15a.tar.xz
linux-dev-f2495e228fce9f9cec84367547813cbb0d6db15a.zip
[SCSI] dual scan thread bug fix
In the highly unusual case where two threads are running concurrently through the scanning code scanning the same target, we run into the situation where one may allocate the target while the other is still using it. In this case, because the reap checks for STARGET_CREATED and kills the target without reference counting, the second thread will do the wrong thing on reap. Fix this by reference counting even creates and doing the STARGET_CREATED check in the final put. Tested-by: Sarah Sharp <sarah.a.sharp@linux.intel.com> Cc: stable@vger.kernel.org # delay backport for 2 months for field testing Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/scsi_sysfs.c')
0 files changed, 0 insertions, 0 deletions