From: "Durrant, Paul" <pdurrant@amazon.co.uk>
To: Stefan Hajnoczi <stefanha@redhat.com>,
"Woodhouse, David" <dwmw@amazon.co.uk>
Cc: "qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
"qemu-block@nongnu.org" <qemu-block@nongnu.org>
Subject: RE: aio_set_event_notifier(is_external=true) in Xen code?
Date: Tue, 28 Mar 2023 16:36:29 +0000 [thread overview]
Message-ID: <1c064dc2c005455a88025f985a9bf66b@amazon.co.uk> (raw)
In-Reply-To: <20230328155050.GA1632689@fedora>
> -----Original Message-----
> From: Stefan Hajnoczi <stefanha@redhat.com>
> Sent: 28 March 2023 16:51
> To: Woodhouse, David <dwmw@amazon.co.uk>; Durrant, Paul
> <pdurrant@amazon.co.uk>
> Cc: qemu-devel@nongnu.org; qemu-block@nongnu.org
> Subject: [EXTERNAL] aio_set_event_notifier(is_external=true) in Xen code?
>
> Hi,
> I'm removing the aio_disable_external() API from QEMU and noticed that
> Xen code calls aio_set_fd_handler(is_external=true) in hw/xen/xen-bus.c
> and hw/i386/kvm/xen_xenstore.c.
>
> It wasn't clear to me whether is_external=true is necessary here.
> is_external=true is mainly used to temporarily pause I/O submission in
> the QEMU block layer. Maybe is_external=true was chosen out of caution
> but actually has no effect in this code.
>
> Does the Xen code rely on is_external=true?
That's a good question. The call in xen-bus.c has been there since commit 83361a8a1f932, which was when it substituted the old call to qemu_set_fd_handler(). I suspect this was out of caution (or possibly misunderstanding) at the time, although setting the call to xen_device_set_event_channel_context() in xen_block_dataplane_stop() does suggest it may be happening while I/O could be in progress so it could have been in response to problems caught in testing.
I suspect the code in xen_xenstore.c just copied what xen-bus.c did.
Sorry I can't give you a definitive answer... it's all rather a long time ago.
Cheers,
Paul
next prev parent reply other threads:[~2023-03-28 16:37 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-28 15:50 aio_set_event_notifier(is_external=true) in Xen code? Stefan Hajnoczi
2023-03-28 16:36 ` Durrant, Paul [this message]
2023-03-28 18:10 ` Stefan Hajnoczi
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=1c064dc2c005455a88025f985a9bf66b@amazon.co.uk \
--to=pdurrant@amazon.co.uk \
--cc=dwmw@amazon.co.uk \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@redhat.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).