2021-07-23 13:25:41 +00:00
|
|
|
From c313a76ce818135f02ab158a9f0c8e4b8e96698a Mon Sep 17 00:00:00 2001
|
2020-10-31 11:18:15 +00:00
|
|
|
From: Al Stone <ahs3@redhat.com>
|
|
|
|
Date: Mon, 28 Sep 2020 11:49:42 -0600
|
2021-07-23 13:25:41 +00:00
|
|
|
Subject: [PATCH 34/45] Support STAO 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 | 6 +++---
|
|
|
|
1 file changed, 3 insertions(+), 3 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
|
|
|
@@ -285,14 +285,14 @@ AcpiDmDumpStao (
|
|
|
|
{
|
|
|
|
ACPI_STATUS Status;
|
|
|
|
char *Namepath;
|
|
|
|
- UINT32 Length = Table->Length;
|
2021-07-23 13:25:41 +00:00
|
|
|
+ UINT32 TableLength = AcpiUtReadUint32 (&Table->Length);
|
2020-10-31 11:18:15 +00:00
|
|
|
UINT32 StringLength;
|
|
|
|
UINT32 Offset = sizeof (ACPI_TABLE_STAO);
|
|
|
|
|
|
|
|
|
|
|
|
/* Main table */
|
|
|
|
|
|
|
|
- Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoStao);
|
|
|
|
+ Status = AcpiDmDumpTable (TableLength, 0, Table, 0, AcpiDmTableInfoStao);
|
|
|
|
if (ACPI_FAILURE (Status))
|
|
|
|
{
|
|
|
|
return;
|
|
|
|
@@ -300,7 +300,7 @@ AcpiDmDumpStao (
|
|
|
|
|
|
|
|
/* The rest of the table consists of Namepath strings */
|
|
|
|
|
|
|
|
- while (Offset < Table->Length)
|
|
|
|
+ while (Offset < TableLength)
|
|
|
|
{
|
|
|
|
Namepath = ACPI_ADD_PTR (char, Table, Offset);
|
|
|
|
StringLength = strlen (Namepath) + 1;
|