From 03338d798c929d8df4a11b01191248ba32cebad2 Mon Sep 17 00:00:00 2001 From: Michal Mielewczyk Date: Mon, 17 Mar 2025 12:29:20 +0100 Subject: [PATCH] detach pipeline: remove unused completion The completion callback is called only in the cache stop scenario, after flushing the metadata Signed-off-by: Michal Mielewczyk --- src/mngt/ocf_mngt_cache.c | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/src/mngt/ocf_mngt_cache.c b/src/mngt/ocf_mngt_cache.c index da41f51..105353e 100644 --- a/src/mngt/ocf_mngt_cache.c +++ b/src/mngt/ocf_mngt_cache.c @@ -3875,18 +3875,6 @@ static void ocf_mngt_cache_detach_update_metadata(ocf_pipeline_t pipeline, ocf_pipeline_next(context->pipeline); } -static void ocf_mngt_cache_detach_unplug_complete(void *priv, int error) -{ - struct ocf_mngt_cache_unplug_context *context = priv; - - if (error) { - ENV_BUG_ON(error != -OCF_ERR_WRITE_CACHE); - context->cache_write_error = error; - } - - ocf_pipeline_next(context->pipeline); -} - static void ocf_mngt_cache_detach_deinit_services(ocf_pipeline_t pipeline, void *priv, ocf_pipeline_arg_t arg) { @@ -3896,8 +3884,7 @@ static void ocf_mngt_cache_detach_deinit_services(ocf_pipeline_t pipeline, ENV_BUG_ON(cache->conf_meta->dirty_flushed == DIRTY_NOT_FLUSHED); _ocf_mngt_cache_deinit_services(cache, false, - &context->deinit_services_context, - ocf_mngt_cache_detach_unplug_complete, context); + &context->deinit_services_context, NULL, context); } static void ocf_mngt_cache_detach_finish(ocf_pipeline_t pipeline,