From owner-freebsd-net@FreeBSD.ORG Mon Sep 6 06:33:16 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A7B8A16A4CE; Mon, 6 Sep 2004 06:33:16 +0000 (GMT) Received: from cell.sick.ru (cell.sick.ru [217.72.144.68]) by mx1.FreeBSD.org (Postfix) with ESMTP id EB85443D58; Mon, 6 Sep 2004 06:33:15 +0000 (GMT) (envelope-from glebius@freebsd.org) Received: from cell.sick.ru (glebius@localhost [127.0.0.1]) by cell.sick.ru (8.12.11/8.12.8) with ESMTP id i866XDMU084419 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 6 Sep 2004 10:33:14 +0400 (MSD) (envelope-from glebius@freebsd.org) Received: (from glebius@localhost) by cell.sick.ru (8.12.11/8.12.11/Submit) id i866XD2u084418; Mon, 6 Sep 2004 10:33:13 +0400 (MSD) (envelope-from glebius@freebsd.org) X-Authentication-Warning: cell.sick.ru: glebius set sender to glebius@freebsd.org using -f Date: Mon, 6 Sep 2004 10:33:13 +0400 From: Gleb Smirnoff To: Luigi Rizzo Message-ID: <20040906063313.GB84269@cell.sick.ru> References: <20040905205249.GA81337@cell.sick.ru> <20040905142036.A23213@xorpc.icir.org> <20040905230100.GA82214@cell.sick.ru> <20040905222954.A26501@xorpc.icir.org> Mime-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: <20040905222954.A26501@xorpc.icir.org> User-Agent: Mutt/1.5.6i cc: net@freebsd.org Subject: Re: bridge callbacks in if_ed.c? X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Sep 2004 06:33:16 -0000 On Sun, Sep 05, 2004 at 10:29:54PM -0700, Luigi Rizzo wrote: L> > L> I'd rather not apply the patch unless you can show that L> > L> the current code leads to incorrect behaviour. L> > L> > I suspect that packets dropped by bridge_in() called from if_ed will L> > not be captured by bpf(4). This is incorrect. L> L> if you read the code you see that the bpf behaviour is L> as it should be, and your suspect is unfounded. L> L> - if (!ifp->if_bpf && BDG_ACTIVE( (ifp) ) ) { You are right, sorry. But the packets dropped by bridge will not enter lower hook of ng_ether(4), like they do in case of other interfaces. L> (my summary and pov on the discussion in a separate email) Actually, I'm working on better interaction of ng_ether and bridge, and this hack in if_ed is on the way. And this "will se the light" quite soon. -- Totus tuus, Glebius. GLEBIUS-RIPN GLEB-RIPE