This patch series modifies existing ACPI table parsers. Now, structure type values are used as indexes to access a centralized database containing information on how to parse each structure in the table.
Replacing a 'switch' statements with arrays indexed by the Type value allows consolidation of metadata about buiding blocks of an ACPI table. The additional data stored about each structure includes: - ACPI-defined name - instance count - compatible architectures (x86, AArch64, etc...) - information on how to parse the structure The new metadata allows more extensive ACPI table contents validation in acpiview, which is implemented in this patch series. Changes can be seen at: https://github.com/KrzysztofKoch1/edk2/tree/616_refactor_acpiview_parser_loops_v1 Krzysztof Koch (6): ShellPkg: acpiview: Add interface for data-driven table parsing ShellPkg: acpiview: Make MADT parsing logic data driven ShellPkg: acpiview: Make SRAT parsing logic data driven ShellPkg: acpiview: Make GTDT parsing logic data driven ShellPkg: acpiview: Make IORT parsing logic data driven ShellPkg: acpiview: Make PPTT parsing logic data driven ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiParser.c | 263 +++++++++++++++ ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiParser.h | 234 +++++++++++++ ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c | 123 ++++--- ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Iort/IortParser.c | 353 +++++++++++++------- ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Madt/MadtParser.c | 217 +++++++----- ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Madt/MadtParser.h | 3 +- ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Pptt/PpttParser.c | 152 ++++----- ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Pptt/PpttParser.h | 2 +- ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Srat/SratParser.c | 204 +++++------ 9 files changed, 1093 insertions(+), 458 deletions(-) -- 'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)' -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#58644): https://edk2.groups.io/g/devel/message/58644 Mute This Topic: https://groups.io/mt/74000907/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-