Received: from eggs.gnu.org ([2001:4830:134:3::10]:41074) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1c3rzK-0002eD-2p for qemu-devel@nongnu.org; Mon, 07 Nov 2016 17:01:58 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1c3rzJ-0008HU-8H for qemu-devel@nongnu.org; Mon, 07 Nov 2016 17:01:58 -0500 References: <1478553214-497-1-git-send-email-jsnow@redhat.com> <1478553214-497-2-git-send-email-jsnow@redhat.com> From: Eric Blake Message-ID: Date: Mon, 7 Nov 2016 16:01:48 -0600 MIME-Version: 1.0 In-Reply-To: <1478553214-497-2-git-send-email-jsnow@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="FsTU28OeXA4FMe11xmb57tsrWIecXBdvL" Subject: Re: [Qemu-devel] [PATCH v2 1/6] block-backend: Always notify on blk_eject List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: John Snow , qemu-block@nongnu.org Cc: kwolf@redhat.com, pkrempa@redhat.com, qemu-devel@nongnu.org, mreitz@redhat.com, pbonzini@redhat.com This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --FsTU28OeXA4FMe11xmb57tsrWIecXBdvL From: Eric Blake To: John Snow , qemu-block@nongnu.org Cc: kwolf@redhat.com, pkrempa@redhat.com, qemu-devel@nongnu.org, mreitz@redhat.com, pbonzini@redhat.com Message-ID: Subject: Re: [Qemu-devel] [PATCH v2 1/6] block-backend: Always notify on blk_eject References: <1478553214-497-1-git-send-email-jsnow@redhat.com> <1478553214-497-2-git-send-email-jsnow@redhat.com> In-Reply-To: <1478553214-497-2-git-send-email-jsnow@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 11/07/2016 03:13 PM, John Snow wrote: > blk_eject is only used by scsi-disk and atapi, and in both cases we > only attempt to invoke blk_eject if we have a bona-fide change in > tray state. >=20 > The "issue" here is that the tray state does not generate a QMP event > unless there is a medium/BDS attached to the device, so if libvirt et a= l > are waiting for a tray event to occur from an empty-but-closed drive, > software opening that drive will not emit an event and libvirt will > wait forever. >=20 > Change this by modifying blk_eject to always emit an event, instead of > conditionally on a "real" backend eject. >=20 > Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=3D1373264 >=20 > Reported-by: Peter Krempa > Signed-off-by: John Snow > --- > block/block-backend.c | 13 +++++++------ > 1 file changed, 7 insertions(+), 6 deletions(-) Reviewed-by: Eric Blake --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --FsTU28OeXA4FMe11xmb57tsrWIecXBdvL Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJYIPnNAAoJEKeha0olJ0NqBMQIAIRADeQdH9SQH+IDfd5+URD9 NM7aqLYQPUwsOGINRQvfvng5pN45sR9p7wpofoXA7rIpwWsyK/iWlKJKLR+aYeG+ RgAct9Jn+IkC5YNolp7jgnZAWpfZhNFPRNHfc/f78Ct62y2NQwVrAEs5ikKN5jZl grXrnZiWEs/81HUv9Qdc+zP9Bw7be0PKx4J34pxmZZ8lrpHqrmNq4dNST5KazCSp tDEwR8Vp1iF2lq7h2TP042IQDNFn1Ufgfd0QhZ4Ee6/E/iO9oPrvysJxqq0UozyM XOxGm1XwxFpVLutyCrxKv1afanrw1N0baOd7sMQ5fyWgAaEI1IYoJwZDf8D8dw8= =hj63 -----END PGP SIGNATURE----- --FsTU28OeXA4FMe11xmb57tsrWIecXBdvL--