TianoCore EDK2 master
Loading...
Searching...
No Matches
NonMmramMapStandaloneMm.c File Reference
#include "PiSmmCpuCommon.h"

Go to the source code of this file.

Functions

EFI_PHYSICAL_ADDRESS GetSmmProfileData (IN OUT UINT64 *Size)
 
BOOLEAN IsNonMmramLoggingAddress (IN UINT64 Address)
 
BOOLEAN IsSmmCommBufferForbiddenAddress (IN UINT64 Address)
 
VOID BuildMemoryMapFromResDescHobs (OUT MM_CPU_MEMORY_REGION **MemoryRegion, OUT UINTN *MemoryRegionCount)
 
VOID CreateExtendedProtectionRange (OUT MM_CPU_MEMORY_REGION **MemoryRegion, OUT UINTN *MemoryRegionCount)
 
VOID CreateNonMmramMemMap (IN UINT8 PhysicalAddressBits, OUT MM_CPU_MEMORY_REGION **MemoryRegion, OUT UINTN *MemoryRegionCount)
 

Detailed Description

Copyright (c) 2024, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file NonMmramMapStandaloneMm.c.

Function Documentation

◆ BuildMemoryMapFromResDescHobs()

VOID BuildMemoryMapFromResDescHobs ( OUT MM_CPU_MEMORY_REGION **  MemoryRegion,
OUT UINTN MemoryRegionCount 
)

Build Memory Region from ResourceDescriptor HOBs by excluding Logging attribute range.

Parameters
[out]MemoryRegionReturned Non-Mmram Memory regions.
[out]MemoryRegionCountA pointer to the number of Memory regions.

Definition at line 120 of file NonMmramMapStandaloneMm.c.

◆ CreateExtendedProtectionRange()

VOID CreateExtendedProtectionRange ( OUT MM_CPU_MEMORY_REGION **  MemoryRegion,
OUT UINTN MemoryRegionCount 
)

Build extended protection MemoryRegion.

The caller is responsible for freeing MemoryRegion via FreePool().

Parameters
[out]MemoryRegionReturned Non-Mmram Memory regions.
[out]MemoryRegionCountA pointer to the number of Memory regions.

Definition at line 188 of file NonMmramMapStandaloneMm.c.

◆ CreateNonMmramMemMap()

VOID CreateNonMmramMemMap ( IN UINT8  PhysicalAddressBits,
OUT MM_CPU_MEMORY_REGION **  MemoryRegion,
OUT UINTN MemoryRegionCount 
)

Create the Non-Mmram Memory Region within the ResourceDescriptor HOBs without Logging attribute.

The caller is responsible for freeing MemoryRegion via FreePool().

Parameters
[in]PhysicalAddressBitsThe bits of physical address to map.
[out]MemoryRegionReturned Non-Mmram Memory regions.
[out]MemoryRegionCountA pointer to the number of Memory regions.

Definition at line 207 of file NonMmramMapStandaloneMm.c.

◆ GetSmmProfileData()

EFI_PHYSICAL_ADDRESS GetSmmProfileData ( IN OUT UINT64 *  Size)

Get SmmProfileData.

Parameters
[in,out]SizeReturn Size of SmmProfileData. 0 means the gMmProfileDataHobGuid does not exist.
Returns
Address of SmmProfileData

Definition at line 20 of file NonMmramMapStandaloneMm.c.

◆ IsNonMmramLoggingAddress()

BOOLEAN IsNonMmramLoggingAddress ( IN UINT64  Address)

Return if the Address is the NonMmram logging Address.

Parameters
[in]Addressthe address to be checked
Returns
TRUE The address is the NonMmram logging Address.
FALSE The address is not the NonMmram logging Address.

Definition at line 62 of file NonMmramMapStandaloneMm.c.

◆ IsSmmCommBufferForbiddenAddress()

BOOLEAN IsSmmCommBufferForbiddenAddress ( IN UINT64  Address)

Return if the Address is forbidden as SMM communication buffer.

Parameters
[in]Addressthe address to be checked
Returns
TRUE The address is forbidden as SMM communication buffer.
FALSE The address is allowed as SMM communication buffer.

Definition at line 94 of file NonMmramMapStandaloneMm.c.