From patchwork Tue Mar 26 12:38:44 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luiz Capitulino X-Patchwork-Id: 231190 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 98CF52C0079 for ; Tue, 26 Mar 2013 23:39:56 +1100 (EST) Received: from localhost ([::1]:58068 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UKTAQ-0002LA-Ri for incoming@patchwork.ozlabs.org; Tue, 26 Mar 2013 08:39:54 -0400 Received: from eggs.gnu.org ([208.118.235.92]:38337) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UKT9T-0001Wl-0W for qemu-devel@nongnu.org; Tue, 26 Mar 2013 08:38:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UKT9R-0002E0-23 for qemu-devel@nongnu.org; Tue, 26 Mar 2013 08:38:54 -0400 Received: from mx1.redhat.com ([209.132.183.28]:33655) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UKT9Q-0002Du-PE for qemu-devel@nongnu.org; Tue, 26 Mar 2013 08:38:52 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r2QCcqKo023893 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 26 Mar 2013 08:38:52 -0400 Received: from localhost (ovpn-113-125.phx2.redhat.com [10.3.113.125]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r2QCcpS8026700; Tue, 26 Mar 2013 08:38:51 -0400 From: Luiz Capitulino To: qemu-devel@nongnu.org Date: Tue, 26 Mar 2013 08:38:44 -0400 Message-Id: <1364301526-11431-3-git-send-email-lcapitulino@redhat.com> In-Reply-To: <1364301526-11431-1-git-send-email-lcapitulino@redhat.com> References: <1364301526-11431-1-git-send-email-lcapitulino@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 209.132.183.28 Cc: aliguori@us.ibm.com Subject: [Qemu-devel] [PULL 2/4] QMP: TPM QMP and man page documentation updates X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: Corey Bryant Signed-off-by: Corey Bryant Reviewed-by: Eric Blake Reviewed-by: Markus Armbruster Signed-off-by: Luiz Capitulino --- qemu-options.hx | 3 ++- qmp-commands.hx | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 60 insertions(+), 1 deletion(-) diff --git a/qemu-options.hx b/qemu-options.hx index d7afeab..c40ba55 100644 --- a/qemu-options.hx +++ b/qemu-options.hx @@ -2241,7 +2241,8 @@ Backend type must be: @option{passthrough}. The specific backend type will determine the applicable options. -The @code{-tpmdev} option requires a @code{-device} option. +The @code{-tpmdev} option creates the TPM backend and requires a +@code{-device} option that specifies the TPM frontend interface model. Options to each backend are described below. diff --git a/qmp-commands.hx b/qmp-commands.hx index b370060..3aa6bd1 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -2721,18 +2721,76 @@ EQMP .mhandler.cmd_new = qmp_marshal_input_query_tpm, }, +SQMP +query-tpm +--------- + +Return information about the TPM device. + +Arguments: None + +Example: + +-> { "execute": "query-tpm" } +<- { "return": + [ + { "model": "tpm-tis", + "options": + { "type": "passthrough", + "data": + { "cancel-path": "/sys/class/misc/tpm0/device/cancel", + "path": "/dev/tpm0" + } + }, + "id": "tpm0" + } + ] + } + +EQMP + { .name = "query-tpm-models", .args_type = "", .mhandler.cmd_new = qmp_marshal_input_query_tpm_models, }, +SQMP +query-tpm-models +---------------- + +Return a list of supported TPM models. + +Arguments: None + +Example: + +-> { "execute": "query-tpm-models" } +<- { "return": [ "tpm-tis" ] } + +EQMP + { .name = "query-tpm-types", .args_type = "", .mhandler.cmd_new = qmp_marshal_input_query_tpm_types, }, +SQMP +query-tpm-types +--------------- + +Return a list of supported TPM types. + +Arguments: None + +Example: + +-> { "execute": "query-tpm-types" } +<- { "return": [ "passthrough" ] } + +EQMP + { .name = "chardev-add", .args_type = "id:s,backend:q",