TianoCore EDK2 master
|
#include <IndustryStandard/ServiceProcessorManagementInterfaceTable.h>
#include <Library/DebugLib.h>
#include <Library/BaseMemoryLib.h>
#include <Protocol/AcpiTable.h>
#include <AcpiTableGenerator.h>
#include <ConfigurationManagerObject.h>
#include <ConfigurationManagerHelper.h>
#include <Library/TableHelperLib.h>
#include <IndustryStandard/IpmiNetFnApp.h>
#include <Library/IpmiCommandLib.h>
#include <Protocol/ConfigurationManagerProtocol.h>
Go to the source code of this file.
Macros | |
#define | SPMI_GENERATOR_REVISION CREATE_REVISION (1, 0) |
Functions | |
GET_OBJECT_LIST (EObjNameSpaceArchCommon, EArchCommonObjSpmiInterfaceInfo, CM_ARCH_COMMON_SPMI_INTERFACE_INFO) | |
GET_OBJECT_LIST (EObjNameSpaceArchCommon, EArchCommonObjSpmiInterruptDeviceInfo, CM_ARCH_COMMON_SPMI_INTERRUPT_DEVICE_INFO) | |
STATIC EFI_STATUS EFIAPI | BuildSpmiTable (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 | AcpiSpmiLibConstructor (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable) |
EFI_STATUS EFIAPI | AcpiSpmiLibDestructor (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable) |
Variables | |
STATIC EFI_ACPI_SERVICE_PROCESSOR_MANAGEMENT_INTERFACE_TABLE | AcpiSpmi |
STATIC CONST ACPI_TABLE_GENERATOR | SpmiGenerator |
SPMI Table Generator
Copyright (C) 2024 Advanced Micro Devices, Inc. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file SpmiGenerator.c.
#define SPMI_GENERATOR_REVISION CREATE_REVISION (1, 0) |
This macro defines the SPMI Table Generator revision.
Definition at line 311 of file SpmiGenerator.c.
EFI_STATUS EFIAPI AcpiSpmiLibConstructor | ( | 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 355 of file SpmiGenerator.c.
EFI_STATUS EFIAPI AcpiSpmiLibDestructor | ( | 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 379 of file SpmiGenerator.c.
STATIC EFI_STATUS EFIAPI BuildSpmiTable | ( | 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 SPMI ACPI table.
This function invokes the Configuration Manager protocol interface to get the required hardware 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. |
Validate interface type.
If the interface type is SSIF, the Address Space ID should be SMBUS.
For non-ssif interface types, the Address Space ID should be System Memory or System I/O.
Validate Interrupt Type, bit[7:2] should be zero.
Interrupt Type bit[0] should be zero for SSIF interface type.
PCI device flag bit0 should be zero for SSIF interface type.
Validate SCI GPE bit if GPE number is provided.
If GlobalSystemInterrupt is provided, the interrupt type should be GSI.
Update IPMI specification version
Definition at line 113 of file SpmiGenerator.c.
GET_OBJECT_LIST | ( | EObjNameSpaceArchCommon | , |
EArchCommonObjSpmiInterfaceInfo | , | ||
CM_ARCH_COMMON_SPMI_INTERFACE_INFO | |||
) |
GET_OBJECT_LIST | ( | EObjNameSpaceArchCommon | , |
EArchCommonObjSpmiInterruptDeviceInfo | , | ||
CM_ARCH_COMMON_SPMI_INTERRUPT_DEVICE_INFO | |||
) |
Retrieve the SPMI interrupt and device information.
Definition at line 50 of file SpmiGenerator.c.
STATIC CONST ACPI_TABLE_GENERATOR SpmiGenerator |
The interface for the SPMI Table Generator.
Definition at line 317 of file SpmiGenerator.c.