TianoCore EDK2 master
|
#include <IndustryStandard/HighPrecisionEventTimerTable.h>
#include <AcpiTableGenerator.h>
#include <ConfigurationManagerHelper.h>
#include <ConfigurationManagerObject.h>
#include <Library/BaseMemoryLib.h>
#include <Library/DebugLib.h>
#include <Library/TableHelperLib.h>
#include <Protocol/AcpiTable.h>
#include <Protocol/ConfigurationManagerProtocol.h>
#include <X64NameSpaceObjects.h>
#include <Library/IoLib.h>
Go to the source code of this file.
Macros | |
#define | HPET_VALID_PAGE_PROTECTION |
#define | HPET_GENERATOR_REVISION CREATE_REVISION (1, 0) |
Functions | |
GET_OBJECT_LIST (EObjNameSpaceX64, EX64ObjHpetInfo, CM_X64_HPET_INFO) | |
STATIC EFI_STATUS EFIAPI | HpetUpdateTableInfo (IN CONST EDKII_CONFIGURATION_MANAGER_PROTOCOL *CONST CfgMgrProtocol) |
STATIC EFI_STATUS EFIAPI | BuildHpetTable (IN CONST ACPI_TABLE_GENERATOR *CONST This, IN CONST CM_STD_OBJ_ACPI_TABLE_INFO *CONST AcpiTableInfo, IN CONST EDKII_CONFIGURATION_MANAGER_PROTOCOL *CONST CfgMgrProtocol, OUT EFI_ACPI_DESCRIPTION_HEADER **CONST Table) |
EFI_STATUS EFIAPI | AcpiHpetLibConstructor (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable) |
EFI_STATUS EFIAPI | AcpiHpetLibDestructor (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable) |
Variables | |
STATIC EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER | AcpiHpet |
STATIC CONST ACPI_TABLE_GENERATOR | HpetGenerator |
Generate ACPI HPET table for AMD platforms.
Copyright (C) 2024 Advanced Micro Devices, Inc. All rights reserved.
SPDX-License-Identifier BSD-2-Clause-Patent
Definition in file AcpiHpetLib.c.
#define HPET_GENERATOR_REVISION CREATE_REVISION (1, 0) |
This macro defines the HPET Table Generator revision.
Definition at line 247 of file AcpiHpetLib.c.
#define HPET_VALID_PAGE_PROTECTION |
This macro defines supported HPET page protection flags
Definition at line 24 of file AcpiHpetLib.c.
EFI_STATUS EFIAPI AcpiHpetLibConstructor | ( | IN EFI_HANDLE | ImageHandle, |
IN EFI_SYSTEM_TABLE * | SystemTable | ||
) |
Register the Generator with the ACPI Table Factory.
[in] | ImageHandle | The handle to the image. |
[in] | SystemTable | Pointer to the System Table. |
EFI_SUCCESS | The Generator is registered. |
EFI_INVALID_PARAMETER | A parameter is invalid. |
EFI_ALREADY_STARTED | The Generator for the Table ID is already registered. |
Definition at line 292 of file AcpiHpetLib.c.
EFI_STATUS EFIAPI AcpiHpetLibDestructor | ( | IN EFI_HANDLE | ImageHandle, |
IN EFI_SYSTEM_TABLE * | SystemTable | ||
) |
Deregister the Generator from the ACPI Table Factory.
[in] | ImageHandle | The handle to the image. |
[in] | SystemTable | Pointer to the System Table. |
EFI_SUCCESS | The Generator is deregistered. |
EFI_INVALID_PARAMETER | A parameter is invalid. |
EFI_NOT_FOUND | The Generator is not registered. |
Definition at line 316 of file AcpiHpetLib.c.
STATIC EFI_STATUS EFIAPI BuildHpetTable | ( | IN CONST ACPI_TABLE_GENERATOR *CONST | This, |
IN CONST CM_STD_OBJ_ACPI_TABLE_INFO *CONST | AcpiTableInfo, | ||
IN CONST EDKII_CONFIGURATION_MANAGER_PROTOCOL *CONST | CfgMgrProtocol, | ||
OUT EFI_ACPI_DESCRIPTION_HEADER **CONST | Table | ||
) |
Construct the HPET table.
This function invokes the Configuration Manager protocol interface to get the required information for generating the ACPI table.
If this function allocates any resources then they must be freed in the FreeXXXXTableResources function.
[in] | This | Pointer to the table generator. |
[in] | AcpiTableInfo | Pointer to the ACPI Table Info. |
[in] | CfgMgrProtocol | Pointer to the Configuration Manager Protocol Interface. |
[out] | Table | Pointer to the constructed ACPI Table. |
EFI_SUCCESS | Table generated successfully. |
EFI_INVALID_PARAMETER | A parameter is invalid. |
EFI_NOT_FOUND | The required object was not found. |
EFI_BAD_BUFFER_SIZE | The size returned by the Configuration Manager is less than the Object size for the requested object. |
Definition at line 186 of file AcpiHpetLib.c.
GET_OBJECT_LIST | ( | EObjNameSpaceX64 | , |
EX64ObjHpetInfo | , | ||
CM_X64_HPET_INFO | |||
) |
This macro expands to a function that retrieves the HPET device information from the Configuration Manager.
STATIC EFI_STATUS EFIAPI HpetUpdateTableInfo | ( | IN CONST EDKII_CONFIGURATION_MANAGER_PROTOCOL *CONST | CfgMgrProtocol | ) |
Update HPET table information.
[in] | CfgMgrProtocol | Pointer to the Configuration Manager Protocol Interface. |
EFI_SUCCESS | Success. |
EFI_INVALID_PARAMETER | A parameter is invalid. |
EFI_NOT_FOUND | The required object was not found or the HPET is not enabled. |
EFI_BAD_BUFFER_SIZE | The size returned by the Configuration Manager is less than the Object size for the requested object. |
EFI_UNSUPPORTED | If invalid protection and oem flags provided. |
Definition at line 76 of file AcpiHpetLib.c.
The ACPI HPET Table.
Definition at line 41 of file AcpiHpetLib.c.
STATIC CONST ACPI_TABLE_GENERATOR HpetGenerator |
The interface for the HPET Table Generator.
Definition at line 253 of file AcpiHpetLib.c.