/** @file\r
*\r
-* Copyright (c) 2011-2012, ARM Limited. All rights reserved.\r
+* Copyright (c) 2011-2013, ARM Limited. All rights reserved.\r
*\r
* This program and the accompanying materials\r
* are licensed and made available under the terms and conditions of the BSD License\r
EFI_LOAD_OPTION EfiLoadOption;\r
UINTN EfiLoadOptionSize;\r
\r
- Status = GetEnvironmentVariable (BootVariableName, NULL, &EfiLoadOptionSize, (VOID**)&EfiLoadOption);\r
+ Status = GetGlobalEnvironmentVariable (BootVariableName, NULL, &EfiLoadOptionSize, (VOID**)&EfiLoadOption);\r
if (!EFI_ERROR(Status)) {\r
*BdsLoadOption = NULL;\r
Status = BootOptionParseLoadOption (EfiLoadOption, EfiLoadOptionSize, BdsLoadOption);\r
// When it is a new entry we must add the entry to the BootOrder\r
if (OldLoadOption == NULL) {\r
// Add the new Boot Index to the list\r
- Status = GetEnvironmentVariable (L"BootOrder", NULL, &BootOrderSize, (VOID**)&BootOrder);\r
+ Status = GetGlobalEnvironmentVariable (L"BootOrder", NULL, &BootOrderSize, (VOID**)&BootOrder);\r
if (!EFI_ERROR(Status)) {\r
BootOrder = ReallocatePool (BootOrderSize, BootOrderSize + sizeof(UINT16), BootOrder);\r
// Add the new index at the end\r
);\r
DEBUG((EFI_D_ERROR,"Create %s\n",BootVariableName));\r
\r
- // Free memory allocated by GetEnvironmentVariable\r
+ // Free memory allocated by GetGlobalEnvironmentVariable\r
if (!EFI_ERROR(Status)) {\r
FreePool (BootOrder);\r
}\r
BOOLEAN Found;\r
\r
// Get the Boot Option Order from the environment variable\r
- Status = GetEnvironmentVariable (L"BootOrder", NULL, &BootOrderSize, (VOID**)&BootOrder);\r
+ Status = GetGlobalEnvironmentVariable (L"BootOrder", NULL, &BootOrderSize, (VOID**)&BootOrder);\r
if (!EFI_ERROR(Status)) {\r
for (BootIndex = 0; BootIndex <= 0xFFFF; BootIndex++) {\r
Found = FALSE;\r