Message ID | 20220429173629.621418-4-trondmy@kernel.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [v2,1/4] SUNRPC: Don't leak sockets in xs_local_connect() | expand |
On Fri, 2022-04-29 at 13:36 -0400, trondmy@kernel.org wrote: > From: Trond Myklebust <trond.myklebust@hammerspace.com> > > This reverts commit 7073ea8799a8cf73db60270986f14e4aae20fa80. > > We must not try to connect the socket while the transport is under > construction, because the mechanisms to safely tear it down are not > in > place. > > Cc: stable@vger.kernel.org > Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com> Sorry. I intended to add a "Reported-by: wanghai (M) <wanghai38@huawei.com>" That has been added to the version in my "testing" branch.
在 2022/4/30 8:56, Trond Myklebust 写道: > On Fri, 2022-04-29 at 13:36 -0400, trondmy@kernel.org wrote: >> From: Trond Myklebust <trond.myklebust@hammerspace.com> >> >> This reverts commit 7073ea8799a8cf73db60270986f14e4aae20fa80. >> >> We must not try to connect the socket while the transport is under >> construction, because the mechanisms to safely tear it down are not >> in >> place. >> >> Cc: stable@vger.kernel.org >> Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com> > Sorry. I intended to add a > > "Reported-by: wanghai (M) <wanghai38@huawei.com>" > > That has been added to the version in my "testing" branch. > Thanks for your help, I tested it carefully and this patchset can solve my problem. By the way, when can this patchset be applied to linux mainline?
在 2022/4/30 8:56, Trond Myklebust 写道: > On Fri, 2022-04-29 at 13:36 -0400, trondmy@kernel.org wrote: >> From: Trond Myklebust <trond.myklebust@hammerspace.com> >> >> This reverts commit 7073ea8799a8cf73db60270986f14e4aae20fa80. >> >> We must not try to connect the socket while the transport is under >> construction, because the mechanisms to safely tear it down are not >> in >> place. >> >> Cc: stable@vger.kernel.org >> Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com> > Sorry. I intended to add a > > "Reported-by: wanghai (M) <wanghai38@huawei.com>" > > That has been added to the version in my "testing" branch. > Hi, Trond. If it is just to fix my problem, is it enough to apply only patch3 and patch4? I tested that if only patch3 and patch4 are applied, the problem seems to be fixed.
diff --git a/net/sunrpc/xprtsock.c b/net/sunrpc/xprtsock.c index 25b8a8ead56b..650102a9c86a 100644 --- a/net/sunrpc/xprtsock.c +++ b/net/sunrpc/xprtsock.c @@ -2875,9 +2875,6 @@ static struct rpc_xprt *xs_setup_local(struct xprt_create *args) } xprt_set_bound(xprt); xs_format_peer_addresses(xprt, "local", RPCBIND_NETID_LOCAL); - ret = ERR_PTR(xs_local_setup_socket(transport)); - if (ret) - goto out_err; break; default: ret = ERR_PTR(-EAFNOSUPPORT);