]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
s390/qeth: when thread completes, wake up all waiters
authorJulian Wiedmann <jwi@linux.vnet.ibm.com>
Tue, 20 Mar 2018 06:59:13 +0000 (07:59 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 22 Mar 2018 15:52:30 +0000 (11:52 -0400)
qeth_wait_for_threads() is potentially called by multiple users, make
sure to notify all of them after qeth_clear_thread_running_bit()
adjusted the thread_running_mask. With no timeout, callers would
otherwise stall.

Signed-off-by: Julian Wiedmann <jwi@linux.vnet.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/s390/net/qeth_core_main.c

index 4a820afececda2f0ef37e5d80559290bddca2162..42ee8806fa537f782b75c2a254281d12bf44bd0e 100644 (file)
@@ -960,7 +960,7 @@ void qeth_clear_thread_running_bit(struct qeth_card *card, unsigned long thread)
        spin_lock_irqsave(&card->thread_mask_lock, flags);
        card->thread_running_mask &= ~thread;
        spin_unlock_irqrestore(&card->thread_mask_lock, flags);
-       wake_up(&card->wait_q);
+       wake_up_all(&card->wait_q);
 }
 EXPORT_SYMBOL_GPL(qeth_clear_thread_running_bit);