diff -up ./drivers/acpi/apei/hest.c.w64 ./drivers/acpi/apei/hest.c --- ./drivers/acpi/apei/hest.c.w64 2017-02-07 02:27:30.000000000 +0900 +++ ./drivers/acpi/apei/hest.c 2017-02-07 02:29:12.000000000 +0900 @@ -128,9 +128,11 @@ EXPORT_SYMBOL_GPL(apei_hest_parse); */ static int __init hest_parse_cmc(struct acpi_hest_header *hest_hdr, void *data) { - int i; struct acpi_hest_ia_corrected *cmc; +#ifdef CONFIG_X86_MCE struct acpi_hest_ia_error_bank *mc_bank; + int i; +#endif if (hest_hdr->type != ACPI_HEST_TYPE_IA32_CORRECTED_CHECK) return 0; @@ -147,11 +149,13 @@ static int __init hest_parse_cmc(struct if (!(cmc->flags & ACPI_HEST_FIRMWARE_FIRST) || !cmc->num_hardware_banks) return 1; +#ifdef CONFIG_X86_MCE pr_info(HEST_PFX "Enabling Firmware First mode for corrected errors.\n"); mc_bank = (struct acpi_hest_ia_error_bank *)(cmc + 1); for (i = 0; i < cmc->num_hardware_banks; i++, mc_bank++) mce_disable_bank(mc_bank->bank_number); +#endif return 1; }