From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36231) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XvOxb-0000Z9-9X for qemu-devel@nongnu.org; Mon, 01 Dec 2014 06:16:13 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XvOxU-0005pz-0O for qemu-devel@nongnu.org; Mon, 01 Dec 2014 06:16:07 -0500 Received: from mx1.redhat.com ([209.132.183.28]:44810) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XvOxT-0005pp-Ns for qemu-devel@nongnu.org; Mon, 01 Dec 2014 06:15:59 -0500 Date: Mon, 1 Dec 2014 11:15:46 +0000 From: Stefan Hajnoczi Message-ID: <20141201111546.GC4248@stefanha-thinkpad.redhat.com> References: <1417013204-30676-1-git-send-email-kwolf@redhat.com> <1417013204-30676-2-git-send-email-kwolf@redhat.com> <20141128114953.GG13631@stefanha-thinkpad.redhat.com> <20141128121959.GD4035@noname.redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="2/5bycvrmDh4d1IB" Content-Disposition: inline In-Reply-To: <20141128121959.GD4035@noname.redhat.com> Subject: Re: [Qemu-devel] [RFC PATCH 1/3] qemu-img bench List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf Cc: Stefan Hajnoczi , ming.lei@canonical.com, pl@kamp.de, qemu-devel@nongnu.org, pbonzini@redhat.com --2/5bycvrmDh4d1IB Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Nov 28, 2014 at 01:19:59PM +0100, Kevin Wolf wrote: > Am 28.11.2014 um 12:49 hat Stefan Hajnoczi geschrieben: > > On Wed, Nov 26, 2014 at 03:46:42PM +0100, Kevin Wolf wrote: > > > + while (data.n > 0) { > > > + main_loop_wait(false); > > > + } > >=20 > > Why is this false (non-blocking)? This is why you get the main loop > > spun warning message. > >=20 > > Using true (blocking) seems like the right thing. data.n changes as > > part of the callback, which is invoked from the main loop. There is no > > need to be non-blocking. >=20 > I think the parameter has exactly the opposite meaning as what you > describe: >=20 > int main_loop_wait(int nonblocking) >=20 > If it were true, you would get timeout =3D 0. qemu-io and qemu-nbd also > pass false here. Oops, you are right! Sorry, I was confused. Stefan --2/5bycvrmDh4d1IB Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAEBAgAGBQJUfE3iAAoJEJykq7OBq3PInhoH/jPtjYEw0sPkXQdNRwmzNxxE Sovgeo/WL47fy7giqxybWGG2E8OcigDmT12tYzfb2L152/Qtk726vNKyt9+yReen 3MDlX7DeEJ2jpxRAIcFbyXbtcwPqolbgtkpefbX+CjrNZz5Q1qr1hHH9FV9x0fXB YZm1MqQVI523I9DV2ya9yRzHImE4/wzutTM5GsD9MiHfSewYVTLFjgepwNsTDEG8 HvondhPTel9ZmkIhqGhdl58e1S9tz04bV1Gv7sE2SEhotfgdkLpgvbwC47wQGM+n lltmeGCpcECMZlLQJSMwpY3TcQNeAhag8HFWFoLqUKTzSzV7SVWEQu0qF3MsgHo= =eK9u -----END PGP SIGNATURE----- --2/5bycvrmDh4d1IB--