Lines Matching refs:cache_size
802 dm_cblock_t cache_size;
1118 clear_bitset(mq->cache_hit_bits, from_cblock(mq->cache_size));
1138 return from_cblock(mq->cache_size) * p / 100u;
1164 nr_free = from_cblock(mq->cache_size) - mq->cache_alloc.nr_allocated;
1732 __smq_create(dm_cblock_t cache_size, sector_t origin_size, sector_t cache_block_size,
1744 mq->cache_size = cache_size;
1747 calc_hotspot_params(origin_size, cache_block_size, from_cblock(cache_size),
1752 if (space_init(&mq->es, total_sentinels + mq->nr_hotspot_blocks + from_cblock(cache_size))) {
1770 total_sentinels + mq->nr_hotspot_blocks + from_cblock(cache_size));
1779 if (from_cblock(cache_size)) {
1780 mq->cache_hit_bits = alloc_bitset(from_cblock(cache_size));
1785 clear_bitset(mq->cache_hit_bits, from_cblock(mq->cache_size));
1795 from_cblock(mq->cache_size) / mq->cache_blocks_per_hotspot_block);
1803 if (h_init(&mq->table, &mq->es, from_cblock(cache_size)))
1840 static struct dm_cache_policy *smq_create(dm_cblock_t cache_size,
1844 return __smq_create(cache_size, origin_size, cache_block_size,
1848 static struct dm_cache_policy *mq_create(dm_cblock_t cache_size,
1852 return __smq_create(cache_size, origin_size, cache_block_size,
1856 static struct dm_cache_policy *cleaner_create(dm_cblock_t cache_size,
1860 return __smq_create(cache_size, origin_size, cache_block_size,