aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/scsi/aacraid/commsup.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/scsi/aacraid/commsup.c b/drivers/scsi/aacraid/commsup.c
index 5156e057d062..23a8e9f8dcb4 100644
--- a/drivers/scsi/aacraid/commsup.c
+++ b/drivers/scsi/aacraid/commsup.c
@@ -515,10 +515,12 @@ int aac_fib_send(u16 command, struct fib *fibptr, unsigned long size,
515 } 515 }
516 udelay(5); 516 udelay(5);
517 } 517 }
518 } else 518 } else if (down_interruptible(&fibptr->event_wait) == 0) {
519 (void)down_interruptible(&fibptr->event_wait); 519 fibptr->done = 2;
520 up(&fibptr->event_wait);
521 }
520 spin_lock_irqsave(&fibptr->event_lock, flags); 522 spin_lock_irqsave(&fibptr->event_lock, flags);
521 if (fibptr->done == 0) { 523 if ((fibptr->done == 0) || (fibptr->done == 2)) {
522 fibptr->done = 2; /* Tell interrupt we aborted */ 524 fibptr->done = 2; /* Tell interrupt we aborted */
523 spin_unlock_irqrestore(&fibptr->event_lock, flags); 525 spin_unlock_irqrestore(&fibptr->event_lock, flags);
524 return -EINTR; 526 return -EINTR;