diff options
author | Mike Snitzer <snitzer@redhat.com> | 2014-07-14 23:37:18 +0400 |
---|---|---|
committer | Mike Snitzer <snitzer@redhat.com> | 2014-08-01 20:30:33 +0400 |
commit | 895b47d7989af3aacea16380b190b1bb8f046362 (patch) | |
tree | ff1fa6f0a86063b69d09a76acc6d996face2acdc /drivers/md/dm-cache-target.c | |
parent | 304affaa88328fe8f40ff14f5e6ccbfad8f121eb (diff) | |
download | linux-895b47d7989af3aacea16380b190b1bb8f046362.tar.xz |
dm cache metadata: use dm-space-map-metadata.h defined size limits
Commit 7d48935e cleaned up the persistent-data's space-map-metadata
limits by elevating them to dm-space-map-metadata.h. Update
dm-cache-metadata to use these same limits.
The calculation for DM_CACHE_METADATA_MAX_SECTORS didn't account for the
sizeof the disk_bitmap_header. So the supported maximum metadata size
is a bit smaller (reduced from 33423360 to 33292800 sectors).
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Acked-by: Joe Thornber <ejt@redhat.com>
Diffstat (limited to 'drivers/md/dm-cache-target.c')
-rw-r--r-- | drivers/md/dm-cache-target.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/md/dm-cache-target.c b/drivers/md/dm-cache-target.c index 75073c83a4b5..a54108e1e233 100644 --- a/drivers/md/dm-cache-target.c +++ b/drivers/md/dm-cache-target.c @@ -2840,7 +2840,7 @@ static void cache_status(struct dm_target *ti, status_type_t type, residency = policy_residency(cache->policy); DMEMIT("%u %llu/%llu %u %llu/%llu %u %u %u %u %u %u %lu ", - (unsigned)(DM_CACHE_METADATA_BLOCK_SIZE >> SECTOR_SHIFT), + (unsigned)DM_CACHE_METADATA_BLOCK_SIZE, (unsigned long long)(nr_blocks_metadata - nr_free_blocks_metadata), (unsigned long long)nr_blocks_metadata, cache->sectors_per_block, |