From: NeilBrown Date: Thu, 9 Nov 2006 01:44:48 +0000 (-0800) Subject: [PATCH] md: fix sizing problem with raid5-reshape and CONFIG_LBD=n X-Git-Tag: v2.6.19-rc6~55 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=0692c6b1cf5537b190f90fb5903f1af89a41b0a8;p=linux-2.6-omap-h63xx.git [PATCH] md: fix sizing problem with raid5-reshape and CONFIG_LBD=n I forgot to has the size-in-blocks to (loff_t) before shifting up to a size-in-bytes. Signed-off-by: Neil Brown Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c index e14f4578072..69c3e201fa3 100644 --- a/drivers/md/raid5.c +++ b/drivers/md/raid5.c @@ -3659,7 +3659,7 @@ static void end_reshape(raid5_conf_t *conf) bdev = bdget_disk(conf->mddev->gendisk, 0); if (bdev) { mutex_lock(&bdev->bd_inode->i_mutex); - i_size_write(bdev->bd_inode, conf->mddev->array_size << 10); + i_size_write(bdev->bd_inode, (loff_t)conf->mddev->array_size << 10); mutex_unlock(&bdev->bd_inode->i_mutex); bdput(bdev); }