Blame SOURCES/0014-Support-EINJ-in-a-big-endian-world.patch

9897bb
From 70d1047abe010c80c2dd74f6afdc7005b91e6163 Mon Sep 17 00:00:00 2001
9897bb
From: Al Stone <ahs3@redhat.com>
9897bb
Date: Sat, 19 Sep 2020 15:50:19 -0600
9897bb
Subject: [PATCH 14/45] Support EINJ in a big-endian world
9897bb
9897bb
Signed-off-by: Al Stone <ahs3@redhat.com>
9897bb
---
9897bb
 source/common/dmtbdump1.c | 4 ++--
9897bb
 1 file changed, 2 insertions(+), 2 deletions(-)
9897bb
9897bb
Index: acpica-unix2-20210604/source/common/dmtbdump1.c
9897bb
===================================================================
9897bb
--- acpica-unix2-20210604.orig/source/common/dmtbdump1.c
9897bb
+++ acpica-unix2-20210604/source/common/dmtbdump1.c
9897bb
@@ -882,7 +882,7 @@ AcpiDmDumpEinj (
9897bb
 {
9897bb
     ACPI_STATUS             Status;
9897bb
     ACPI_WHEA_HEADER        *Subtable;
9897bb
-    UINT32                  Length = Table->Length;
9897bb
+    UINT32                  Length = AcpiUtReadUint32 (&Table->Length);
9897bb
     UINT32                  Offset = sizeof (ACPI_TABLE_EINJ);
9897bb
 
9897bb
 
9897bb
@@ -897,7 +897,7 @@ AcpiDmDumpEinj (
9897bb
     /* Subtables */
9897bb
 
9897bb
     Subtable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, Table, Offset);
9897bb
-    while (Offset < Table->Length)
9897bb
+    while (Offset < Length)
9897bb
     {
9897bb
         AcpiOsPrintf ("\n");
9897bb
         Status = AcpiDmDumpTable (Length, Offset, Subtable,