From owner-freebsd-net@FreeBSD.ORG Sun Jan 11 11:57:49 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 B186A16A4D0 for ; Sun, 11 Jan 2004 11:57:49 -0800 (PST) Received: from arginine.spc.org (arginine.spc.org [195.206.69.236]) by mx1.FreeBSD.org (Postfix) with ESMTP id B6D6743D53 for ; Sun, 11 Jan 2004 11:57:47 -0800 (PST) (envelope-from bms@spc.org) Received: from localhost (localhost [127.0.0.1]) by arginine.spc.org (Postfix) with ESMTP id D28596520C; Sun, 11 Jan 2004 19:57:45 +0000 (GMT) Received: from arginine.spc.org ([127.0.0.1]) by localhost (arginine.spc.org [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 51777-03-14; Sun, 11 Jan 2004 19:57:45 +0000 (GMT) Received: from saboteur.dek.spc.org (82-147-17-88.dsl.uk.rapidplay.com [82.147.17.88]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by arginine.spc.org (Postfix) with ESMTP id 9AA4F65319; Sun, 11 Jan 2004 19:57:41 +0000 (GMT) Received: by saboteur.dek.spc.org (Postfix, from userid 1001) id A2C312E; Sun, 11 Jan 2004 19:57:40 +0000 (GMT) Date: Sun, 11 Jan 2004 19:57:40 +0000 From: Bruce M Simpson To: Guy Helmer Message-ID: <20040111195740.GK17555@saboteur.dek.spc.org> Mail-Followup-To: Guy Helmer , Richard Bejtlich , freebsd-net@freebsd.org References: <20040109171717.33976.qmail@web60804.mail.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: cc: freebsd-net@freebsd.org cc: Richard Bejtlich Subject: Re: Paper on device polling and packet capture performance 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: Sun, 11 Jan 2004 19:57:49 -0000 On Fri, Jan 09, 2004 at 03:51:43PM -0600, Guy Helmer wrote: > I want to look at memory-mapped access to the BPF device. > This would preserve the existing network device drivers > while reducing mbuf copies, context switches/user-kernel > transitions, and latency. Performance ought to be > comparable to Luca's approach, and this would also > preserve bpf filtering capability. > > (If someone else has already done this, I'd love to > know where to find the code!) I did review some patches related to this last month but they weren't for FreeBSD. One big problem with the approach involved which leapt out at me was that the space was allocated within user address space, which introduces the risk of page faults (as you may know we can't ever fault with a mutex held -- or it's game over). I'd be happy to review other patches for this. My personal feeling though is that the actual performance increase may not be that great, but it's a case of someone implementing it and doing the math. BMS