From: Jan Beulich <jbeulich@suse.com>
To: Jason Andryuk <jason.andryuk@amd.com>
Cc: Stefano Stabellini <sstabellini@kernel.org>,
Julien Grall <julien@xen.org>,
Bertrand Marquis <bertrand.marquis@arm.com>,
Michal Orzel <michal.orzel@amd.com>,
xen-devel@lists.xenproject.org
Subject: Re: [PATCH v3 8/8] xen/dom0less: store xenstore event channel in page
Date: Wed, 27 Aug 2025 09:58:30 +0200 [thread overview]
Message-ID: <609d686e-a41c-47f4-9e5d-3733e9ec7723@suse.com> (raw)
In-Reply-To: <20250826210847.126015-9-jason.andryuk@amd.com>
On 26.08.2025 23:08, Jason Andryuk wrote:
> --- a/xen/common/device-tree/dom0less-build.c
> +++ b/xen/common/device-tree/dom0less-build.c
> @@ -26,6 +26,7 @@
> #include <public/event_channel.h>
> #include <public/io/xs_wire.h>
>
> +#include <asm/guest_access.h>
> #include <asm/setup.h>
>
> #include <xen/static-memory.h>
> @@ -120,8 +121,14 @@ static void __init initialize_domU_xenstore(void)
>
> if ( gfn != XENSTORE_PFN_LATE_ALLOC && IS_ENABLED(CONFIG_GRANT_TABLE) )
> {
> + evtchn_port_t port = d->arch.hvm.params[HVM_PARAM_STORE_EVTCHN];
> + paddr_t evtchn_gaddr = gfn_to_gaddr(_gfn(gfn)) +
> + offsetof(struct xenstore_domain_interface, evtchn_port);
> +
> ASSERT(gfn < UINT32_MAX);
> gnttab_seed_entry(d, GNTTAB_RESERVED_XENSTORE, xs_domid, gfn);
> + access_guest_memory_by_gpa(d, evtchn_gaddr, &port, sizeof(port),
> + true /* is_write */);
Isn't the use of an arch-specific function going to pose yet another issue
for making this code usable on x86? Can't you use copy_to_guest_phys() here?
Which may in turn need to be passed in by the caller, see e.g. dtb_load()
and initrd_load() (i.e. cache flushing may also be necessary for Arm).
Jan
next prev parent reply other threads:[~2025-08-27 7:58 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-26 21:08 [PATCH v3 0/8] init-dom0less and dom0less xenstore evtchn Jason Andryuk
2025-08-26 21:08 ` [PATCH v3 1/8] tools/init-dom0less: Make handles global Jason Andryuk
2025-08-27 15:12 ` Jürgen Groß
2025-08-26 21:08 ` [PATCH v3 2/8] tools/init-dom0less: Factor out xenstore setup Jason Andryuk
2025-08-26 21:08 ` [PATCH v3 3/8] tools/init-dom0less: Only introduce un-introduced domains Jason Andryuk
2025-08-26 21:08 ` [PATCH v3 4/8] tools/init-dom0less: Switch domain_exists to check xenstore name Jason Andryuk
2025-08-26 21:08 ` [PATCH v3 5/8] tools/init-dom0less: Use introduced to determine no-enhanced Jason Andryuk
2025-08-26 21:08 ` [PATCH v3 6/8] tools/init-dom0less: Remove use of err() Jason Andryuk
2025-08-26 21:08 ` [PATCH v3 7/8] tools/init-dom0less: Continue on error Jason Andryuk
2025-08-26 21:08 ` [PATCH v3 8/8] xen/dom0less: store xenstore event channel in page Jason Andryuk
2025-08-27 7:58 ` Jan Beulich [this message]
2025-08-27 13:19 ` Jason Andryuk
2025-08-27 14:00 ` Jan Beulich
2025-08-27 8:03 ` Orzel, Michal
2025-08-27 13:24 ` Jason Andryuk
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=609d686e-a41c-47f4-9e5d-3733e9ec7723@suse.com \
--to=jbeulich@suse.com \
--cc=bertrand.marquis@arm.com \
--cc=jason.andryuk@amd.com \
--cc=julien@xen.org \
--cc=michal.orzel@amd.com \
--cc=sstabellini@kernel.org \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.