On 02/15/2018 07:35 AM, Marc-André Lureau wrote:
+#define DPRINTF_STS \ >+ DPRINTF("%s: %d: sts = 0x%08x\n", __func__, __LINE__, sts) >+ >+typedef struct TestState { >+ CompatGMutex data_mutex; >+ CompatGCond data_cond; >+ SocketAddress *addr; >+ QIOChannel *tpm_ioc; >+ GThread *emu_tpm_thread; >+ struct tpm_hdr *tpm_msg; >+} TestState;We could avoid code duplication. What about adding a tests/tpm-emu.c/h ?
ok, let me give that a try.