Store PP config params in cache superblock.

It allows to modify and retrieve particular PP params event if it isn't active
and store values between cache stop and load.

Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
This commit is contained in:
Michal Mielewczyk
2019-09-27 02:30:48 -04:00
parent 75569ecaba
commit dfc55538ce
11 changed files with 162 additions and 151 deletions

View File

@@ -814,26 +814,28 @@ ocf_promotion_t ocf_mngt_cache_promotion_get_policy(ocf_cache_t cache);
*
* @param[in] cache Cache handle
* @param[in] param_id Promotion policy parameter id
* @param[in] type Promotion policy type
* @param[in] param_value Promotion policy parameter value
*
* @retval 0 Parameter has been set successfully
* @retval Non-zero Error occurred and parameter has not been set
*/
int ocf_mngt_cache_promotion_set_param(ocf_cache_t cache, uint8_t param_id,
uint32_t param_value);
ocf_promotion_t type, uint32_t param_value);
/**
* @brief Get promotion policy parameter for given cache
*
* @param[in] cache Cache handle
* @param[in] param_id Promotion policy parameter id
* @param[in] type Promotion policy type
* @param[out] param_value Variable to store parameter value
*
* @retval 0 Parameter has been retrieved successfully
* @retval Non-zero Error occurred and parameter has not been retrieved
*/
int ocf_mngt_cache_promotion_get_param(ocf_cache_t cache, uint8_t param_id,
uint32_t *param_value);
ocf_promotion_t type, uint32_t *param_value);
/**
* @brief IO class configuration