Skip to content

Commit

Permalink
mptcp: use mptcp_get_ext helper
Browse files Browse the repository at this point in the history
Use mptcp_get_ext() helper defined in protocol.h instead of open-coding
it in mptcp_sendmsg_frag().

Reviewed-by: Matthieu Baerts <[email protected]>
Signed-off-by: Geliang Tang <[email protected]>
Signed-off-by: Mat Martineau <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
  • Loading branch information
geliangtang authored and kuba-moo committed Oct 27, 2023
1 parent 83d580d commit a16c054
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions net/mptcp/protocol.c
Original file line number Diff line number Diff line change
Expand Up @@ -1267,7 +1267,7 @@ static int mptcp_sendmsg_frag(struct sock *sk, struct sock *ssk,
* queue management operation, to avoid breaking the ext <->
* SSN association set here
*/
mpext = skb_ext_find(skb, SKB_EXT_MPTCP);
mpext = mptcp_get_ext(skb);
if (!mptcp_skb_can_collapse_to(data_seq, skb, mpext)) {
TCP_SKB_CB(skb)->eor = 1;
goto alloc_skb;
Expand All @@ -1289,7 +1289,7 @@ static int mptcp_sendmsg_frag(struct sock *sk, struct sock *ssk,

i = skb_shinfo(skb)->nr_frags;
reuse_skb = false;
mpext = skb_ext_find(skb, SKB_EXT_MPTCP);
mpext = mptcp_get_ext(skb);
}

/* Zero window and all data acked? Probe. */
Expand Down

0 comments on commit a16c054

Please sign in to comment.