DCCP protocol discussions
 help / color / mirror / Atom feed
From: Gerrit Renker <gerrit@erg.abdn.ac.uk>
To: dccp@vger.kernel.org
Subject: Re: [PATCH 07/15] Convert dccp_sample_rtt to ktime_t
Date: Tue, 21 Aug 2007 13:17:02 +0000	[thread overview]
Message-ID: <200708211417.03084@strip-the-willow> (raw)
In-Reply-To: <20070819235043.GK24792@ghostprotocols.net>

After a bit more testing, I found that this one has one bug.

|  @@ -593,22 +591,21 @@ EXPORT_SYMBOL_GPL(dccp_rcv_state_process);
|    * @t_recv: receive timestamp of packet with timestamp echo
|    * @t_hist: packet history timestamp or NULL
|    */
|  -u32 dccp_sample_rtt(struct sock *sk, struct timeval *t_recv,
|  -				     struct timeval *t_hist)
|  +u32 dccp_sample_rtt(struct sock *sk, ktime_t t_recv, ktime_t *t_hist)
|   {
|   	struct dccp_sock *dp = dccp_sk(sk);
|   	struct dccp_options_received *or = &dp->dccps_options_received;
|  -	suseconds_t delta;
|  +	s64 delta;
|   
|   	if (t_hist = NULL) {
|   		if (!or->dccpor_timestamp_echo) {
|   			DCCP_WARN("packet without timestamp echo\n");
|   			return DCCP_SANE_RTT_MAX;
|   		}
|  -		timeval_sub_usecs(t_recv, or->dccpor_timestamp_echo * 10);
|  -		delta = timeval_usecs(t_recv);
|  +		ktime_sub_us(t_recv, or->dccpor_timestamp_echo * 10);
|  +		delta = ktime_to_us(t_recv);
=> It should read
    t_recv = ktime_sub_us(t_recv, or->dccpor_timestamp_echo * 10);
    the statement is otherwise void.


      reply	other threads:[~2007-08-21 13:17 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-19 23:50 [PATCH 07/15] Convert dccp_sample_rtt to ktime_t Arnaldo Carvalho de Melo
2007-08-21 13:17 ` Gerrit Renker [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=200708211417.03084@strip-the-willow \
    --to=gerrit@erg.abdn.ac.uk \
    --cc=dccp@vger.kernel.org \
    /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