diff options
author | Joe Hershberger | 2012-05-23 07:59:15 +0000 |
---|---|---|
committer | Joe Hershberger | 2012-05-23 17:52:53 -0500 |
commit | ece223b52ae9ab94f7ae83a9ac49b9f6319a94cb (patch) | |
tree | 1d2c3ec21e2802f52bb6d95b25ae16ad9d97cad8 /net/cdp.c | |
parent | 22f6e99d5b0c54758646334c1153737a5585bd57 (diff) |
net: Refactor to separate the UDP handler from the ARP handler
Call a built-in dummy if none is registered... don't require
protocols to register a handler (eliminating dummies)
NetConsole now uses the ARP handler when waiting on arp
(instead of needing a #define hack in arp.c)
Clear handlers at the end of net loop
Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
Acked-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'net/cdp.c')
-rw-r--r-- | net/cdp.c | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/net/cdp.c b/net/cdp.c index fa924097ac8..3d9559eb3b6 100644 --- a/net/cdp.c +++ b/net/cdp.c @@ -238,13 +238,6 @@ CDPTimeout(void) net_set_state(NETLOOP_SUCCESS); } -static void -CDPDummyHandler(uchar *pkt, unsigned dest, IPaddr_t sip, unsigned src, - unsigned len) -{ - /* nothing */ -} - void cdp_receive(const uchar *pkt, unsigned len) { const uchar *t; @@ -368,7 +361,6 @@ CDPStart(void) CDPApplianceVLAN = htons(-1); NetSetTimeout(CDP_TIMEOUT, CDPTimeout); - NetSetHandler(CDPDummyHandler); CDPSendTrigger(); } |