From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42269) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bBN8X-0005zU-Aj for qemu-devel@nongnu.org; Fri, 10 Jun 2016 10:10:14 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bBN8T-0001e2-9q for qemu-devel@nongnu.org; Fri, 10 Jun 2016 10:10:13 -0400 Received: from mx1.redhat.com ([209.132.183.28]:37813) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bBN8T-0001de-10 for qemu-devel@nongnu.org; Fri, 10 Jun 2016 10:10:09 -0400 References: <146549365829.19073.16167213667487620246.stgit@fimbulvetr.bsc.es> <146549369062.19073.12756219669255027925.stgit@fimbulvetr.bsc.es> From: Eric Blake Message-ID: <575ACA3E.9060001@redhat.com> Date: Fri, 10 Jun 2016 08:10:06 -0600 MIME-Version: 1.0 In-Reply-To: <146549369062.19073.12756219669255027925.stgit@fimbulvetr.bsc.es> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="NfrrjB6cL4HiIGiu7SCr2UADD1TIBfNSv" Subject: Re: [Qemu-devel] [PATCH v2 6/6] trace: Add QAPI/QMP interfaces to query and control per-vCPU tracing state List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: =?UTF-8?Q?Llu=c3=ads_Vilanova?= , qemu-devel@nongnu.org Cc: Eduardo Habkost , Stefan Hajnoczi , Markus Armbruster , Luiz Capitulino This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --NfrrjB6cL4HiIGiu7SCr2UADD1TIBfNSv Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 06/09/2016 11:34 AM, Llu=C3=ADs Vilanova wrote: > Signed-off-by: Llu=C3=ADs Vilanova > Reviewed-by: Stefan Hajnoczi > --- > monitor.c | 4 +- > qapi/trace.json | 20 ++++++-- > qmp-commands.hx | 18 ++++++- > trace/qmp.c | 143 ++++++++++++++++++++++++++++++++++++++++++++---= -------- > 4 files changed, 147 insertions(+), 38 deletions(-) >=20 > +++ b/qapi/trace.json > @@ -1,6 +1,6 @@ > # -*- mode: python -*- > # > -# Copyright (C) 2011-2014 Llu=C3=ADs Vilanova > +# Copyright (C) 2011-2016 Llu=C3=ADs Vilanova > # > # This work is licensed under the terms of the GNU GPL, version 2 or l= ater. > # See the COPYING file in the top-level directory. > @@ -29,11 +29,12 @@ > # > # @name: Event name. > # @state: Tracing state. > +# @vcpu: Whether this is a per-vCPU event (since 2.6). s/2.6/2.7/ > # > # Since 2.2 > ## > { 'struct': 'TraceEventInfo', > - 'data': {'name': 'str', 'state': 'TraceEventState'} } > + 'data': {'name': 'str', 'state': 'TraceEventState', 'vcpu': 'bool'} = } > =20 > ## > # @trace-event-get-state: > @@ -41,13 +42,18 @@ > # Query the state of events. > # > # @name: Event name pattern (case-sensitive glob). > +# @vcpu: #optional The vCPU to check (any by default; since 2.6). and again > # > # Returns: a list of @TraceEventInfo for the matching events > # > +# For any event without the "vcpu" property: > +# - If @name is a pattern and @vcpu is set, events are ignored. > +# - If @name is not a pattern and @vcpu is set, an error is raised. > +# > # Since 2.2 > ## > { 'command': 'trace-event-get-state', > - 'data': {'name': 'str'}, > + 'data': {'name': 'str', '*vcpu': 'int'}, > 'returns': ['TraceEventInfo'] } > =20 > ## > @@ -58,8 +64,14 @@ > # @name: Event name pattern (case-sensitive glob). > # @enable: Whether to enable tracing. > # @ignore-unavailable: #optional Do not match unavailable events with = @name. > +# @vcpu: #optional The vCPU to act upon (all by default; since 2.6). and again > +# > +# For any event without the "vcpu" property: > +# - If @name is a pattern and @vcpu is set, events are ignored. > +# - If @name is not a pattern and @vcpu is set, an error is raised. > # > # Since 2.2 > ## > { 'command': 'trace-event-set-state', > - 'data': {'name': 'str', 'enable': 'bool', '*ignore-unavailable': 'bo= ol'} } > + 'data': {'name': 'str', 'enable': 'bool', '*ignore-unavailable': 'bo= ol', > + '*vcpu': 'int'} } > diff --git a/qmp-commands.hx b/qmp-commands.hx > index 28801a2..ae1e533 100644 > --- a/qmp-commands.hx > @@ -4773,7 +4786,6 @@ Move mouse pointer to absolute coordinates (20000= , 400). > { "type": "abs", "data" : { "axis": "x", "value" : 2000= 0 } }, > { "type": "abs", "data" : { "axis": "y", "value" : 400 = } } ] } } > <- { "return": {} } > - > EQMP Spurious hunk. --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --NfrrjB6cL4HiIGiu7SCr2UADD1TIBfNSv 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/ iQEcBAEBCAAGBQJXWso+AAoJEKeha0olJ0Nq5nsH/RRIJ8B/Xl3Npri1xLJT22Sr NDg/d8KO9qIrbSAYmLyBKwCEecucL6eylF/1vzoYAwPTodQ6fCGvbe6PSi3+AByT rKjoUD2jB3t1/yikUrd+GiBaM+fTxXDcdeOm1pPeV1DEv2nMgysVhJPA+mmeX4NC NN+i955mdnrQwdsBKw+HZ7PliP2cieqci5Du4Kx5D5hV9c1TuCsSmi8H/dqdvPiF OMaOAbccNCmWREMDgyygJDhS+/9mZtm+X2D/6C9VBvpNzDUWlhxm6noKjA+wvBJ9 mXl/9P8SPtWI7CQpRj7ohRS0V6tvf7zF2tH07BbQzNuXT2LhmAtDlUKKoBhBc/8= =Gdgv -----END PGP SIGNATURE----- --NfrrjB6cL4HiIGiu7SCr2UADD1TIBfNSv--