netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Willem de Bruijn <willemdebruijn.kernel@gmail.com>
To: Richard Sanger <rsanger@wand.net.nz>
Cc: Network Development <netdev@vger.kernel.org>,
	Daniel Borkmann <daniel@iogearbox.net>
Subject: Re: [PATCH] net: packetmmap: fix only tx timestamp on request
Date: Mon, 3 May 2021 20:36:31 -0400	[thread overview]
Message-ID: <CA+FuTSeDTYMZzT3n3tfm9KPCRx_ObWU-HaU4JxZCSCm_8sf2XA@mail.gmail.com> (raw)
In-Reply-To: <1620085579-5646-1-git-send-email-rsanger@wand.net.nz>

On Mon, May 3, 2021 at 8:04 PM Richard Sanger <rsanger@wand.net.nz> wrote:
>
> The packetmmap tx ring should only return timestamps if requested,
> as documented. This allows compatibility with non-timestamp aware
> user-space code which checks tp_status == TP_STATUS_AVAILABLE;
> not expecting additional timestamp flags to be set.

This is an established interface.

Passing the status goes back to 2013, since commit b9c32fb27170
("packet: if hw/sw ts enabled in rx/tx ring, report which ts we got").

Passing a timestamp itself in tp_sec/tp_usec goes back to before git,
probably to the introduction of the ring.

I don't think we can change this now. That will likely break
applications that have come to expect current behavior.

Is it documented somewhere that the ring works differently? Or are you
referring to the general SO_TIMESTAMPING behavior, which is a separate
timestamp interface.

  reply	other threads:[~2021-05-04  0:37 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-03 23:46 [PATCH] net: packetmmap: fix only tx timestamp on request Richard Sanger
2021-05-04  0:36 ` Willem de Bruijn [this message]
2021-05-04  1:22   ` Richard Sanger
2021-05-04 14:45     ` Willem de Bruijn
2021-05-05  4:29       ` Richard Sanger
2021-05-05  5:09         ` Richard Sanger
2021-05-06  1:23         ` Willem de Bruijn
2021-05-11 22:11           ` Richard Sanger
2021-05-11 22:56             ` 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=CA+FuTSeDTYMZzT3n3tfm9KPCRx_ObWU-HaU4JxZCSCm_8sf2XA@mail.gmail.com \
    --to=willemdebruijn.kernel@gmail.com \
    --cc=daniel@iogearbox.net \
    --cc=netdev@vger.kernel.org \
    --cc=rsanger@wand.net.nz \
    /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;
as well as URLs for NNTP newsgroup(s).