summaryrefslogtreecommitdiff
path: root/drivers/acpi/apei
diff options
context:
space:
mode:
authorChen, Gong <gong.chen@linux.intel.com>2013-10-18 14:27:51 -0700
committerTony Luck <tony.luck@intel.com>2013-10-21 15:12:00 -0700
commit833ba4b1ba653f279c78e8e3352527acce8946e6 (patch)
tree32a3f728adc7fe06ac82daff58082955f4fa207d /drivers/acpi/apei
parent31d141e3a666269a3b6fcccddb0351caf7454240 (diff)
downloadlinux-833ba4b1ba653f279c78e8e3352527acce8946e6.tar.gz
linux-833ba4b1ba653f279c78e8e3352527acce8946e6.tar.xz
ACPI, APEI, CPER: Fix status check during error printing
Commit aaf9d93be71c: ACPI / APEI: fix error status check condition for CPER only catches condition check before print, but a similar check is needed during printing CPER error sections. Signed-off-by: Chen, Gong <gong.chen@linux.intel.com> Reviewed-by: Borislav Petkov <bp@suse.de> Reviewed-by: Mauro Carvalho Chehab <m.chehab@samsung.com> Signed-off-by: Tony Luck <tony.luck@intel.com>
Diffstat (limited to 'drivers/acpi/apei')
-rw-r--r--drivers/acpi/apei/cper.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/acpi/apei/cper.c b/drivers/acpi/apei/cper.c
index 33dc6a004802..f827f02bfbe8 100644
--- a/drivers/acpi/apei/cper.c
+++ b/drivers/acpi/apei/cper.c
@@ -353,7 +353,7 @@ void apei_estatus_print(const char *pfx,
cper_severity_str(severity));
data_len = estatus->data_length;
gdata = (struct acpi_hest_generic_data *)(estatus + 1);
- while (data_len > sizeof(*gdata)) {
+ while (data_len >= sizeof(*gdata)) {
gedata_len = gdata->error_data_length;
apei_estatus_print_section(pfx, gdata, sec_no);
data_len -= gedata_len + sizeof(*gdata);