]> git.baikalelectronics.ru Git - kernel.git/commit
md: add feature flag MD_FEATURE_RAID0_LAYOUT
authorNeilBrown <neilb@suse.de>
Mon, 9 Sep 2019 06:52:29 +0000 (16:52 +1000)
committerSong Liu <songliubraving@fb.com>
Fri, 13 Sep 2019 20:10:06 +0000 (13:10 -0700)
commit85d9dc37ed90f2c5f2534527e9dd9c47c2ae4669
treebb6125970eda98dfc945d1060cfe91ea676f4f7e
parent4bb46cf9a8adfe0a621b7343ebd780d0c0dd3001
md: add feature flag MD_FEATURE_RAID0_LAYOUT

Due to a bug introduced in Linux 3.14 we cannot determine the
correctly layout for a multi-zone RAID0 array - there are two
possibilities.

It is possible to tell the kernel which to chose using a module
parameter, but this can be clumsy to use.  It would be best if
the choice were recorded in the metadata.
So add a feature flag for this purpose.
If it is set, then the 'layout' field of the superblock is used
to determine which layout to use.

If this flag is not set, then mddev->layout gets set to -1,
which causes the module parameter to be required.

Acked-by: Guoqing Jiang <guoqing.jiang@cloud.ionos.com>
Signed-off-by: NeilBrown <neilb@suse.de>
Signed-off-by: Song Liu <songliubraving@fb.com>
drivers/md/md.c
drivers/md/raid0.c
include/uapi/linux/raid/md_p.h