From owner-freebsd-hackers Wed Mar 11 08:01:17 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id IAA29904 for freebsd-hackers-outgoing; Wed, 11 Mar 1998 08:01:17 -0800 (PST) (envelope-from owner-freebsd-hackers@FreeBSD.ORG) Received: from ns1.yes.no (ns1.yes.no [195.119.24.10]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id IAA29893 for ; Wed, 11 Mar 1998 08:01:09 -0800 (PST) (envelope-from eivind@bitbox.follo.net) Received: from bitbox.follo.net (bitbox.follo.net [194.198.43.36]) by ns1.yes.no (8.8.7/8.8.7) with ESMTP id QAA19636; Wed, 11 Mar 1998 16:01:08 GMT Received: (from eivind@localhost) by bitbox.follo.net (8.8.6/8.8.6) id RAA17876; Wed, 11 Mar 1998 17:01:07 +0100 (MET) Message-ID: <19980311170107.44621@follo.net> Date: Wed, 11 Mar 1998 17:01:07 +0100 From: Eivind Eklund To: "Justin T. Gibbs" Cc: hackers@FreeBSD.ORG Subject: Re: userconfig data -> linker set -> ELF segment References: <19980311162228.43166@follo.net> <199803111530.IAA13420@pluto.plutotech.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.89.1i In-Reply-To: <199803111530.IAA13420@pluto.plutotech.com>; from Justin T. Gibbs on Wed, Mar 11, 1998 at 08:27:13AM -0700 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Wed, Mar 11, 1998 at 08:27:13AM -0700, Justin T. Gibbs wrote: > > * Loading 'just the probe code' isn't possible using a.out > > (AFAIK) > > * Depending on device drivers being LKMs lowers reliability (N > > files that can fail, instead of just having a single kernel) > > Then provide a mechanism to have the driver entry point also called when > linked statically. This sound like the following would be about right: for device in (static set of devices) find driver for in (linker set of drivers) call driver callback with info on device endfor show userconfig with devices registered by register_device #ifdef REALLY_CORRECT_SYSTEM_NOT_YET for each bus call probes endfor show userconfig again for each bus call attach endfor #else for each bus call probes call attach endfor #endif driver callback: call register_device for device, with suitable description etc. For the LKM case, the load-function would call register_device, and (possibly) force a re-probe. Does that sound right to you? The above actually sounds like it might be something that is reasonably quick to implement, and it would both solve my problem (creating an enabling technology for externally developed drivers in a fairly short time horizont) and be an enabling technology for further development (good handling of LKMs with a longer time horizon.) Only tradeoff: Old device drivers/LKMs Will Not Work, as they don't register themselves properly. This might be solvable (e.g, by scanning the present linker sets). Eivind. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message