From: Kevin Wolf <kwolf@redhat.com>
To: Stefan Hajnoczi <stefanha@redhat.com>
Cc: qemu-devel@nongnu.org, "Peter Xu" <peterx@redhat.com>,
"Michael S. Tsirkin" <mst@redhat.com>,
"Philippe Mathieu-Daudé" <philmd@linaro.org>,
"David Hildenbrand" <david@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Fam Zheng" <fam@euphon.net>,
qemu-block@nongnu.org
Subject: Re: [PATCH v2 0/4] scsi: eliminate AioContext lock
Date: Mon, 18 Dec 2023 11:28:35 +0100 [thread overview]
Message-ID: <ZYAe06nz-KRshz0b@redhat.com> (raw)
In-Reply-To: <20231204164259.1515217-1-stefanha@redhat.com>
[ Cc: qemu-block ]
Am 04.12.2023 um 17:42 hat Stefan Hajnoczi geschrieben:
> v2:
> - Reschedule BH in new AioContext if change is detected [Kevin]
> - Drop stray "remember" in Patch 2's commit description [Eric]
>
> The SCSI subsystem uses the AioContext lock to protect internal state. This is
> necessary because the main loop and the IOThread can access SCSI state in
> parallel. This inter-thread access happens during scsi_device_purge_requests()
> and scsi_dma_restart_cb().
>
> This patch series modifies the code so SCSI state is only accessed from the
> IOThread that is executing requests. Once this has been achieved the AioContext
> lock is no longer necessary.
>
> Note that a few aio_context_acquire()/aio_context_release() calls still remain
> after this series. They surround API calls that invoke AIO_WAIT_WHILE() and
> therefore still rely on the AioContext lock for now.
>
> Stefan Hajnoczi (4):
> scsi: only access SCSIDevice->requests from one thread
> virtio-scsi: don't lock AioContext around
> virtio_queue_aio_attach_host_notifier()
> scsi: don't lock AioContext in I/O code path
> dma-helpers: don't lock AioContext in dma_blk_cb()
Thanks, applied to the block branch.
Kevin
prev parent reply other threads:[~2023-12-18 10:29 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-04 16:42 [PATCH v2 0/4] scsi: eliminate AioContext lock Stefan Hajnoczi
2023-12-04 16:42 ` [PATCH v2 1/4] scsi: only access SCSIDevice->requests from one thread Stefan Hajnoczi
2023-12-19 15:11 ` Kevin Wolf
2023-12-19 16:02 ` Stefan Hajnoczi
2023-12-04 16:42 ` [PATCH v2 2/4] virtio-scsi: don't lock AioContext around virtio_queue_aio_attach_host_notifier() Stefan Hajnoczi
2023-12-04 16:42 ` [PATCH v2 3/4] scsi: don't lock AioContext in I/O code path Stefan Hajnoczi
2023-12-04 16:42 ` [PATCH v2 4/4] dma-helpers: don't lock AioContext in dma_blk_cb() Stefan Hajnoczi
2023-12-18 10:28 ` Kevin Wolf [this message]
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=ZYAe06nz-KRshz0b@redhat.com \
--to=kwolf@redhat.com \
--cc=david@redhat.com \
--cc=fam@euphon.net \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=peterx@redhat.com \
--cc=philmd@linaro.org \
--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).