|
@@ -1739,10 +1739,10 @@ static int push_scqe(ns_dev * card, vc_map * vc, scq_info * scq, ns_scqe * tbd,
|
|
|
}
|
|
|
|
|
|
scq->full = 1;
|
|
|
- spin_unlock_irqrestore(&scq->lock, flags);
|
|
|
- interruptible_sleep_on_timeout(&scq->scqfull_waitq,
|
|
|
- SCQFULL_TIMEOUT);
|
|
|
- spin_lock_irqsave(&scq->lock, flags);
|
|
|
+ wait_event_interruptible_lock_irq_timeout(scq->scqfull_waitq,
|
|
|
+ scq->tail != scq->next,
|
|
|
+ scq->lock,
|
|
|
+ SCQFULL_TIMEOUT);
|
|
|
|
|
|
if (scq->full) {
|
|
|
spin_unlock_irqrestore(&scq->lock, flags);
|
|
@@ -1789,10 +1789,10 @@ static int push_scqe(ns_dev * card, vc_map * vc, scq_info * scq, ns_scqe * tbd,
|
|
|
scq->full = 1;
|
|
|
if (has_run++)
|
|
|
break;
|
|
|
- spin_unlock_irqrestore(&scq->lock, flags);
|
|
|
- interruptible_sleep_on_timeout(&scq->scqfull_waitq,
|
|
|
- SCQFULL_TIMEOUT);
|
|
|
- spin_lock_irqsave(&scq->lock, flags);
|
|
|
+ wait_event_interruptible_lock_irq_timeout(scq->scqfull_waitq,
|
|
|
+ scq->tail != scq->next,
|
|
|
+ scq->lock,
|
|
|
+ SCQFULL_TIMEOUT);
|
|
|
}
|
|
|
|
|
|
if (!scq->full) {
|