Received: from eggs.gnu.org ([2001:4830:134:3::10]:53710) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bSPu6-0004K3-7e for qemu-devel@nongnu.org; Wed, 27 Jul 2016 10:33:48 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bSPu1-0006hU-9F for qemu-devel@nongnu.org; Wed, 27 Jul 2016 10:33:45 -0400 References: <1468845016-43468-1-git-send-email-pasic@linux.vnet.ibm.com> <1469532873-78542-1-git-send-email-pasic@linux.vnet.ibm.com> <7c4bdb1e-f0aa-4a07-2780-37f4f92c6665@redhat.com> <57979B63.1060505@linux.vnet.ibm.com> <87popznsn6.fsf@dusky.pond.sub.org> From: Max Reitz Message-ID: Date: Wed, 27 Jul 2016 16:33:31 +0200 MIME-Version: 1.0 In-Reply-To: <87popznsn6.fsf@dusky.pond.sub.org> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="39MknEtGkgP2hqlCQx0N06LEFgKFInrgR" Subject: Re: [Qemu-devel] [PATCH v2 1/1] block: improve error handling in raw_open List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster Cc: Halil Pasic , qemu-block@nongnu.org, Kevin Wolf , Cornelia Huck , qemu-devel@nongnu.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --39MknEtGkgP2hqlCQx0N06LEFgKFInrgR From: Max Reitz To: Markus Armbruster Cc: Halil Pasic , qemu-block@nongnu.org, Kevin Wolf , Cornelia Huck , qemu-devel@nongnu.org Message-ID: Subject: Re: [Qemu-devel] [PATCH v2 1/1] block: improve error handling in raw_open References: <1468845016-43468-1-git-send-email-pasic@linux.vnet.ibm.com> <1469532873-78542-1-git-send-email-pasic@linux.vnet.ibm.com> <7c4bdb1e-f0aa-4a07-2780-37f4f92c6665@redhat.com> <57979B63.1060505@linux.vnet.ibm.com> <87popznsn6.fsf@dusky.pond.sub.org> In-Reply-To: <87popznsn6.fsf@dusky.pond.sub.org> Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: quoted-printable On 27.07.2016 14:59, Markus Armbruster wrote: > Max Reitz writes: >=20 >> On 26.07.2016 19:18, Halil Pasic wrote: > [...] >>> Frankly, I'm a bit uncomfortable with asking (do not want to be pushy= ), >>> but do you have an opinion on the 'error_report_err' issue (pointed >>> out in the cover letter part)? >> >> You are using drive_add with QMP? As far as I know, one can only do so= >> with human-monitor-command which returns the error string like so: >> >> {"return": "Could not open file: No such file or directory\r\n"} >> >> Apart from that, as for QMP, in theory you're supposed to use >> blockdev-add >=20 > In theory, we're supposed to have completed development of blockdev-add= > into a useful, supported interface... >=20 >> and device_add, I think (although blockdev-add is still >> considered experimental...). >=20 > ... but we haven't, and that's why libvirt isn't using it, and you > shouldn't be using it, either. Yes, you're right, of course. Anyway, I just tried to point out that drive_add is not a QMP command (whereas blockdev-add is), so its error reporting is rather awkward (in contrast to QMP's blockdev-add). So the fact that drive_add's error reporting isn't very nice is not because of drive_add itself but because of the fact that it's an HMP command. The corresponding QMP command thus works just fine. Max >> And blockdev-add will return the error >> string like so: >> >> {"error": {"class": "GenericError", "desc": "Could not open file: No >> such file or directory"}} --39MknEtGkgP2hqlCQx0N06LEFgKFInrgR 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 iQEvBAEBCAAZBQJXmMY7EhxtcmVpdHpAcmVkaGF0LmNvbQAKCRA7sUIC6DisrcGf B/9Dzp85IJoNleJ3l7AeQKz8Ur+tlM8593Z8uQ+QWfUoqjeuWnr1KuzET9c69K3c Kq98LYYB9b7iYI1bNsCSuDVD54cutLpOfo1Th24Q23iZNCWLnYodSbM1JkXwn0P6 RZnLg7x5N6FJYLJKjQzJPcnhr4F/Vme0246T81XhrAlRnt9kaeq9RwQvtSg6ku0L rcRrIL95s6DVdNSOjVogsxGlOo4tIThI+kb9TMSgTEhhWZnXG92bL9kN/fRg0GTx 3nm2f8yM3e+rCri0801fzTnpmWU3MBT95pMch3CheafCvKvxW8XH+p4w/TYnUQFH RWkHu+xSH4E3PeK42hkXyAGT =C7nD -----END PGP SIGNATURE----- --39MknEtGkgP2hqlCQx0N06LEFgKFInrgR--