remove metadata updater
Signed-off-by: Adam Rutkowski <adam.j.rutkowski@intel.com>
This commit is contained in:
committed by
Kozlowski Mateusz
parent
953e0f25d7
commit
f589341c9a
@@ -26,7 +26,6 @@
|
||||
#include "cleaning/acp.h"
|
||||
#include "promotion/nhit.h"
|
||||
#include "ocf_metadata.h"
|
||||
#include "ocf_metadata_updater.h"
|
||||
#include "ocf_io_class.h"
|
||||
#include "ocf_stats.h"
|
||||
#include "ocf_mngt.h"
|
||||
|
||||
@@ -159,39 +159,15 @@ struct ocf_cleaner_ops {
|
||||
void (*stop)(ocf_cleaner_t c);
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Metadata updater operations
|
||||
*/
|
||||
struct ocf_metadata_updater_ops {
|
||||
/**
|
||||
* @brief Initialize metadata updater.
|
||||
*
|
||||
* This function should create worker, thread, timer or any other
|
||||
* mechanism responsible for calling metadata updater routine.
|
||||
*
|
||||
* @param[in] mu Handle to metadata updater to be initialized
|
||||
*
|
||||
* @retval 0 Metadata updater has been initializaed successfully
|
||||
* @retval Non-zero I/O queue initialization failure
|
||||
*/
|
||||
int (*init)(ocf_metadata_updater_t mu);
|
||||
typedef struct ocf_persistent_meta_zone *ocf_persistent_meta_zone_t;
|
||||
|
||||
/**
|
||||
* @brief Kick metadata updater processing
|
||||
*
|
||||
* This function should inform worker, thread or any other mechanism,
|
||||
* that there are new metadata requests to be processed.
|
||||
*
|
||||
* @param[in] mu Metadata updater to be kicked
|
||||
*/
|
||||
void (*kick)(ocf_metadata_updater_t mu);
|
||||
|
||||
/**
|
||||
* @brief Stop metadata updater
|
||||
*
|
||||
* @param[in] mu Metadata updater beeing stopped
|
||||
*/
|
||||
void (*stop)(ocf_metadata_updater_t mu);
|
||||
struct ocf_persistent_metadata_ops {
|
||||
ocf_persistent_meta_zone_t (*init)(ocf_cache_t cache, size_t size,
|
||||
bool *load);
|
||||
int (*deinit)(ocf_persistent_meta_zone_t zone);
|
||||
void *(*alloc)(ocf_persistent_meta_zone_t zone, size_t size,
|
||||
int alloc_id, bool *load);
|
||||
int (*free)(ocf_persistent_meta_zone_t zone, int alloc_id, void *ptr);
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -204,9 +180,6 @@ struct ocf_ctx_ops {
|
||||
/* Cleaner operations */
|
||||
struct ocf_cleaner_ops cleaner;
|
||||
|
||||
/* Metadata updater operations */
|
||||
struct ocf_metadata_updater_ops metadata_updater;
|
||||
|
||||
/* Logger operations */
|
||||
struct ocf_logger_ops logger;
|
||||
};
|
||||
|
||||
@@ -1,50 +0,0 @@
|
||||
/*
|
||||
* Copyright(c) 2012-2021 Intel Corporation
|
||||
* SPDX-License-Identifier: BSD-3-Clause-Clear
|
||||
*/
|
||||
|
||||
#ifndef __OCF_METADATA_UPDATER_H__
|
||||
#define __OCF_METADATA_UPDATER_H__
|
||||
|
||||
/**
|
||||
* @file
|
||||
* @brief OCF metadata updater API
|
||||
*
|
||||
*/
|
||||
|
||||
/**
|
||||
* @brief Run metadata updater
|
||||
*
|
||||
* @param[in] mu Metadata updater instance to run
|
||||
*
|
||||
* @retval Hint if there is need to rerun without waiting.
|
||||
*/
|
||||
uint32_t ocf_metadata_updater_run(ocf_metadata_updater_t mu);
|
||||
|
||||
/**
|
||||
* @brief Set metadata updater private data
|
||||
*
|
||||
* @param[in] c Metadata updater handle
|
||||
* @param[in] priv Private data
|
||||
*/
|
||||
void ocf_metadata_updater_set_priv(ocf_metadata_updater_t mu, void *priv);
|
||||
|
||||
/**
|
||||
* @brief Get metadata updater private data
|
||||
*
|
||||
* @param[in] c Metadata updater handle
|
||||
*
|
||||
* @retval Metadata updater private data
|
||||
*/
|
||||
void *ocf_metadata_updater_get_priv(ocf_metadata_updater_t mu);
|
||||
|
||||
/**
|
||||
* @brief Get cache instance to which metadata updater belongs
|
||||
*
|
||||
* @param[in] c Metadata updater handle
|
||||
*
|
||||
* @retval Cache instance
|
||||
*/
|
||||
ocf_cache_t ocf_metadata_updater_get_cache(ocf_metadata_updater_t mu);
|
||||
|
||||
#endif /* __OCF_METADATA_UPDATER_H__ */
|
||||
Reference in New Issue
Block a user