TianoCore EDK2 master
|
#include <PiSmm.h>
#include <Library/UefiBootServicesTableLib.h>
#include <Library/SmmServicesTableLib.h>
#include <Library/DebugLib.h>
#include <Guid/MemoryProfile.h>
Go to the source code of this file.
Functions | |
BOOLEAN EFIAPI | BufferInSmram (IN VOID *Buffer) |
EFI_STATUS EFIAPI | SmmMemoryProfileLibConstructor (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable) |
EFI_STATUS EFIAPI | MemoryProfileLibRecord (IN PHYSICAL_ADDRESS CallerAddress, IN MEMORY_PROFILE_ACTION Action, IN EFI_MEMORY_TYPE MemoryType, IN VOID *Buffer, IN UINTN Size, IN CHAR8 *ActionString OPTIONAL) |
Variables | |
EDKII_MEMORY_PROFILE_PROTOCOL * | mLibProfileProtocol |
EDKII_SMM_MEMORY_PROFILE_PROTOCOL * | mLibSmmProfileProtocol |
Support routines for memory profile for Smm phase drivers.
Copyright (c) 2016 - 2018, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file SmmMemoryProfileLib.c.
BOOLEAN EFIAPI BufferInSmram | ( | IN VOID * | Buffer | ) |
Check whether the start address of buffer is within any of the SMRAM ranges.
[in] | Buffer | The pointer to the buffer to be checked. |
TRUE | The buffer is in SMRAM ranges. |
FALSE | The buffer is out of SMRAM ranges. |
Definition at line 42 of file MemoryAllocationLib.c.
EFI_STATUS EFIAPI MemoryProfileLibRecord | ( | IN PHYSICAL_ADDRESS | CallerAddress, |
IN MEMORY_PROFILE_ACTION | Action, | ||
IN EFI_MEMORY_TYPE | MemoryType, | ||
IN VOID * | Buffer, | ||
IN UINTN | Size, | ||
IN CHAR8 *ActionString | OPTIONAL | ||
) |
Record memory profile of multilevel caller.
[in] | CallerAddress | Address of caller. |
[in] | Action | Memory profile action. |
[in] | MemoryType | Memory type. EfiMaxMemoryType means the MemoryType is unknown. |
[in] | Buffer | Buffer address. |
[in] | Size | Buffer size. |
[in] | ActionString | String for memory profile action. Only needed for user defined allocate action. |
Definition at line 100 of file SmmMemoryProfileLib.c.
EFI_STATUS EFIAPI SmmMemoryProfileLibConstructor | ( | IN EFI_HANDLE | ImageHandle, |
IN EFI_SYSTEM_TABLE * | SystemTable | ||
) |
The constructor function initializes memory profile for SMM phase.
ImageHandle | The firmware allocated handle for the EFI image. |
SystemTable | A pointer to the EFI System Table. |
EFI_SUCCESS | The constructor always returns EFI_SUCCESS. |
Definition at line 45 of file SmmMemoryProfileLib.c.
EDKII_MEMORY_PROFILE_PROTOCOL* mLibProfileProtocol |
Definition at line 17 of file SmmMemoryProfileLib.c.
EDKII_SMM_MEMORY_PROFILE_PROTOCOL* mLibSmmProfileProtocol |
Definition at line 18 of file SmmMemoryProfileLib.c.