Re: [PATCH 1/5] md: Make update_size() take the number of sectors. | |
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] | |
On Thursday July 10, maan@xxxxxxxxxxxxxxx wrote: > @@ -4588,7 +4588,7 @@ static int update_array_info(mddev_t *mddev, mdu_array_info_t *info) > return mddev->pers->reconfig(mddev, info->layout, -1); > } > if (info->size >= 0 && mddev->size != info->size) > - rv = update_size(mddev, info->size); > + rv = update_size(mddev, info->size * 2); > > if (mddev->raid_disks != info->raid_disks) > rv = update_raid_disks(mddev, info->raid_disks); I've made this rv = update_size(mddev, (sector_t)info->size * 2); as info->size is an int and without the cast, a size of 2TB (2^31 K) would become 0. Otherwise, it's good. Thanks. NeilBrown -- To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html
[Home] [ATA RAID] [Linux] [Managing RAID on Linux] [Linux IDE] [Linux SCSI] [Linux Hams] [Device-Mapper] [Kernel] [Linux Books] [Linux Admin] [Linux Net] [GFS] [RPM] [Photos] [Yosemite Photos] [Yosemite News] [AMD 64] [Linux Nework]
![]() |