1

Is it easy to prevent kernel from passing packets to network layer?

view story
linux-howto

http://stackoverflow.com – Frames received by the network card will be handled by the driver and then passed to the upper layer of the protocol stack by the Linux kernel. Is there an easy way to prevent the kernel from passing packets to network layer? So that I can receive the frames from datalink layer and handle all the packets by myself(perhaps application layer programs would be rewrite)? I think re-compile the kernel is necessary, should this be done by modifying code in softirq or functions like netif_rx or in the list queues per cpu? (HowTos)