Netdev List
 help / color / mirror / Atom feed
From: Benjamin Poirier <benjamin.poirier@gmail.com>
To: Felipe Dias <felipediassss@gmail.com>
Cc: netdev@vger.kernel.org
Subject: Re: skb->timestamp == 0.000000 ?
Date: Mon, 21 Nov 2011 16:11:40 -0500	[thread overview]
Message-ID: <20111121211140.GB24753@d2.suse.de> (raw)
In-Reply-To: <CAJX4=r3wTn9v6-5oEpGdeKkFjKsRLZwc76tE9M4FiVJX4Lpisg@mail.gmail.com>

On 11/11/19 18:13, Felipe Dias wrote:
> Hi..
> 
> Please let me know if this isnt right list to this kind of question.
> 
> I'm registering a new protocol handler with dev_add_pack. I would like
> to know only the difference between timestamp on skb->tstamp and the
> time of reception by my module.
> 
> So I do:
> ----
> struct timeval time_skb, time_module;
> do_gettimeofday(&time_module):
> skb_get_timestamp(skb, &time_skb);
> ---
> 
> And time_skb.tv_sec and time_skb.tv_usec are equal to 0;
> 
> I'm doing some wrong ?

Timestamps have to be enabled
have a look at:
net_enable_timestamp()

-Ben

  reply	other threads:[~2011-11-21 21:11 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-19 21:13 skb->timestamp == 0.000000 ? Felipe Dias
2011-11-21 21:11 ` Benjamin Poirier [this message]
2011-11-22 14:04   ` Felipe Dias
2011-11-22 14:10     ` Eric Dumazet

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=20111121211140.GB24753@d2.suse.de \
    --to=benjamin.poirier@gmail.com \
    --cc=felipediassss@gmail.com \
    --cc=netdev@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