netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Hemminger <shemminger@vyatta.com>
To: Patrick Ohly <patrick.ohly@intel.com>
Cc: Octavian Purdila <opurdila@ixiacom.com>, netdev@vger.kernel.org
Subject: Re: [RFC][PATCH 1/1] net: support for hardware timestamping
Date: Tue, 29 Jul 2008 08:54:57 -0700	[thread overview]
Message-ID: <20080729085457.033a9fd2@extreme> (raw)
In-Reply-To: <1217343163.30512.34.camel@ecld0pohly>

On Tue, 29 Jul 2008 16:52:43 +0200
Patrick Ohly <patrick.ohly@intel.com> wrote:

> On Tue, 2008-07-29 at 03:08 +0300, Octavian Purdila wrote:
> > New socket option and socket control message are added as well
> > (SO_TIMESTAMPHW and SCM_TIMESTAMPHW).
> 
> How is a network driver notified that it is expected to do hardware time
> stamping? The connection between the socket option and the driver isn't
> quite clear to me (which might very well be due to my lack of experience
> in this area - please bear with me...). Is the driver expected to check
> the socket flags whenever it gets a chance?
> 
> IMHO it would be necessary to attach this configuration change not just
> to a socket, but also to a message which is then routed to the right
> device driver.
>
In my sky2 sample code, I took a different approach:
 1. Why have HW timestamps different than existing timestamps? If you
    just use existing timestamp, no socket API is needed.
 2. Driver can periodically check if socket timestamping is enabled,
    (atomic_read(&netstamp_needed)) and enable hardware stamping then.
    Alternatively, add a new notifier to net_enable_timestamp() and
    net_disable_timestamp().


   

  parent reply	other threads:[~2008-07-29 15:54 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-29  0:07 [RFC][PATCH 0/1] net: support for hardware timestamps Octavian Purdila
2008-07-29  0:08 ` [RFC][PATCH 1/1] net: support for hardware timestamping Octavian Purdila
2008-07-29 14:52   ` Patrick Ohly
2008-07-29 15:49     ` Octavian Purdila
2008-07-30  9:35       ` Patrick Ohly
2008-07-30 13:38         ` Octavian Purdila
2008-07-30 14:00           ` Patrick Ohly
2008-07-29 15:54     ` Stephen Hemminger [this message]
2008-07-29 16:11       ` Octavian Purdila
2008-07-29 17:30         ` Ingo Oeser
2008-07-29 18:10           ` Octavian Purdila
2008-07-29 18:27             ` Ingo Oeser
2008-07-30  8:51         ` Patrick Ohly
2008-07-30  9:34           ` Ingo Oeser

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=20080729085457.033a9fd2@extreme \
    --to=shemminger@vyatta.com \
    --cc=netdev@vger.kernel.org \
    --cc=opurdila@ixiacom.com \
    --cc=patrick.ohly@intel.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;
as well as URLs for NNTP newsgroup(s).