IB/ehca: Fix improper use of yield() with spinlock held

Signed-off-by: Hoang-Nam Nguyen <hnguyen@de.ibm.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>

authored by Hoang-Nam Nguyen and committed by Roland Dreier ce29d72c a20f3a6d

+4 -1
+4 -1
drivers/infiniband/hw/ehca/ehca_cq.c
··· 344 unsigned long flags; 345 346 spin_lock_irqsave(&ehca_cq_idr_lock, flags); 347 - while (my_cq->nr_callbacks) 348 yield(); 349 350 idr_remove(&ehca_cq_idr, my_cq->token); 351 spin_unlock_irqrestore(&ehca_cq_idr_lock, flags);
··· 344 unsigned long flags; 345 346 spin_lock_irqsave(&ehca_cq_idr_lock, flags); 347 + while (my_cq->nr_callbacks) { 348 + spin_unlock_irqrestore(&ehca_cq_idr_lock, flags); 349 yield(); 350 + spin_lock_irqsave(&ehca_cq_idr_lock, flags); 351 + } 352 353 idr_remove(&ehca_cq_idr, my_cq->token); 354 spin_unlock_irqrestore(&ehca_cq_idr_lock, flags);