[PATCH v6 04/10] qemu_tpm, security, tests: change 'switch' clauses for 'if'