qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Kevin Wolf <kwolf@redhat.com>
Cc: "Michael S. Tsirkin" <mst@redhat.com>,
	"Stefan Hajnoczi" <stefanha@gmail.com>,
	qemu-devel <qemu-devel@nongnu.org>,
	"Keith Busch" <keith.busch@gmail.com>,
	"Busch, Keith" <keith.busch@intel.com>,
	"Hannes Reinecke" <hare@suse.de>,
	"Andreas Färber" <afaerber@suse.de>
Subject: Re: [Qemu-devel] [PATCH] NVMe: Initial commit to add an NVM Express device
Date: Thu, 13 Dec 2012 10:34:58 +0100	[thread overview]
Message-ID: <50C9A142.8070603@redhat.com> (raw)
In-Reply-To: <50C99C0C.80704@redhat.com>

Il 13/12/2012 10:12, Kevin Wolf ha scritto:
>>> There seems to be an issue with the bdrv_aio_[readv/writev]
>>> routines. I added some additional tracing in the block and
>>> coroutine code, and well, long story short, the coroutine
>>> "bdrv_co_io_em" needs to call "qemu_coroutine_yield" before his
>>> aio callback "bdrv_co_io_em_complete" invokes
>>> "qemu_coroutine_enter". It does not always win this race in my
>>> experiments, and qemu aborts with a recursive re-entry error. I
>>> don't know this coroutine code well enough to propose a fix --
>>> I'd say maybe use locks but I think that defeats the purpose of
>>> using coroutines if I understand them correctly?
>
> The block layer, like most other qemu functions, is supposed to run 
> under the qemu_global_mutex (also called BQL). Do you call into it
> from a different thread that doesn't take this lock?

Yes, that's the main problem.

Paolo

  reply	other threads:[~2012-12-13  9:35 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-08  0:05 [Qemu-devel] [PATCH] NVMe: Initial commit to add an NVM Express device Keith Busch
2012-12-08  7:38 ` Stefan Weil
2012-12-08  7:52 ` Stefan Weil
2012-12-08 17:59 ` Andreas Färber
2012-12-08 19:20   ` Keith Busch
2012-12-08 20:59     ` Andreas Färber
2012-12-10 12:36     ` Kevin Wolf
2012-12-10 14:11       ` Stefan Hajnoczi
2012-12-10 16:28         ` Busch, Keith
2012-12-13  0:13         ` Busch, Keith
2012-12-13  9:12           ` Kevin Wolf
2012-12-13  9:34             ` Paolo Bonzini [this message]
2012-12-13  9:33 ` Paolo Bonzini

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=50C9A142.8070603@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=afaerber@suse.de \
    --cc=hare@suse.de \
    --cc=keith.busch@gmail.com \
    --cc=keith.busch@intel.com \
    --cc=kwolf@redhat.com \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@gmail.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).