[Click] Linux integration diagram?

Adam M click at irotas.net
Mon Jul 23 12:59:28 EDT 2007


Hi Beyers,

That explanation actually helped a lot! I didn't really understand
exactly how PollDevice and FromDevice operated and how they were
distinct, so thanks for the explanation.

To give you a little more detail, basically what I'm trying to figure
out is if there's any inherent reason why FromDevice would not work with
a "virtual" interface created using TUN on Linux. We use a virtual
interface to simulate such things as radio networks, and we're
considering using Click as the routing framework.

I'm not just convinced yet that the two can play nicely together. I'm
don't know if you will either (it seems that not many people understand
virtual interfaces that well), but I figured I'd take a shot. :)

Thanks again,
Adam


On Mon, 23 Jul 2007 18:44:17 +0200, "Beyers Cronje" <bcronje at gmail.com>
said:
> Hi Adam,
> 
> I haven't seen a diagram as such. I can try and give you a simple
> overview
> of how it works (on the receive side of things). Click kernel module
> ethernet integration works on two methods depending on whether you use
> PollDevice or FromDevice.
> 
> PollDevice - You can only use PollDevice if you have an Intel e1000 NIC
> with
> the Click polling patch applied. This polling patch modifies the e1000
> driver and in short does the following, it disables interrupts on the NIC
> which in turn means that Linux will not process any packets from the NIC.
> Then Click through PollDevice continually polls the receive queue of the
> NIC
> and receives any packets on the NIC's rx queue. It also supplies the
> driver
> with clean SKBs after it has received packets. Once the packet is inside
> Click it follows the push/pull processing of Click.
> 
> FromDevice - FromDevice works with any Linux NIC driver. The Click kernel
> patch modifies the Linux netif_receive_skb() function to intercept
> packets
> before Linux process them. This means interrupts are still in play. See
> netif_receive_skb() in the kernel patch along with FromDevice element
> code.
> 
> See https://pdos.csail.mit.edu/pipermail/click/2005-April/003845.html for
> an
> overview on how Click's push/pull packet processing operates.
> 
> Hope this helps a bit.
> 
> Beyers


More information about the click mailing list