tpm: tpm_tis: Add the missed acpi_put_table() to fix memory leak
authorHanjun Guo <guohanjun@huawei.com>
Thu, 17 Nov 2022 11:23:42 +0000 (19:23 +0800)
committerJarkko Sakkinen <jarkko@kernel.org>
Thu, 8 Dec 2022 16:20:47 +0000 (16:20 +0000)
commitdb9622f762104459ff87ecdf885cc42c18053fd9
tree8a7d8a460f0f3f6dd623d2edb3609f828839d8d1
parent37e90c374dd11cf4919c51e847c6d6ced0abc555
tpm: tpm_tis: Add the missed acpi_put_table() to fix memory leak

In check_acpi_tpm2(), we get the TPM2 table just to make
sure the table is there, not used after the init, so the
acpi_put_table() should be added to release the ACPI memory.

Fixes: 4cb586a188d4 ("tpm_tis: Consolidate the platform and acpi probe flow")
Cc: stable@vger.kernel.org
Signed-off-by: Hanjun Guo <guohanjun@huawei.com>
Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
drivers/char/tpm/tpm_tis.c