1 Star 0 Fork 10

jinlun/dim_9

forked from src-openEuler/dim 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
backport-Dont-queue-measurement-task-when-baseline-failed.patch 1.02 KB
一键复制 编辑 原始数据 按行查看 历史
jinlun 提交于 2024-04-16 10:12 . backport some patches
From 6617fb034f69009893c33c8dd6b4e1485b77800f Mon Sep 17 00:00:00 2001
From: Huaxin Lu <luhuaxin1@huawei.com>
Date: Wed, 14 Feb 2024 13:21:27 +0800
Subject: [PATCH 17/26] Dont queue measurement task when baseline failed
---
src/core/dim_core_measure.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/src/core/dim_core_measure.c b/src/core/dim_core_measure.c
index 4ccbd0c..ff134e5 100644
--- a/src/core/dim_core_measure.c
+++ b/src/core/dim_core_measure.c
@@ -120,6 +120,10 @@ static void measure_work_cb(struct work_struct *work)
static void baseline_work_cb(struct work_struct *work)
{
dim_measure_task_measure(DIM_BASELINE, &dim_core_handle);
+ /* if baseline is failed, dont perform measurement */
+ if (dim_measure_status_error(&dim_core_handle))
+ return;
+
queue_delayed_measure_work();
}
@@ -244,4 +248,4 @@ void dim_core_measure_destroy(void)
dim_measure_destroy(&dim_core_handle);
dim_core_policy_destroy();
mutex_unlock(&dim_core_measure_lock);
-}
\ No newline at end of file
+}
--
2.33.0
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/jinlun123123/dim_9.git
git@gitee.com:jinlun123123/dim_9.git
jinlun123123
dim_9
dim_9
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385