mptcp: store remote id from MP_JOIN SYN/ACK in local ctx

Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2079368
Upstream Status: net-next.git commit 8a348392209f

commit 8a348392209ffdd70926253f014eec0c04dbf3e7
Author: Kishen Maloor <kishen.maloor@intel.com>
Date:   Mon May 2 13:52:33 2022 -0700

    mptcp: store remote id from MP_JOIN SYN/ACK in local ctx

    This change reads the addr id assigned to the remote endpoint
    of a subflow from the MP_JOIN SYN/ACK message and stores it
    in the related subflow context. The remote id was not being
    captured prior to this change, and will now provide a consistent
    view of remote endpoints and their ids as seen through netlink
    events.

    Acked-by: Paolo Abeni <pabeni@redhat.com>
    Signed-off-by: Kishen Maloor <kishen.maloor@intel.com>
    Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com>
    Signed-off-by: Jakub Kicinski <kuba@kernel.org>

Signed-off-by: Davide Caratti <dcaratti@redhat.com>
This commit is contained in:
Davide Caratti 2022-05-06 11:03:24 +02:00
parent 1075196418
commit 696ae7aa09
1 changed files with 1 additions and 0 deletions

View File

@ -443,6 +443,7 @@ static void subflow_finish_connect(struct sock *sk, const struct sk_buff *skb)
subflow->backup = mp_opt.backup;
subflow->thmac = mp_opt.thmac;
subflow->remote_nonce = mp_opt.nonce;
subflow->remote_id = mp_opt.join_id;
pr_debug("subflow=%p, thmac=%llu, remote_nonce=%u backup=%d",
subflow, subflow->thmac, subflow->remote_nonce,
subflow->backup);