[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v5 08/18] xen/sysctl: wrap around XEN_SYSCTL_lockprof_op
- To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Penny Zheng <Penny.Zheng@xxxxxxx>
- Date: Mon, 16 Jun 2025 14:41:18 +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=TPsu3Whzar30hPPztM4eYMHCA+8Epbp9x/t6GVQxLw0=; b=SuNrWdKcc3XV4Y9qGslJOAQWyTvbW80BOpKG+N79L9nP3zF/uTdMTwXyg7VxR5XOTeNnGxc9j6yS7zzRWKPdSU99t+lrx3rYv2PI46LG9IWFPz9sNwJJavMcnSkr2rINyKsJTqPY2Sq3GfYzOSnv2OoKPLoj7AwiH6tTBjMZLYuDuKzo3lY3gSVHMwUeTxtXMPYuZ+ipo0dhcrb78VN+T5Nwj7KJAVdPkBC2mNlHQgWneAal+Dzdy74PtLwa3haYMnJKZ3oWUvlXcGl0LDqcq6uaLfpglrMlwCj6ZTIbELWCNWcxvIqX+1yE2X4R5bhjCZcZ6OlzaVp29BOvirj3wQ==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=pVmLdi47vlZNlcUWRqS7mlnyQMAJCVFUpASLGD8RaIVWHrzCxzYYnJmn07j88lQGHU7xuKWj5BzHOQdrpMLddkZ5BUrvqOomE8lSamp4ywCyzqurVgd34lOv9XCuN6lvSygIf/3B9X33gP26nWfgT40vv6iWh6Nz+4mlcRJgYViT67rpBQM6sSPtcVPEbOcqdfJ+tCPz+kW8G3AR4TRu0HWWqNAucxDIduIFmoI+ucMEFR+RmpaGL2ApYd2I9V+DXIyVf2QZqHchCckmp9JZxSJ8FczYlKZaCK2ue/QTCFM0h8OftmqZj4I2a1t9CJvTtaF2CyxR+rFwAAUUtK8gxQ==
- 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:22 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
The following function is only to serve spinlock profiling via
XEN_SYSCTL_lockprof_op, so it shall be wrapped:
- spinlock_profile_control()
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/spinlock.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/xen/common/spinlock.c b/xen/common/spinlock.c
index 38caa10a2e..0389293b09 100644
--- a/xen/common/spinlock.c
+++ b/xen/common/spinlock.c
@@ -690,6 +690,7 @@ void cf_check spinlock_profile_reset(unsigned char key)
spinlock_profile_iterate(spinlock_profile_reset_elem, NULL);
}
+#ifdef CONFIG_SYSCTL
typedef struct {
struct xen_sysctl_lockprof_op *pc;
int rc;
@@ -749,6 +750,7 @@ int spinlock_profile_control(struct xen_sysctl_lockprof_op
*pc)
return rc;
}
+#endif /* CONFIG_SYSCTL */
void _lock_profile_register_struct(
int32_t type, struct lock_profile_qhead *qhead, int32_t idx)
--
2.34.1
|