lkml.org 
[lkml]   [1999]   [May]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: raw network packets
Date
In muc.lists.linux-kernel, you wrote:
>I receive packets from my fieldbus driver. I want to do the
>protocol-stuff in userland. How can I pass the raw packets up to a
>socket created by a userland application?
>of cause I would like to limit my coding to the driver module and keep
>my fingers away from the original kernel files.
>
>I guess it must be something about skb->mac.raw, skb->nh.raw and
>skb->h.raw.
>
>But I do seem to need to register a protocol type with the network core
>so my packets would not get droped. Is this right? What else do I need
>to get my packets though to userland with minimal effort?

Such a facility is already builtin - SOCK_PACKET (2.0)/PF_PACKET (2.2). There
you can bind to L2 protocol types.



-Andi

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:51    [W:0.042 / U:0.088 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site