1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

cache: use undefined settings for cache_policy

As cache_policy is evaluated in runtime, we no longer should use
CFG_COMMENTED, but have to switch to CFG_UNDEFINED.

So as long as the value is undefined, it's runtime evaluated.
Once it's set - it's always respected (no runtime fallback).

Also fix version of introduced settings to 2.2.128.
This commit is contained in:
Zdenek Kabelac 2015-08-17 11:19:28 +02:00
parent b297d78367
commit d4c024c836

View File

@ -474,13 +474,13 @@ cfg(allocation_cache_mode_CFG, "cache_mode", allocation_CFG_SECTION, CFG_DEFAULT
"writeback - Data blocks are written from the cache back\n"
"to disk after some delay to improve performance.\n")
cfg_runtime(allocation_cache_policy_CFG, "cache_policy", allocation_CFG_SECTION, CFG_PROFILABLE | CFG_DEFAULT_COMMENTED, CFG_TYPE_STRING, vsn(2, 2, 127), 0, NULL,
cfg_runtime(allocation_cache_policy_CFG, "cache_policy", allocation_CFG_SECTION, CFG_PROFILABLE | CFG_DEFAULT_UNDEFINED, CFG_TYPE_STRING, vsn(2, 2, 128), 0, NULL,
"The default cache policy used for new cache volume.\n"
"Generally available policies are: mq, smq.\n"
"mq - Multiqueue policy with 88 bytes per block\n"
"smq - Stochastic multique with 25 bytes per block (kernel >= 4.2).\n")
"For the kernel 4.2 and newer the default policy is smq\n"
"(Stochastic multique), otherwise the older mq (Multiqueue),\n"
"policy is selected.\n")
cfg_section(allocation_cache_settings_CFG_SECTION, "cache_settings", allocation_CFG_SECTION, CFG_PROFILABLE | CFG_DEFAULT_COMMENTED, vsn(2, 2, 127), 0, NULL,
cfg_section(allocation_cache_settings_CFG_SECTION, "cache_settings", allocation_CFG_SECTION, CFG_PROFILABLE | CFG_DEFAULT_COMMENTED, vsn(2, 2, 128), 0, NULL,
"Individual settings for policies.\n"
"See the help for individual policies for more info.\n")