ACPI / APEI / ARM64: APEI initial support for ARM64

This patch provides APEI arch-specific bits for ARM64

Meanwhile,
 (1) Move HEST type (ACPI_HEST_TYPE_IA32_CORRECTED_CHECK) checking to
     a generic place.
 (2) Select HAVE_ACPI_APEI when EFI and ACPI is set on ARM64, because
     arch_apei_get_mem_attribute is using efi_mem_attributes() on
     ARM64.

Signed-off-by: Tomasz Nowicki <[email protected]>
Tested-by: Jonathan (Zhixiong) Zhang <[email protected]>
Signed-off-by: Fu Wei <[email protected]>
[ Fu Wei: improve && upstream ]
Acked-by: Hanjun Guo <[email protected]>
Tested-by: Tyler Baicar <[email protected]>
Acked-by: Will Deacon <[email protected]>
Reviewed-by: Borislav Petkov <[email protected]>
Signed-off-by: Rafael J. Wysocki <[email protected]>
This commit is contained in:
Tomasz Nowicki 2016-12-01 21:51:12 +08:00 • committed by Rafael J. Wysocki
commit 9f9a35a7b6
4 changed files with 33 additions and 7 deletions

View file

@ -123,7 +123,13 @@ EXPORT_SYMBOL_GPL(apei_hest_parse);
*/
static int __init hest_parse_cmc(struct acpi_hest_header *hest_hdr, void *data)
{
return arch_apei_enable_cmcff(hest_hdr, data);
if (hest_hdr->type != ACPI_HEST_TYPE_IA32_CORRECTED_CHECK)
return 0;
if (!acpi_disable_cmcff)
return !arch_apei_enable_cmcff(hest_hdr, data);
return 0;
}
struct ghes_arr {
@ -232,8 +238,9 @@ void __init acpi_hest_init(void)
goto err;
}
if (!acpi_disable_cmcff)
apei_hest_parse(hest_parse_cmc, NULL);
rc = apei_hest_parse(hest_parse_cmc, NULL);
if (rc)
goto err;
if (!ghes_disable) {
rc = apei_hest_parse(hest_parse_ghes_count, &ghes_count);