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 e7209afb4250c1bc7261513b897e606de53e4a12..c069be8cbcb291868b0419e8867e48d8b7acc6e2 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;
                                        }