Re: [Q]: Linux and real device drivers

David Olofson (audiality@swipnet.se)
Tue, 28 Sep 1999 02:41:50 +0200


On Mon, 27 Sep 1999, Benjamin Scott wrote:
> > - means changes require a greater investment of effort
>
> Good! Linux is all about investing the effort needed to design and
> implement a good system. If someone has to actually put a little thought into
> their code, rather then posting the first thing that compiles, maybe Linux
> will be even better. :-)

Indeed! It has happened more than once that I've discovered design flaws before
just trying to design a nice interface and describe it, before hacking the
code. Doing it the other way around is certainly not a good idea, unless you
*really* know what the whole thing is going to look like from the start...

> As I am fond of saying, "One man's interface is another man's
> implementation."

Well, I've had to do most of my implementations myself so far. Fortunately, my
memory (not the RAM in the box!) is a little unreliable (something to do with
this creative "gift", I guess...), which means I'll learn my lesson if I design
a messy interface...

> > - broken designs stay broken longer
>
> Design changes all the time now in Linux, why should we assume documenting
> code internals will prevent those changes from happening? Documenting things
> may, however, make design flaws more apparent, and/or make updating code to
> work with the new design easier.

And another point: Some brief API documentation might make it easier for more
people to get a more complete overview of the system. I think that can serve as
a quicker way in for new hackers, if nothing else.

> > - and you don't get very far telling volunteers to do things they don't
> > want to
>
> First of all, nobody is suggesting we hire a bunch of kernel police to go
> around and beat-up anybody who doesn't comment their code. What has been
> suggested is some sort of framework to make documenting the kernel easier, and
> then using those docs easier. Frankly, at 60+ megabytes, I think that makes
> sense.
>
> Second: If Linus wants to tell volunteers to do things such-and-such a way,
> he does. And they do so, or they ship out. This is nothing new.

Yeah, there really needs to be some control, or it will all end up in chaos in
the long run. And hacking a few lines of text for a new/modified function call,
structure, or whatever, isn't really all that much work, is it?

(Ahem, quite a few of us tend to hack quite a lot of text in the form of mail,
BTW... :-)

//David

·A·U·D·I·A·L·I·T·Y· P r o f e s s i o n a l L i n u x A u d i o
- - ------------------------------------------------------------- - -
·Rock Solid David Olofson:
·Low Latency www.angelfire.com/or/audiality ·Audio Hacker
·Plug-Ins audiality@swipnet.se ·Linux Advocate
·Open Source ·Singer/Composer

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/