Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

md-cluster: change array_sectors and update size are not supported

Currently, some features are not supported yet,
such as change array_sectors and update size, so
return EINVAL for them and listed it in document.

Reviewed-by: NeilBrown <neilb@suse.com>
Signed-off-by: Guoqing Jiang <gqjiang@suse.com>
Signed-off-by: Shaohua Li <shli@fb.com>

authored by

Guoqing Jiang and committed by
Shaohua Li
ab5a98b1 1535212c

+14
+6
Documentation/md-cluster.txt
··· 316 316 nodes are using the raid which is achieved by lock all bitmap 317 317 locks within the cluster, and also those locks are unlocked 318 318 accordingly. 319 + 320 + 7. Unsupported features 321 + 322 + There are somethings which are not supported by cluster MD yet. 323 + 324 + - update size and change array_sectors.
+8
drivers/md/md.c
··· 4817 4817 if (err) 4818 4818 return err; 4819 4819 4820 + /* cluster raid doesn't support change array_sectors */ 4821 + if (mddev_is_clustered(mddev)) 4822 + return -EINVAL; 4823 + 4820 4824 if (strncmp(buf, "default", 7) == 0) { 4821 4825 if (mddev->pers) 4822 4826 sectors = mddev->pers->size(mddev, 0, 0); ··· 6441 6437 struct md_rdev *rdev; 6442 6438 int rv; 6443 6439 int fit = (num_sectors == 0); 6440 + 6441 + /* cluster raid doesn't support update size */ 6442 + if (mddev_is_clustered(mddev)) 6443 + return -EINVAL; 6444 6444 6445 6445 if (mddev->pers->resize == NULL) 6446 6446 return -EINVAL;