summaryrefslogtreecommitdiffstats
path: root/include/scsi
diff options
context:
space:
mode:
authorBart Van Assche <bart.vanassche@sandisk.com>2017-06-02 23:21:53 +0200
committerMartin K. Petersen <martin.petersen@oracle.com>2017-06-13 02:55:58 +0200
commit551eb598e5ea52996eb821f43740496a78a97b68 (patch)
treefe57f0a626a83e9e2d1d183168df1306c201e90c /include/scsi
parentscsi: Avoid that scsi_exit_rq() triggers a use-after-free (diff)
downloadlinux-551eb598e5ea52996eb821f43740496a78a97b68.tar.xz
linux-551eb598e5ea52996eb821f43740496a78a97b68.zip
scsi: Split scsi_internal_device_block()
Instead of passing a "wait" argument to scsi_internal_device_block(), split this function into a function that waits and a function that doesn't wait. This will make it easier to serialize SCSI device state changes through a mutex. Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Reviewed-by: Christoph Hellwig <hch@lst.de> Cc: Sreekanth Reddy <sreekanth.reddy@broadcom.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'include/scsi')
-rw-r--r--include/scsi/scsi_device.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/scsi/scsi_device.h b/include/scsi/scsi_device.h
index 05641aebd181..6ce6888f3c69 100644
--- a/include/scsi/scsi_device.h
+++ b/include/scsi/scsi_device.h
@@ -472,7 +472,7 @@ static inline int scsi_device_created(struct scsi_device *sdev)
sdev->sdev_state == SDEV_CREATED_BLOCK;
}
-int scsi_internal_device_block(struct scsi_device *sdev, bool wait);
+int scsi_internal_device_block_nowait(struct scsi_device *sdev);
int scsi_internal_device_unblock(struct scsi_device *sdev,
enum scsi_device_state new_state);