[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH v3 12/28] xen/domctl: wrap domain_pause_by_systemcontroller() with MGMT_HYPERCALLS


  • To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Penny Zheng <Penny.Zheng@xxxxxxx>
  • Date: Mon, 13 Oct 2025 18:15:24 +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=OiVfy+8J6MhVdjDVcDOUDk8nZiMCRgJp1Xtsq49ycA0=; b=pIx3f6fa/GsIynN3++oOkc/k4rOZdgD0oY81DFFyxAvkDhGAFVZmU3CIEr66/N5/Ziy8YVFfE4FWpvc6nLuOpxeSCOZ7xh1mlVwLuH5P/mrGzq3I1YHdnOG+sUX6EimC7UR8L8rT11q1NKQuOCIofjiPeZEkRSP/CuCdMWvrBZeKZcpndlntnD4UMdPoGGjPc2avDSG8xmrbVzihEjPWBD/JzlGWItekOm2eN7AS5opOolXaz/TKsYCM/Itk7rmyFy4UBnS7TLcPc9vQOkVou06aQsDa8Cpp6Rh6mj2y2cgOD2v2OKPYJUTqC4Z/eJW45j5bvuKyT67o2oec1kcaeg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=Vd5LtCI4DsYdnZFZTS78mNPd4pPxKRMnHM+1EXJCB7uBXcxaOFmlo0rfi5LmcbBxPc2s02jRyxpF5jXXZ54xvy2mJ2W+OYpC+XewMXjRmw/d79jk4+KJNbTs2JKr8R0lMhCdJlPiBrIHGvCwBe6inQyKAw0PEBTQWjaqwaQYLKNTdBl5hIXw0aD8pvXw8jgCcIti5EwEIXekNxwr70ZZ7HzEokwIiRqhFAzpFe79U1ZfU4bMSAMiSwPnIUWbEInqWFF3nS2oeg9/KTd1ZgRwozq+aqtaRxD7TEfxeLOuoMY7W1lkiogWk3yf08MKq1OdWNtECIe8huczXPNZwLaRGA==
  • Cc: <ray.huang@xxxxxxx>, <oleksii.kurochko@xxxxxxxxx>, 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, 13 Oct 2025 10:26:54 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

Function domain_pause_by_systemcontroller() is responsible for
XEN_DOMCTL_pausedomain domctl-op, and shall be wrapped around with
CONFIG_MGMT_HYPERCALLS. Otherwiae it will become unreachable when
MGMT_HYPERCALLS=n and hence violating Misra rule 2.1.

Signed-off-by: Penny Zheng <Penny.Zheng@xxxxxxx>
---
v1 -> v2:
- adapt to changes of "unify DOMCTL to MGMT_HYPERCALLS"
- provide transient wrapping around XEN_DOMCTL_pausedomain-case
---
v2 -> v3:
- remove transient wrapping around XEN_DOMCTL_pausedomain-case
- address "violating Misra rule 2.1" in commit message
---
 xen/common/domain.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/xen/common/domain.c b/xen/common/domain.c
index 775c339285..976172c7d3 100644
--- a/xen/common/domain.c
+++ b/xen/common/domain.c
@@ -1606,10 +1606,12 @@ static int _domain_pause_by_systemcontroller(struct 
domain *d, bool sync)
     return 0;
 }
 
+#ifdef CONFIG_MGMT_HYPERCALLS
 int domain_pause_by_systemcontroller(struct domain *d)
 {
     return _domain_pause_by_systemcontroller(d, true /* sync */);
 }
+#endif /* CONFIG_MGMT_HYPERCALLS */
 
 int domain_pause_by_systemcontroller_nosync(struct domain *d)
 {
-- 
2.34.1




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.