ShellPkg: Add acpiview tool to dump ACPI tables
authorRuiyu Ni <ruiyu.ni@intel.com>
Fri, 20 Apr 2018 08:08:22 +0000 (16:08 +0800)
committerRuiyu Ni <ruiyu.ni@intel.com>
Mon, 23 Apr 2018 09:52:44 +0000 (17:52 +0800)
commitee4dc24f57c32a445e7c747396c9bfbd8b221568
treea332a4c461762cf555bc62b4eb9930f1bb4888fa
parent8b5c80e0296c7050348a6a89f2cef66190c6141d
ShellPkg: Add acpiview tool to dump ACPI tables

This program is provided to allow examination of ACPI table contents
from the UEFI Shell.  This can help with investigations, especially at
that stage where the tables are not enabling an OS to boot.
The program is not exhaustive, and only encapsulates detailed knowledge
of a limited number of table types.

Default behaviour is to display the content of all tables installed.
'Known' table types will be parsed and displayed with descriptions and
field values.  Where appropriate a degree of consistency checking is
done and errors may be reported in the output.
Other table types will be displayed as an array of Hexadecimal bytes.

To facilitate debugging, the -s and -d options can be used to generate a
binary file image of a table that can be copied elsewhere for
investigation using tools such as those provided by acpica.org.  This is
especially relevant for AML type tables like DSDT and SSDT.

The inspiration for this is the existing smbiosview Debug1 Shell
command.

Many tables are not explicitly handled, in part because no examples are
available for our testing.

The program is designed to be extended to new tables with minimal
effort, and contributions are invited.

Change-Id: Ifa23dc80ab8ab042c56e88424847e796a8122a7c
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Sami Mujawar <sami.mujawar@arm.com>
Signed-off-by: Evan Lloyd <evan.lloyd@arm.com>
Signed-off-by: Sami Mujawar <sami.mujawar@arm.com>
Signed-off-by: Evan Lloyd <evan.lloyd@arm.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
Tested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
25 files changed:
ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiParser.h [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiTableParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiTableParser.h [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiView.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiView.h [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Bgrt/BgrtParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Dbg2/Dbg2Parser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Dsdt/DsdtParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Fadt/FadtParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Iort/IortParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Madt/MadtParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Mcfg/McfgParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Rsdp/RsdpParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Slit/SlitParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Spcr/SpcrParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Srat/SratParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Ssdt/SsdtParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Xsdt/XsdtParser.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/UefiShellAcpiViewCommandLib.c [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/UefiShellAcpiViewCommandLib.h [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/UefiShellAcpiViewCommandLib.inf [new file with mode: 0644]
ShellPkg/Library/UefiShellAcpiViewCommandLib/UefiShellAcpiViewCommandLib.uni [new file with mode: 0644]
ShellPkg/ShellPkg.dec