netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next v4 0/5] net-timestamp: additional sw tstamps and
@ 2014-07-30 15:48 Willem de Bruijn
  2014-07-30 15:48 ` [PATCH net-next v4 1/5] net-timestamp: extend SCM_TIMESTAMPING ancillary data struct Willem de Bruijn
                   ` (5 more replies)
  0 siblings, 6 replies; 13+ messages in thread
From: Willem de Bruijn @ 2014-07-30 15:48 UTC (permalink / raw)
  To: netdev; +Cc: davem, eric.dumazet, richardcochran, Willem de Bruijn

Extend socket tx timestamping:
- allow multiple types of software timestamps aside from send (1)
- add software timestamp on tc enqueue (3)
- add software timestamp for TCP (4)
- add software timestamp for TCP on ACK (5)

The sk_flags option space is nearly exhausted. Also move the
many timestamp options to a new sk->sk_tstamps (2).

The patchset extends Linux tx timestamping to monitoring of latency
incurred within the kernel stack and to protocols embedded in TCP.
Complex kernel setups may have multiple layers of queueing, including
multiple instances of traffic shaping, and many classes per layer.
Many applications embed discrete payloads into TCP bytestreams for
reliability, flow control, etcetera. Detecting application tail
latency in such scenarios relies on identifying the exact queue
responsible if on the host, or the network latency if otherwise.

Changelog:
v3->v4
  - (v3 review comment) removed skb->mark packet identification (*A)
  - (v3 review comment) fixed indentation
  - tcp: fixed poll() to return POLLERR on non-zero queue
  - rebased to work without syststamp
  - comments: removed all traces of MSG_TSTAMP_.. (*B)

v2->v3
  - extend the SO_TIMESTAMPING API, instead of defining a new one.
  - add protocol independent support to correlate tstamps with data,
    based on returning skb->mark.
  - removed no-payload optimization and documentation (for now):

    I have a follow-on patch that reintroduces MSG_TSTAMP along with a
    new socket option SOF_TIMESTAMPING_OPT_ONFLAG. This is equivalent
    to sequence setsockopt(<enable>); send(..); setsockopt(<disable>),
    but avoids the need to define a MSG_TSTAMP_<TYPE> for each type.

    I will leave these three patches as follow-on, as this patchset is
    large enough as is.

v1->2
  - expand timestamping (existing and new) to SOCK_RAW and ping sockets
  - rename sock_errqueue_timestamping to scm_timestamping
  - change timestamp data format: do not add fields to scm_timestamping.
      Doing so could break legacy applications. Instead, communicate
      through an existing, but unused, field in the error message.
  - rename SOF_.._OPT_TX_NO_PAYLOAD to shorter SOF_.._OPT_TSONLY
  - move msg_tstamp test app out of patchset and to github
      git://github.com/wdebruij/kerneltools.git

v4 comments:

A: unique correlation of payload and timestamp when multiple payloads
   are in flight requires more extensive changes if we do not use
   skb->mark. That is better left to a follow-up patch.
B: similarly, I intend to submit the MSG_TSTAMP short-hand for
   setsockopt(<enable>); send; setsockopt(<disable>); as follow-up
   for review.

-- 
2.0.0.526.g5318336

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2014-08-01 13:45 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-30 15:48 [PATCH net-next v4 0/5] net-timestamp: additional sw tstamps and Willem de Bruijn
2014-07-30 15:48 ` [PATCH net-next v4 1/5] net-timestamp: extend SCM_TIMESTAMPING ancillary data struct Willem de Bruijn
2014-07-31 20:37   ` David Miller
2014-07-30 15:48 ` [PATCH net-next v4 2/5] net-timestamp: move timestamp flags out of sk_flags Willem de Bruijn
2014-07-30 15:48 ` [PATCH net-next v4 3/5] net-timestamp: ENQ timestamp on enqueue to traffic shaping layer Willem de Bruijn
2014-07-31 20:38   ` David Miller
2014-07-30 15:48 ` [PATCH net-next v4 4/5] net-timestamp: TCP timestamping Willem de Bruijn
2014-07-31 20:41   ` David Miller
2014-07-30 15:48 ` [PATCH net-next v4 5/5] net-timestamp: ACK timestamp for bytestreams Willem de Bruijn
2014-07-31 20:43 ` [PATCH net-next v4 0/5] net-timestamp: additional sw tstamps and David Miller
2014-07-31 21:36   ` Willem de Bruijn
2014-08-01  5:35     ` David Miller
2014-08-01 13:44       ` Willem de Bruijn

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).