[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v5 07/18] xen/sysctl: wrap around XEN_SYSCTL_perfc_op
- To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Penny Zheng <Penny.Zheng@xxxxxxx>
- Date: Mon, 16 Jun 2025 14:41:17 +0800
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0)
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=WItGqxAhxBw21f3KfwdiFUW2nn+4erXPhuSpx0xV6H8=; b=CYbLa0axuaQcb2a3qxM6rV8bMJxK+kY247ouH/iDrkag12IbbbrZP3YmYrRju26gNjOydMJKZoE9cGIMCBrYc4L9S9WmDqDSOUbJi7RI9ENGovB9tmco8elqx6Ez2lREXMUXh+8a+DQfE11U1jNUJVZloElbbWxK/X5KEyuwPsozC0DbJLEzQkyrXTQJytR8+QsmmLMgYj6D2dMN6XeWcwfTkWU4hn1h9gW/tn6YZPlRCzqmyAxyrxk7/Aw1r/YkXpZmDYYlwlQcUUp0YIFBdbx6w+yqiUt7MEfi8Up1ozBKMkG+b9gvB6fnNnZECZPu0jkllpdUs8Hg6eUo3QoH+w==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=vjoYUfl8lz0JQiz66yWKXsQWUGDR0UpeqxkvyAZ+E6kcHA8II7tWZLQ3UC+UIOgbNaiePyCSPQGd8lOpwI2626cCpyCPvG8Yxl7WO0o5T3ASycej5Zjquo8AL86PLTvZHCuDFogzxFyExlRRRKkyNrxZtgH62s/Tf5ZCUQIpD3+Njctghhy4krGzskCNYl2kmUkk0kiEl3acYQm2YHrf5VbTrobt33GThk3jqrY2ydX2Va37OxwTgMyF8kN8abavFVP6n5GZozW1hxW3rfhRTW5TJsa5GaD4YApUcfdJBtkK5z3ctLYZxbBgTvN1oL9TaFwzkJ+VgnnxptALIGCVaA==
- Cc: <ray.huang@xxxxxxx>, Penny Zheng <Penny.Zheng@xxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, "Julien Grall" <julien@xxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>
- Delivery-date: Mon, 16 Jun 2025 06:42:20 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
perfc_control() and perfc_copy_info() are responsible for providing control
of perf counters via XEN_SYSCTL_perfc_op in DOM0, so they both shall
be wrapped.
Signed-off-by: Penny Zheng <Penny.Zheng@xxxxxxx>
Reviewed-by: Stefano Stabellini <sstabellini@xxxxxxxxxx>
---
v2 -> v3:
- add the blank line
---
v3 -> v4:
- remove transient "#ifdef CONFIG_SYSCTL"
---
xen/common/perfc.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/xen/common/perfc.c b/xen/common/perfc.c
index 8302b7cf6d..0f3b89af2c 100644
--- a/xen/common/perfc.c
+++ b/xen/common/perfc.c
@@ -149,6 +149,7 @@ void cf_check perfc_reset(unsigned char key)
}
}
+#ifdef CONFIG_SYSCTL
static struct xen_sysctl_perfc_desc perfc_d[NR_PERFCTRS];
static xen_sysctl_perfc_val_t *perfc_vals;
static unsigned int perfc_nbr_vals;
@@ -265,6 +266,7 @@ int perfc_control(struct xen_sysctl_perfc_op *pc)
return rc;
}
+#endif /* CONFIG_SYSCTL */
/*
* Local variables:
--
2.34.1
|