From owner-freebsd-current@FreeBSD.ORG Wed Apr 16 20:24:05 2003 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D81C837B401 for ; Wed, 16 Apr 2003 20:24:05 -0700 (PDT) Received: from stork.mail.pas.earthlink.net (stork.mail.pas.earthlink.net [207.217.120.188]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6004743FBD for ; Wed, 16 Apr 2003 20:24:03 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0039.cvx40-bradley.dialup.earthlink.net ([216.244.42.39] helo=mindspring.com) by stork.mail.pas.earthlink.net with asmtp (SSLv3:RC4-MD5:128) (Exim 3.33 #1) id 19600G-0000FZ-00; Wed, 16 Apr 2003 20:24:01 -0700 Message-ID: <3E9E1E00.E59E090B@mindspring.com> Date: Wed, 16 Apr 2003 20:22:40 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: "Alastair G. Hogge" References: <200304171136.57515.agh@tpg.com.au> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-ELNK-Trace: b1a02af9316fbb217a47c185c03b154d40683398e744b8a48534a8a8ca45d2573c460b743380cefb350badd9bab72f9c350badd9bab72f9c350badd9bab72f9c cc: freebsd-current@FreeBSD.ORG Subject: Re: Auto kernel module loading X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Apr 2003 03:24:06 -0000 "Alastair G. Hogge" wrote: > Hello list, > > Just the other day I was configuring/striping my kernel to the barest I could > manage. I was doing this to hopefully reduce kernel build time. > > Now after adding 60 lines to loader.conf to load the modules I need, I began > thinking is there a way for FreeBSD to load the modules automaticly at boot > time itself? No. > If not, would be hard to implement such a feature? How would someone go about > doing such a thing? As I would be happy to give it a go....but don't know > where to start. It would not be too hard. You could implement seperate sections in the modules for the probe routines, and then load the section seperately, only loading the module itself if it probed true. Most likely, you would want to reuse the same area of memory for each of the seperate probe routines, to avoid fragging kernel memory (any more than it already frags itself). If you felt that were too much work, you could implement a seperate data section with PCI ID and other information. You could probably fit each and every one into a single 4K page in each individual driver. This would probably cover most of the drivers that you would ever have to worry about seeing be actively needed. > Does the documentation project have some info to help? I'm cvsup-ing them > right now as I once recall seeing an article titled something like > "Programmers guide to FreeBSD" www.freebsd.org, under documentation. It has a link to the programmers guide, online. -- Terry