From 8ead643730866a79a5306a2832ed57a682d1519e Mon Sep 17 00:00:00 2001 From: wenzhiwei11 Date: Mon, 18 Oct 2021 17:52:20 +0800 Subject: [PATCH] arm64/mpam: fix the problem that the ret variable is not initialized MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit kylin inclusion category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I4AHUL?from=project-issue CVE: NA --------------------------------------------------- initialize the value "ret" in "schemata_list_init()" Signed-off-by: 温志伟 Reviewed-by: Jian Cheng Signed-off-by: Wang ShaoBo --- arch/arm64/kernel/mpam/mpam_ctrlmon.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/kernel/mpam/mpam_ctrlmon.c b/arch/arm64/kernel/mpam/mpam_ctrlmon.c index b1d32d432556..b7508ad8c531 100644 --- a/arch/arm64/kernel/mpam/mpam_ctrlmon.c +++ b/arch/arm64/kernel/mpam/mpam_ctrlmon.c @@ -127,7 +127,7 @@ static int add_schema(enum resctrl_conf_type t, struct resctrl_resource *r) int schemata_list_init(void) { - int ret; + int ret = 0; struct mpam_resctrl_res *res; struct resctrl_resource *r; -- GitLab