From owner-freebsd-hackers Wed Aug 23 22:53:34 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from fw.wintelcom.net (ns1.wintelcom.net [209.1.153.20]) by hub.freebsd.org (Postfix) with ESMTP id 4CD7C37B422 for ; Wed, 23 Aug 2000 22:53:33 -0700 (PDT) Received: (from bright@localhost) by fw.wintelcom.net (8.10.0/8.10.0) id e7O5rW101014; Wed, 23 Aug 2000 22:53:32 -0700 (PDT) Date: Wed, 23 Aug 2000 22:53:32 -0700 From: Alfred Perlstein To: Louis Gerbarg Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: A few device questions Message-ID: <20000823225331.X4854@fw.wintelcom.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.4i In-Reply-To: ; from gerbal@rpi.edu on Thu, Aug 24, 2000 at 01:48:32AM -0400 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG * Louis Gerbarg [000823 22:48] wrote: > > The mem driver does not seem to have an attach call. To hack around that > on darwin I used a static variable initialized to 0, and then put a test > for it in the open call. If it is zero it runs my attach routine and sets > the variable to 1. Is there a better way to do this in the FreeBSD mem > driver? Yes, have a look at src/sys/netinet/accf_http.c particularly the DECLARE_MODULE macro, this allows one to declare routines to be run at the time when modload or boot happens. Sorry I can't answer your other questions, I try to avoid entropy. :) -- -Alfred Perlstein - [bright@wintelcom.net|alfred@freebsd.org] "I have the heart of a child; I keep it in a jar on my desk." To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message