Messages in this thread Patch in this message |  | | Date | Tue, 14 Aug 2001 21:30:23 +0200 | From | Christoph Hellwig <> | Subject | Re: [PATCH] CDP handler for linux |
| |
Hi Chis,
In article <Pine.LNX.4.33.0108141934130.3283-100000@monolith.shad0w.org.uk> you wrote: > I've been working on an addition to the kernel over the past > couple of days that enables the kernel to interpret CDP (Cisco Discovery > Protocol) packets which can be transmited by various pieces of Cisco kit. > > I've got it to the stage where it will read neighbors packets and > display them via a /proc/net entry, but I've only really tested it with > the router I have access to here, so I was wondering:
> --- linux-2.4/net/cdp/Makefile Thu Jan 1 01:00:00 1970 > +++ linux-2.4.7-cdp/net/cdp/Makefile Thu Aug 9 12:11:44 2001 > @@ -0,0 +1,25 @@ > +# > +# Makefile for the Linux CDP layer. > +# > +# Note! Dependencies are done automagically by 'make dep', which also > +# removes any old dependencies. DON'T put your own dependencies here > +# unless it's something special (ie not a .c file). > +# > +# Note 2! The CFLAGS definition is now in the main makefile... > + > +# We only get in/to here if CONFIG_CDP = 'y' or 'm' > + > +O_TARGET := cdp.o > + > +export-objs = af_cdp.o You don't export symbols, so you don't need to add your object to export-objs.
> + > +obj-y := af_cdp.o > + > +ifeq ($(CONFIG_CDP),m) > + obj-m += $(O_TARGET) > +endif > + > +include $(TOPDIR)/Rules.make > + > +tar: > + tar -cvf /dev/f1 .
Kill this tar rule, please :)
> diff -urN -X dontdiff linux-2.4/net/cdp/af_cdp.c linux-2.4.7-cdp/net/cdp/af_cdp.c > --- linux-2.4/net/cdp/af_cdp.c Thu Jan 1 01:00:00 1970 > +++ linux-2.4.7-cdp/net/cdp/af_cdp.c Tue Aug 14 19:14:11 2001 > @@ -0,0 +1,509 @@ > +/* > + * Implements a CDP handler. > + * > + * This code is derived from protocol specifications by Cisco Systems > + * and various code culled from the Kernel source tree, mostly the IPX > + * code. > + * > + * Unless otherwise commented, all revisions by Chris Crowther. > + * > + * Revision 0.1.0: Initial coding. > + * Revision 0.1.1: Incoming CDP packet handling working, prefix's and addresses > + * need handling still. > + * > + * Portions Copyright (c) 2001 Chris Crowther.
I think it's all yours, isn't it?
Besides this little nitpicks I'd like to give you the advise to send this to linuxnetdev, too.
Christoph
-- Whip me. Beat me. Make me maintain AIX. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
|  |