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-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=0692c6b1cf5537b190f90fb5903f1af89a41b0a8;p=linux-beck.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 e14f45780720..69c3e201fa3b 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); }