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) d...@newsguy.com d...@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 majord...@freebsd.org with "unsubscribe freebsd-hackers" in the body of the message