diff options
author | Ingo Molnar <mingo@kernel.org> | 2014-07-28 08:03:00 (GMT) |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2014-07-28 08:03:00 (GMT) |
commit | ca5bc6cd5de5b53eb8fd6fea39aa3fe2a1e8c3d9 (patch) | |
tree | 75beaae2d4b6bc654eb28994dd5906d8dcf5ef46 /drivers/md/dm-thin-metadata.c | |
parent | c1221321b7c25b53204447cff9949a6d5a7ddddc (diff) | |
parent | d8d28c8f00e84a72e8bee39a85835635417bee49 (diff) | |
download | linux-ca5bc6cd5de5b53eb8fd6fea39aa3fe2a1e8c3d9.tar.xz |
Merge branch 'sched/urgent' into sched/core, to merge fixes before applying new changes
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'drivers/md/dm-thin-metadata.c')
-rw-r--r-- | drivers/md/dm-thin-metadata.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/md/dm-thin-metadata.c b/drivers/md/dm-thin-metadata.c index b086a94..e9d33ad 100644 --- a/drivers/md/dm-thin-metadata.c +++ b/drivers/md/dm-thin-metadata.c @@ -613,6 +613,15 @@ static int __open_metadata(struct dm_pool_metadata *pmd) disk_super = dm_block_data(sblock); + /* Verify the data block size hasn't changed */ + if (le32_to_cpu(disk_super->data_block_size) != pmd->data_block_size) { + DMERR("changing the data block size (from %u to %llu) is not supported", + le32_to_cpu(disk_super->data_block_size), + (unsigned long long)pmd->data_block_size); + r = -EINVAL; + goto bad_unlock_sblock; + } + r = __check_incompat_features(disk_super, pmd); if (r < 0) goto bad_unlock_sblock; |