]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
ACPI: APEI: fix the wrong iteration of generic error status block
authorgengdongjiu <gengdongjiu@huawei.com>
Thu, 17 Aug 2017 12:07:18 +0000 (20:07 +0800)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 24 Aug 2017 01:29:46 +0000 (03:29 +0200)
commitc4335fdd38227788178953c101b77180504d7ea0
treeaee9af84eabebc7d57f91df74589f553b7b76757
parentbdb9458a3382ba745a66be5526d3899103c76eda
ACPI: APEI: fix the wrong iteration of generic error status block

The revision 0x300 generic error data entry is different
from the old version, but currently iterating through the
GHES estatus blocks does not take into account this difference.
This will lead to failure to get the right data entry if GHES
has revision 0x300 error data entry.

Update the GHES estatus iteration macro to properly increment using
acpi_hest_get_next(), and correct the iteration termination condition
because the status block data length only includes error data
length.

Convert the CPER estatus checking and printing iteration logic
to use same macro.

Signed-off-by: Dongjiu Geng <gengdongjiu@huawei.com>
Tested-by: Tyler Baicar <tbaicar@codeaurora.org>
Reviewed-by: Borislav Petkov <bp@suse.de>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/apei/apei-internal.h
drivers/firmware/efi/cper.c
include/acpi/ghes.h