mirror of https://github.com/acidanthera/audk.git
EmbeddedPkg/CoherentDmaLib: Fix typo in DmaAlignedBuffer
The only valid memory types for DmaAlignedBuffer should be EfiBootServicesData and EfiRuntimeServicesData. However due to the typo, there is no way to allocate runtime pages, and INVALID_PARAMETER is always returned. Fix the typo. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Vladimir Olovyannikov <vladimir.olovyannikov@broadcom.com> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
This commit is contained in:
parent
4d62189347
commit
c783da6599
|
@ -154,7 +154,7 @@ DmaAllocateAlignedBuffer (
|
|||
//
|
||||
if (MemoryType == EfiBootServicesData) {
|
||||
*HostAddress = AllocateAlignedPages (Pages, Alignment);
|
||||
} else if (MemoryType != EfiRuntimeServicesData) {
|
||||
} else if (MemoryType == EfiRuntimeServicesData) {
|
||||
*HostAddress = AllocateAlignedRuntimePages (Pages, Alignment);
|
||||
} else {
|
||||
return EFI_INVALID_PARAMETER;
|
||||
|
|
Loading…
Reference in New Issue