From owner-freebsd-hackers@FreeBSD.ORG Tue Jun 15 20:29:23 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from green.homeunix.org (freefall.freebsd.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 0A4D016A4CE; Tue, 15 Jun 2004 20:29:23 +0000 (GMT) Received: from green.homeunix.org (green@localhost [127.0.0.1]) by green.homeunix.org (8.12.11/8.12.11) with ESMTP id i5FKTMwN006526; Tue, 15 Jun 2004 16:29:22 -0400 (EDT) (envelope-from green@green.homeunix.org) Received: (from green@localhost) by green.homeunix.org (8.12.11/8.12.11/Submit) id i5FKTLO7006525; Tue, 15 Jun 2004 16:29:21 -0400 (EDT) (envelope-from green) Date: Tue, 15 Jun 2004 16:29:21 -0400 From: Brian Feldman To: Ed Maste , "'Sergey Lyubka'" , freebsd-hackers@freebsd.org Message-ID: <20040615202921.GF1016@green.homeunix.org> References: <20040614174749.GF14722@empiric.dek.spc.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040614174749.GF14722@empiric.dek.spc.org> User-Agent: Mutt/1.5.6i Subject: Re: memory mapped packet capturing - bpf replacement ? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 15 Jun 2004 20:29:23 -0000 On Mon, Jun 14, 2004 at 06:47:49PM +0100, Bruce M Simpson wrote: > On Mon, Jun 14, 2004 at 08:38:57AM -0400, Ed Maste wrote: > > Hello Sergey. I haven't looked at your code, but I'll provide > > some comments, having implemented a mmaped ringbuffer BPF > > replacement myself. > > We've had some prior interest in this. Do you have patches? If so, I'd be > more than happy to look at them. > > Linux has something similar, but when I looked at the mechanism involved, > I was loathe to adopt the same logic because the buffer(s) involved were > allocated from userland and then mapped accordingly; we generally can't > afford to take a page fault in that path, for mutex related reasons. If I finally get to finish fixing wiring, you should simply be able to call vslock(9) in your kernel module and get that functionality. As it is, vslock(9) is broken.... -- Brian Fundakowski Feldman \'[ FreeBSD ]''''''''''\ <> green@FreeBSD.org \ The Power to Serve! \ Opinions expressed are my own. \,,,,,,,,,,,,,,,,,,,,,,\