netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* netlink callback and socket buffer.
@ 2009-02-13 20:35 Giacomo
  2009-02-14 17:16 ` Pablo Neira Ayuso
  0 siblings, 1 reply; 2+ messages in thread
From: Giacomo @ 2009-02-13 20:35 UTC (permalink / raw)
  To: netfilter-devel

Good evening to everybody.

In recent kernels (>=2.6.24) netlink_kernel_create() callback function
has the following signature:


(void *) function(struct sk_buff* skb);

while before it was

(void  *) function(struct sock *skctrl, int len)

In the latter, i used to call skb_dequeue, obtain the skb and then,
once data was extracted, I used
to kfree_skb(skb); where skb is a sk_buff* obtained by skb_dequeue();

Now (with the (void *) function(struct sk_buff* skb)  callback) I get
data from skb but DO NOT HAVE
TO kfree_skb() it...

Is it true?  Is it automatically freed by the kernel once the callback returns?

Thanks in advance.

Giacomo S.


-- 
Giacomo S.
http://www.giacomos.it

- - - - - - - - - - - - - - - - - - - - - -

* Aprile 2008: iqfire-wall, un progetto
  open source che implementa un
  filtro di pacchetti di rete per Linux,
  e` disponibile per il download qui:
  http://sourceforge.net/projects/ipfire-wall

* Informazioni e pagina web ufficiale:
  http://www.giacomos.it/iqfire/index.html

- - - - - - - - - - - - - - - - - - - - - -

 . ''  `.
:   :'    :
 `.  ` '
    `- Debian GNU/Linux -- The power of freedom
        http://www.debian.org

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-02-14 17:16 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-02-13 20:35 netlink callback and socket buffer Giacomo
2009-02-14 17:16 ` Pablo Neira Ayuso

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).