[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 10/17] tools/xenstored: Read event channel from xenstored page
- To: Juergen Gross <jgross@xxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Jason Andryuk <jason.andryuk@xxxxxxx>
- Date: Thu, 17 Jul 2025 16:03:25 -0400
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=suse.com 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=fJJfQHZMwoiMiFvNjuHEHJzOUaC+uV1I4oxU2u9+lUg=; b=JzUSVtC8vA1h6wupfYo+S4KTfwnasJVf7tlarD3QI1F7LzBJ1kSvoShNIjXcr0DC6rU/766tOGuzv97Tj4P7C9g0pcxITY2kDqKQdOc47RSA1wkHMaUoEjOZW9ChVxo621lLZ2bzB0reXqSlv6GnS7Lkz93H9CVwYjUW5Gn1nTTpwRmsAndVhBu9brewGMVk2DJYLyOz4zhCwkfJRp89IgSl0BUScXx+/4erz5Yy+mPqd7BewrQKa0olFUcSTu25AQMIMdzn6bTNlA8830ydeP6dllb/pv1x+cRWQBqnqgncU0HiiKrXu5GrBOFKSypBSmFs4p4hljvdkGh2zJZYvg==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=rdp80vbjCTGz5P1Wcq2R+XcyH1qnX+qOuCT/FqhjrWBjnbQzAsHRAfR8fsxZsGU5ru5P86Tjb2rnUEwGzsfNe/ai1vN1ybrS1dhHv80ELqqBVV3gBuLfSaFX1RNLn02+M4gU2XJhUDzFvyLVEvssSW+lb1ZNRM8tIRmfIV8GzCpHVyQSdfjVXTkrn9dUnFKWqewqwl3e9RTVftOM5FBX1rjCscqG4wIglWoIyiDH5xX+XUErNJlc3HncDs8CwFIj+csVG5SkjDn42E3DBfWDhg6lpZFFFPcZGhBAzsbtfrqnMQlNrhjX5TyYj3HF49v9p3eD3FevEoV6KoqjE0bVkA==
- Cc: Julien Grall <julien@xxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>
- Delivery-date: Thu, 17 Jul 2025 20:03:34 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 2025-07-17 02:22, Juergen Gross wrote:
On 16.07.25 23:14, Jason Andryuk wrote:
Make introduce_domain() use an event channel from the the xenstore page.
It is only used if non-zero. Otherwise the passed in event channel port
is used.
The is useful for a xenstored stubdom to configure domains autonomously.
Signed-off-by: Jason Andryuk <jason.andryuk@xxxxxxx>
---
tools/xenstored/domain.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/tools/xenstored/domain.c b/tools/xenstored/domain.c
index e1d5e8d614..94b2a1eaa7 100644
--- a/tools/xenstored/domain.c
+++ b/tools/xenstored/domain.c
@@ -1021,9 +1021,15 @@ static struct domain *introduce_domain(const
void *ctx,
return NULL;
if (!domain->introduced) {
+ evtchn_port_t iface_port;
interface = map_interface(domid);
if (!interface && !restore)
return NULL;
+
+ iface_port = interface->evtchn_port;
+ if (iface_port)
+ port = iface_port;
+
Any reason you introduced iface_port?
I think you could just use:
+ if (interface->evtchn_port)
+ port = interface->evtchn_port;
Yes, I think this would be fine.
Thanks,
Jason
|