!98 [sync] PR-95: etmem: set scan_type optional, and fix sequence of header file
From: @openeuler-sync-bot Reviewed-by: @liubo254 Signed-off-by: @liubo254
This commit is contained in:
commit
ac3ba0c93f
@ -0,0 +1,56 @@
|
||||
From e0703d2fc07f99c184d678d1d33ccf6fa7855d81 Mon Sep 17 00:00:00 2001
|
||||
From: chenrenhui <chenrenhui1@huawei.com>
|
||||
Date: Thu, 15 Aug 2024 20:29:15 +0800
|
||||
Subject: [PATCH] etmem: set scan_type optional, and fix sequence of header file
|
||||
|
||||
Signed-off-by: chenrenhui <chenrenhui1@huawei.com>
|
||||
---
|
||||
etmem/inc/etmemd_inc/etmemd_thirdparty_export.h | 2 +-
|
||||
etmem/src/etmemd_src/etmemd_file.c | 3 +++
|
||||
etmem/src/etmemd_src/etmemd_project.c | 2 +-
|
||||
3 files changed, 5 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/etmem/inc/etmemd_inc/etmemd_thirdparty_export.h b/etmem/inc/etmemd_inc/etmemd_thirdparty_export.h
|
||||
index 9d145ce..6cd8094 100644
|
||||
--- a/etmem/inc/etmemd_inc/etmemd_thirdparty_export.h
|
||||
+++ b/etmem/inc/etmemd_inc/etmemd_thirdparty_export.h
|
||||
@@ -16,8 +16,8 @@
|
||||
#ifndef ETMEM_THIRDPARTY_EXPORT_H
|
||||
#define ETMEM_THIRDPARTY_EXPORT_H
|
||||
|
||||
-#include "etmemd_project_exp.h"
|
||||
#include "etmemd_engine_exp.h"
|
||||
+#include "etmemd_project_exp.h"
|
||||
#include "etmemd_task_exp.h"
|
||||
|
||||
#endif
|
||||
diff --git a/etmem/src/etmemd_src/etmemd_file.c b/etmem/src/etmemd_src/etmemd_file.c
|
||||
index d204685..8e739d0 100644
|
||||
--- a/etmem/src/etmemd_src/etmemd_file.c
|
||||
+++ b/etmem/src/etmemd_src/etmemd_file.c
|
||||
@@ -22,6 +22,9 @@ static int parse_item(GKeyFile *config, char *group_name, struct config_item *it
|
||||
void *val;
|
||||
|
||||
if (!g_key_file_has_key(config, group_name, item->key, NULL)) {
|
||||
+ if (strcmp(item->key, "scan_type") == 0) {
|
||||
+ return item->fill(obj, "page");
|
||||
+ }
|
||||
if (item->option) {
|
||||
return 0;
|
||||
}
|
||||
diff --git a/etmem/src/etmemd_src/etmemd_project.c b/etmem/src/etmemd_src/etmemd_project.c
|
||||
index d1c34f3..4990fdb 100644
|
||||
--- a/etmem/src/etmemd_src/etmemd_project.c
|
||||
+++ b/etmem/src/etmemd_src/etmemd_project.c
|
||||
@@ -716,7 +716,7 @@ static bool check_swapcache_wmark_valid(struct project *proj)
|
||||
|
||||
static struct config_item g_project_config_items[] = {
|
||||
{"name", STR_VAL, fill_project_name, false},
|
||||
- {"scan_type", STR_VAL, fill_project_scan_type, false},
|
||||
+ {"scan_type", STR_VAL, fill_project_scan_type, true},
|
||||
{"sysmem_threshold", INT_VAL, fill_project_sysmem_threshold, true},
|
||||
{"swapcache_high_wmark", INT_VAL, fill_project_swapcache_high_wmark, true},
|
||||
{"swapcache_low_wmark", INT_VAL, fill_project_swapcache_low_wmark, true},
|
||||
--
|
||||
2.45.1.windows.1
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
Name: etmem
|
||||
Version: 1.1
|
||||
Release: 8
|
||||
Release: 9
|
||||
Summary: etmem
|
||||
License: MulanPSL-2.0
|
||||
URL: https://gitee.com/openeuler/etmem
|
||||
@ -13,6 +13,7 @@ Patch0003: 0004-etmem-fix-multiple-etmemd-and-too-many-err-log-probl.patch
|
||||
Patch0004: 0005-etmem-1.1-add-riscv64-support.patch
|
||||
Patch0005: 0006-etmem-fix-project-stop-cmd-timeout-problem.patch
|
||||
Patch0006: 0007-etmem-construct-etmem-debug-info-package.patch
|
||||
Patch0007: 0008-etmem-set-scan_type-optional-and-fix-sequence-of-head.patch
|
||||
|
||||
#Dependency
|
||||
BuildRequires: cmake gcc gcc-c++ glib2-devel
|
||||
@ -69,6 +70,12 @@ install -m 0644 userswap/include/uswap_api.h $RPM_BUILD_ROOT%{_includedir}
|
||||
%postun -p /sbin/ldconfig
|
||||
|
||||
%changelog
|
||||
* Mon Nov 4 2024 chenrenhui <chenrenhui1@huawei.com> - 1.1-9
|
||||
- Type: bugfix
|
||||
- CVE:NA
|
||||
- SUG:NA
|
||||
- DESC:set scan_type optional, and fix sequence of header file
|
||||
|
||||
* Tue Apr 2 2024 tangyuchen <tangyuchen5@huawei.com> - 1.1-8
|
||||
- Type: bugfix
|
||||
- CVE:NA
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user