summaryrefslogtreecommitdiff
path: root/EdkModulePkg/Universal/Variable/RuntimeDxe/reclaim.c
diff options
context:
space:
mode:
Diffstat (limited to 'EdkModulePkg/Universal/Variable/RuntimeDxe/reclaim.c')
-rw-r--r--EdkModulePkg/Universal/Variable/RuntimeDxe/reclaim.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/EdkModulePkg/Universal/Variable/RuntimeDxe/reclaim.c b/EdkModulePkg/Universal/Variable/RuntimeDxe/reclaim.c
index 00ebcf84fd..4c7249046c 100644
--- a/EdkModulePkg/Universal/Variable/RuntimeDxe/reclaim.c
+++ b/EdkModulePkg/Universal/Variable/RuntimeDxe/reclaim.c
@@ -1,20 +1,20 @@
/*++
-Copyright (c) 2006, Intel Corporation
-All rights reserved. This program and the accompanying materials
-are licensed and made available under the terms and conditions of the BSD License
-which accompanies this distribution. The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+Copyright (c) 2006 - 2007, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
Module Name:
reclaim.c
-
+
Abstract:
-
+
Handles non-volatile variable store garbage collection, using FTW
(Fault Tolerant Write) protocol.
@@ -82,7 +82,7 @@ GetFvbHandleByAddress (
}
}
- gBS->FreePool (HandleBuffer);
+ FreePool (HandleBuffer);
return Status;
}
@@ -216,8 +216,8 @@ Returns:
// Prepare for the variable data
//
FtwBufferSize = ((VARIABLE_STORE_HEADER *) ((UINTN) VariableBase))->Size;
- Status = gBS->AllocatePool (EfiRuntimeServicesData, FtwBufferSize, (VOID **) &FtwBuffer);
- if (EFI_ERROR (Status)) {
+ FtwBuffer = AllocateRuntimePool (FtwBufferSize);
+ if (FtwBuffer == NULL) {
return EFI_OUT_OF_RESOURCES;
}
@@ -236,6 +236,6 @@ Returns:
FtwBuffer
);
- gBS->FreePool (FtwBuffer);
+ FreePool (FtwBuffer);
return Status;
}