mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Oleg Drokin <green@dredd.crimea.edu>
To: kuznet@ms2.inr.ac.ru
Cc: linux-kernel@vger.kernel.org, davem@redhat.com, david-b@pacbell.net
Subject: Re: IP layer bug?
Date: Sat, 31 Mar 2001 19:03:14 +0400	[thread overview]
Message-ID: <20010331190314.A27130@dredd.crimea.edu> (raw)
In-Reply-To: <20010325005731.A5243@dredd.crimea.edu> <200103301713.VAA03794@ms2.inr.ac.ru>
In-Reply-To: <200103301713.VAA03794@ms2.inr.ac.ru>; from kuznet@ms2.inr.ac.ru on Fri, Mar 30, 2001 at 09:13:40PM +0400

Hello!

On Fri, Mar 30, 2001 at 09:13:40PM +0400, kuznet@ms2.inr.ac.ru wrote:
> >    For now I workarounded it with filling skb->cb with zeroes before
> >    netif_rx(),
> This is right. For another examples look into tunnels.
Hm. But comment in linux/skbuff.h says:
        /*
         * This is the control buffer. It is free to use for every
         * layer. Please put your private variables there. If you
         * want to keep them across layers you have to do a skb_clone()
         * first. This is owned by whoever has the skb queued ATM.
         */
Which does not imply I should clear buffer after I am passing ownership.

> > but I believe it is a kludge and networking layer should be fixed instead.
> No.

> alloc_skb() creates skb with clean cb. ip_rcv() and other protocol handlers
> do not redo this work. If device uses cb internally, it must clear it
> before handing skb to netif_rx().
Why not document it somewhere, so that others will not fall into the same trap?

Bye,
    Oleg

  reply	other threads:[~2001-03-31 15:06 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-03-24 21:57 Oleg Drokin
2001-03-26 10:36 ` Manoj Sontakke
2001-03-26  6:09   ` Oleg Drokin
2001-03-26 12:21     ` Manoj Sontakke
2001-03-26  7:02       ` Oleg Drokin
2001-03-30 17:13 ` kuznet
2001-03-31 15:03   ` Oleg Drokin [this message]
2001-03-31 15:32     ` kuznet
2001-04-02  9:25       ` Oleg Drokin

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=20010331190314.A27130@dredd.crimea.edu \
    --to=green@dredd.crimea.edu \
    --cc=davem@redhat.com \
    --cc=david-b@pacbell.net \
    --cc=kuznet@ms2.inr.ac.ru \
    --cc=linux-kernel@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

all inboxes | Powered by JetHome®