mirror of
https://github.com/SCST-project/scst.git
synced 2026-08-21 22:56:32 +00:00
scst_vdisk, vdev_sysfs_process_get_filename(): Make sure that dev->dev_unregistering is reread from memory in each loop iteration. Note: the now removed "(volatile bool)" cast did not have any effect.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3894 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
@@ -4432,7 +4432,8 @@ static int vdev_sysfs_process_get_filename(struct scst_sysfs_work_item *work)
|
||||
* under scst_vdisk_mutex.
|
||||
*/
|
||||
while (!mutex_trylock(&scst_vdisk_mutex)) {
|
||||
if ((volatile bool)(dev->dev_unregistering)) {
|
||||
smp_mb();
|
||||
if (dev->dev_unregistering) {
|
||||
TRACE_MGMT_DBG("Skipping being unregistered dev %s",
|
||||
dev->virt_name);
|
||||
res = -ENOENT;
|
||||
|
||||
Reference in New Issue
Block a user