From nobody Mon Feb 9 09:52:42 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=philmd@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=philmd@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1601645991; cv=none; d=zohomail.com; s=zohoarc; b=OHUN8d1rZSedzE7pd5N/zTOxxiQa5tl0hJoZIh0aDRoWXEugQzdgiM6Jo+d/jh69drxWo/NcoX8JnAlIaiyUWeBFZQv+3ISMEeEdi19GE4k39JS0O0VYF6z+YsJlIb6cJGSRPVdnRitzlX/e8ISIxfYZLSTbU5Kf9lGhAcbN3KA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1601645991; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:To; bh=tvVXKSfjWkoZJFhCHk1dGuX00kfrmBZkcI+Ka1f3ccA=; b=Fyhb+ngF4gCUGYOhjrY4BUdNEiR2GOZUd4E76N1TpebD3uX/uyr6oisFKfmIvZNlu5GGh/hC7ZxgA4krBltVtvOF2lc6OdsgHhkpHE4pGqo6o2zjvXaQCwa+Fc+cc1oitgoL4MMnYU4YkH37+/l6dXs90gAg2IoZ/S5BLoTZjBw= 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=philmd@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= 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 1601645991979239.86056648217095; Fri, 2 Oct 2020 06:39:51 -0700 (PDT) Received: from mail-wr1-f72.google.com (mail-wr1-f72.google.com [209.85.221.72]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-4-rNZRteNTM5W_ZM9dE8OzWw-1; Fri, 02 Oct 2020 09:39:49 -0400 Received: by mail-wr1-f72.google.com with SMTP id a2so561892wrp.8 for ; Fri, 02 Oct 2020 06:39:49 -0700 (PDT) Return-Path: Return-Path: Received: from localhost.localdomain (74.red-83-53-161.dynamicip.rima-tde.net. [83.53.161.74]) by smtp.gmail.com with ESMTPSA id d18sm1779795wrm.10.2020.10.02.06.39.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 Oct 2020 06:39:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1601645990; h=from:from: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; bh=tvVXKSfjWkoZJFhCHk1dGuX00kfrmBZkcI+Ka1f3ccA=; b=WLnR9ETfDS4r/AKBNje6d4yfmzyiqvTwaUreLh30eQ6pSwV7xqInImU0HYuHJ6YTXF3kMc S3kGoKovKhN2PMSpSJ2RtMuEXJja6ki5bjjaKx0hfMDqDbTsyXpBx4VZdsKb75uPqd5H92 gbs29dFhDH749aiGKcl1vJKdg1qwXnI= X-MC-Unique: rNZRteNTM5W_ZM9dE8OzWw-1 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=tvVXKSfjWkoZJFhCHk1dGuX00kfrmBZkcI+Ka1f3ccA=; b=PGL59d0X7WozZpgAQgJNMnkKjSsLq6jCAm9IH6VMkyyZVkYimegXnEQhpQ9xEWmv/C l3OvOf7p1cEaByhSJEYCDaBGJjS79FiKMtzE9Vqk8K+moyWuFXJK+1Xtenz8xTi7xrkB uS7mg4ZTnzIkQ7DBkzu3R009U9ndmhzFV/+rd69Bcamf71yfI5QVtdOPpVIc9aUkASJB 8tBkCpLAscqXk69iTns/qi/d8Z7PnqFfAmnDKnBTCsLzQ8yElftkyfGz/Kz1qgqOd6SI S5Plp8akQt+nnNLUWnVjObXn43tPd3s+1znp4nfcNqDM1zBWUs7oNfgk1YDDToaelsYd B/Ew== X-Gm-Message-State: AOAM533C4ckMrLuG5grtG/1YYWu+icGInkpIQJGHdF82Y3cg/kxYI2Cm LxlI77IGvrNUq8Cdex2F2hh2+UmB2H/7uDJgQvi0xWMF4q3M05ItAFjcNlFYHBsKUtlAKGjnqmi q+cDygnpl7qLiZw== X-Received: by 2002:adf:9bcf:: with SMTP id e15mr3075486wrc.93.1601645987716; Fri, 02 Oct 2020 06:39:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwXZ0DUtM8ag+Gzw12Jr6+YpFZwVTHU0tycGVTY/5KbE5Wb3wWL4PNJqnB0Xi/zQrZCrmxEzA== X-Received: by 2002:adf:9bcf:: with SMTP id e15mr3075463wrc.93.1601645987503; Fri, 02 Oct 2020 06:39:47 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Richard Henderson , Marcel Apfelbaum , "Dr. David Alan Gilbert" , xen-devel@lists.xenproject.org, Gerd Hoffmann , Markus Armbruster , Paolo Bonzini , Juan Quintela , Stefano Stabellini , Anthony Perard , Eric Blake , Paul Durrant , Peter Maydell , "Michael S. Tsirkin" , Eduardo Habkost , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PATCH 4/5] qapi: Restrict 'query-kvm' command to machine code Date: Fri, 2 Oct 2020 15:39:22 +0200 Message-Id: <20201002133923.1716645-5-philmd@redhat.com> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20201002133923.1716645-1-philmd@redhat.com> References: <20201002133923.1716645-1-philmd@redhat.com> MIME-Version: 1.0 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=philmd@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) Restricting query-kvm to machine.json pulls slightly less QAPI-generated code into user-mode and tools. Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- qapi/machine.json | 30 ++++++++++++++++++++++++++++++ qapi/misc.json | 30 ------------------------------ 2 files changed, 30 insertions(+), 30 deletions(-) diff --git a/qapi/machine.json b/qapi/machine.json index 5a3bbcae01..7c9a263778 100644 --- a/qapi/machine.json +++ b/qapi/machine.json @@ -561,6 +561,36 @@ ## { 'command': 'inject-nmi' } =20 +## +# @KvmInfo: +# +# Information about support for KVM acceleration +# +# @enabled: true if KVM acceleration is active +# +# @present: true if KVM acceleration is built into this executable +# +# Since: 0.14.0 +## +{ 'struct': 'KvmInfo', 'data': {'enabled': 'bool', 'present': 'bool'} } + +## +# @query-kvm: +# +# Returns information about KVM acceleration +# +# Returns: @KvmInfo +# +# Since: 0.14.0 +# +# Example: +# +# -> { "execute": "query-kvm" } +# <- { "return": { "enabled": true, "present": true } } +# +## +{ 'command': 'query-kvm', 'returns': 'KvmInfo' } + ## # @NumaOptionsType: # diff --git a/qapi/misc.json b/qapi/misc.json index 2a5d03a69e..9813893269 100644 --- a/qapi/misc.json +++ b/qapi/misc.json @@ -68,36 +68,6 @@ ## { 'command': 'query-name', 'returns': 'NameInfo', 'allow-preconfig': true } =20 -## -# @KvmInfo: -# -# Information about support for KVM acceleration -# -# @enabled: true if KVM acceleration is active -# -# @present: true if KVM acceleration is built into this executable -# -# Since: 0.14.0 -## -{ 'struct': 'KvmInfo', 'data': {'enabled': 'bool', 'present': 'bool'} } - -## -# @query-kvm: -# -# Returns information about KVM acceleration -# -# Returns: @KvmInfo -# -# Since: 0.14.0 -# -# Example: -# -# -> { "execute": "query-kvm" } -# <- { "return": { "enabled": true, "present": true } } -# -## -{ 'command': 'query-kvm', 'returns': 'KvmInfo' } - ## # @IOThreadInfo: # --=20 2.26.2