aboutsummaryrefslogtreecommitdiff
path: root/tpm.c
diff options
context:
space:
mode:
authorStefan Berger <stefanb@linux.vnet.ibm.com>2013-04-22 10:41:39 -0400
committerAnthony Liguori <aliguori@us.ibm.com>2013-04-23 10:40:40 -0500
commitbb71623811686ce3c34ce724f073f5c5dd95f51b (patch)
tree2d5dba20544e7890c1923f066d28d6c0ecdcecaa /tpm.c
parent13daf6cad05a65970381cd8b876426d55133aadf (diff)
downloadqemu-arm-bb71623811686ce3c34ce724f073f5c5dd95f51b.tar.gz
Move TPM passthrough specific command line options to backend structure
Move the TPM passthrough specific command line options to the passthrough backend implementation and attach them to the backend's interface structure. Add code to tpm.c for validating the TPM command line options. Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com> Reviewed-by: Corey Bryan <coreyb@linux.vnet.ibm.com> Message-id: 1366641699-21420-1-git-send-email-stefanb@linux.vnet.ibm.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'tpm.c')
-rw-r--r--tpm.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/tpm.c b/tpm.c
index c91da43cf1..f13c9bc80c 100644
--- a/tpm.c
+++ b/tpm.c
@@ -159,6 +159,14 @@ static int configure_tpm(QemuOpts *opts)
return 1;
}
+ /* validate backend specific opts */
+ qemu_opts_validate(opts, be->opts, &local_err);
+ if (error_is_set(&local_err)) {
+ qerror_report_err(local_err);
+ error_free(local_err);
+ return 1;
+ }
+
drv = be->create(opts, id);
if (!drv) {
return 1;