IB/ehca: Fix mismatched spin_unlock in irq handler
authorHoang-Nam Nguyen <hnguyen@linux.vnet.ibm.com>
Fri, 19 Jan 2007 21:50:10 +0000 (22:50 +0100)
committerRoland Dreier <rolandd@cisco.com>
Tue, 23 Jan 2007 01:03:55 +0000 (17:03 -0800)
The lock is taken with _irqsave and hence must be released with
_irqrestore on all paths.

Signed-off-by Hoang-Nam Nguyen <hnguyen@de.ibm.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
drivers/infiniband/hw/ehca/ehca_irq.c

index e7209af..c069be8 100644 (file)
@@ -440,7 +440,8 @@ void ehca_tasklet_eq(unsigned long data)
                                        cq = idr_find(&ehca_cq_idr, token);
 
                                        if (cq == NULL) {
-                                               spin_unlock(&ehca_cq_idr_lock);
+                                               spin_unlock_irqrestore(&ehca_cq_idr_lock,
+                                                                      flags);
                                                break;
                                        }