[PATCH 1/3] tpm: Put the TCPA table buf after using it

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The acpi_get_table() should be coupled with acpi_put_table() if
the mapped table is not used for runtime to release the table
mapping, put the TCPA table buf after using it.

Signed-off-by: Hanjun Guo <guohanjun@xxxxxxxxxx>
---
 drivers/char/tpm/eventlog/acpi.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/char/tpm/eventlog/acpi.c b/drivers/char/tpm/eventlog/acpi.c
index 63ada5e..e8ac30b 100644
--- a/drivers/char/tpm/eventlog/acpi.c
+++ b/drivers/char/tpm/eventlog/acpi.c
@@ -79,6 +79,9 @@ int tpm_read_log_acpi(struct tpm_chip *chip)
 		start = buff->client.log_start_addr;
 		break;
 	}
+
+	acpi_put_table((struct acpi_table_header *)buff);
+
 	if (!len) {
 		dev_warn(&chip->dev, "%s: TCPA log area empty\n", __func__);
 		return -EIO;
-- 
1.7.12.4




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux Kernel]     [Linux Kernel Hardening]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux