From: David Miller <davem@davemloft.net>
To: soheil.kdev@gmail.com
Cc: netdev@vger.kernel.org, soheil@google.com
Subject: Re: [PATCH net] tun: fix transmit timestamp support
Date: Tue, 23 Aug 2016 23:11:07 -0700 (PDT) [thread overview]
Message-ID: <20160823.231107.146565893536621022.davem@davemloft.net> (raw)
In-Reply-To: <1471990953-6793-1-git-send-email-soheil.kdev@gmail.com>
From: Soheil Hassas Yeganeh <soheil.kdev@gmail.com>
Date: Tue, 23 Aug 2016 18:22:33 -0400
> From: Soheil Hassas Yeganeh <soheil@google.com>
>
> Instead of using sock_tx_timestamp, use skb_tx_timestamp to record
> software transmit timestamp of a packet.
>
> sock_tx_timestamp resets and overrides the tx_flags of the skb.
> The function is intended to be called from within the protocol
> layer when creating the skb, not from a device driver. This is
> inconsistent with other drivers and will cause issues for TCP.
>
> In TCP, we intend to sample the timestamps for the last byte
> for each sendmsg/sendpage. For that reason, tcp_sendmsg calls
> tcp_tx_timestamp only with the last skb that it generates.
> For example, if a 128KB message is split into two 64KB packets
> we want to sample the SND timestamp of the last packet. The current
> code in the tun driver, however, will result in sampling the SND
> timestamp for both packets.
>
> Also, when the last packet is split into smaller packets for
> retranmission (see tcp_fragment), the tun driver will record
> timestamps for all of the retransmitted packets and not only the
> last packet.
>
> Fixes: eda297729171 (tun: Support software transmit time stamping.)
> Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com>
> Signed-off-by: Francis Yan <francisyyan@google.com>
Applied and queued up for -stable, thanks.
prev parent reply other threads:[~2016-08-24 6:11 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-23 22:22 [PATCH net] tun: fix transmit timestamp support Soheil Hassas Yeganeh
2016-08-23 23:15 ` Eric Dumazet
2016-08-24 6:11 ` David Miller [this message]
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=20160823.231107.146565893536621022.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=soheil.kdev@gmail.com \
--cc=soheil@google.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