Philosophy 101: The device driver

Philosophy 101: The device driver

Post by Simon Mackinl » Wed, 03 Apr 1996 04:00:00

Here's one that's had me puzzled for a long, long time,
the original old chestnut if you like...

As far as I can make out, the Unix, and Linux philosophy
in the area of device drivers, is to simply provide a
software interface to the hardware in question. This is
substantiated by inspection; the device driver generally
supports data transfer to and from the hardware via
read() and write(), and software hooks to change the
state of said hardware via ioctl().

Now, the level of abstraction _from_ the hardware is
quite minimal; abstraction, and device independance,
is provided with libraries. Libraries can have members
which provide a common software interface for hardware
which may well be dissimilar in implimentation, but
similar in function.

Obviously, if my understanding is incomplete, inaccurate,
or just plain wrong, then the remainder of this post will
be rendered nonsensical; still, I would like to hear about
it, I do want to learn...

Ok, question time, class; Why does Linux's sound driver
seek to encapsulate *all* possible sound hardware in one
device driver?

In my quite possibly ill-informed opinion, Linux _should_
have device driver support for given sound hardware
implemenations, sure - that's what device drivers seem to
be all about. But surely, bundling all sound devices into
one common model, that of dsp, mixer, and sequencer, is
a job for a sound library?

Cheers, I'd really like to see this one thrashed out,
if only for my personal education.


strength through elegance  ///  beauty in intelligence


1. linux ppc and devices kernal version 101

Hello all,

I have gone down the road of trying to get my stylus printing again.
I had to upgrade my kernal to 2.1.101 and I have ghostscript 5.10.

When ever I write anything to the /dev/cua0 device my machine locks
up solid.  I have to power it down.  I mean nothing works after I
write to this device.

So I'm thinking that my devices are not properly created.  This do to
the kernal upgrade and device number changes again.  The MAKEDEV I
have from the LinuxPCC 98 CD simply does not work at all.  I have
followed all the info I could find in order to get it to gen new
devices but I does absolutely nothing.

What I want to do is regenerate all my devices to make sure that they
are all in line with the kernal version I'm running.

Note: Yes my printer is plugged into the printer port.

Any help would be muchly appreciated.

System details that pertain to this problem.
ide 2.0 Gig drive
scsi2.0 Gig drive         ( Never can boot linux off this one. )
stylus 600 printer

Mark Daku

2. port forwarding, firewall issues, tcpdump outputs

3. FEPS Ethernet Driver v1.101 and IEEE 802

4. Linux PC as a X-Terminal

5. Device driver calling another device driver.

6. Csh Programming Considered Harmful

7. Device driver question (generic device driver)

8. IP spoofing- do you need to worry?

9. Q: /proc/driver file philosophy

10. 101 Things you can do I Linux but not in DOS/Win

11. Key Electronics Midiator 101/104

12. Solaris 2.4 flunks Routing 101

13. Problems with 2.1.101 and USMDOS