MdePkg/MdeModulePkg: Implement the missing SetMemorySpaceCapabilities function.
It is defined in the PI Specification version 1.3. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Eugene Cohen <eugene@hp.com> Reviewed-by: Liming Gao <liming.gao@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16409 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@@ -1863,7 +1863,7 @@ CoreGetMemorySpaceDescriptor (
|
||||
resource range specified by BaseAddress and Length.
|
||||
@retval EFI_UNSUPPORTED The bit mask of attributes is not support for the memory resource
|
||||
range specified by BaseAddress and Length.
|
||||
@retval EFI_ACCESS_DEFINED The attributes for the memory resource range specified by
|
||||
@retval EFI_ACCESS_DENIED The attributes for the memory resource range specified by
|
||||
BaseAddress and Length cannot be modified.
|
||||
@retval EFI_OUT_OF_RESOURCES There are not enough system resources to modify the attributes of
|
||||
the memory resource range.
|
||||
@@ -1880,6 +1880,32 @@ CoreSetMemorySpaceAttributes (
|
||||
);
|
||||
|
||||
|
||||
/**
|
||||
Modifies the capabilities for a memory region in the global coherency domain of the
|
||||
processor.
|
||||
|
||||
@param BaseAddress The physical address that is the start address of a memory region.
|
||||
@param Length The size in bytes of the memory region.
|
||||
@param Capabilities The bit mask of capabilities that the memory region supports.
|
||||
|
||||
@retval EFI_SUCCESS The capabilities were set for the memory region.
|
||||
@retval EFI_INVALID_PARAMETER Length is zero.
|
||||
@retval EFI_UNSUPPORTED The capabilities specified by Capabilities do not include the
|
||||
memory region attributes currently in use.
|
||||
@retval EFI_ACCESS_DENIED The capabilities for the memory resource range specified by
|
||||
BaseAddress and Length cannot be modified.
|
||||
@retval EFI_OUT_OF_RESOURCES There are not enough system resources to modify the capabilities
|
||||
of the memory resource range.
|
||||
**/
|
||||
EFI_STATUS
|
||||
EFIAPI
|
||||
CoreSetMemorySpaceCapabilities (
|
||||
IN EFI_PHYSICAL_ADDRESS BaseAddress,
|
||||
IN UINT64 Length,
|
||||
IN UINT64 Capabilities
|
||||
);
|
||||
|
||||
|
||||
/**
|
||||
Returns a map of the memory resources in the global coherency domain of the
|
||||
processor.
|
||||
@@ -2816,4 +2842,26 @@ CoreUpdateProfile (
|
||||
IN VOID *Buffer
|
||||
);
|
||||
|
||||
/**
|
||||
Internal function. Converts a memory range to use new attributes.
|
||||
|
||||
@param Start The first address of the range Must be page
|
||||
aligned
|
||||
@param NumberOfPages The number of pages to convert
|
||||
@param NewAttributes The new attributes value for the range.
|
||||
|
||||
@retval EFI_INVALID_PARAMETER Invalid parameter
|
||||
@retval EFI_NOT_FOUND Could not find a descriptor cover the specified
|
||||
range or convertion not allowed.
|
||||
@retval EFI_SUCCESS Successfully converts the memory range to the
|
||||
specified attributes.
|
||||
|
||||
**/
|
||||
VOID
|
||||
CoreUpdateMemoryAttributes (
|
||||
IN EFI_PHYSICAL_ADDRESS Start,
|
||||
IN UINT64 NumberOfPages,
|
||||
IN UINT64 NewAttributes
|
||||
);
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user