[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL v1 09/12] hw/tpm: Move few declarations from 'tpm_util.h' to 'tpm_
From: |
Stefan Berger |
Subject: |
[PULL v1 09/12] hw/tpm: Move few declarations from 'tpm_util.h' to 'tpm_int.h' |
Date: |
Tue, 23 Jun 2020 07:41:11 -0400 |
From: Philippe Mathieu-Daudé <philmd@redhat.com>
We are going to make "tpm_util.h" publicly accessible by
moving it to the include/ directory in a pair of commits.
Keep declarations internals to hw/tpm/ in "tpm_int.h".
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Reviewed-by: Stefan Berger <stefanb@linux.ibm.com>
Message-id: 20200612085444.8362-10-philmd@redhat.com
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
---
hw/tpm/tpm_int.h | 11 +++++++++++
hw/tpm/tpm_util.h | 10 ----------
2 files changed, 11 insertions(+), 10 deletions(-)
diff --git a/hw/tpm/tpm_int.h b/hw/tpm/tpm_int.h
index fd5ebc6489..9f72879d89 100644
--- a/hw/tpm/tpm_int.h
+++ b/hw/tpm/tpm_int.h
@@ -13,6 +13,7 @@
#define TPM_TPM_INT_H
#include "qemu/option.h"
+#include "sysemu/tpm.h"
#define TPM_STANDARD_CMDLINE_OPTS \
{ \
@@ -74,4 +75,14 @@ struct tpm_resp_hdr {
#define TPM_RC_FAILURE 0x101
#define TPM_RC_LOCALITY 0x907
+int tpm_util_get_buffer_size(int tpm_fd, TPMVersion tpm_version,
+ size_t *buffersize);
+
+typedef struct TPMSizedBuffer {
+ uint32_t size;
+ uint8_t *buffer;
+} TPMSizedBuffer;
+
+void tpm_sized_buffer_reset(TPMSizedBuffer *tsb);
+
#endif /* TPM_TPM_INT_H */
diff --git a/hw/tpm/tpm_util.h b/hw/tpm/tpm_util.h
index 7889081fba..d524935576 100644
--- a/hw/tpm/tpm_util.h
+++ b/hw/tpm/tpm_util.h
@@ -66,19 +66,9 @@ static inline void tpm_cmd_set_error(void *b, uint32_t error)
stl_be_p(b + 6, error);
}
-int tpm_util_get_buffer_size(int tpm_fd, TPMVersion tpm_version,
- size_t *buffersize);
-
#define DEFINE_PROP_TPMBE(_n, _s, _f) \
DEFINE_PROP(_n, _s, _f, qdev_prop_tpm, TPMBackend *)
-typedef struct TPMSizedBuffer {
- uint32_t size;
- uint8_t *buffer;
-} TPMSizedBuffer;
-
-void tpm_sized_buffer_reset(TPMSizedBuffer *tsb);
-
void tpm_util_show_buffer(const unsigned char *buffer,
size_t buffer_size, const char *string);
--
2.24.1
- [PULL v1 00/12] Merge tpm 2020/06/23 v1, Stefan Berger, 2020/06/23
- [PULL v1 02/12] backends: Add TPM files into their own directory, Stefan Berger, 2020/06/23
- [PULL v1 01/12] docs/specs/tpm: Correct header path name, Stefan Berger, 2020/06/23
- [PULL v1 05/12] hw/tpm: Include missing 'qemu/option.h' header, Stefan Berger, 2020/06/23
- [PULL v1 04/12] hw/tpm: Do not include 'qemu/osdep.h' in header, Stefan Berger, 2020/06/23
- [PULL v1 03/12] hw/tpm: Rename TPMDEV as TPM_BACKEND in Kconfig, Stefan Berger, 2020/06/23
- [PULL v1 06/12] hw/tpm: Move 'hw/acpi/tpm.h' inclusion from header to sources, Stefan Berger, 2020/06/23
- [PULL v1 09/12] hw/tpm: Move few declarations from 'tpm_util.h' to 'tpm_int.h',
Stefan Berger <=
- [PULL v1 07/12] hw/tpm: Remove unnecessary 'tpm_int.h' header inclusion, Stefan Berger, 2020/06/23
- [PULL v1 08/12] hw/tpm: Make TRACE_TPM_UTIL_SHOW_BUFFER check local to tpm_util.c, Stefan Berger, 2020/06/23
- [PULL v1 10/12] hw/tpm: Move DEFINE_PROP_TPMBE() macro to 'tmp_prop.h' local header, Stefan Berger, 2020/06/23
- [PULL v1 11/12] hw/tpm: Make 'tpm_util.h' publicly accessible as "sysemu/tpm_util.h", Stefan Berger, 2020/06/23
- [PULL v1 12/12] tpm: Move backend code under the 'backends/' directory, Stefan Berger, 2020/06/23
- Re: [PULL v1 00/12] Merge tpm 2020/06/23 v1, Peter Maydell, 2020/06/25