From owner-freebsd-net Wed Jun 27 11:12:32 2001 Delivered-To: freebsd-net@freebsd.org Received: from coopcomp.com (coopcomp.com [161.58.219.43]) by hub.freebsd.org (Postfix) with ESMTP id 3585B37B407 for ; Wed, 27 Jun 2001 11:12:29 -0700 (PDT) (envelope-from seichert@coopcomp.com) Received: from gourdy.coopcomp.com (gourdy.coopcomp.com [64.81.249.34]) by coopcomp.com (8.11.2) id f5RICSn05045; Wed, 27 Jun 2001 12:12:28 -0600 (MDT) Received: by gourdy.coopcomp.com (sSMTP sendmail emulation); Wed, 27 Jun 2001 11:12:22 -0700 Date: Wed, 27 Jun 2001 11:12:22 -0700 From: Stuart Eichert To: net@freebsd.org Subject: Am I missing something? Message-ID: <20010627111222.A9434@gourdy.coopcomp.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org In the past (under FreeBSD 3.0 and 3.3) I implemented a new networking protocol, that ran over Ethernet(and nothing else for that matter). I put a new ETHERTYPE into ethernet.h(0x0801 for the record). In addition I modified the switch statements in if_ethersubr.c:ether_output and if_ethersubr.c:ether_input to recognize this type and act accordingly. In addition I modified sys/socket.h to add an additional address family and protocol family for my protocol. From there I implemented the protocol in a separate directory, made some changes in the conf directory and then I was able to compile a new kernel with support for my protocol. This is cool and all (and yes I have updated it to work in 4.3), but I don't like the idea that anyone who wants to try out this protocol and any associated programs has to recompile an entire kernel. I would much prefer to create a kernel module that someone can load, test, and then unload. I don't think that I can do this however, because of the ethernet routines in if_ethersubr.c. These routines do not allow for the dynamic addition of new ETHERTYPES. I guess one could screw around with netgraph or tap(though I really know next to nothing about them), but that would not allow me to plug the protocol in below the socket layer. Is there no way to make a kernel module that will allow for the dynamic addition of ethernet protocols or am I just missing something? -- ------------ Stuart Eichert Cooperative Computers, Inc. seichert@coopcomp.com (650)938-0730 x 15 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message