Re: PS/2 Esdi patch #8

Paul Gortmaker
2001-05-27T00:01:25Z

Jens Axboe wrote:
>
> On Thu, May 24 2001, Paul Gortmaker wrote:
>
> > Probably makes sense for driver to set it regardless, seeing
> > as default (MAX_SECTORS) has changed several times over last
> > few months. At least then it will be under driver control
> > and not at the mercy of some global value.
>
> You might want to assign that max_sect array too, otherwise it's just
> going to waste space :-)

Heh, yes. :)

> Take a look at how ps2esdi handles requests -- always processing just
> the first segment. Alas, it doesn't matter how big the request is.

Well here is the missing line, for completeness, in case somebody
someday gets bored and changes the above behaviour (it won't be me!)

Paul.

--- drivers/block/ps2esdi.c~ Thu May 24 16:33:46 2001
+++ drivers/block/ps2esdi.c Sat May 26 04:47:45 2001
@@ -424,6 +424,7 @@
request_dma(dma_arb_level, "ed");
request_region(io_base, 4, "ed");
blksize_size[MAJOR_NR] = ps2esdi_blocksizes;
+ max_sectors[MAJOR_NR] = ps2esdi_maxsect;

for (i = 0; i < ps2esdi_drives; i++) {
register_disk(&ps2esdi_gendisk,MKDEV(MAJOR_NR,i<<6),1<<6,