mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: nergal@7bulls.com (Rafal Wojtczuk)
To: linux-kernel@vger.kernel.org
Subject: dev_add_pack() question
Date: Wed, 9 May 2001 14:29:06 +0000	[thread overview]
Message-ID: <20010509142906.B1388@lda.sur5.net> (raw)

Hello,
I register a callback function with dev_add_pack() this way:
  memset (&proto, 0, sizeof proto);
  proto.type = htons (ETH_P_ALL);
  proto.func = my_callback_function;
  dev_add_pack (&proto);
my_callback_function() receives all packets with local src/dst IP (including
SNATed ones) as well as all incoming ones, but forwarded outgoing packets are 
not passed to my_callback_function(). Looks like AF_PACKET sockets also rely 
on dev_add_pack(), yet of course tcpdump (correctly) shows all the packets. 
How should I register a callback with dev_add_pack() so that the callback
receives all the packets ?

Save yourself,
Nergal


                 reply	other threads:[~2001-05-09 12:42 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20010509142906.B1388@lda.sur5.net \
    --to=nergal@7bulls.com \
    --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®