Just to be consistent with existing naming we use.
# be placed on different PVs from the pool data.
thin_pool_metadata_require_separate_pvs = 0
- # Specify chunk size calculation method for thin pool volumes.
+ # Specify chunk size calculation policy for thin pool volumes.
# Possible options are:
- # "default" - if thin_pool_chunk_size is defined, use it.
+ # "generic" - if thin_pool_chunk_size is defined, use it.
# Otherwise, calcucate the chunk size based on
# estimation and device hints exposed in sysfs:
# the minimum_io_size. The chunk size is always
# performance based on device hints exposed in
# sysfs: the optimal_io_size. The chunk size is
# always at least 512KiB.
- # thin_pool_chunk_size_calculation = "default"
+ # thin_pool_chunk_size_policy = "generic"
# Specify the minimal chunk size (in KB) for thin pool volumes.
# Use of the larger chunk size may improve perfomance for plain
cfg(allocation_thin_pool_metadata_require_separate_pvs_CFG, "thin_pool_metadata_require_separate_pvs", allocation_CFG_SECTION, 0, CFG_TYPE_BOOL, DEFAULT_THIN_POOL_METADATA_REQUIRE_SEPARATE_PVS, vsn(2, 2, 89), NULL)
cfg(allocation_thin_pool_zero_CFG, "thin_pool_zero", allocation_CFG_SECTION, CFG_PROFILABLE, CFG_TYPE_BOOL, DEFAULT_THIN_POOL_ZERO, vsn(2, 2, 99), NULL)
cfg(allocation_thin_pool_discards_CFG, "thin_pool_discards", allocation_CFG_SECTION, CFG_PROFILABLE, CFG_TYPE_STRING, DEFAULT_THIN_POOL_DISCARDS, vsn(2, 2, 99), NULL)
-cfg(allocation_thin_pool_chunk_size_calculation_CFG, "thin_pool_chunk_size_calculation", allocation_CFG_SECTION, CFG_PROFILABLE, CFG_TYPE_STRING, DEFAULT_THIN_POOL_CHUNK_SIZE_CALCULATION, vsn(2, 2, 101), NULL)
+cfg(allocation_thin_pool_chunk_size_policy_CFG, "thin_pool_chunk_size_policy", allocation_CFG_SECTION, CFG_PROFILABLE, CFG_TYPE_STRING, DEFAULT_THIN_POOL_CHUNK_SIZE_POLICY, vsn(2, 2, 101), NULL)
cfg(allocation_thin_pool_chunk_size_CFG, "thin_pool_chunk_size", allocation_CFG_SECTION, CFG_PROFILABLE, CFG_TYPE_INT, 0, vsn(2, 2, 99), NULL)
#define DEFAULT_THIN_POOL_MAX_METADATA_SIZE (16 * 1024 * 1024) /* KB */
#define DEFAULT_THIN_POOL_MIN_METADATA_SIZE 2048 /* KB */
#define DEFAULT_THIN_POOL_OPTIMAL_SIZE (128 * 1024 * 1024) /* KB */
-#define DEFAULT_THIN_POOL_CHUNK_SIZE_CALCULATION "default"
+#define DEFAULT_THIN_POOL_CHUNK_SIZE_POLICY "generic"
#define DEFAULT_THIN_POOL_CHUNK_SIZE 64 /* KB */
#define DEFAULT_THIN_POOL_CHUNK_SIZE_PERFORMANCE 512 /* KB */
#define DEFAULT_THIN_POOL_DISCARDS "passdown"
int activation_skip; /* activation skip flags */
activation_change_t activate; /* non-snapshot, non-mirror */
thin_discards_t discards; /* thin */
-#define THIN_CHUNK_SIZE_CALC_METHOD_DEFAULT 0x01
+#define THIN_CHUNK_SIZE_CALC_METHOD_GENERIC 0x01
#define THIN_CHUNK_SIZE_CALC_METHOD_PERFORMANCE 0x02
int thin_chunk_size_calc_method;
int *chunk_size_calc_method,
uint32_t *chunk_size)
{
- if (!strcasecmp(str, "default")) {
- *chunk_size_calc_method = THIN_CHUNK_SIZE_CALC_METHOD_DEFAULT;
+ if (!strcasecmp(str, "generic")) {
+ *chunk_size_calc_method = THIN_CHUNK_SIZE_CALC_METHOD_GENERIC;
*chunk_size = DEFAULT_THIN_POOL_CHUNK_SIZE * 2;
}
else if (!strcasecmp(str, "performance")) {
if (!(passed_args & PASS_ARG_CHUNK_SIZE)) {
if (!(*chunk_size = find_config_tree_int(cmd, allocation_thin_pool_chunk_size_CFG, profile) * 2)) {
- str = find_config_tree_str(cmd, allocation_thin_pool_chunk_size_calculation_CFG, profile);
+ str = find_config_tree_str(cmd, allocation_thin_pool_chunk_size_policy_CFG, profile);
if (!_get_pool_chunk_size_calc(str, chunk_size_calc_method, chunk_size))
return_0;
}