From owner-cvs-src Tue Feb 25 23:41:10 2003 Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 41D0437B401; Tue, 25 Feb 2003 23:41:07 -0800 (PST) Received: from rwcrmhc51.attbi.com (rwcrmhc51.attbi.com [204.127.198.38]) by mx1.FreeBSD.org (Postfix) with ESMTP id A681743F3F; Tue, 25 Feb 2003 23:41:06 -0800 (PST) (envelope-from julian@elischer.org) Received: from interjet.elischer.org (12-232-168-4.client.attbi.com[12.232.168.4]) by rwcrmhc51.attbi.com (rwcrmhc51) with ESMTP id <20030226074106051003k6dde>; Wed, 26 Feb 2003 07:41:06 +0000 Received: from localhost (localhost.elischer.org [127.0.0.1]) by InterJet.elischer.org (8.9.1a/8.9.1) with ESMTP id XAA93197; Tue, 25 Feb 2003 23:41:04 -0800 (PST) Date: Tue, 25 Feb 2003 23:41:02 -0800 (PST) From: Julian Elischer To: Bill Paul Cc: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/netgraph ng_fec.c In-Reply-To: <200302260638.h1Q6cs15050045@repoman.freebsd.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-cvs-src@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, 25 Feb 2003, Bill Paul wrote: > wpaul 2003/02/25 22:38:54 PST > > Modified files: > sys/netgraph ng_fec.c > Log: > Attempt to make the ng_fec module play nice with BPF again. Things have > changed since this code was written: > > - The ng_ether_input_p hook only accepts two arguments now: the pointer > to the ether header structure is gone. The problem is that you should not be using ng_ether_input_p at all that is a private interface between ng_ether.c and if_ethersubr.c. You should be connecting a hook to ng_ether.c which will in turn use ng_ether_input_p. I have on my list (right after my real job(TM) and kernel threading and some netgraph cleanups) to alter ng_fec to use the official interface. i.e. yu should be able to say: ngctl fxp0: mkpeer fec lower lower1 ngctl name fxp0:lower fec1 ngctl fxp1: connect fec1: lower lower2 ngctl fxp0: connect fec1: upper upper and hook an fec module onto two ethernet interfaces. (using fxp0 as the upper end) as it is, having ng_fec loaded in the kernel produces an instant coredump if ng_ether is also loaded as they fight over ng_ether's private hook into the ethernet code. As I said.. It's on my list .. but don't hold your breath. > > - It's no longer necessary to cons up a fake ether header before passing > incoming packets to BPF_MTAP(). > > ng_fec_input() has been modified to account for these two changes. > Running tcpdump on fec0 should work now. > > PR: kern/46720 > > Revision Changes Path > 1.4 +6 -16 src/sys/netgraph/ng_fec.c > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-src" in the body of the message