qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Kevin Wolf <kwolf@redhat.com>
To: Stefan Hajnoczi <stefanha@redhat.com>
Cc: qemu-devel@nongnu.org, "Michal Privoznik" <mprivozn@redhat.com>,
	"Hanna Reitz" <hreitz@redhat.com>,
	qemu-block@nongnu.org, "Michael S. Tsirkin" <mst@redhat.com>,
	"Daniel P. Berrangé" <berrange@redhat.com>,
	"Michael Roth" <michael.roth@amd.com>,
	"Eduardo Habkost" <eduardo@habkost.net>,
	"Eric Blake" <eblake@redhat.com>,
	"Markus Armbruster" <armbru@redhat.com>,
	"Paolo Bonzini" <pbonzini@redhat.com>
Subject: Re: [PATCH v4 4/4] virtio-blk: add iothread-vq-mapping parameter
Date: Thu, 21 Dec 2023 14:10:20 +0100	[thread overview]
Message-ID: <ZYQ5PM8Hak2xDpIj@redhat.com> (raw)
In-Reply-To: <20231220134755.814917-5-stefanha@redhat.com>

Am 20.12.2023 um 14:47 hat Stefan Hajnoczi geschrieben:
> Add the iothread-vq-mapping parameter to assign virtqueues to IOThreads.
> Store the vq:AioContext mapping in the new struct
> VirtIOBlockDataPlane->vq_aio_context[] field and refactor the code to
> use the per-vq AioContext instead of the BlockDriverState's AioContext.
> 
> Reimplement --device virtio-blk-pci,iothread= and non-IOThread mode by
> assigning all virtqueues to the IOThread and main loop's AioContext in
> vq_aio_context[], respectively.
> 
> The comment in struct VirtIOBlockDataPlane about EventNotifiers is
> stale. Remove it.
> 
> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>

I'm looking at virtio_blk_dma_restart_cb/bh(). It seems to run all
queued requests in the iothread of the first vq, but when the requests
complete, they will push the result to their original vq.

Do we know that the dataplane isn't started and won't be started until
the requests complete? (I wouldn't expect so, because then moving to the
AioContext of the BlockBackend wouldn't have been necessary either.) Or
is there another reason why this is safe?

Kevin



  reply	other threads:[~2023-12-21 13:11 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-20 13:47 [PATCH v4 0/4] virtio-blk: add iothread-vq-mapping parameter Stefan Hajnoczi
2023-12-20 13:47 ` [PATCH v4 1/4] qdev-properties: alias all object class properties Stefan Hajnoczi
2023-12-21 12:39   ` Kevin Wolf
2023-12-21 15:47     ` Stefan Hajnoczi
2023-12-20 13:47 ` [PATCH v4 2/4] string-output-visitor: show structs as "<omitted>" Stefan Hajnoczi
2023-12-20 13:47 ` [PATCH v4 3/4] qdev: add IOThreadVirtQueueMappingList property type Stefan Hajnoczi
2023-12-20 13:47 ` [PATCH v4 4/4] virtio-blk: add iothread-vq-mapping parameter Stefan Hajnoczi
2023-12-21 13:10   ` Kevin Wolf [this message]
2024-01-18 21:28     ` Stefan Hajnoczi
2023-12-21 13:40   ` Kevin Wolf
2024-01-19 13:41     ` Stefan Hajnoczi
2023-12-21 21:07 ` [PATCH v4 0/4] " Kevin Wolf

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=ZYQ5PM8Hak2xDpIj@redhat.com \
    --to=kwolf@redhat.com \
    --cc=armbru@redhat.com \
    --cc=berrange@redhat.com \
    --cc=eblake@redhat.com \
    --cc=eduardo@habkost.net \
    --cc=hreitz@redhat.com \
    --cc=michael.roth@amd.com \
    --cc=mprivozn@redhat.com \
    --cc=mst@redhat.com \
    --cc=pbonzini@redhat.com \
    --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).