md: add 'size' as a personality method
authorDan Williams <dan.j.williams@intel.com>
Wed, 18 Mar 2009 01:10:40 +0000 (18:10 -0700)
committerDan Williams <dan.j.williams@intel.com>
Tue, 31 Mar 2009 03:57:49 +0000 (14:57 +1100)
commit80c3a6ce4ba4470379b9e6a4d9bcd9d2ee26ae03
treede88622f05a7e681ac7bff7714e8f2d8953b66ac
parent93ed05e2a56b5ee06c0100a169433b11c4aa5d0b
md: add 'size' as a personality method

In preparation for giving userspace control over ->array_sectors we need
to be able to retrieve the 'default' size, and the 'anticipated' size
when a reshape is requested.  For personalities that do not reshape emit
a warning if anything but the default size is requested.

In the raid5 case we need to update ->previous_raid_disks to make the
new 'default' size available.

Reviewed-by: Andre Noll <maan@systemlinux.org>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
drivers/md/faulty.c
drivers/md/linear.c
drivers/md/md.h
drivers/md/multipath.c
drivers/md/raid0.c
drivers/md/raid1.c
drivers/md/raid10.c
drivers/md/raid5.c