netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [Patch net] tipc: fix a missing rhashtable_walk_exit()
@ 2018-08-23 23:19 Cong Wang
  2018-08-30  0:59 ` David Miller
  2018-09-04  9:13 ` Ying Xue
  0 siblings, 2 replies; 3+ messages in thread
From: Cong Wang @ 2018-08-23 23:19 UTC (permalink / raw)
  To: netdev; +Cc: Cong Wang, Herbert Xu, Ying Xue

rhashtable_walk_exit() must be paired with rhashtable_walk_enter().

Fixes: 40f9f4397060 ("tipc: Fix tipc_sk_reinit race conditions")
Cc: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Ying Xue <ying.xue@windriver.com>
Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com>
---
 net/tipc/socket.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/net/tipc/socket.c b/net/tipc/socket.c
index c1e93c9515bc..c9a50b62c738 100644
--- a/net/tipc/socket.c
+++ b/net/tipc/socket.c
@@ -2672,6 +2672,8 @@ void tipc_sk_reinit(struct net *net)
 
 		rhashtable_walk_stop(&iter);
 	} while (tsk == ERR_PTR(-EAGAIN));
+
+	rhashtable_walk_exit(&iter);
 }
 
 static struct tipc_sock *tipc_sk_lookup(struct net *net, u32 portid)
-- 
2.14.4

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-09-04 13:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-08-23 23:19 [Patch net] tipc: fix a missing rhashtable_walk_exit() Cong Wang
2018-08-30  0:59 ` David Miller
2018-09-04  9:13 ` Ying Xue

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).