From: Florian Westphal <fw at strlen.de>
To: mptcp at lists.01.org
Subject: [MPTCP] Re: [PATCH 9/9] don't flag parent socket as RCV_SHUTDOWN if one one subflow has closed
Date: Mon, 02 Dec 2019 19:00:54 +0100 [thread overview]
Message-ID: <20191202180054.GR795@breakpoint.cc> (raw)
In-Reply-To: 9fecd7952e5f37bf025d368143f15f1cb69964c5.camel@redhat.com
[-- Attachment #1: Type: text/plain, Size: 1268 bytes --]
Paolo Abeni <pabeni(a)redhat.com> wrote:
> On Sat, 2019-11-30 at 23:49 +0100, Florian Westphal wrote:
> > @@ -642,7 +647,7 @@ bool mptcp_subflow_data_available(struct sock *sk)
> > /* set EoF only there is no data available - we already spooled
> > * all the pending skbs
> > */
> > - if (sk->sk_shutdown & RCV_SHUTDOWN || sk->sk_state == TCP_CLOSE)
> > + if (subflow_is_done(sk))
> > subflow->rx_eof = 1;
> > return false;
> > }
> > @@ -666,13 +671,15 @@ static void subflow_data_ready(struct sock *sk)
> > return;
> > }
> >
> > - /* always propagate the EoF */
> > - if (mptcp_subflow_data_available(sk) || subflow->rx_eof) {
> > + if (mptcp_subflow_data_available(sk)) {
> > smp_mb__before_atomic();
> > set_bit(MPTCP_DATA_READY, &mptcp_sk(parent)->flags);
> > smp_mb__after_atomic();
> >
> > parent->sk_data_ready(parent);
> > + } else if (subflow->rx_eof) {
> > + /* tell parent to (re-)check eof on all subflows */
> > + mptcp_subflow_eof(parent);
> > }
> > }
> >
>
> With subflow_state_change() in place, do we still need the above
> chunks?!? e.g. why is not subflow_state_change() enough to catch the
> subflow eof condition?
Right, it might be possible to drop that indeed.
next reply other threads:[~2019-12-02 18:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-02 18:00 Florian Westphal [this message]
-- strict thread matches above, loose matches on Subject: below --
2019-12-02 12:43 [MPTCP] Re: [PATCH 9/9] don't flag parent socket as RCV_SHUTDOWN if one one subflow has closed Paolo Abeni
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=20191202180054.GR795@breakpoint.cc \
--to=unknown@example.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.