Re: I request inclusion of reiser4 in the mainline kernel

Nick Piggin
2005-09-20T04:16:45Z

Hans Reiser wrote:

>So why is the code in the kernel so hard to read then?
>
>Linux kernel code is getting better, and Andrew Morton's code is
>especially good, but for the most part it's unnecessarily hard to read.
>Look at the elevator code for instance. Ugh.
>
>

What's wrong with the elevator code?

The elevator code was one of the first things I got involved with
as a complete kernel newbie, and I was able to follow the current
code well enough to make a new IO scheduler, and extend the
elevator API sufficiently to provide the fairly unique
capabilities I needed.

If it is the elevator *API* you are worried about, that is fairly
trivial and well documented by Jens and myself in
Documentation/block/biodoc.txt, along with an overview of some key
ideas useful for iosched implementors.

as-iosched.c itself is IMO reasonably well commented (at least
the non-trivial, non-boilerplate functions). That is not to say it
is trivial to understand because it is a fairly complex state
machine and heuristics, but at less than 2000 lines of very well
contained code it is not an impossible task to understand it.

If that is too much for you, noop-iosched.c implements a fully
working io scheduler in exactly 94 lines, including whitespace and
comments.

What are your specific concerns? I would be interested in helping
to fix any valid ones you have.

Thanks,
Nick

Send instant messages to your online friends http://au.messenger.yahoo.com