Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 09 Jul 1999 15:06:09 +0900
From:      "Daniel C. Sobral" <dcs@newsguy.com>
To:        Kelly Yancey <kbyanc@alcnet.com>
Cc:        freebsd-hackers@FreeBSD.ORG
Subject:   Re: new loader question / module question
Message-ID:  <37859151.349BF7DA@newsguy.com>
References:  <Pine.BSF.4.05.9905021557360.35603-100000@kronos.alcnet.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Ok, ok, this message is a few months old, but better late than
never, right? (<-- retorical question, no need to actually answer...
;)

Kelly Yancey wrote:
> 
>   I was working on a module and need to be able to pass parameters to the
> module (preferably without having to compile them in). I noticed that the
> splash module does this (sort of) by having you load the image to display
> and specifying a "tag" for it so that the module can scan for the tag and
> find the image. I need to be able to pass more than a single configuration
> option though. I am considering putting all of the configuration options
> into a single config file, having that loaded into memory by the boot
> loader (much the way the splash module loads it's image) and then when the
> module loads it can scan memory for the configuration information and
> parse it. Is there a better way?

It might not be better, but it's an alternative way. Loader saves
any arguments passed to a module at load time under the tag
MODINFO_ARGS, which can be retrieved (I suppose -- if the kernel
does not junk it somewhere) with preload_search_info().

--
Daniel C. Sobral			(8-DCS)
dcs@newsguy.com
dcs@freebsd.org

	Given infinite time, 100 monkeys could type out the complete works
of Shakespeare.
	Win 98 source code? Eight monkeys, five minutes.




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?37859151.349BF7DA>