From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:32986) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bwRMN-0006ba-Cx for qemu-devel@nongnu.org; Tue, 18 Oct 2016 06:11:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bwRMM-0006rq-M0 for qemu-devel@nongnu.org; Tue, 18 Oct 2016 06:11:03 -0400 Date: Tue, 18 Oct 2016 11:10:55 +0100 From: Stefan Hajnoczi Message-ID: <20161018101055.GE19457@stefanha-x1.localdomain> References: <1476380062-18001-1-git-send-email-pbonzini@redhat.com> <1476380062-18001-16-git-send-email-pbonzini@redhat.com> <20161016164010.GF2128@stefanha-x1.localdomain> <23793765-8363-005e-c752-7534ce174a04@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="6e7ZaeXHKrTJCxdu" Content-Disposition: inline In-Reply-To: <23793765-8363-005e-c752-7534ce174a04@redhat.com> Subject: Re: [Qemu-devel] [PATCH 15/18] block: only call aio_poll on the current thread's AioContext List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: Stefan Hajnoczi , kwolf@redhat.com, qemu-block@nongnu.org, famz@redhat.com, qemu-devel@nongnu.org --6e7ZaeXHKrTJCxdu Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Oct 17, 2016 at 10:04:59AM +0200, Paolo Bonzini wrote: >=20 >=20 > On 16/10/2016 18:40, Stefan Hajnoczi wrote: > > > void bdrv_wakeup(BlockDriverState *bs) > > > { > > > + if (bs->wakeup) { > > > + aio_bh_schedule_oneshot(qemu_get_aio_context(), dummy_bh_cb,= NULL); > > > + } > > > } > >=20 > > Why use a dummy BH instead of aio_notify()? >=20 > Originally I used aio_bh_schedule_oneshot() because aio_notify() is not > enough for aio_poll() to return true. It's also true that I am not > using anymore the result of aio_poll, though. >=20 > Since this is not a fast path and it's not very much stressed by > qemu-iotests, I think it's better if we can move towards making > aio_notify() more or less an internal detail. If you prefer > aio_notify(), however, I can look into that as well. I was just wondering if there is a reason that I missed. Stefan --6e7ZaeXHKrTJCxdu Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEcBAEBAgAGBQJYBfUvAAoJEJykq7OBq3PIg18H/R+VfeK3tSBX1zgaIK0s5LR8 V9co0yr9RFxt/INyXDgrKLK/EVvNUviuFJiU9MK0XPqRWGH4zWwlLw+G4boFNoLa dGky1y7OwYiIxkhOGrTXSydDqv9xR4T6S4bzfVCq1BVW1AiXhBbxYVxga/VF/R84 XEN4KYwm9Dn5py05QUpA51sSMHiRHJNFoR94ajpX7kyXxuWILbcNa3fXLkMgeGGJ 2Vpt+0X3HfK6Tyj4AsK4l42tDKSUrDulXWn+V+LKFTqH+MzeYqYtOJtPq/ontCmg 5suYm/YvgtpFfhgjLFOQGpRFn+0MFgihYu6r6SwmrsVOHxsxYdaDv/E4wO17uzo= =oWhV -----END PGP SIGNATURE----- --6e7ZaeXHKrTJCxdu--