lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-devel] Re: [lwip-users] filter broadcast packet


From: Jonathan Larmour
Subject: Re: [lwip-devel] Re: [lwip-users] filter broadcast packet
Date: Fri, 25 Jan 2008 13:26:49 +0000
User-agent: Thunderbird 1.5.0.12 (X11/20070530)

Piero 74 wrote:
> I found up to know two important protocols which use broadcast:
> 
> ARP: has its own ethernet type... it is simple to find if broadcast
> packet is arp packet
> DHCP: is based on udp: i think it is difficoult to filter in emac irq
> function
> 
> Do you know other protocol? how i can check if there is dhcp packet at
> ethernet frame level?

Because of the possible presence of things like IP options, you would have
to decode each layer of packet. In which case, since that's what the stack
already does, I'm not sure you would find much gain. But it can be done.
Unless you have particular application requirements, ARP and DHCP are
mostly all the broadcasts you'd find on a typical network.

But backing up a little, since the packets have to be processed by the
tcpip thread really, you may be able to do that directly from your IRQ,
rather than from another separate thread. It depends on whether your
mailbox implementation is interrupt-safe. If it is, then you could post it
to the mailbox directly.

Jifl
-- 
eCosCentric Limited      http://www.eCosCentric.com/     The eCos experts
Barnwell House, Barnwell Drive, Cambridge, UK.       Tel: +44 1223 245571
Registered in England and Wales: Reg No 4422071.
------["Si fractum non sit, noli id reficere"]------       Opinions==mine




reply via email to

[Prev in Thread] Current Thread [Next in Thread]