diff options
author | Heinz Mauelshagen <heinzm@redhat.com> | 2014-03-27 15:14:10 -0400 |
---|---|---|
committer | Mike Snitzer <snitzer@redhat.com> | 2014-03-27 16:56:23 -0400 |
commit | 64ab346a360a4b15c28fb8531918d4a01f4eabd9 (patch) | |
tree | 7b1902c2b9c5980b7a18ea8f7e7a4cc633911804 /drivers/md/dm-cache-metadata.h | |
parent | d132cc6d9e92424bb9d4fd35f5bd0e55d583f4be (diff) |
dm cache: remove remainder of distinct discard block size
Discard block size not being equal to cache block size causes data
corruption by erroneously avoiding migrations in issue_copy() because
the discard state is being cleared for a group of cache blocks when it
should not.
Completely remove all code that enabled a distinction between the
cache block size and discard block size.
Signed-off-by: Heinz Mauelshagen <heinzm@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'drivers/md/dm-cache-metadata.h')
-rw-r--r-- | drivers/md/dm-cache-metadata.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/md/dm-cache-metadata.h b/drivers/md/dm-cache-metadata.h index cd906f14f98d..ce8468bb616e 100644 --- a/drivers/md/dm-cache-metadata.h +++ b/drivers/md/dm-cache-metadata.h | |||
@@ -72,14 +72,14 @@ dm_cblock_t dm_cache_size(struct dm_cache_metadata *cmd); | |||
72 | 72 | ||
73 | int dm_cache_discard_bitset_resize(struct dm_cache_metadata *cmd, | 73 | int dm_cache_discard_bitset_resize(struct dm_cache_metadata *cmd, |
74 | sector_t discard_block_size, | 74 | sector_t discard_block_size, |
75 | dm_dblock_t new_nr_entries); | 75 | dm_oblock_t new_nr_entries); |
76 | 76 | ||
77 | typedef int (*load_discard_fn)(void *context, sector_t discard_block_size, | 77 | typedef int (*load_discard_fn)(void *context, sector_t discard_block_size, |
78 | dm_dblock_t dblock, bool discarded); | 78 | dm_oblock_t dblock, bool discarded); |
79 | int dm_cache_load_discards(struct dm_cache_metadata *cmd, | 79 | int dm_cache_load_discards(struct dm_cache_metadata *cmd, |
80 | load_discard_fn fn, void *context); | 80 | load_discard_fn fn, void *context); |
81 | 81 | ||
82 | int dm_cache_set_discard(struct dm_cache_metadata *cmd, dm_dblock_t dblock, bool discard); | 82 | int dm_cache_set_discard(struct dm_cache_metadata *cmd, dm_oblock_t dblock, bool discard); |
83 | 83 | ||
84 | int dm_cache_remove_mapping(struct dm_cache_metadata *cmd, dm_cblock_t cblock); | 84 | int dm_cache_remove_mapping(struct dm_cache_metadata *cmd, dm_cblock_t cblock); |
85 | int dm_cache_insert_mapping(struct dm_cache_metadata *cmd, dm_cblock_t cblock, dm_oblock_t oblock); | 85 | int dm_cache_insert_mapping(struct dm_cache_metadata *cmd, dm_cblock_t cblock, dm_oblock_t oblock); |