Skip to content

Commit

Permalink
mptcp: print out port and ahmac when receiving ADD_ADDR
Browse files Browse the repository at this point in the history
This patch printed out more debugging information for the ADD_ADDR
suboption parsing on the incoming path.

Reviewed-by: Mat Martineau <[email protected]>
Signed-off-by: Geliang Tang <[email protected]>
  • Loading branch information
geliangtang authored and jenkins-tessares committed Dec 9, 2020
1 parent faec918 commit f561498
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions net/mptcp/options.c
Original file line number Diff line number Diff line change
Expand Up @@ -242,9 +242,6 @@ static void mptcp_parse_option(const struct sk_buff *skb,

mp_opt->add_addr = 1;
mp_opt->addr_id = *ptr++;
pr_debug("ADD_ADDR%s: id=%d, echo=%d",
(mp_opt->family == MPTCP_ADDR_IPVERSION_6) ? "6" : "",
mp_opt->addr_id, mp_opt->echo);
if (mp_opt->family == MPTCP_ADDR_IPVERSION_4) {
memcpy((u8 *)&mp_opt->addr.s_addr, (u8 *)ptr, 4);
ptr += 4;
Expand All @@ -269,6 +266,9 @@ static void mptcp_parse_option(const struct sk_buff *skb,
mp_opt->ahmac = get_unaligned_be64(ptr);
ptr += 8;
}
pr_debug("ADD_ADDR%s: id=%d, ahmac=%llu, echo=%d, port=%d",
(mp_opt->family == MPTCP_ADDR_IPVERSION_6) ? "6" : "",
mp_opt->addr_id, mp_opt->ahmac, mp_opt->echo, mp_opt->port);
break;

case MPTCPOPT_RM_ADDR:
Expand Down

0 comments on commit f561498

Please sign in to comment.