Skip to contentSkip to conversation

be2iscsi: Fix for a possible sleep while holding lock V2

PATCH New Jayamohan Kallickal 1 participant 1 message Feb 20, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 3/7 be2iscsi: Fix for a possible sleep while holding lock V2

This patch fixes a situation where we could call udelay
while holding spin_lock

---
 drivers/scsi/be2iscsi/be_cmds.c |    7 -------
 1 files changed, 0 insertions(+), 7 deletions(-)
drivers/scsi/be2iscsi/be_cmds.c +0 -7
index 6709857..cda6642 100644
@@ -32,18 +32,11 @@ void be_mcc_notify(struct beiscsi_hba *phba)
 unsigned int alloc_mcc_tag(struct beiscsi_hba *phba)
 {
 	unsigned int tag = 0;
-	unsigned int num = 0;
 
-mcc_tag_rdy:
 	if (phba->ctrl.mcc_tag_available) {
 		tag = phba->ctrl.mcc_tag[phba->ctrl.mcc_alloc_index];
 		phba->ctrl.mcc_tag[phba->ctrl.mcc_alloc_index] = 0;
 		phba->ctrl.mcc_numtag[tag] = 0;
-	} else {
-		udelay(100);
-		num++;
-		if (num < mcc_timeout)
-			goto mcc_tag_rdy;
 	}
 	if (tag) {
 		phba->ctrl.mcc_tag_available--;
Signature · 1 line
1.6.4