summaryrefslogtreecommitdiffstats
path: root/tpm
diff options
context:
space:
mode:
authorCorey Bryant2013-03-20 17:34:48 +0100
committerLuiz Capitulino2013-03-25 21:21:33 +0100
commit88ca7bcff1806594c80782ad19ba50db47086b23 (patch)
tree0ed51b58394a963d5630f2ed2cbeba1906272a20 /tpm
parentMerge remote-tracking branch 'stefanha/net' into staging (diff)
downloadqemu-88ca7bcff1806594c80782ad19ba50db47086b23.tar.gz
qemu-88ca7bcff1806594c80782ad19ba50db47086b23.tar.xz
qemu-88ca7bcff1806594c80782ad19ba50db47086b23.zip
QMP: Remove duplicate TPM type from query-tpm
Signed-off-by: Corey Bryant <coreyb@linux.vnet.ibm.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Diffstat (limited to 'tpm')
-rw-r--r--tpm/tpm.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/tpm/tpm.c b/tpm/tpm.c
index ffd24956d7..ae00eae618 100644
--- a/tpm/tpm.c
+++ b/tpm/tpm.c
@@ -257,14 +257,13 @@ static TPMInfo *qmp_query_tpm_inst(TPMBackend *drv)
res->id = g_strdup(drv->id);
res->model = drv->fe_model;
- res->type = drv->ops->type;
- res->tpm_options = g_new0(TpmTypeOptions, 1);
+ res->options = g_new0(TpmTypeOptions, 1);
- switch (res->type) {
+ switch (drv->ops->type) {
case TPM_TYPE_PASSTHROUGH:
- res->tpm_options->kind = TPM_TYPE_OPTIONS_KIND_TPM_PASSTHROUGH_OPTIONS;
+ res->options->kind = TPM_TYPE_OPTIONS_KIND_PASSTHROUGH;
tpo = g_new0(TPMPassthroughOptions, 1);
- res->tpm_options->tpm_passthrough_options = tpo;
+ res->options->passthrough = tpo;
if (drv->path) {
tpo->path = g_strdup(drv->path);
tpo->has_path = true;