TianoCore EDK2 master
Loading...
Searching...
No Matches
AcpiParser Struct Reference

#include <ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiParser.h>

Data Fields

CONST CHAR16 * NameStr
 
UINT32 Length
 
UINT32 Offset
 
CONST CHAR16 * Format
 
FNPTR_PRINT_FORMATTER PrintFormatter
 
VOID ** ItemPtr
 
FNPTR_FIELD_VALIDATOR FieldValidator
 
VOID * Context
 

Detailed Description

The ACPI_PARSER structure describes the fields of an ACPI table and provides means for the parser to interpret and trace appropriately.

The first three members are populated based on information present in in the ACPI table specifications. The remaining members describe how the parser should report the field information, validate the field data and/or update an external pointer to the field (ItemPtr).

ParseAcpi() uses the format string specified by 'Format' for tracing the field data. If the field is more complex and requires additional processing for formatting and representation a print formatter function can be specified in 'PrintFormatter'.

ParseAcpiBitFields() uses AcpiParser structure to parse the bit fields. It considers Length as a number of bits that need to be parsed. Also, the Offset field will be considered as starting offset of the bitfield.

The PrintFormatter function may choose to use the format string specified by 'Format' or use its own internal format string.

The 'Format' and 'PrintFormatter' members allow flexibility for representing the field data.

Definition at line 339 of file AcpiParser.h.

Field Documentation

◆ Context

VOID* AcpiParser::Context

Optional pointer to context specific information, which the Field Validator function can use to determine additional information about the ACPI table and make decisions about the field being validated. e.g. this could be a pointer to the ACPI table header

Definition at line 383 of file AcpiParser.h.

◆ FieldValidator

FNPTR_FIELD_VALIDATOR AcpiParser::FieldValidator

Optional pointer to a field validator function. The function should directly report any appropriate error or warning and invoke the appropriate counter update function. If not used this parameter must be set to NULL.

Definition at line 376 of file AcpiParser.h.

◆ Format

CONST CHAR16* AcpiParser::Format

Optional Print() style format string for tracing the data. If not used this must be set to NULL.

Definition at line 356 of file AcpiParser.h.

◆ ItemPtr

VOID** AcpiParser::ItemPtr

Optional pointer which may be set to request the parser to update a pointer to the field data. This value is set after the FieldValidator has been called and therefore should not be used by the FieldValidator. If unused this must be set to NULL. ItemPtr is not supported with ParseAcpiBitFields().

Definition at line 370 of file AcpiParser.h.

◆ Length

UINT32 AcpiParser::Length

The length of the field. (Byte Length column from ACPI table spec) Length(in bits) of the bitfield if used with ParseAcpiBitFields().

Definition at line 347 of file AcpiParser.h.

◆ NameStr

CONST CHAR16* AcpiParser::NameStr

String describing the ACPI table field (Field column from ACPI table spec)

Definition at line 342 of file AcpiParser.h.

◆ Offset

UINT32 AcpiParser::Offset

The offset of the field from the start of the table. (Byte Offset column from ACPI table spec) The Bit offset of the field if used with ParseAcpiBitFields().

Definition at line 352 of file AcpiParser.h.

◆ PrintFormatter

FNPTR_PRINT_FORMATTER AcpiParser::PrintFormatter

Optional pointer to a print formatter function which is typically used to trace complex field information. If not used this must be set to NULL. The Format string is passed to the PrintFormatter function but may be ignored by the implementation code.

Definition at line 363 of file AcpiParser.h.


The documentation for this struct was generated from the following file: