summaryrefslogtreecommitdiff
path: root/ArmPkg/Library/BdsLib/BdsLoadOption.c
diff options
context:
space:
mode:
authoroliviermartin <oliviermartin@6f19259b-4bc3-4df7-8a09-765794883524>2013-03-12 00:42:59 +0000
committeroliviermartin <oliviermartin@6f19259b-4bc3-4df7-8a09-765794883524>2013-03-12 00:42:59 +0000
commitc0b2e4775dcb06d9016f17f5d22e6276d9b58397 (patch)
tree1dbf60623d7fa73de0b5dd190bfb81ae8c4ad7e5 /ArmPkg/Library/BdsLib/BdsLoadOption.c
parent7135d76d56ae96ba2fc05d0f0369b2b54ce0b05f (diff)
downloadedk2-platforms-c0b2e4775dcb06d9016f17f5d22e6276d9b58397.tar.xz
ArmPkg: Introduce GetGlobalEnvironmentVariable() function.
Rename GetEnvironmentVariable() function into GetGlobalEnvironmentVariable(). GetEnvironmentVariable() function sill exists but caller must now pass a Guid. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@14176 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'ArmPkg/Library/BdsLib/BdsLoadOption.c')
-rw-r--r--ArmPkg/Library/BdsLib/BdsLoadOption.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/ArmPkg/Library/BdsLib/BdsLoadOption.c b/ArmPkg/Library/BdsLib/BdsLoadOption.c
index 3f4566ffab..be5ed41980 100644
--- a/ArmPkg/Library/BdsLib/BdsLoadOption.c
+++ b/ArmPkg/Library/BdsLib/BdsLoadOption.c
@@ -1,6 +1,6 @@
/** @file
*
-* Copyright (c) 2011-2012, ARM Limited. All rights reserved.
+* Copyright (c) 2011-2013, ARM Limited. All rights reserved.
*
* This program and the accompanying materials
* are licensed and made available under the terms and conditions of the BSD License
@@ -76,7 +76,7 @@ BootOptionFromLoadOptionVariable (
EFI_LOAD_OPTION EfiLoadOption;
UINTN EfiLoadOptionSize;
- Status = GetEnvironmentVariable (BootVariableName, NULL, &EfiLoadOptionSize, (VOID**)&EfiLoadOption);
+ Status = GetGlobalEnvironmentVariable (BootVariableName, NULL, &EfiLoadOptionSize, (VOID**)&EfiLoadOption);
if (!EFI_ERROR(Status)) {
*BdsLoadOption = NULL;
Status = BootOptionParseLoadOption (EfiLoadOption, EfiLoadOptionSize, BdsLoadOption);
@@ -203,7 +203,7 @@ BootOptionToLoadOptionVariable (
// When it is a new entry we must add the entry to the BootOrder
if (OldLoadOption == NULL) {
// Add the new Boot Index to the list
- Status = GetEnvironmentVariable (L"BootOrder", NULL, &BootOrderSize, (VOID**)&BootOrder);
+ Status = GetGlobalEnvironmentVariable (L"BootOrder", NULL, &BootOrderSize, (VOID**)&BootOrder);
if (!EFI_ERROR(Status)) {
BootOrder = ReallocatePool (BootOrderSize, BootOrderSize + sizeof(UINT16), BootOrder);
// Add the new index at the end
@@ -225,7 +225,7 @@ BootOptionToLoadOptionVariable (
);
DEBUG((EFI_D_ERROR,"Create %s\n",BootVariableName));
- // Free memory allocated by GetEnvironmentVariable
+ // Free memory allocated by GetGlobalEnvironmentVariable
if (!EFI_ERROR(Status)) {
FreePool (BootOrder);
}
@@ -249,7 +249,7 @@ BootOptionAllocateBootIndex (
BOOLEAN Found;
// Get the Boot Option Order from the environment variable
- Status = GetEnvironmentVariable (L"BootOrder", NULL, &BootOrderSize, (VOID**)&BootOrder);
+ Status = GetGlobalEnvironmentVariable (L"BootOrder", NULL, &BootOrderSize, (VOID**)&BootOrder);
if (!EFI_ERROR(Status)) {
for (BootIndex = 0; BootIndex <= 0xFFFF; BootIndex++) {
Found = FALSE;