[ofa-general] [PATCH] ipoib: fix hang in ipoib_flush_paths

Yossi Etigin yosefe at Voltaire.COM
Fri Oct 31 05:55:28 PDT 2008


Fixes a hang in ipoib_flush_paths during sm up/down loop.
Even if path_rec_start() fails (for instance, because there is no sm_ah),
the path is added to the path list by neigh_add_path().
Then, ipoib_flush_paths() will wait for path->done, but it will never
complete because the request was not issued at all.

Signed-off-by: Yossi Etigin <yosefe at voltaire.com>

--

Fixes bugzilla 1329.

Index: b/drivers/infiniband/ulp/ipoib/ipoib_main.c
===================================================================
--- a/drivers/infiniband/ulp/ipoib/ipoib_main.c	2008-10-31 14:15:03.000000000 +0200
+++ b/drivers/infiniband/ulp/ipoib/ipoib_main.c	2008-10-31 14:42:22.000000000 +0200
@@ -523,6 +523,7 @@ static int path_rec_start(struct net_dev
 	if (path->query_id < 0) {
 		ipoib_warn(priv, "ib_sa_path_rec_get failed: %d\n", path->query_id);
 		path->query = NULL;
+		complete(&path->done);
 		return path->query_id;
 	}
 

-- 
--Yossi



More information about the general mailing list