1 From: NeilBrown <neilb@suse.de>
2 Subject: Don't fail to start a RAID1 with a small chunksize
6 For a RAID1 array, chunksize is almost meaningless (it is used to
7 round down the device size to a multiple of chunksize, but that is
8 largely of historical interest).
9 However it is possible to set the chunksize, and it is possible to
10 set it to be less than PAGE_SIZE. This currently causes the
11 array to fail to start. However there is no good reason for that.
12 And YaST seems to create RAID1 arrays with a 4K chunks which breaks
13 on PPC-64 machines with 64K pages.
15 So ignore the "chunk_size < PAGE_SIZE" check on RAID1 like we do
18 Signed-off-by: Neil Brown <neilb@suse.de>
21 drivers/md/md.c | 6 +++---
22 1 file changed, 3 insertions(+), 3 deletions(-)
26 @@ -3587,13 +3587,13 @@ static int do_md_run(mddev_t * mddev)
29 if (chunk_size < PAGE_SIZE) {
31 + if (mddev->level != 0 && mddev->level != 1) {
32 printk(KERN_ERR "too small chunk_size: %d < %ld\n",
33 chunk_size, PAGE_SIZE);
36 - printk(KERN_ERR "too small chunk_size: %d < %ld, but continuing anyway on raid0. Good luck!\n",
37 - chunk_size, PAGE_SIZE);
38 + printk(KERN_ERR "too small chunk_size: %d < %ld, but continuing anyway on raid%d. Good luck!\n",
39 + chunk_size, PAGE_SIZE, mddev->level);