[ofa-general] Re: having problems with the latest for-2.6.27 tree
Roland Dreier
rdreier at cisco.com
Wed Jul 9 12:21:54 PDT 2008
It looks like an existing bug that now bites harder after the conversion
to mutex... on the normal exit path, iw_conn_req_handler never did
cma_enable_remove(conn_id) and now doesn't unlock the mutex.
So I think the fix is:
diff --git a/drivers/infiniband/core/cma.c b/drivers/infiniband/core/cma.c
index ead2b33..ae11d5c 100644
--- a/drivers/infiniband/core/cma.c
+++ b/drivers/infiniband/core/cma.c
@@ -1342,8 +1342,11 @@ static int iw_conn_req_handler(struct iw_cm_id *cm_id,
cma_exch(conn_id, CMA_DESTROYING);
mutex_unlock(&conn_id->handler_mutex);
rdma_destroy_id(&conn_id->id);
+ goto out;
}
+ mutex_unlock(&conn_id->handler_mutex);
+
out:
if (dev)
dev_put(dev);
I've rolled this and the mutex_lock_nested() fixes into the patch in my
tree and pushed it out... will test rping shortly.
Would have been nice for the original author of a patch changing locking
to test with lockdep (IB needed the mutex_lock_nested treatment too),
but oh well.
- R.
More information about the general
mailing list