2021-07-23 13:25:41 +00:00
|
|
|
From 724fcc83d359e4c8abbd2a48755e96049afa06d6 Mon Sep 17 00:00:00 2001
|
2020-10-31 11:18:15 +00:00
|
|
|
From: Al Stone <ahs3@redhat.com>
|
|
|
|
Date: Wed, 23 Sep 2020 12:25:38 -0600
|
2021-07-23 13:25:41 +00:00
|
|
|
Subject: [PATCH 22/45] Support SRAT in a big-endian world
|
2020-10-31 11:18:15 +00:00
|
|
|
|
|
|
|
Signed-off-by: Al Stone <ahs3@redhat.com>
|
|
|
|
---
|
|
|
|
source/common/dmtbdump3.c | 9 +++++----
|
|
|
|
1 file changed, 5 insertions(+), 4 deletions(-)
|
|
|
|
|
2021-07-23 13:25:41 +00:00
|
|
|
Index: acpica-unix2-20210604/source/common/dmtbdump3.c
|
2020-10-31 11:18:15 +00:00
|
|
|
===================================================================
|
2021-07-23 13:25:41 +00:00
|
|
|
--- acpica-unix2-20210604.orig/source/common/dmtbdump3.c
|
|
|
|
+++ acpica-unix2-20210604/source/common/dmtbdump3.c
|
2020-10-31 11:18:15 +00:00
|
|
|
@@ -173,11 +173,12 @@ AcpiDmDumpSrat (
|
|
|
|
UINT32 Offset = sizeof (ACPI_TABLE_SRAT);
|
|
|
|
ACPI_SUBTABLE_HEADER *Subtable;
|
|
|
|
ACPI_DMTABLE_INFO *InfoTable;
|
2021-07-23 13:25:41 +00:00
|
|
|
+ UINT32 TableLength = AcpiUtReadUint32 (&Table->Length);
|
2020-10-31 11:18:15 +00:00
|
|
|
|
|
|
|
|
|
|
|
/* Main table */
|
|
|
|
|
|
|
|
- Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoSrat);
|
|
|
|
+ Status = AcpiDmDumpTable (TableLength, 0, Table, 0, AcpiDmTableInfoSrat);
|
|
|
|
if (ACPI_FAILURE (Status))
|
|
|
|
{
|
|
|
|
return;
|
|
|
|
@@ -186,12 +187,12 @@ AcpiDmDumpSrat (
|
|
|
|
/* Subtables */
|
|
|
|
|
|
|
|
Subtable = ACPI_ADD_PTR (ACPI_SUBTABLE_HEADER, Table, Offset);
|
|
|
|
- while (Offset < Table->Length)
|
|
|
|
+ while (Offset < TableLength)
|
|
|
|
{
|
|
|
|
/* Common subtable header */
|
|
|
|
|
|
|
|
AcpiOsPrintf ("\n");
|
|
|
|
- Status = AcpiDmDumpTable (Table->Length, Offset, Subtable,
|
|
|
|
+ Status = AcpiDmDumpTable (TableLength, Offset, Subtable,
|
|
|
|
Subtable->Length, AcpiDmTableInfoSratHdr);
|
|
|
|
if (ACPI_FAILURE (Status))
|
|
|
|
{
|
|
|
|
@@ -245,7 +246,7 @@ AcpiDmDumpSrat (
|
|
|
|
}
|
|
|
|
|
|
|
|
AcpiOsPrintf ("\n");
|
|
|
|
- Status = AcpiDmDumpTable (Table->Length, Offset, Subtable,
|
|
|
|
+ Status = AcpiDmDumpTable (TableLength, Offset, Subtable,
|
|
|
|
Subtable->Length, InfoTable);
|
|
|
|
if (ACPI_FAILURE (Status))
|
|
|
|
{
|