39 lines
1.4 KiB
Diff
39 lines
1.4 KiB
Diff
|
From 8d0ea4932cebc5d13cc811eb4f78b66a5e3cfd2c Mon Sep 17 00:00:00 2001
|
||
|
From: Al Stone <ahs3@redhat.com>
|
||
|
Date: Wed, 23 Sep 2020 12:16:37 -0600
|
||
|
Subject: [PATCH 18/40] Support XSDT in a big-endian world
|
||
|
|
||
|
Signed-off-by: Al Stone <ahs3@redhat.com>
|
||
|
---
|
||
|
source/common/dmtbdump.c | 6 ++++--
|
||
|
1 file changed, 4 insertions(+), 2 deletions(-)
|
||
|
|
||
|
Index: acpica-unix2-20200925/source/common/dmtbdump.c
|
||
|
===================================================================
|
||
|
--- acpica-unix2-20200925.orig/source/common/dmtbdump.c
|
||
|
+++ acpica-unix2-20200925/source/common/dmtbdump.c
|
||
|
@@ -318,6 +318,7 @@ AcpiDmDumpXsdt (
|
||
|
UINT32 Entries;
|
||
|
UINT32 Offset;
|
||
|
UINT32 i;
|
||
|
+ UINT32 TableLength = AcpiUtReadUint32(&Table->Length);
|
||
|
|
||
|
|
||
|
/* Point to start of table pointer array */
|
||
|
@@ -327,12 +328,13 @@ AcpiDmDumpXsdt (
|
||
|
|
||
|
/* XSDT uses 64-bit pointers */
|
||
|
|
||
|
- Entries = (Table->Length - sizeof (ACPI_TABLE_HEADER)) / sizeof (UINT64);
|
||
|
+ Entries = (TableLength - sizeof (ACPI_TABLE_HEADER)) / sizeof (UINT64);
|
||
|
|
||
|
for (i = 0; i < Entries; i++)
|
||
|
{
|
||
|
AcpiDmLineHeader2 (Offset, sizeof (UINT64), "ACPI Table Address", i);
|
||
|
- AcpiOsPrintf ("%8.8X%8.8X\n", ACPI_FORMAT_UINT64 (Array[i]));
|
||
|
+ AcpiOsPrintf ("%8.8X%8.8X\n",
|
||
|
+ ACPI_FORMAT_UINT64 (AcpiUtReadUint64(&Array[i])));
|
||
|
Offset += sizeof (UINT64);
|
||
|
}
|
||
|
}
|