Re: another IDE cleanup: kill duplicated code

From: Martin Dalecki (dalecki@evision-ventures.com)
Date: Tue Feb 12 2002 - 05:52:35 EST


Pavel Machek wrote:

>Hi!
>
>This is slightly longer but also simple cleanup. It kills code
>duplication and removes unneccessary assignments/casts. Please apply,
>
>
If you are already at it, I would like to ask to you consider seriously
the removal of the
following entries in the ide drivers /proc control files:

    ide_add_setting(drive, "breada_readahead", ... 1,
2, &read_ahead[major], NULL);
    ide_add_setting(drive, "file_readahead", ...
&max_readahead[major][minor], NULL);

Those calls can be found in ide-cd.c, ide-disk,c and ide-floppy.c

The first does control an array of values, which doesn't make sense in
first place. I.e. changing it doesn't
change ANY behaviour of the kernel.

The second of them is trying to control a file-system level constant
inside the actual block device driver.
This is a blatant violation of the layering principle in software
design, and should go as soon as
possible.

BTW.> The wole IDE /proc stuff found there makes me vommit...
Both in terms of interface and in terms of coding style.
Apparently Andre Hendrick doesn't know what ioctrl are about and is
missing the windows
registry greatly.

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



This archive was generated by hypermail 2b29 : Fri Feb 15 2002 - 21:00:48 EST