mirror of https://github.com/acidanthera/audk.git
MdeModulePkg VariableRuntimeDxe: Bug fix and and refine debug message.
Correct NV variable base address for flash memory attribute set to EFI_MEMORY_RUNTIME. Refine the debug error message. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Dong, Guo <guo.dong@intel.com> Reviewed-by: Gao, Liming <liming.gao@intel.com> Reviewed-by: Zeng, Star <star.zeng@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16054 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
710db4e899
commit
e7bafeb9a8
|
@ -366,7 +366,7 @@ FtwNotificationEvent (
|
|||
//
|
||||
// Mark the variable storage region of the FLASH as RUNTIME.
|
||||
//
|
||||
VariableStoreBase = mVariableModuleGlobal->VariableGlobal.NonVolatileVariableBase;
|
||||
VariableStoreBase = NvStorageVariableBase + (((EFI_FIRMWARE_VOLUME_HEADER *)(UINTN)(NvStorageVariableBase))->HeaderLength);
|
||||
VariableStoreLength = ((VARIABLE_STORE_HEADER *)(UINTN)VariableStoreBase)->Size;
|
||||
BaseAddress = VariableStoreBase & (~EFI_PAGE_MASK);
|
||||
Length = VariableStoreLength + (VariableStoreBase - BaseAddress);
|
||||
|
@ -374,7 +374,7 @@ FtwNotificationEvent (
|
|||
|
||||
Status = gDS->GetMemorySpaceDescriptor (BaseAddress, &GcdDescriptor);
|
||||
if (EFI_ERROR (Status)) {
|
||||
DEBUG ((DEBUG_WARN, "Variable driver failed to add EFI_MEMORY_RUNTIME attribute to Flash.\n"));
|
||||
DEBUG ((DEBUG_WARN, "Variable driver failed to get flash memory attribute.\n"));
|
||||
} else {
|
||||
Status = gDS->SetMemorySpaceAttributes (
|
||||
BaseAddress,
|
||||
|
|
Loading…
Reference in New Issue