mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-27 07:34:06 +02:00
MdeModulePkg: fix mixed dos and linux EOL format issue
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hot Tian <hot.tian@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16552 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
b947f0cf44
commit
736a692e7c
@ -812,22 +812,22 @@ CoreConvertSpace (
|
|||||||
goto Done;
|
goto Done;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
//
|
//
|
||||||
// Set capabilities operation
|
// Set capabilities operation
|
||||||
//
|
//
|
||||||
case GCD_SET_CAPABILITIES_MEMORY_OPERATION:
|
case GCD_SET_CAPABILITIES_MEMORY_OPERATION:
|
||||||
if ((BaseAddress & EFI_PAGE_MASK) != 0 || (Length & EFI_PAGE_MASK) != 0) {
|
if ((BaseAddress & EFI_PAGE_MASK) != 0 || (Length & EFI_PAGE_MASK) != 0) {
|
||||||
Status = EFI_INVALID_PARAMETER;
|
Status = EFI_INVALID_PARAMETER;
|
||||||
|
|
||||||
goto Done;
|
goto Done;
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
// Current attributes must still be supported with new capabilities
|
// Current attributes must still be supported with new capabilities
|
||||||
//
|
//
|
||||||
if ((Capabilities & Entry->Attributes) != Entry->Attributes) {
|
if ((Capabilities & Entry->Attributes) != Entry->Attributes) {
|
||||||
Status = EFI_UNSUPPORTED;
|
Status = EFI_UNSUPPORTED;
|
||||||
goto Done;
|
goto Done;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
Link = Link->ForwardLink;
|
Link = Link->ForwardLink;
|
||||||
@ -916,8 +916,8 @@ CoreConvertSpace (
|
|||||||
//
|
//
|
||||||
// Set capabilities operation
|
// Set capabilities operation
|
||||||
//
|
//
|
||||||
case GCD_SET_CAPABILITIES_MEMORY_OPERATION:
|
case GCD_SET_CAPABILITIES_MEMORY_OPERATION:
|
||||||
Entry->Capabilities = Capabilities;
|
Entry->Capabilities = Capabilities;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
Link = Link->ForwardLink;
|
Link = Link->ForwardLink;
|
||||||
@ -1606,16 +1606,16 @@ CoreSetMemorySpaceCapabilities (
|
|||||||
IN UINT64 Capabilities
|
IN UINT64 Capabilities
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
EFI_STATUS Status;
|
EFI_STATUS Status;
|
||||||
|
|
||||||
DEBUG ((DEBUG_GCD, "GCD:CoreSetMemorySpaceCapabilities(Base=%016lx,Length=%016lx)\n", BaseAddress, Length));
|
DEBUG ((DEBUG_GCD, "GCD:CoreSetMemorySpaceCapabilities(Base=%016lx,Length=%016lx)\n", BaseAddress, Length));
|
||||||
DEBUG ((DEBUG_GCD, " Capabilities = %016lx\n", Capabilities));
|
DEBUG ((DEBUG_GCD, " Capabilities = %016lx\n", Capabilities));
|
||||||
|
|
||||||
Status = CoreConvertSpace (GCD_SET_CAPABILITIES_MEMORY_OPERATION, (EFI_GCD_MEMORY_TYPE) 0, (EFI_GCD_IO_TYPE) 0, BaseAddress, Length, Capabilities, 0);
|
Status = CoreConvertSpace (GCD_SET_CAPABILITIES_MEMORY_OPERATION, (EFI_GCD_MEMORY_TYPE) 0, (EFI_GCD_IO_TYPE) 0, BaseAddress, Length, Capabilities, 0);
|
||||||
if (!EFI_ERROR(Status)) {
|
if (!EFI_ERROR(Status)) {
|
||||||
CoreUpdateMemoryAttributes(BaseAddress, RShiftU64(Length, EFI_PAGE_SHIFT), Capabilities);
|
CoreUpdateMemoryAttributes(BaseAddress, RShiftU64(Length, EFI_PAGE_SHIFT), Capabilities);
|
||||||
}
|
}
|
||||||
|
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1396,13 +1396,13 @@ CoreFreePages (
|
|||||||
)
|
)
|
||||||
{
|
{
|
||||||
EFI_STATUS Status;
|
EFI_STATUS Status;
|
||||||
|
|
||||||
Status = CoreInternalFreePages (Memory, NumberOfPages);
|
Status = CoreInternalFreePages (Memory, NumberOfPages);
|
||||||
if (!EFI_ERROR (Status)) {
|
if (!EFI_ERROR (Status)) {
|
||||||
CoreUpdateProfile ((EFI_PHYSICAL_ADDRESS) (UINTN) RETURN_ADDRESS (0), MemoryProfileActionFreePages, (EFI_MEMORY_TYPE) 0, EFI_PAGES_TO_SIZE (NumberOfPages), (VOID *) (UINTN) Memory);
|
CoreUpdateProfile ((EFI_PHYSICAL_ADDRESS) (UINTN) RETURN_ADDRESS (0), MemoryProfileActionFreePages, (EFI_MEMORY_TYPE) 0, EFI_PAGES_TO_SIZE (NumberOfPages), (VOID *) (UINTN) Memory);
|
||||||
}
|
}
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
This function checks to see if the last memory map descriptor in a memory map
|
This function checks to see if the last memory map descriptor in a memory map
|
||||||
|
@ -433,13 +433,13 @@ CoreFreePool (
|
|||||||
)
|
)
|
||||||
{
|
{
|
||||||
EFI_STATUS Status;
|
EFI_STATUS Status;
|
||||||
|
|
||||||
Status = CoreInternalFreePool (Buffer);
|
Status = CoreInternalFreePool (Buffer);
|
||||||
if (!EFI_ERROR (Status)) {
|
if (!EFI_ERROR (Status)) {
|
||||||
CoreUpdateProfile ((EFI_PHYSICAL_ADDRESS) (UINTN) RETURN_ADDRESS (0), MemoryProfileActionFreePool, (EFI_MEMORY_TYPE) 0, 0, Buffer);
|
CoreUpdateProfile ((EFI_PHYSICAL_ADDRESS) (UINTN) RETURN_ADDRESS (0), MemoryProfileActionFreePool, (EFI_MEMORY_TYPE) 0, 0, Buffer);
|
||||||
}
|
}
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Internal function to free a pool entry.
|
Internal function to free a pool entry.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user