Subject: RE: PCIC interrupt selection
To: None <port-i386@netbsd.org>
From: Harald Bjoroy <harald@bitcon.no>
List: port-i386
Date: 08/11/1998 18:14:02
Hi again.

I don't know if this helps you with some new ideas and new thinking, but
we should also maybe see to what Windows NT does.

Firstly I have to arrest myself on what I said about IO.SYS and
MSDOS.SYS (before someone flames me to death); io.sys is a binary file
and msdos.sys is the parameters for this file, but still; this is not
the same as "good old msdos."

Windows NT stores all driver information in the registry, and has a
concept of dependencies.

Note: This info may be inaccurate, but maybe some concepts can be stolen
to create a new model for NetBSD?

When NT boots, the process SERVICES.EXE loads all services (which means
daemons and drivers) by fetching the info from registry. It starts
drivers with different priorities. First it stars drivers with "boot"
priority, then it continues to "system" and then "automatic" drivers.
Some drivers can start other drivers marked "manual".

When a driver is started, SERVICES.EXE first starts all the drivers this
driver is dependent of. As an example, when SERMOUSE is to be started,
SERVICES.EXE first starts "SERIAL", then (if successful) SERMOUSE is
started.

When you install a 3Com Etherlink III card on NT, you have to specify
which bus it is on, one reason probably being that the OS has to know
which driver it is dependent of, since the same driver is used for ISA
and PCMCIA Etherlink III.

Maybe it is possible to introduce a dependency concept in NetBSD? a
global structure holds info on which drivers are started and which is
not, and which resources has been claimed by the started devices?

When configuring the kernel, you could have an option for noting
dependencies.

One easy way for the startup would be to iterate repeatedly through the
list of drivers, starting the ones with all dependent drivers started,
start over until all dependencies are solved or until no more
dependencies can be solved; all the time tracking information in an
helper structure.

Just some ideas;

Harald Bjoroy.

[snip: my previous message + what I commented on]