All of lore.kernel.org
 help / color / mirror / Atom feed
From: Florian Westphal <fw@strlen.de>
To: Paolo Abeni <pabeni@redhat.com>
Cc: Florian Westphal <fw@strlen.de>, mptcp@lists.linux.dev
Subject: Re: [PATCH mptcp-next 3/3] mptcp: add SIOCINQ, OUTQ and OUTQNSD ioctls
Date: Wed, 10 Nov 2021 09:53:13 +0100	[thread overview]
Message-ID: <20211110085313.GD16363@breakpoint.cc> (raw)
In-Reply-To: <b467d2f950e6dd6c3f8e6c745b4c9a884625c77f.camel@redhat.com>

Paolo Abeni <pabeni@redhat.com> wrote:
> > +	if (sk->sk_state == TCP_LISTEN)
> > +		return -EINVAL;
> > +
> > +	if ((1 << sk->sk_state) & (TCPF_SYN_SENT | TCPF_SYN_RECV))
> > +		return 0;
> > +
> > +	delta = READ_ONCE(msk->write_seq) - v;
> 
> This is under the msk socket lock and write_seq is protected by the
> full/plain msk socket lock so READ_ONCE should not be necessary, I
> think. The same for 'snd_nxt' below. 

Then why is write_seq updated with WRITE_ONCE in lots of places?

  reply	other threads:[~2021-11-10  8:53 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-08 10:57 [PATCH mptcp-next 0/3] support for setsockopt(TCP_INQ) Florian Westphal
2021-11-08 10:57 ` [PATCH mptcp-next 1/3] mptcp: add TCP_INQ cmsg support Florian Westphal
2021-11-10  1:11   ` Mat Martineau
2021-11-10 10:17     ` Florian Westphal
2021-11-10 19:13       ` Mat Martineau
2021-11-10 19:35         ` Mat Martineau
2021-11-10 23:09           ` Florian Westphal
2021-11-11  0:05             ` Mat Martineau
2021-11-11 10:48       ` Paolo Abeni
2021-11-08 10:57 ` [PATCH mptcp-next 2/3] selftests: mptcp: add TCP_INQ support Florian Westphal
2021-11-10  1:18   ` Mat Martineau
2021-11-10 10:18     ` Florian Westphal
2021-11-08 10:57 ` [PATCH mptcp-next 3/3] mptcp: add SIOCINQ, OUTQ and OUTQNSD ioctls Florian Westphal
2021-11-08 17:08   ` Matthieu Baerts
2021-11-10  8:48   ` Paolo Abeni
2021-11-10  8:53     ` Florian Westphal [this message]
     [not found] <7bfe33f96550ffd6efaa3266f6027a8d7c500b70.camel@redhat.com>
2021-11-10 11:02 ` Paolo Abeni
2021-11-10 11:37   ` Florian Westphal
2021-11-10 11:45     ` Paolo Abeni
2021-11-10 11:49       ` Florian Westphal

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=20211110085313.GD16363@breakpoint.cc \
    --to=fw@strlen.de \
    --cc=mptcp@lists.linux.dev \
    --cc=pabeni@redhat.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.