diff options
author | Hanjun Guo <guohanjun@huawei.com> | 2020-05-07 11:09:18 +0200 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2020-05-09 11:29:17 +0200 |
commit | 11c7bdffc7433090d3692bb99efcc580405ccac8 (patch) | |
tree | 79078a1b86e258f4cccf08dfa651ecd702d99a24 /drivers/acpi | |
parent | ACPI: APEI: Put the error record serialization table for error path (diff) | |
download | linux-11c7bdffc7433090d3692bb99efcc580405ccac8.tar.xz linux-11c7bdffc7433090d3692bb99efcc580405ccac8.zip |
ACPI: APEI: Put the HEST table for error path
hest_tab will be used after hest_init(), but we need to release
it for error path.
Signed-off-by: Hanjun Guo <guohanjun@huawei.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi')
-rw-r--r-- | drivers/acpi/apei/hest.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/acpi/apei/hest.c b/drivers/acpi/apei/hest.c index 822402480f7d..953a2fae8b15 100644 --- a/drivers/acpi/apei/hest.c +++ b/drivers/acpi/apei/hest.c @@ -243,8 +243,8 @@ void __init acpi_hest_init(void) } else if (ACPI_FAILURE(status)) { const char *msg = acpi_format_exception(status); pr_err(HEST_PFX "Failed to get table, %s\n", msg); - rc = -EINVAL; - goto err; + hest_disable = HEST_DISABLED; + return; } rc = apei_hest_parse(hest_parse_cmc, NULL); @@ -266,4 +266,5 @@ void __init acpi_hest_init(void) return; err: hest_disable = HEST_DISABLED; + acpi_put_table((struct acpi_table_header *)hest_tab); } |