qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Hajnoczi <stefanha@redhat.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: qemu-devel@nongnu.org, jcody@redhat.com, qemu-block@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v2 0/3] do not use aio_context_acquire/release in AIO-based drivers
Date: Thu, 23 Feb 2017 10:34:25 +0000	[thread overview]
Message-ID: <20170223103425.GA18728@stefanha-x1.localdomain> (raw)
In-Reply-To: <20170222180725.28611-1-pbonzini@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 1165 bytes --]

On Wed, Feb 22, 2017 at 07:07:22PM +0100, Paolo Bonzini wrote:
> aio_context_acquire/release are only going away as soon as the block layer
> becomes thread-safe, but we can already move away to other finer-grained
> mutex whenever possible.
> 
> These three drivers don't use coroutines, hence a QemuMutex is a fine
> primitive to use for protecting any per-BDS data in the libraries
> they use.  The QemuMutex must protect any fd handlers or bottom halves,
> and also the BlockDriver callbacks which were implicitly being called
> under aio_context_acquire.
> 
> Paolo
> 
> v1->v2: missing unlock in error paths (patch 2, Stefan)
> 
> Paolo Bonzini (3):
>   curl: do not use aio_context_acquire/release
>   nfs: do not use aio_context_acquire/release
>   iscsi: do not use aio_context_acquire/release
> 
>  block/curl.c  | 24 ++++++++++-------
>  block/iscsi.c | 83 +++++++++++++++++++++++++++++++++++++++++++++--------------
>  block/nfs.c   | 23 ++++++++++++++---
>  3 files changed, 98 insertions(+), 32 deletions(-)
> 
> -- 
> 2.9.3
> 

Thanks, applied to my block tree:
https://github.com/stefanha/qemu/commits/block

Stefan

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 455 bytes --]

      parent reply	other threads:[~2017-02-23 10:34 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-22 18:07 [Qemu-devel] [PATCH v2 0/3] do not use aio_context_acquire/release in AIO-based drivers Paolo Bonzini
2017-02-22 18:07 ` [Qemu-devel] [PATCH 1/3] curl: do not use aio_context_acquire/release Paolo Bonzini
2017-02-22 18:07 ` [Qemu-devel] [PATCH 2/3] nfs: " Paolo Bonzini
2017-02-22 18:07 ` [Qemu-devel] [PATCH 3/3] iscsi: " Paolo Bonzini
2017-02-23 10:34 ` Stefan Hajnoczi [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=20170223103425.GA18728@stefanha-x1.localdomain \
    --to=stefanha@redhat.com \
    --cc=jcody@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.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 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).