[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[XEN][PATCH] x86: hvm: hypercall: use define instead of const in hvm_hypercall()
- To: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Grygorii Strashko <grygorii_strashko@xxxxxxxx>
- Date: Fri, 12 Sep 2025 09:47:03 +0000
- Accept-language: en-US
- 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=c3cXhSVaQPKt/puKFM1lKoxFGYP+UyaXGv6+MogjbpM=; b=V5nf1BgftrDk/j2eEa8pgHvz6B9ZSIoZZrs6uHg2BOg8x6VnHCcyXvYEWcfJTTd4MveMSnxzjixuKuBX9vvNiHIzE3zr8+sGFYcDN6AMX1t2dxTKH2eXT0gw+AXJDZh/Pu+jzt0SyvnXqNayKaRgw94fxI4DmoSKp4jgYIZqgSQhNkL4hPUmzHdFkaP6FFBuIlBXaxrpGiLE7TzEoKJQlE85nS7XCq0AZadRHVQv3YbCcUDnJtBH6LWo4ElajlIwFwfq0/YOdiu0YijR6ftTUX1tFInA+3fUTYA8xrnRgOcde83d3P9bTyxqmAxM9jVXUukgGfhZXcmC9fBBhsSz7g==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=LNiJRa2VinkPYWdAVUwWUq3XaS+MaBJL641atsfsDxQxwQdf8JM8PYn1HQdYzegFdeX/eAIno/TWOSAYwcwxO8i8ARzQoTIS1XURG/9YLpvp8gY8qYHGxYrk/cpJ0FR7m8uFNwW881ZJLD0dKEAfjURA/ECvdexUOCYDvPpUOhFhHnZBDNMGTrS2hP21ms3WRh9Dk776Dy/nAb1REPxdnKRf+Stlh1Cn/ZkMX0iXO6Z8mwMJ8PKNarFc8JnLJ00oWJpRodXpoS9HMKpLdGspZxrwWDzx+nhziTCQFp/NwocFR0IlQO1pHnURI9KaPFOR5ggVYxXNaku4rFbJ286H/g==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=epam.com;
- Cc: Grygorii Strashko <grygorii_strashko@xxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>
- Delivery-date: Fri, 12 Sep 2025 09:47:18 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
- Thread-index: AQHcI8oxX/I/itfE00GCxamYjAZC5A==
- Thread-topic: [XEN][PATCH] x86: hvm: hypercall: use define instead of const in hvm_hypercall()
From: Grygorii Strashko <grygorii_strashko@xxxxxxxx>
Use define X86_MODE_64BIT instead of constant in hvm_hypercall() for "mode"
conditional check to improve code readability.
Signed-off-by: Grygorii Strashko <grygorii_strashko@xxxxxxxx>
---
xen/arch/x86/hvm/hypercall.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/xen/arch/x86/hvm/hypercall.c b/xen/arch/x86/hvm/hypercall.c
index 6f8dfdff4ac6..b254b3e2f7d6 100644
--- a/xen/arch/x86/hvm/hypercall.c
+++ b/xen/arch/x86/hvm/hypercall.c
@@ -155,7 +155,7 @@ int hvm_hypercall(struct cpu_user_regs *regs)
curr->hcall_preempted = false;
- if ( mode == 8 )
+ if ( mode == X86_MODE_64BIT )
{
HVM_DBG_LOG(DBG_LEVEL_HCALL, "hcall%lu(%lx, %lx, %lx, %lx, %lx)",
eax, regs->rdi, regs->rsi, regs->rdx, regs->r10, regs->r8);
--
2.34.1
|