The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Matthieu Baerts <matttbe@kernel.org>
To: Eric Dumazet <edumazet@google.com>
Cc: Mat Martineau <martineau@kernel.org>,
	Geliang Tang <geliang@kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Simon Horman <horms@kernel.org>,
	netdev@vger.kernel.org, mptcp@lists.linux.dev,
	linux-kernel@vger.kernel.org, Gang Yan <yangang@kylinos.cn>
Subject: Re: [PATCH net-next v3 7/7] mptcp: implemented OoO queue pruning
Date: Wed, 12 Aug 2026 16:47:11 +0200	[thread overview]
Message-ID: <dc89cede-57ef-448e-96f8-e8251d9007ec@kernel.org> (raw)
In-Reply-To: <CANn89iL-rnJtxVxJEf3j0PX3X8A04vsf-XXQvb-_FyjMBBM5nw@mail.gmail.com>

Hi Eric,

On 12/08/2026 13:39, Eric Dumazet wrote:
> On Fri, Aug 7, 2026 at 3:50 PM Matthieu Baerts (NGI0)
> <matttbe@kernel.org> wrote:
>>
>> From: Paolo Abeni <pabeni@redhat.com>
>>
>> When moving incoming skbs in the msk receive queue and the latter
>> is above limits, prune it as needed quite alike what TCP is doing
>> at the subflow level. The main difference relies in the stop condition:
>> since MPTCP does not perform collapsing, it's better off dropping the
>> bare minimum to fit the (newer) incoming packet.
>>
>> Signed-off-by: Paolo Abeni <pabeni@redhat.com>
>> Tested-by: Gang Yan <yangang@kylinos.cn>
>> Reviewed-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
>> Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
>> ---
>> v2:
>>  - Uniform the new counter with the other OFO ones.
>> v3:
>>  - prune only for new data
>>  - reorganize the code to follow more closely TCP
>> ---
> 
> ...
> 
>> +
>> +/* The stack can't drop packets for fallback socket at the msk level, or the
>> + * stream will break.
>> + */
>> +static bool mptcp_can_ingest(const struct sock *sk)
>> +{
>> +       return unlikely(sk_rmem_alloc_get(sk) <= READ_ONCE(sk->sk_rcvbuf)) ||
>> +                       __mptcp_check_fallback(mptcp_sk(sk));
>> +}
>> +
> 
> This unlikely() seems inverted.

Thank you, yes it is!

Paolo already told me that before I sent the v3, but it looks like I was
in an OoM state, and the pruning was a bit too aggressive on my side...

A follow-up patch will be sent soon.

Cheers,
Matt
-- 
Sponsored by the NGI0 Core fund.


  reply	other threads:[~2026-08-12 14:47 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-07 13:49 [PATCH net-next v3 0/7] mptcp: out-of-order queue pruning Matthieu Baerts (NGI0)
2026-08-07 13:49 ` [PATCH net-next v3 1/7] mptcp: move the retrans loop to a separate helper Matthieu Baerts (NGI0)
2026-08-07 13:49 ` [PATCH net-next v3 2/7] mptcp: move the stale logic out of retrans scheduler Matthieu Baerts (NGI0)
2026-08-07 13:49 ` [PATCH net-next v3 3/7] mptcp: let the retrans scheduler do its job Matthieu Baerts (NGI0)
2026-08-07 13:49 ` [PATCH net-next v3 4/7] mptcp: explicitly drop over memory limits Matthieu Baerts (NGI0)
2026-08-07 13:49 ` [PATCH net-next v3 5/7] mptcp: enforce hard limit on backlog flushing Matthieu Baerts (NGI0)
2026-08-07 13:49 ` [PATCH net-next v3 6/7] mptcp: avoid code duplication in __mptcp_move_skb() Matthieu Baerts (NGI0)
2026-08-07 13:49 ` [PATCH net-next v3 7/7] mptcp: implemented OoO queue pruning Matthieu Baerts (NGI0)
2026-08-12 11:39   ` Eric Dumazet
2026-08-12 14:47     ` Matthieu Baerts [this message]
2026-08-10  9:53 ` [PATCH net-next v3 0/7] mptcp: out-of-order " Paolo Abeni
2026-08-10 10:57   ` Matthieu Baerts
2026-08-12  1:40 ` patchwork-bot+netdevbpf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=dc89cede-57ef-448e-96f8-e8251d9007ec@kernel.org \
    --to=matttbe@kernel.org \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=geliang@kernel.org \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=martineau@kernel.org \
    --cc=mptcp@lists.linux.dev \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=yangang@kylinos.cn \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox