|
|
214d7a |
From 62cc2f4ae212bd0fad83f643921ac216ebb9a986 Mon Sep 17 00:00:00 2001
|
|
|
214d7a |
From: Al Stone <ahs3@redhat.com>
|
|
|
214d7a |
Date: Fri, 18 Sep 2020 15:20:37 -0600
|
|
|
214d7a |
Subject: [PATCH 03/45] Always display table header content in human-readable
|
|
|
214d7a |
form
|
|
|
214d7a |
|
|
|
214d7a |
When comparing two binary data tables, little-endian values are read
|
|
|
214d7a |
from each table header and printed out. Make sure they show up in a
|
|
|
214d7a |
form that makes sense to humans.
|
|
|
214d7a |
|
|
|
214d7a |
Signed-off-by: Al Stone <ahs3@redhat.com>
|
|
|
214d7a |
---
|
|
|
214d7a |
source/tools/acpibin/abcompare.c | 7 ++++---
|
|
|
214d7a |
1 file changed, 4 insertions(+), 3 deletions(-)
|
|
|
214d7a |
|
|
|
214d7a |
Index: acpica-unix2-20210604/source/tools/acpibin/abcompare.c
|
|
|
214d7a |
===================================================================
|
|
|
214d7a |
--- acpica-unix2-20210604.orig/source/tools/acpibin/abcompare.c
|
|
|
214d7a |
+++ acpica-unix2-20210604/source/tools/acpibin/abcompare.c
|
|
|
214d7a |
@@ -42,6 +42,7 @@
|
|
|
214d7a |
*/
|
|
|
214d7a |
|
|
|
214d7a |
#include "acpibin.h"
|
|
|
214d7a |
+#include "acutils.h"
|
|
|
214d7a |
|
|
|
214d7a |
|
|
|
214d7a |
ACPI_TABLE_HEADER Header1;
|
|
|
214d7a |
@@ -179,14 +180,14 @@ AbPrintHeadersInfo (
|
|
|
214d7a |
/* Display header information for both headers */
|
|
|
214d7a |
|
|
|
214d7a |
printf ("Signature %8.4s : %4.4s\n", Header->Signature, Header2->Signature);
|
|
|
214d7a |
- printf ("Length %8.8X : %8.8X\n", Header->Length, Header2->Length);
|
|
|
214d7a |
+ printf ("Length %8.8X : %8.8X\n", AcpiUtReadUint32 (&Header->Length), AcpiUtReadUint32 (&Header2->Length));
|
|
|
214d7a |
printf ("Revision %8.2X : %2.2X\n", Header->Revision, Header2->Revision);
|
|
|
214d7a |
printf ("Checksum %8.2X : %2.2X\n", Header->Checksum, Header2->Checksum);
|
|
|
214d7a |
printf ("OEM ID %8.6s : %.6s\n", Header->OemId, Header2->OemId);
|
|
|
214d7a |
printf ("OEM Table ID %8.8s : %.8s\n", Header->OemTableId, Header2->OemTableId);
|
|
|
214d7a |
- printf ("OEM Revision %8.8X : %8.8X\n", Header->OemRevision, Header2->OemRevision);
|
|
|
214d7a |
+ printf ("OEM Revision %8.8X : %8.8X\n", AcpiUtReadUint32 (&Header->OemRevision), AcpiUtReadUint32 (&Header2->OemRevision));
|
|
|
214d7a |
printf ("ASL Compiler ID %8.4s : %.4s\n", Header->AslCompilerId, Header2->AslCompilerId);
|
|
|
214d7a |
- printf ("Compiler Revision %8.8X : %8.8X\n", Header->AslCompilerRevision, Header2->AslCompilerRevision);
|
|
|
214d7a |
+ printf ("Compiler Revision %8.8X : %8.8X\n", AcpiUtReadUint32 (&Header->AslCompilerRevision), AcpiUtReadUint32 (&Header2->AslCompilerRevision));
|
|
|
214d7a |
printf ("\n");
|
|
|
214d7a |
}
|
|
|
214d7a |
|