diff options
Diffstat (limited to 'hw/tpm/tpm_passthrough.c')
-rw-r--r-- | hw/tpm/tpm_passthrough.c | 36 |
1 files changed, 1 insertions, 35 deletions
diff --git a/hw/tpm/tpm_passthrough.c b/hw/tpm/tpm_passthrough.c index 815a72ef9a..4c21e52b7c 100644 --- a/hw/tpm/tpm_passthrough.c +++ b/hw/tpm/tpm_passthrough.c @@ -54,7 +54,6 @@ struct TPMPassthruState { bool tpm_executing; bool tpm_op_canceled; int cancel_fd; - bool had_startup_error; TPMVersion tpm_version; }; @@ -227,29 +226,11 @@ static void tpm_passthrough_handle_request(TPMBackend *tb, TPMBackendCmd cmd) } } -/* - * Start the TPM (thread). If it had been started before, then terminate - * and start it again. - */ -static int tpm_passthrough_startup_tpm(TPMBackend *tb) -{ - return 0; -} - static void tpm_passthrough_reset(TPMBackend *tb) { - TPMPassthruState *tpm_pt = TPM_PASSTHROUGH(tb); - DPRINTF("tpm_passthrough: CALL TO TPM_RESET!\n"); tpm_passthrough_cancel_cmd(tb); - - tpm_pt->had_startup_error = false; -} - -static int tpm_passthrough_init(TPMBackend *tb) -{ - return 0; } static bool tpm_passthrough_get_tpm_established_flag(TPMBackend *tb) @@ -264,13 +245,6 @@ static int tpm_passthrough_reset_tpm_established_flag(TPMBackend *tb, return 0; } -static bool tpm_passthrough_get_startup_error(TPMBackend *tb) -{ - TPMPassthruState *tpm_pt = TPM_PASSTHROUGH(tb); - - return tpm_pt->had_startup_error; -} - static size_t tpm_passthrough_realloc_buffer(TPMSizedBuffer *sb) { size_t wanted_size = 4096; /* Linux tpm.c buffer size */ @@ -309,11 +283,6 @@ static void tpm_passthrough_cancel_cmd(TPMBackend *tb) } } -static const char *tpm_passthrough_create_desc(void) -{ - return "Passthrough TPM backend driver"; -} - static TPMVersion tpm_passthrough_get_tpm_version(TPMBackend *tb) { TPMPassthruState *tpm_pt = TPM_PASSTHROUGH(tb); @@ -453,13 +422,10 @@ static const QemuOptDesc tpm_passthrough_cmdline_opts[] = { static const TPMDriverOps tpm_passthrough_driver = { .type = TPM_TYPE_PASSTHROUGH, .opts = tpm_passthrough_cmdline_opts, - .desc = tpm_passthrough_create_desc, + .desc = "Passthrough TPM backend driver", .create = tpm_passthrough_create, - .init = tpm_passthrough_init, - .startup_tpm = tpm_passthrough_startup_tpm, .realloc_buffer = tpm_passthrough_realloc_buffer, .reset = tpm_passthrough_reset, - .had_startup_error = tpm_passthrough_get_startup_error, .cancel_cmd = tpm_passthrough_cancel_cmd, .get_tpm_established_flag = tpm_passthrough_get_tpm_established_flag, .reset_tpm_established_flag = tpm_passthrough_reset_tpm_established_flag, |