summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthieu Baerts <matthieu.baerts@tessares.net>2023-01-25 11:47:22 +0100
committerPaolo Abeni <pabeni@redhat.com>2023-01-26 13:33:30 +0100
commit7e9740e0e84e21281759590ccec4e3c926eb54bf (patch)
treeeaef070f0bcfe41096c1120d00716a8865653ed5
parentb9d69db87fb77fc80997993d40f091b323b3651e (diff)
mptcp: propagate sk_ipv6only to subflows
Usually, attributes are propagated to subflows as well. Here, if subflows are created by other ways than the MPTCP path-manager, it is important to make sure they are in v6 if it is asked by the userspace. Reviewed-by: Mat Martineau <mathew.j.martineau@linux.intel.com> Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net> Signed-off-by: Paolo Abeni <pabeni@redhat.com>
-rw-r--r--net/mptcp/sockopt.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/mptcp/sockopt.c b/net/mptcp/sockopt.c
index 582ed93bcc8a..9986681aaf40 100644
--- a/net/mptcp/sockopt.c
+++ b/net/mptcp/sockopt.c
@@ -1255,6 +1255,7 @@ static void sync_socket_options(struct mptcp_sock *msk, struct sock *ssk)
ssk->sk_priority = sk->sk_priority;
ssk->sk_bound_dev_if = sk->sk_bound_dev_if;
ssk->sk_incoming_cpu = sk->sk_incoming_cpu;
+ ssk->sk_ipv6only = sk->sk_ipv6only;
__ip_sock_set_tos(ssk, inet_sk(sk)->tos);
if (sk->sk_userlocks & tx_rx_locks) {