|
|
2c1b57 |
commit 5c5ea85b4deedf5e7491a905bbb4f4a3bc284f2c
|
|
|
2c1b57 |
Author: Alexey Obitotskiy <aleksey.obitotskiy@intel.com>
|
|
|
2c1b57 |
Date: Tue May 9 12:25:43 2017 +0200
|
|
|
2c1b57 |
|
|
|
2c1b57 |
imsm: allow drives in a container regardless of sector size
|
|
|
2c1b57 |
|
|
|
2c1b57 |
IMSM doesn't allow to create arrays including drives with different
|
|
|
2c1b57 |
sector sizes. The initial idea was not to permit to combine drives
|
|
|
2c1b57 |
with different sector size in the same container. The problem is it
|
|
|
2c1b57 |
only worked for array creation. On array assemble there are no
|
|
|
2c1b57 |
calls to metadata handlers to see if drive is suitable for a container
|
|
|
2c1b57 |
(e.g. as a spare) and it leads to wrong configuration.
|
|
|
2c1b57 |
|
|
|
2c1b57 |
Revert the change and allow adding drives with different sector size
|
|
|
2c1b57 |
to the container.
|
|
|
2c1b57 |
|
|
|
2c1b57 |
Signed-off-by: Alexey Obitotskiy <aleksey.obitotskiy@intel.com>
|
|
|
2c1b57 |
Signed-off-by: Tomasz Majchrzak <tomasz.majchrzak@intel.com>
|
|
|
2c1b57 |
Signed-off-by: Jes Sorensen <jsorensen@fb.com>
|
|
|
2c1b57 |
|
|
|
2c1b57 |
diff --git a/super-intel.c b/super-intel.c
|
|
|
2c1b57 |
index e13c940..2a5d848 100644
|
|
|
2c1b57 |
--- a/super-intel.c
|
|
|
2c1b57 |
+++ b/super-intel.c
|
|
|
2c1b57 |
@@ -5716,12 +5716,6 @@ static int add_to_super_imsm(struct supertype *st, mdu_disk_info_t *dk,
|
|
|
2c1b57 |
if (super->sector_size == 0) {
|
|
|
2c1b57 |
/* this a first device, so sector_size is not set yet */
|
|
|
2c1b57 |
super->sector_size = member_sector_size;
|
|
|
2c1b57 |
- } else if (member_sector_size != super->sector_size) {
|
|
|
2c1b57 |
- pr_err("Mixing between different sector size is forbidden, aborting...\n");
|
|
|
2c1b57 |
- if (dd->devname)
|
|
|
2c1b57 |
- free(dd->devname);
|
|
|
2c1b57 |
- free(dd);
|
|
|
2c1b57 |
- return 1;
|
|
|
2c1b57 |
}
|
|
|
2c1b57 |
|
|
|
2c1b57 |
/* clear migr_rec when adding disk to container */
|