From owner-cvs-src@FreeBSD.ORG Wed Sep 20 07:26:56 2006 Return-Path: X-Original-To: cvs-src@freebsd.org 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 92C1516A403; Wed, 20 Sep 2006 07:26:56 +0000 (UTC) (envelope-from peterjeremy@optushome.com.au) Received: from mail14.syd.optusnet.com.au (mail14.syd.optusnet.com.au [211.29.132.195]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7E31943D45; Wed, 20 Sep 2006 07:26:55 +0000 (GMT) (envelope-from peterjeremy@optushome.com.au) Received: from turion.vk2pj.dyndns.org (c220-239-19-236.belrs4.nsw.optusnet.com.au [220.239.19.236]) by mail14.syd.optusnet.com.au (8.12.11/8.12.11) with ESMTP id k8K7QQab029493 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO); Wed, 20 Sep 2006 17:26:51 +1000 Received: from turion.vk2pj.dyndns.org (localhost.vk2pj.dyndns.org [127.0.0.1]) by turion.vk2pj.dyndns.org (8.13.6/8.13.6) with ESMTP id k8K7QQ3a000902; Wed, 20 Sep 2006 17:26:26 +1000 (EST) (envelope-from peter@turion.vk2pj.dyndns.org) Received: (from peter@localhost) by turion.vk2pj.dyndns.org (8.13.6/8.13.6/Submit) id k8K7QQPF000901; Wed, 20 Sep 2006 17:26:26 +1000 (EST) (envelope-from peter) Date: Wed, 20 Sep 2006 17:26:26 +1000 From: Peter Jeremy To: Jung-uk Kim Message-ID: <20060920072626.GA738@turion.vk2pj.dyndns.org> References: <200609182218.k8IMIMUT059300@repoman.freebsd.org> <200609191431.01649.jkim@FreeBSD.org> <20060919190449.GC720@turion.vk2pj.dyndns.org> <200609191535.08184.jkim@FreeBSD.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Q68bSM7Ycu6FN28Q" Content-Disposition: inline In-Reply-To: <200609191535.08184.jkim@FreeBSD.org> X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc User-Agent: Mutt/1.5.12-2006-07-14 Cc: cvs-src@freebsd.org, src-committers@freebsd.org, cvs-all@freebsd.org, John Baldwin Subject: Re: cvs commit: src/sys/dev/bge if_bge.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Sep 2006 07:26:56 -0000 --Q68bSM7Ycu6FN28Q Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, 2006-Sep-19 15:35:06 -0400, Jung-uk Kim wrote: [VLAN tagging] >Why don't we just fake it up from ether_input() and pass it to=20 >BPF_MTAP() instead of 'teaching' bpf? I think it is more logical=20 >thing to do. As Andre points out, this negates the benefit of IFCAP_VLAN_HWTAGGING. In addition, the code necessary to correctly re-insert the VLAN tag (to provide a fully valid mbuf chain for further processing) will be larger and slower than the code necessary to kludge a mbuf that is adequate for bpf_filter(). bpf_mtap2() provides an example of kludging an mbuf header to allow data to be pre-pended. The code to kludge up the VLAN tag insertion would be similar (though somewhat more complex). Overall, I believe this approach is probably preferable to just disabling hardware VLAN tagging if there is a bpf filter. --=20 Peter Jeremy --Q68bSM7Ycu6FN28Q Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (FreeBSD) iD8DBQFFEO0i/opHv/APuIcRAuNSAJ0XAFeUznlXYBKCpAxM3GM/pBALdQCeMOz9 JO0pLra3AhjtfufsAT8z+1Y= =Ekb2 -----END PGP SIGNATURE----- --Q68bSM7Ycu6FN28Q--