提交 6c712a87 编写于 作者: X Xie XiuQi

arm64/mpam: only add new domain node to domain list

hulk inclusion
category: bugfix
bugzilla: 14212
CVE: NA

Only add a new domain to domain list, don't care about exist domain
node.
Signed-off-by: NXie XiuQi <xiexiuqi@huawei.com>
Reviewed-by: NHanjun Guo <guohanjun@huawei.com>
Signed-off-by: NYang Yingliang <yangyingliang@huawei.com>
上级 ad4a9b6f
......@@ -1208,6 +1208,8 @@ static void mpam_domains_init(struct resctrl_resource *r)
if (!d)
d = kzalloc(sizeof(*d), GFP_KERNEL);
else
continue;
if (!d) {
mpam_domains_destroy(r);
......@@ -1263,7 +1265,8 @@ static void mpam_domains_init(struct resctrl_resource *r)
return;
}
list_add_tail(&d->list, add_pos);
if (add_pos)
list_add_tail(&d->list, add_pos);
id++;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册