From owner-freebsd-net@FreeBSD.ORG Thu Aug 8 09:16:58 2013 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id B919C721 for ; Thu, 8 Aug 2013 09:16:58 +0000 (UTC) (envelope-from guy@alum.mit.edu) Received: from b.mail.sonic.net (b.mail.sonic.net [64.142.19.5]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 9FDA721E1 for ; Thu, 8 Aug 2013 09:16:58 +0000 (UTC) Received: from [10.0.1.2] ([66.201.46.179]) (authenticated bits=0) by b.mail.sonic.net (8.13.8.Beta0-Sonic/8.13.7) with ESMTP id r788RS9x015404 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Thu, 8 Aug 2013 01:27:28 -0700 Content-Type: text/plain; charset=iso-8859-1 Mime-Version: 1.0 (Mac OS X Mail 6.3 \(1503\)) Subject: Re: BPF_MISC+BPF_COP and BPF_COPX From: Guy Harris In-Reply-To: <5203535D.2040508@netbsd.org> Date: Thu, 8 Aug 2013 01:27:32 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: <0C9DFD21-D09F-4163-BF90-4258838577A7@alum.mit.edu> References: <20130804191310.2FFBB14A152@mail.netbsd.org> <5202693C.50608@netbsd.org> <20130807175548.1528014A21F@mail.netbsd.org> <5203535D.2040508@netbsd.org> To: darrenr@netbsd.org X-Mailer: Apple Mail (2.1503) Cc: tech-net@netbsd.org, Mindaugas Rasiukevicius , freebsd-net@freebsd.org X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Aug 2013 09:16:58 -0000 On Aug 8, 2013, at 1:14 AM, Darren Reed wrote: > A BPF program generated on Linux is just as valid as on Solaris or = NetBSD. Not necessarily - negative offsets in load and store instructions are = supported on Linux to access some metadata that's not in the packet = data, but those aren't, as far as I know, supported on other platforms. However, there is a subset of BPF that all kernel BPF implementations, = and the userland implementation in libpcap, support.=