summaryrefslogtreecommitdiff
path: root/drivers/target/target_core_device.c
diff options
context:
space:
mode:
authorNicholas Bellinger <nab@linux-iscsi.org>2015-06-23 09:44:05 +0300
committerNicholas Bellinger <nab@linux-iscsi.org>2015-06-23 09:54:10 +0300
commit1adff1b3a7f75a1c255b7fcab5676edf29d4a5d8 (patch)
tree7fe5b62dba64a17e68dfd50b2e2745a2751811ff /drivers/target/target_core_device.c
parentc51c8e7bcac966f209da83630fc8ca7e6cad279b (diff)
downloadlinux-1adff1b3a7f75a1c255b7fcab5676edf29d4a5d8.tar.xz
target: Convert se_lun->lun_deve_lock to normal spinlock
This patch converts se_lun->lun_deve_lock acquire/release access to use a normal, non bottom-half spin_lock_t for protecting se_lun->lun_deve_list access. Reported-by: Christoph Hellwig <hch@lst.de> Cc: Hannes Reinecke <hare@suse.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Diffstat (limited to 'drivers/target/target_core_device.c')
-rw-r--r--drivers/target/target_core_device.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/target/target_core_device.c b/drivers/target/target_core_device.c
index ed084023e7d4..b6df5b9a6890 100644
--- a/drivers/target/target_core_device.c
+++ b/drivers/target/target_core_device.c
@@ -352,10 +352,10 @@ int core_enable_device_list_for_node(
hlist_add_head_rcu(&new->link, &nacl->lun_entry_hlist);
mutex_unlock(&nacl->lun_entry_mutex);
- spin_lock_bh(&lun->lun_deve_lock);
+ spin_lock(&lun->lun_deve_lock);
list_del(&orig->lun_link);
list_add_tail(&new->lun_link, &lun->lun_deve_list);
- spin_unlock_bh(&lun->lun_deve_lock);
+ spin_unlock(&lun->lun_deve_lock);
kref_put(&orig->pr_kref, target_pr_kref_release);
wait_for_completion(&orig->pr_comp);
@@ -369,9 +369,9 @@ int core_enable_device_list_for_node(
hlist_add_head_rcu(&new->link, &nacl->lun_entry_hlist);
mutex_unlock(&nacl->lun_entry_mutex);
- spin_lock_bh(&lun->lun_deve_lock);
+ spin_lock(&lun->lun_deve_lock);
list_add_tail(&new->lun_link, &lun->lun_deve_list);
- spin_unlock_bh(&lun->lun_deve_lock);
+ spin_unlock(&lun->lun_deve_lock);
return 0;
}
@@ -403,9 +403,9 @@ void core_disable_device_list_for_node(
* NodeACL context specific PR metadata for demo-mode
* MappedLUN *deve will be released below..
*/
- spin_lock_bh(&lun->lun_deve_lock);
+ spin_lock(&lun->lun_deve_lock);
list_del(&orig->lun_link);
- spin_unlock_bh(&lun->lun_deve_lock);
+ spin_unlock(&lun->lun_deve_lock);
/*
* Disable struct se_dev_entry LUN ACL mapping
*/