DynamicTablesPkg: Arm IORT Table Generator

The IORT generator uses the configuration manager protocol
to obtain information about the PCI Root Complex, SMMU,
GIC ITS, Performance Monitoring counters etc. and generates
the IORT table.

The mappings between the components are represented using
tokens. The generator invokes the configuration manager
protocol interfaces and requests for objects referenced by
tokens to establish the link.

This table data is then used by the Table Manager to install
the IORT table.

The Table Manager then invokes the generator interface to free
any resources allocated by the IORT table generator.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Sami Mujawar <sami.mujawar@arm.com>
Reviewed-by: Alexei Fedorov <alexei.fedorov@arm.com>
This commit is contained in:
Sami Mujawar 2018-12-15 12:31:47 +00:00
parent 7e79e0519d
commit dfaffc6967
4 changed files with 2174 additions and 0 deletions

View File

@ -30,6 +30,7 @@
NULL|DynamicTablesPkg/Library/Acpi/Arm/AcpiDbg2LibArm/AcpiDbg2LibArm.inf
NULL|DynamicTablesPkg/Library/Acpi/Arm/AcpiFadtLibArm/AcpiFadtLibArm.inf
NULL|DynamicTablesPkg/Library/Acpi/Arm/AcpiGtdtLibArm/AcpiGtdtLibArm.inf
NULL|DynamicTablesPkg/Library/Acpi/Arm/AcpiIortLibArm/AcpiIortLibArm.inf
NULL|DynamicTablesPkg/Library/Acpi/Arm/AcpiMadtLibArm/AcpiMadtLibArm.inf
NULL|DynamicTablesPkg/Library/Acpi/Arm/AcpiMcfgLibArm/AcpiMcfgLibArm.inf
NULL|DynamicTablesPkg/Library/Acpi/Arm/AcpiRawLibArm/AcpiRawLibArm.inf

View File

@ -0,0 +1,42 @@
## @file
# IORT Table Generator
#
# Copyright (c) 2017 - 2018, ARM Limited. All rights reserved.
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
##
[Defines]
INF_VERSION = 0x00010019
BASE_NAME = AcpiIortLibArm
FILE_GUID = 25682BA8-B41D-4403-B034-253769E0DAD5
VERSION_STRING = 1.0
MODULE_TYPE = DXE_DRIVER
LIBRARY_CLASS = NULL|DXE_DRIVER
CONSTRUCTOR = AcpiIortLibConstructor
DESTRUCTOR = AcpiIortLibDestructor
[Sources]
IortGenerator.c
[Packages]
MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
EmbeddedPkg/EmbeddedPkg.dec
DynamicTablesPkg/DynamicTablesPkg.dec
[LibraryClasses]
BaseLib
[Pcd]
[Protocols]
[Guids]

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,50 @@
/** @file
Copyright (c) 2018, ARM Limited. All rights reserved.
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
http://opensource.org/licenses/bsd-license.php
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
@par Glossary:
- Cm or CM - Configuration Manager
- Obj or OBJ - Object
- Std or STD - Standard
**/
#ifndef IORT_GENERATOR_H_
#define IORT_GENERATOR_H_
#pragma pack(1)
/** A structure that describes the Node indexer
used for indexing the IORT nodes.
*/
typedef struct IortNodeIndexer {
/// Index token for the Node
CM_OBJECT_TOKEN Token;
/// Pointer to the node
VOID * Object;
/// Node offset from the start of the IORT table
UINT32 Offset;
} IORT_NODE_INDEXER;
typedef struct AcpiIortGenerator {
/// ACPI Table generator header
ACPI_TABLE_GENERATOR Header;
// IORT Generator private data
/// IORT node count
UINT32 IortNodeCount;
/// Pointer to the node indexer array
IORT_NODE_INDEXER * NodeIndexer;
} ACPI_IORT_GENERATOR;
#pragma pack()
#endif // IORT_GENERATOR_H_