Message ID | 20220725205231.87529-1-mathew.j.martineau@linux.intel.com (mailing list archive) |
---|---|
State | Accepted |
Commit | b5177ed92bf6f9d90a2493ed51c1327e088be1df |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | [net] mptcp: Do not return EINPROGRESS when subflow creation succeeds | expand |
Hello: This patch was applied to netdev/net.git (master) by Jakub Kicinski <kuba@kernel.org>: On Mon, 25 Jul 2022 13:52:31 -0700 you wrote: > New subflows are created within the kernel using O_NONBLOCK, so > EINPROGRESS is the expected return value from kernel_connect(). > __mptcp_subflow_connect() has the correct logic to consider EINPROGRESS > to be a successful case, but it has also used that error code as its > return value. > > Before v5.19 this was benign: all the callers ignored the return > value. Starting in v5.19 there is a MPTCP_PM_CMD_SUBFLOW_CREATE generic > netlink command that does use the return value, so the EINPROGRESS gets > propagated to userspace. > > [...] Here is the summary with links: - [net] mptcp: Do not return EINPROGRESS when subflow creation succeeds https://git.kernel.org/netdev/net/c/b5177ed92bf6 You are awesome, thank you!
diff --git a/net/mptcp/subflow.c b/net/mptcp/subflow.c index 63e8892ec807..af28f3b60389 100644 --- a/net/mptcp/subflow.c +++ b/net/mptcp/subflow.c @@ -1533,7 +1533,7 @@ int __mptcp_subflow_connect(struct sock *sk, const struct mptcp_addr_info *loc, mptcp_sock_graft(ssk, sk->sk_socket); iput(SOCK_INODE(sf)); WRITE_ONCE(msk->allow_infinite_fallback, false); - return err; + return 0; failed_unlink: list_del(&subflow->node);