diff options
author | Marc-André Lureau <marcandre.lureau@redhat.com> | 2017-10-10 00:55:57 +0200 |
---|---|---|
committer | Stefan Berger <stefanb@linux.vnet.ibm.com> | 2017-10-19 11:42:29 -0400 |
commit | d2809766250d0e6b358588819c6c2e422685edfe (patch) | |
tree | c2131386621368bc0e9643a26a9cc897d56cbe75 /hw/tpm/tpm_tis.c | |
parent | c106ede9c85bf4b38c52dbee96b00c2aa0a97dee (diff) | |
download | qemu-d2809766250d0e6b358588819c6c2e422685edfe.zip qemu-d2809766250d0e6b358588819c6c2e422685edfe.tar.gz qemu-d2809766250d0e6b358588819c6c2e422685edfe.tar.bz2 |
tpm: remove locty_data from TPMState
Keep it internal to tpm-tis instead.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Diffstat (limited to 'hw/tpm/tpm_tis.c')
-rw-r--r-- | hw/tpm/tpm_tis.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/hw/tpm/tpm_tis.c b/hw/tpm/tpm_tis.c index ffed7bf..ad28456 100644 --- a/hw/tpm/tpm_tis.c +++ b/hw/tpm/tpm_tis.c @@ -203,12 +203,10 @@ static void tpm_tis_sts_set(TPMLocality *l, uint32_t flags) static void tpm_tis_tpm_send(TPMState *s, uint8_t locty) { TPMTISEmuState *tis = &s->s.tis; + TPMLocality *locty_data = &tis->loc[locty]; tpm_tis_show_buffer(&tis->loc[locty].w_buffer, "tpm_tis: To TPM"); - s->locty_number = locty; - s->locty_data = &tis->loc[locty]; - /* * w_offset serves as length indicator for length of data; * it's reset when the response comes back @@ -217,10 +215,10 @@ static void tpm_tis_tpm_send(TPMState *s, uint8_t locty) s->cmd = (TPMBackendCmd) { .locty = locty, - .in = s->locty_data->w_buffer.buffer, - .in_len = s->locty_data->w_offset, - .out = s->locty_data->r_buffer.buffer, - .out_len = s->locty_data->r_buffer.size + .in = locty_data->w_buffer.buffer, + .in_len = locty_data->w_offset, + .out = locty_data->r_buffer.buffer, + .out_len = locty_data->r_buffer.size }; tpm_backend_deliver_request(s->be_driver, &s->cmd); |