Blame SOURCES/0024-Support-MSCT-in-a-big-endian-world.patch

214d7a
From ae38e1578d18abf41330bb3dbaef9ea56a52f49b Mon Sep 17 00:00:00 2001
214d7a
From: Al Stone <ahs3@redhat.com>
214d7a
Date: Wed, 23 Sep 2020 15:44:21 -0600
214d7a
Subject: [PATCH 24/45] Support MSCT in a big-endian world
214d7a
214d7a
Signed-off-by: Al Stone <ahs3@redhat.com>
214d7a
---
214d7a
 source/common/dmtbdump2.c | 7 ++++---
214d7a
 1 file changed, 4 insertions(+), 3 deletions(-)
214d7a
214d7a
Index: acpica-unix2-20210604/source/common/dmtbdump2.c
214d7a
===================================================================
214d7a
--- acpica-unix2-20210604.orig/source/common/dmtbdump2.c
214d7a
+++ acpica-unix2-20210604/source/common/dmtbdump2.c
214d7a
@@ -1133,11 +1133,12 @@ AcpiDmDumpMsct (
214d7a
     ACPI_STATUS             Status;
214d7a
     UINT32                  Offset = sizeof (ACPI_TABLE_MSCT);
214d7a
     ACPI_MSCT_PROXIMITY     *Subtable;
214d7a
+    UINT32                  TableLength = AcpiUtReadUint32 (&Table->Length);
214d7a
 
214d7a
 
214d7a
     /* Main table */
214d7a
 
214d7a
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoMsct);
214d7a
+    Status = AcpiDmDumpTable (TableLength, 0, Table, 0, AcpiDmTableInfoMsct);
214d7a
     if (ACPI_FAILURE (Status))
214d7a
     {
214d7a
         return;
214d7a
@@ -1146,12 +1147,12 @@ AcpiDmDumpMsct (
214d7a
     /* Subtables */
214d7a
 
214d7a
     Subtable = ACPI_ADD_PTR (ACPI_MSCT_PROXIMITY, Table, Offset);
214d7a
-    while (Offset < Table->Length)
214d7a
+    while (Offset < TableLength)
214d7a
     {
214d7a
         /* Common subtable header */
214d7a
 
214d7a
         AcpiOsPrintf ("\n");
214d7a
-        Status = AcpiDmDumpTable (Table->Length, Offset, Subtable,
214d7a
+        Status = AcpiDmDumpTable (TableLength, Offset, Subtable,
214d7a
             sizeof (ACPI_MSCT_PROXIMITY), AcpiDmTableInfoMsct0);
214d7a
         if (ACPI_FAILURE (Status))
214d7a
         {