fc3eef63e8
This includes new source tarballs, updated patches, and updated expected results for test cases. In addition, three new tables (PRMT, RGRT and SVKL) now have big-endian support. Signed-off-by: Al Stone <ahs3@redhat.com>
97 lines
3.1 KiB
Diff
97 lines
3.1 KiB
Diff
From 9fc0e46189feb926b13713422ea2722e273a31b5 Mon Sep 17 00:00:00 2001
|
|
From: Al Stone <ahs3@redhat.com>
|
|
Date: Mon, 19 Oct 2020 17:30:30 -0400
|
|
Subject: [PATCH 40/45] Support S3PT in a big-endian world
|
|
|
|
---
|
|
source/common/dmtbdump2.c | 15 +++++++++------
|
|
source/compiler/dttable2.c | 4 +++-
|
|
2 files changed, 12 insertions(+), 7 deletions(-)
|
|
|
|
Index: acpica-unix2-20220331/source/common/dmtbdump2.c
|
|
===================================================================
|
|
--- acpica-unix2-20220331.orig/source/common/dmtbdump2.c
|
|
+++ acpica-unix2-20220331/source/common/dmtbdump2.c
|
|
@@ -2495,6 +2495,8 @@ AcpiDmDumpS3pt (
|
|
ACPI_FPDT_HEADER *Subtable;
|
|
ACPI_DMTABLE_INFO *InfoTable;
|
|
ACPI_TABLE_S3PT *S3ptTable = ACPI_CAST_PTR (ACPI_TABLE_S3PT, Tables);
|
|
+ UINT32 S3ptTableLength = AcpiUtReadUint32 (&S3ptTable->Length);
|
|
+ UINT16 SubtableType;
|
|
|
|
|
|
/* Main table */
|
|
@@ -2506,19 +2508,20 @@ AcpiDmDumpS3pt (
|
|
}
|
|
|
|
Subtable = ACPI_ADD_PTR (ACPI_FPDT_HEADER, S3ptTable, Offset);
|
|
- while (Offset < S3ptTable->Length)
|
|
+ while (Offset < S3ptTableLength)
|
|
{
|
|
/* Common subtable header */
|
|
|
|
AcpiOsPrintf ("\n");
|
|
- Status = AcpiDmDumpTable (S3ptTable->Length, Offset, Subtable,
|
|
+ Status = AcpiDmDumpTable (S3ptTableLength, Offset, Subtable,
|
|
Subtable->Length, AcpiDmTableInfoS3ptHdr);
|
|
if (ACPI_FAILURE (Status))
|
|
{
|
|
return 0;
|
|
}
|
|
|
|
- switch (Subtable->Type)
|
|
+ SubtableType = AcpiUtReadUint16 (&Subtable->Type);
|
|
+ switch (SubtableType)
|
|
{
|
|
case ACPI_S3PT_TYPE_RESUME:
|
|
|
|
@@ -2533,7 +2536,7 @@ AcpiDmDumpS3pt (
|
|
default:
|
|
|
|
AcpiOsPrintf ("\n**** Unknown S3PT subtable type 0x%X\n",
|
|
- Subtable->Type);
|
|
+ SubtableType);
|
|
|
|
/* Attempt to continue */
|
|
|
|
@@ -2546,7 +2549,7 @@ AcpiDmDumpS3pt (
|
|
}
|
|
|
|
AcpiOsPrintf ("\n");
|
|
- Status = AcpiDmDumpTable (S3ptTable->Length, Offset, Subtable,
|
|
+ Status = AcpiDmDumpTable (S3ptTableLength, Offset, Subtable,
|
|
Subtable->Length, InfoTable);
|
|
if (ACPI_FAILURE (Status))
|
|
{
|
|
@@ -2560,7 +2563,7 @@ NextSubtable:
|
|
Subtable = ACPI_ADD_PTR (ACPI_FPDT_HEADER, Subtable, Subtable->Length);
|
|
}
|
|
|
|
- return (S3ptTable->Length);
|
|
+ return (S3ptTableLength);
|
|
}
|
|
|
|
|
|
Index: acpica-unix2-20220331/source/compiler/dttable2.c
|
|
===================================================================
|
|
--- acpica-unix2-20220331.orig/source/compiler/dttable2.c
|
|
+++ acpica-unix2-20220331/source/compiler/dttable2.c
|
|
@@ -1803,6 +1803,7 @@ DtCompileS3pt (
|
|
DT_SUBTABLE *ParentTable;
|
|
ACPI_DMTABLE_INFO *InfoTable;
|
|
DT_FIELD *SubtableStart;
|
|
+ UINT16 S3ptHeaderType;
|
|
|
|
|
|
Status = DtCompileTable (PFieldList, AcpiDmTableInfoS3pt,
|
|
@@ -1830,7 +1831,8 @@ DtCompileS3pt (
|
|
|
|
S3ptHeader = ACPI_CAST_PTR (ACPI_FPDT_HEADER, Subtable->Buffer);
|
|
|
|
- switch (S3ptHeader->Type)
|
|
+ S3ptHeaderType = AcpiUtReadUint16 (&S3ptHeader->Type);
|
|
+ switch (S3ptHeaderType)
|
|
{
|
|
case ACPI_S3PT_TYPE_RESUME:
|
|
|