tests/qtest/tpm-emu: Avoid hangs using abort handlers closing channels
commit255b00b4def7bac1fd313adca931426f4eb10b05
authorStefan Berger <stefanb@linux.ibm.com>
Wed, 11 Jan 2023 13:45:47 +0000 (11 08:45 -0500)
committerStefan Berger <stefanb@linux.ibm.com>
Mon, 16 Jan 2023 22:19:52 +0000 (16 17:19 -0500)
tree37a4d754be163e67ae4da82b703ad1221881a188
parent82df11e78d0baef7ffb7e7933c6fb830ffed087c
tests/qtest/tpm-emu: Avoid hangs using abort handlers closing channels

Install abort handlers that close the TPM control and data channels in
case an abort occurs. The purpose of this is to have QEMU terminate
under abnormal test case failures to resolve intermittent hangs on s390x
hosts running TPM tests for QEMU/x86_64.

Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-id: 20230111134547.3959604-1-stefanb@linux.ibm.com
tests/qtest/tpm-emu.c