> The whole industry of device drivers seem like a bizarre activity to me.
> Some thought questions:
> 1. Why does a person have to write a different device driver for each
> Unix variant?
Because there is no standard interface?-(
> 2. Why does a person have to reinvent the handling routines for timers,
> and interrupt handling? (Or in my case cut and past from some other
It might look odd, but it makes sense. Windows NT has got a very "clean"
I/O architecture that encapsulates such stuff into DLLs which belong to the
operating system (and can be exchanged for unusual hardware like proprietary
multiprocessor architectures, ...).
This should make it much easier to write device drivers and
to port them across different hardware platforms. But there is a constant
overhead for every I/O operation. If you compare the I/O performance of the
same hardware running NT and running OS/2 or some UNIXes, this seems to have
not been a very good idea.
Microkernel systems like Mach had similiar problems. As far as I know, the
architecture allows to run some driver stuff as a user process, but the Mach
people put much driver stuff into the kernel for performance reasons.
> 3. Wouldn't make a whole lot more sense to write a device
> driver generator - where you feed it a configuration file - and it
> generates the appropriate C driver code with
> the appropriate hardware specific code in the write places...
The same problem as with much other good ideas: Seems to be a good idea, but
someone has to do it. And I'm quite sure that a hand-written driver will
offer much better performance if the programmer writing it knows what he's
Matthias Heidbrink E-Mail:
Helmstedter Str. 20 Matthias_Heidbrink@b.maus.de (max. 16 KB/day)
10717 Berlin, Germany email@example.com
Tel. +49-30-8536361 firstname.lastname@example.org (at work; http://www.carano.com)
Offene Liste Informatik: http://autos.cs.tu-berlin.de/OLI/