Re: cciss update [2/2] fixes for Steeleye Lifekeeper
From: James Bottomley
Date: Fri Oct 15 2004 - 10:17:48 EST
On Thu, 2004-10-14 at 13:39, Christoph Hellwig wrote:
> Such a volume has been configured and set up, and although it's still
> ugly I'd say it's okay. But the patch also adds one gendisk per controller
> even if no volume is set up.
That's this bit of code:
@@ -2762,7 +2810,9 @@ static int __devinit cciss_init_one(stru
disk->fops = &cciss_fops;
disk->queue = hba[i]->queue;
disk->private_data = drv;
- if( !(drv->nr_blocks))
+ /* we must register the controller even if no disks
exist */
+ /* this is for the online array utilities */
+ if(!drv->heads && j)
continue;
blk_queue_hardsect_size(hba[i]->queue, drv->block_size);
set_capacity(disk, drv->nr_blocks);
Mike, is there a way we can only allocate a gendisk when we know there's
actually a device there (if owned by another controller currently)?
James
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/