2020-10-24 00:40:24 +00:00
|
|
|
From 19eefeadf92a471f1c4fbc6dd4d035e45fa76dcd Mon Sep 17 00:00:00 2001
|
2020-10-23 19:04:26 +00:00
|
|
|
From: Al Stone <ahs3@redhat.com>
|
|
|
|
Date: Mon, 19 Oct 2020 17:17:40 -0400
|
2020-10-24 00:40:24 +00:00
|
|
|
Subject: [PATCH 4/5] Support VRTC in a big-endian world
|
2020-10-23 19:04:26 +00:00
|
|
|
|
|
|
|
---
|
|
|
|
source/common/dmtbdump3.c | 7 ++++---
|
|
|
|
1 file changed, 4 insertions(+), 3 deletions(-)
|
|
|
|
|
|
|
|
diff --git a/source/common/dmtbdump3.c b/source/common/dmtbdump3.c
|
|
|
|
index da9b81c92..db2f54ffb 100644
|
|
|
|
--- a/source/common/dmtbdump3.c
|
|
|
|
+++ b/source/common/dmtbdump3.c
|
|
|
|
@@ -629,11 +629,12 @@ AcpiDmDumpVrtc (
|
|
|
|
ACPI_STATUS Status;
|
|
|
|
UINT32 Offset = sizeof (ACPI_TABLE_VRTC);
|
|
|
|
ACPI_VRTC_ENTRY *Subtable;
|
|
|
|
+ UINT32 TableLength = AcpiUtReadUint32(&Table->Length);
|
|
|
|
|
|
|
|
|
|
|
|
/* Main table */
|
|
|
|
|
|
|
|
- Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoVrtc);
|
|
|
|
+ Status = AcpiDmDumpTable (TableLength, 0, Table, 0, AcpiDmTableInfoVrtc);
|
|
|
|
if (ACPI_FAILURE (Status))
|
|
|
|
{
|
|
|
|
return;
|
|
|
|
@@ -642,12 +643,12 @@ AcpiDmDumpVrtc (
|
|
|
|
/* Subtables */
|
|
|
|
|
|
|
|
Subtable = ACPI_ADD_PTR (ACPI_VRTC_ENTRY, 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,
|
|
|
|
sizeof (ACPI_VRTC_ENTRY), AcpiDmTableInfoVrtc0);
|
|
|
|
if (ACPI_FAILURE (Status))
|
|
|
|
{
|
|
|
|
--
|
2020-10-24 00:40:24 +00:00
|
|
|
2.26.2
|
2020-10-23 19:04:26 +00:00
|
|
|
|