From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42844) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YGZMV-0006SE-JI for qemu-devel@nongnu.org; Wed, 28 Jan 2015 15:37:20 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YGZMS-0001oQ-BB for qemu-devel@nongnu.org; Wed, 28 Jan 2015 15:37:19 -0500 Received: from mx1.redhat.com ([209.132.183.28]:34582) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YGZMS-0001nv-3c for qemu-devel@nongnu.org; Wed, 28 Jan 2015 15:37:16 -0500 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t0SKbEFN022591 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL) for ; Wed, 28 Jan 2015 15:37:14 -0500 Message-ID: <54C94879.4090406@redhat.com> Date: Wed, 28 Jan 2015 13:37:13 -0700 From: Eric Blake MIME-Version: 1.0 References: <1422387983-32153-1-git-send-email-mreitz@redhat.com> <1422387983-32153-45-git-send-email-mreitz@redhat.com> In-Reply-To: <1422387983-32153-45-git-send-email-mreitz@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="J6wmnXVDtEO8WjJmn6JAOmqD7mvwET777" Subject: Re: [Qemu-devel] [PATCH RESEND 44/50] block: Inquire tray state before tray-moved events List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Max Reitz , qemu-devel@nongnu.org Cc: Kevin Wolf , Fam Zheng , Jeff Cody , Markus Armbruster , Stefan Hajnoczi , John Snow This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --J6wmnXVDtEO8WjJmn6JAOmqD7mvwET777 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 01/27/2015 12:46 PM, Max Reitz wrote: > blk_dev_change_media_cb() is called for all potential tray movements; > however, it is possible to request closing the tray but nothing actuall= y > happening (on a floppy disk drive without a medium). >=20 > Thus, the actual tray status should be inquired before sending a > tray-moved event (and an event should be sent whenever the status > changed). >=20 > Checking @load is now superfluous; it was necessary because it was > possible to change a medium without having explicitly opened the tray > and closed it again (or it might have been possible, at least). This is= > no longer possible, though. >=20 > Signed-off-by: Max Reitz > --- > block/block-backend.c | 17 +++++++---------- > 1 file changed, 7 insertions(+), 10 deletions(-) >=20 Reviewed-by: Eric Blake --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --J6wmnXVDtEO8WjJmn6JAOmqD7mvwET777 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJUyUh5AAoJEKeha0olJ0Nqu40H/1Pbxw9XBv0BEip7IIYYh1y3 Lg2s7rOngF5iDpqtrMZ0m/cgUBsh5tCIwHWo9mlbNlFA2YnK6ja1vdC2qzWQ3q+2 WaYDU5ucJocneykOSdt2gDisLVlPatfpHE10czg/d4brV43U5CXsXgdpYx3EZooV SdPpKw/WZzxvHepwfEtdxFq8Oxrp+qSjJmVsAgsOJF4IMi4XOziGk2955UQD95/9 0OvRmMXFEuBV383tkA3fHOEoh03y3KJxOVMdPrpFEVG10Ip3G3f5S+zECLd5kRfG ERifXDewdaNlsMvM2+62xpJqPywerKLxH7Ftk9phqd5+Uf8K7bt4QZX4LR7Aq5U= =hPOg -----END PGP SIGNATURE----- --J6wmnXVDtEO8WjJmn6JAOmqD7mvwET777--