public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Vladimir Oltean <olteanv@gmail.com>
To: Willem de Bruijn <willemdebruijn.kernel@gmail.com>
Cc: netdev@vger.kernel.org, Paolo Abeni <pabeni@redhat.com>,
	Jakub Kicinski <kuba@kernel.org>,
	"David S. Miller" <davem@davemloft.net>
Subject: Broken SOF_TIMESTAMPING_OPT_ID in linux-4.19.y and earlier stable branches
Date: Thu, 24 Mar 2022 23:39:54 +0200	[thread overview]
Message-ID: <20220324213954.3ln7kvl5utadnux6@skbuf> (raw)

Hello Willem,

I have an application which makes use of SOF_TIMESTAMPING_OPT_ID, and I
received reports from multiple users that all timestamps are delivered
with a tskey of 0 for all stable kernel branches earlier than, and
including, 4.19.

I bisected this issue down to:

| commit 8f932f762e7928d250e21006b00ff9b7718b0a64 (HEAD)
| Author: Willem de Bruijn <willemb@google.com>
| Date:   Mon Dec 17 12:24:00 2018 -0500
| 
|     net: add missing SOF_TIMESTAMPING_OPT_ID support
| 
|     SOF_TIMESTAMPING_OPT_ID is supported on TCP, UDP and RAW sockets.
|     But it was missing on RAW with IPPROTO_IP, PF_PACKET and CAN.
| 
|     Add skb_setup_tx_timestamp that configures both tx_flags and tskey
|     for these paths that do not need corking or use bytestream keys.
| 
|     Fixes: 09c2d251b707 ("net-timestamp: add key to disambiguate concurrent datagrams")
|     Signed-off-by: Willem de Bruijn <willemb@google.com>
|     Acked-by: Soheil Hassas Yeganeh <soheil@google.com>
|     Signed-off-by: David S. Miller <davem@davemloft.net>

and, interestingly, I found this discussion on the topic:
https://www.spinics.net/lists/netdev/msg540752.html
(copied here in case the link rots in the future)

| > Series applied.
| >
| > What is your opinion about -stable for this?
| 
| Thanks David. Since these are just missing features that no one has
| reported as actually having been missing a whole lot, I don't think
| that they are worth the effort or risk.

So I have 2 questions:

Is there a way for user space to validate functional kernel support for
SOF_TIMESTAMPING_OPT_ID? What I'm noticing is that (at least with
AF_PACKET sockets) the "level == SOL_PACKET && type == PACKET_TX_TIMESTAMP"
cmsg is _not_ missing, but instead contains a valid sock_err->ee_data
(tskey) of 0.

If it's not possible, could you please consider sending these fixes as
patches to linux-stable?

             reply	other threads:[~2022-03-24 21:40 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-24 21:39 Vladimir Oltean [this message]
2022-03-25 13:15 ` Broken SOF_TIMESTAMPING_OPT_ID in linux-4.19.y and earlier stable branches Willem de Bruijn
2022-03-25 13:37   ` Vladimir Oltean
2022-03-25 13:48     ` Willem de Bruijn
2022-03-25 14:05       ` Vladimir Oltean
2022-03-25 14:14         ` Willem de Bruijn

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=20220324213954.3ln7kvl5utadnux6@skbuf \
    --to=olteanv@gmail.com \
    --cc=davem@davemloft.net \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=willemdebruijn.kernel@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox