From: Cong Wang Date: Thu, 23 Aug 2018 23:19:44 +0000 (-0700) Subject: tipc: fix a missing rhashtable_walk_exit() X-Git-Tag: v4.18.8~181 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=36b59c8e48e44b34c0929c8de269b186f3b2dadc;p=thirdparty%2Fkernel%2Fstable.git tipc: fix a missing rhashtable_walk_exit() [ Upstream commit bd583fe30427500a2d0abe25724025b1cb5e2636 ] rhashtable_walk_exit() must be paired with rhashtable_walk_enter(). Fixes: 40f9f4397060 ("tipc: Fix tipc_sk_reinit race conditions") Cc: Herbert Xu Cc: Ying Xue Signed-off-by: Cong Wang Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- diff --git a/net/tipc/socket.c b/net/tipc/socket.c index 930852c54d7a6..0a5fa347135e6 100644 --- a/net/tipc/socket.c +++ b/net/tipc/socket.c @@ -2675,6 +2675,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)