Netdev List
 help / color / mirror / Atom feed
From: Patrick Ohly <patrick.ohly@intel.com>
To: Mark Smith <nanog@85d5b20a518b8f6864949bd940457dc124746ddc.nosense.org>
Cc: "netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	Octavian Purdila <opurdila@ixiacom.com>
Subject: Re: Storing hardware timestamps - how about using the new skb's control block?
Date: Wed, 12 Nov 2008 09:27:18 +0100	[thread overview]
Message-ID: <1226478438.31699.55.camel@ecld0pohly> (raw)
In-Reply-To: <20081112072340.1c0c1a74.nanog@85d5b20a518b8f6864949bd940457dc124746ddc.nosense.org>

On Tue, 2008-11-11 at 20:53 +0000, Mark Smith wrote:
> Just a quick suggestion for storing hardware timestamps, how about
> storing them in the new skb's control block?
> 
> From what I understand, any private users of the control block are
> supposed to ignore the existing value, and if a protocol/tap is going
> to be looking at the new skb, it should have done a skb_share_check()
> first to grab it's own private copy if necessary, protecting the
> control block stored timestamp value from any of the other skb
> users who might change the control block value for their own purposes.

My understanding of sk_buff->cb might be wrong, but isn't each layer
allowed to overwrite it as the packet traverses the different queues?
skb_share_check() is not mandatory: the owner of a packet has to call it
if he wants to preserve the control block, not the recipient of a
packet.

If that understanding is correct, then I don't see how the control block
can be used to communicate information across layers. Or do I miss
something fundamental?

-- 
Best Regards, Patrick Ohly

The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.


  reply	other threads:[~2008-11-12  8:27 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-11 20:53 Storing hardware timestamps - how about using the new skb's control block? Mark Smith
2008-11-12  8:27 ` Patrick Ohly [this message]
2008-11-12  8:39   ` David Miller

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=1226478438.31699.55.camel@ecld0pohly \
    --to=patrick.ohly@intel.com \
    --cc=nanog@85d5b20a518b8f6864949bd940457dc124746ddc.nosense.org \
    --cc=netdev@vger.kernel.org \
    --cc=opurdila@ixiacom.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