[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070222165123.GC2672@beardog.cca.cpqcorp.net>
Date: Thu, 22 Feb 2007 10:51:23 -0600
From: "Mike Miller (OS Dev)" <mikem@...rdog.cca.cpqcorp.net>
To: Andrew Morton <akpm@...ux-foundation.org>
Cc: mike.miller@...com, jens.axboe@...cle.com,
linux-kernel@...r.kernel.org, linux-scsi@...r.kernel.org,
gregkh@...ell.com
Subject: Re: [Patch 1/2] cciss: fix for 2TB support
On Wed, Feb 21, 2007 at 07:14:27PM -0800, Andrew Morton wrote:
> On Wed, 21 Feb 2007 15:10:39 -0600 "Mike Miller (OS Dev)" <mikem@...rdog.cca.cpqcorp.net> wrote:
>
> > Patch 1/2
> >
> > This patch changes the way we determine if a logical volume is larger than 2TB. The
> > original test looked for a total_size of 0. Originally we added 1 to the total_size.
> > That would make our read_capacity return size 0 for >2TB lv's. We assumed that we
> > could not have a lv size of 0 so it seemed OK until we were in a clustered system. The
> > backup node would see a size of 0 due to the reservation on the drive. That caused
> > the driver to switch to 16-byte CDB's which are not supported on older controllers.
> > After that everything was broken.
> > It may seem petty but I don't see the value in trying to determine if the LBA is
> > beyond the 2TB boundary. That's why when we switch we use 16-byte CDB's for all
> > read/write operations.
> > Please consider this for inclusion.
> >
> > ...
> >
> > + if (total_size == 0xFFFFFFFF) {
>
> I seem to remember having already questioned this. total_size is sector_t, which
> can be either 32-bit or 64-bit. Are you sure that comparison works as
> intended in both cases?
>
>
> > + if(total_size == 0xFFFFFFFF) {
> > cciss_read_capacity_16(cntl_num, i, 0,
> > &total_size, &block_size);
> > hba[cntl_num]->cciss_read = CCISS_READ_16;
>
> Here too.
It has worked in all of the configs I've tested. Should I change it from sector_t to a
__64? I have not tested all possible configs.
-- mikem
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists