From nobody Sun Feb 8 14:52:10 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) client-ip=63.128.21.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1616059687; cv=none; d=zohomail.com; s=zohoarc; b=gjeZNbW4byk3Ax6AzrUBrj1e0ho4ctTavq8pHSewapoHe9/iKo1k9eL9K1OktOL66MkhOzOeQNBGeRLlBL5g0kzkh99QiKYOa+4TN9/vujue00z1SQonZtfmhkULRqqGeEeZBLu8lxTKG9v/asyMZvF852IQn1RznH4Fwfu9sbo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1616059687; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=v7ZQJp9eR/Qkdq6MDX5eojjk5iHnG+/HMOTC605Od+c=; b=AOsxjYO7i/NoYg/xQONBjP01B1tt3+pOPl7mg3CQGg7Ondt27qIOWbdzk37A+MtKUAl6Fr9HBayoaD9CBmFhuU1rUhwkNVVBIkf4I+sUK/4ASxEJ6ckAtpCTEE0KfraYQZ/OyyX8CSXdoykEDp0+3w7UYKs/RMO5vRzLAN/HFFg= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [63.128.21.124]) by mx.zohomail.com with SMTPS id 1616059687917250.72376158395275; Thu, 18 Mar 2021 02:28:07 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-480-yqhk5Z4KMhO0nmG-nMefUg-1; Thu, 18 Mar 2021 05:28:04 -0400 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id C37C383DD23; Thu, 18 Mar 2021 09:27:59 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A024E690F3; Thu, 18 Mar 2021 09:27:59 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 372944BB7C; Thu, 18 Mar 2021 09:27:59 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 12I9Rhtm006329 for ; Thu, 18 Mar 2021 05:27:43 -0400 Received: by smtp.corp.redhat.com (Postfix) id 3DA4C66A16; Thu, 18 Mar 2021 09:27:43 +0000 (UTC) Received: from localhost.localdomain.com (ovpn-115-61.ams2.redhat.com [10.36.115.61]) by smtp.corp.redhat.com (Postfix) with ESMTP id 291CF63634; Thu, 18 Mar 2021 09:27:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1616059686; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=v7ZQJp9eR/Qkdq6MDX5eojjk5iHnG+/HMOTC605Od+c=; b=PuTNdpuotwlX7j5lFzPx3qf3HZzcyYwWdutOUudLSGLnYWBNDGjf7mhykxVlMDcaLifuq5 SYivHaomu4u2UQ8UZHNYGXutMW3pwU/yHypmpDdQf+ClzWBAz0z6V4EgJ9cf0u+fbAxi33 pb8FzlrkSu9Sl+Ljg3OKRFCWouYzGpw= X-MC-Unique: yqhk5Z4KMhO0nmG-nMefUg-1 From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= To: qemu-devel@nongnu.org Subject: [PULL 03/13] monitor: remove 'query-events' QMP command Date: Thu, 18 Mar 2021 09:25:02 +0000 Message-Id: <20210318092512.250725-4-berrange@redhat.com> In-Reply-To: <20210318092512.250725-1-berrange@redhat.com> References: <20210318092512.250725-1-berrange@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Cc: Fam Zheng , "Michael S. Tsirkin" , libvir-list@redhat.com, Mark Cave-Ayland , Gerd Hoffmann , qemu-block@nongnu.org, Juan Quintela , Wainer dos Santos Moschetta , Marcel Apfelbaum , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Artyom Tarasenko , Laurent Vivier , Thomas Huth , Eduardo Habkost , Richard Henderson , "Dr. David Alan Gilbert" , Greg Kurz , Cleber Rosa , John Snow , David Gibson , Kevin Wolf , Vladimir Sementsov-Ogievskiy , Max Reitz , qemu-ppc@nongnu.org, Paolo Bonzini X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) The code comment suggests removing QAPIEvent_(str|lookup) symbols too, however, these are both auto-generated as standard for any enum in QAPI. As such it they'll exist whether we use them or not. Reviewed-by: Eric Blake Reviewed-by: Thomas Huth Signed-off-by: Daniel P. Berrang=C3=A9 --- docs/system/deprecated.rst | 6 ----- docs/system/removed-features.rst | 6 +++++ monitor/qmp-cmds-control.c | 24 ----------------- qapi/control.json | 45 -------------------------------- 4 files changed, 6 insertions(+), 75 deletions(-) diff --git a/docs/system/deprecated.rst b/docs/system/deprecated.rst index 8f4d756e35..bffc7e4d59 100644 --- a/docs/system/deprecated.rst +++ b/docs/system/deprecated.rst @@ -249,12 +249,6 @@ The ``query-cpus`` command is replaced by the ``query-= cpus-fast`` command. The ``arch`` output member of the ``query-cpus-fast`` command is replaced by the ``target`` output member. =20 -``query-events`` (since 4.0) -'''''''''''''''''''''''''''' - -The ``query-events`` command has been superseded by the more powerful -and accurate ``query-qmp-schema`` command. - chardev client socket with ``wait`` option (since 4.0) '''''''''''''''''''''''''''''''''''''''''''''''''''''' =20 diff --git a/docs/system/removed-features.rst b/docs/system/removed-feature= s.rst index 372aadceae..e932d023a2 100644 --- a/docs/system/removed-features.rst +++ b/docs/system/removed-features.rst @@ -77,6 +77,12 @@ documentation of ``query-hotpluggable-cpus`` for additio= nal details. =20 Use ``blockdev-change-medium`` or ``change-vnc-password`` instead. =20 +``query-events`` (removed in 6.0) +''''''''''''''''''''''''''''''''' + +The ``query-events`` command has been superseded by the more powerful +and accurate ``query-qmp-schema`` command. + Human Monitor Protocol (HMP) commands ------------------------------------- =20 diff --git a/monitor/qmp-cmds-control.c b/monitor/qmp-cmds-control.c index 509ae870bd..513b547233 100644 --- a/monitor/qmp-cmds-control.c +++ b/monitor/qmp-cmds-control.c @@ -130,30 +130,6 @@ CommandInfoList *qmp_query_commands(Error **errp) return list; } =20 -EventInfoList *qmp_query_events(Error **errp) -{ - /* - * TODO This deprecated command is the only user of - * QAPIEvent_str() and QAPIEvent_lookup[]. When the command goes, - * they should go, too. - */ - EventInfoList *ev_list =3D NULL; - QAPIEvent e; - - for (e =3D 0 ; e < QAPI_EVENT__MAX ; e++) { - const char *event_name =3D QAPIEvent_str(e); - EventInfo *info; - - assert(event_name !=3D NULL); - info =3D g_malloc0(sizeof(*info)); - info->name =3D g_strdup(event_name); - - QAPI_LIST_PREPEND(ev_list, info); - } - - return ev_list; -} - /* * Minor hack: generated marshalling suppressed for this command * ('gen': false in the schema) so we can parse the JSON string diff --git a/qapi/control.json b/qapi/control.json index 2615d5170b..71a838d49e 100644 --- a/qapi/control.json +++ b/qapi/control.json @@ -159,51 +159,6 @@ { 'command': 'query-commands', 'returns': ['CommandInfo'], 'allow-preconfig': true } =20 -## -# @EventInfo: -# -# Information about a QMP event -# -# @name: The event name -# -# Since: 1.2 -## -{ 'struct': 'EventInfo', 'data': {'name': 'str'} } - -## -# @query-events: -# -# Return information on QMP events. -# -# Features: -# @deprecated: This command is deprecated, because its output doesn't -# reflect compile-time configuration. Use 'query-qmp-schema' -# instead. -# -# Returns: A list of @EventInfo. -# -# Since: 1.2 -# -# Example: -# -# -> { "execute": "query-events" } -# <- { -# "return": [ -# { -# "name":"SHUTDOWN" -# }, -# { -# "name":"RESET" -# } -# ] -# } -# -# Note: This example has been shortened as the real response is too long. -# -## -{ 'command': 'query-events', 'returns': ['EventInfo'], - 'features': [ 'deprecated' ] } - ## # @quit: # --=20 2.30.2