From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mike Frysinger Date: Fri, 3 Feb 2012 06:55:38 -0500 Subject: [U-Boot] [PATCH 05/28] net: Move CDP out of net.c In-Reply-To: <1327020811-1538-6-git-send-email-joe.hershberger@ni.com> References: <1327020811-1538-1-git-send-email-joe.hershberger@ni.com> <1327020811-1538-6-git-send-email-joe.hershberger@ni.com> Message-ID: <201202030655.39529.vapier@gentoo.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Thursday 19 January 2012 19:53:08 Joe Hershberger wrote: > --- a/include/net.h > +++ b/include/net.h > > +int is_cdp_packet(const uchar *et_addr); seems like this would be better as a static inline since it's just a memcmp > --- /dev/null > +++ b/net/cdp.h > @@ -0,0 +1,18 @@ > +/* > + * Copied from Linux Monitor (LiMon) - Networking. > + * > + * Copyright 1994 - 2000 Neil Russell. > + * (See License) > + * Copyright 2000 Roland Borde > + * Copyright 2000 Paolo Scaffardi > + * Copyright 2000-2002 Wolfgang Denk, wd at denx.de > + */ > + > +#ifndef __CDP_H__ > +#define __CDP_H__ > + > +void CDPStart(void); > +void CDPHandler(const uchar *pkt, unsigned len); > + > +#endif /* __CDP_H__ */ > + no blank newlines at end of files > --- a/net/net.c > +++ b/net/net.c > > +#if defined(CONFIG_CMD_CDP) > +#include "cdp.h" > #endif let's push this ifdef down into cdp.h -mike -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: This is a digitally signed message part. URL: