Subject: Re: Time to fix a 25 year old misdesign
To: NetBSD Kernel Technical Discussion List <tech-kern@NetBSD.ORG>
From: Lennart Augustsson <>
List: tech-kern
Date: 10/17/2000 23:16:33
"Greg A. Woods" wrote:

> > I know you think this design is broken, but I don't.  And it's also something
> > we need if we want to have a working Linux emulation.  (That's may not
> > be the greatest of reasons, I agree. :)
> If Linux emulation requires SIGIO then choose the second option,
> otherwise choose the first and get rid of this nasty hack completely.

I repeat again: I'm not interested in SIGIO and I don't know if Linux
emulation requires it.  But Linux emulation does seem to require that
you can open a device independently for read and write.  This cannot
be implemented with the current device driver API.
Being able to open for read and write independently is my reason for
wanting the redesign.  I just brought up SIGIO as an example of another
thing that is flawed in the current design, and that could be done right
if the driver was informed of all added and deleted references.

> Then once that's done it should be a simple matter of providing separate
> minor devices for logically separate functionality so that those parts
> of the driver which wish to force exclusive access to a single process
> and/or its children can do so without interfering with other similar
> parts.

Well, unfortunately we are stuck with the way devices like audio works
for backwards compatibility reasons.
You should have made sure we got it right in the first place. :)


        -- Lennart