From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:54807) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RoKZA-00011F-5S for qemu-devel@nongnu.org; Fri, 20 Jan 2012 14:56:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RoKZ8-0001rs-Dr for qemu-devel@nongnu.org; Fri, 20 Jan 2012 14:56:03 -0500 Received: from mx1.redhat.com ([209.132.183.28]:39224) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RoKZ7-0001rP-Tk for qemu-devel@nongnu.org; Fri, 20 Jan 2012 14:56:02 -0500 Message-ID: <4F19C6CE.9000509@redhat.com> Date: Fri, 20 Jan 2012 12:55:58 -0700 From: Eric Blake MIME-Version: 1.0 References: <1325858501-25741-1-git-send-email-stefanha@linux.vnet.ibm.com> <1325858501-25741-9-git-send-email-stefanha@linux.vnet.ibm.com> <4F18AF21.7010705@redhat.com> <4F192635.9010707@redhat.com> In-Reply-To: <4F192635.9010707@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="------------enig4F3DE73A4427A000D2E6271B" Subject: Re: [Qemu-devel] [PATCH v4 08/15] qmp: add block_job_cancel command List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf Cc: Luiz Capitulino , Marcelo Tosatti , Stefan Hajnoczi , qemu-devel@nongnu.org This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig4F3DE73A4427A000D2E6271B Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 01/20/2012 01:30 AM, Kevin Wolf wrote: >>> +++ b/hmp-commands.hx >> Looking at this from libvirt's perspective, would it be possible to gi= ve >> this a different name? Then libvirt would know that if >> block_job_cancel_async exists, we have the official semantics; and if = it >> doesn't exist, then we can try block_job_cancel as a fallback to see i= f >> we have the old blocking semantics. >> >> But by using the same name as the old unofficial blocking command, it'= s >> difficult to tell if we should expect an event, or whether completion = of >> the command means completion of the cancel. >> >=20 > You're quoting the HMP part, is that intentional? You shouldn't be usin= g > this at all. Oh - I missed the .hx file name when trimming my reply. I agree that libvirt will be using the QMP, not HMP command. >=20 > Anyway, are there even any qemu versions out there that implement an > older interface? The older interface was backported into RHEL 6.2 qemu, so libvirt has to maintain the distinction (although it can equally be argued that the distinction only exists in the RHEL build, and therefore, only the RHEL build of libvirt has to deal with the issues of an early backport of a qemu feature). >> Is there any policy on _ vs - in command names? It seems awkward to >> have block_job_cancel but query-block-jobs. >=20 > block_job_cancel is HMP, whereas query-block-jobs is a QMP command. QMP= > uses - consistently. Not sure if HMP is consistent, but it tends to use= _. OK, on RHEL 6.2, 'help' on HMP includes help for block_job_cancel, and '{"execute":"query-commands"}' on QMP includes {"name":"block_job_cancel"}, with underscores in both locations. So if your new QMP command is block-job-cancel, you've met the goal of having a different spelling from the RHEL backport of the earlier semantics. And if you stuck with underscores, then it's RHEL's problem to solve :) --=20 Eric Blake eblake@redhat.com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --------------enig4F3DE73A4427A000D2E6271B 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.4.11 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEcBAEBCAAGBQJPGcbOAAoJEKeha0olJ0NqErEH/0xPFy+x3ExztvvvAgvZlQ47 sWTbVKJbSglMQdyixlbsDVU0J0nTdcJp04DtGMWK6cXDrnvbW4nKGRa4O2M9OWKc 86Si/4nLICaJHiIvoiY6C9YKPWwpnFvXESbyVFlWvacUk0q1X/j1YksFDCXS8E2G BoY0zn/CcNIB+bvD8HcaEwYO0VgF407YpC9eob3DiA6BxEgD17yDMt1AqUf0LQtW mcl8T28fZ8gsMYBD5HUBrABUqfjGs7aAsE0PNcFQQS2oiQmBpOzvnCi4bFqZdezl 1irpelpd5A1CwzkIjHL5G+Ns2TP2D1zbzrS78O38MqBt/AIaDpomepFkN1ntlx8= =V5HA -----END PGP SIGNATURE----- --------------enig4F3DE73A4427A000D2E6271B--