[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [XEN][PATCH v4] xen: make VMTRACE support optional
- To: Jan Beulich <jbeulich@xxxxxxxx>
- From: Grygorii Strashko <grygorii_strashko@xxxxxxxx>
- Date: Thu, 20 Nov 2025 12:47:22 +0200
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=epam.com; dmarc=pass action=none header.from=epam.com; dkim=pass header.d=epam.com; arc=none
- 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=zet+1/WAg/mK2F4LaJxBMH8W9F4nGtbtbZDeiT5Djhw=; b=A0WQdMwiAbDjSMaTvleiWEQwg0bbRzA9olZfeL6jvdfdhtts2+EgPffeqj6dH5vBy6aWabV0guVOHzzSQ7FwVgSN2h3hIdzee0snXBle4NG28F0G0Ogf/BTBc5tuuzHIx+s2EIG80K4ZwhnTXruzz33pWnuQKNUsf51uhjC9guIbYIToVyhncpwDJNkkSMJ/t1LZcWp2THK45a0z088rTpyCNJt4y5N3Dak0yWKA8dbQ9koh7xgCz+QPqyl3n+YNRI8RUz9T7tnQ2fSvxy+PLhh/v+gca3TF2bc/2YHVpczMQr/4XVS4kfIu1kQ0SJK4qg90ZF48VWVDy4hA8ZKpsA==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=C3XvLemDMZws75ed4sjQoIDhMW+IqAZjZvC4ITHZ+8Dvf57bN3511AtA23sthp3bUd7LMueziaC5nNcxMWYEhi5HXmuFK3woYr57w/Kl7vvULigv7zXhinEQDxZ+aV+IazdCxCNxL/BDBjs//2b7+dRNqONY5gC5AbrAFLVOVqi+wOb5AQC0SmhA4Tx5QQgaFvwIVRxZFzIODgkw46MZ0lSrJx5ahTeG+f6N4KiBcL9ivZPrgTL8TlYQagfM35yHTqEN4/OEp8v8LuJRUOwSzFLR+HaZZVoyOGe/P7cfWh3bO2DwRhfe3LL6pNHoWEKxUh3LOv6kdPniuV4T7XlKnA==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=epam.com;
- Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Tamas K Lengyel <tamas@xxxxxxxxxxxxx>, Alexandru Isaila <aisaila@xxxxxxxxxxxxxxx>, Petre Pircalabu <ppircalabu@xxxxxxxxxxxxxxx>, Teddy Astie <teddy.astie@xxxxxxxxxx>, Penny Zheng <Penny.Zheng@xxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- Delivery-date: Thu, 20 Nov 2025 10:47:41 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
Hi Jan,
On 20.11.25 10:56, Jan Beulich wrote:
On 19.11.2025 20:31, Grygorii Strashko wrote:
From: Grygorii Strashko <grygorii_strashko@xxxxxxxx>
The VMTRACE feature is depends on Platform/Arch HW and code support and now
can be used only on x86 HVM with Intel VT-x (INTEL_VMX) enabled.
This makes VMTRACE support optional by introducing HVM Kconfig option:
- CONFIG_VMTRACE to enable/disable the feature.
Signed-off-by: Grygorii Strashko <grygorii_strashko@xxxxxxxx>
---
changes in v4:
- format changes
Just partly, ...
@@ -772,13 +775,24 @@ static inline int hvm_vmtrace_get_option(
return -EOPNOTSUPP;
}
+#else
+/*
+ * Function declaration(s) here are used without definition(s) to make compiler
+ * happy when VMTRACE=n, compiler DCE will eliminate unused code.
+ */
+int hvm_vmtrace_output_position(struct vcpu *v, uint64_t *pos);
+#endif
static inline int hvm_vmtrace_reset(struct vcpu *v)
{
+#ifdef CONFIG_VMTRACE
if ( hvm_funcs.vmtrace_reset )
return alternative_call(hvm_funcs.vmtrace_reset, v);
return -EOPNOTSUPP;
+#else
+ return -EOPNOTSUPP;
+#endif
}
... the #else wasn't dropped from here. If no need for a v5 arises, I guess
I can make the adjustment while committing. But it would be really nice if
all earlier comments were taken care of (one way or another) when submitting
a new version.
This is absolutely my miss. Sorry.
I can resend with fix. Just tell me how will be better for you.
With the adjustment:
Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx>
Thank you.
--
Best regards,
-grygorii
|