Implement all four UEFI Runtime Variable services for the nonvolatile\r
and volatile storage space and install variable architecture protocol.\r
\r
-Copyright (c) 2006 - 2008, Intel Corporation \r
+Copyright (c) 2006 - 2009, Intel Corporation \r
All rights reserved. This program and the accompanying materials \r
are licensed and made available under the terms and conditions of the BSD License \r
which accompanies this distribution. The full text of the license may be found at \r
UINTN Index;\r
\r
if (EfiAtRuntime ()) {\r
+ //\r
// Don't use the cache at runtime\r
+ // \r
return;\r
}\r
\r
if (StrCmp (VariableName, Entry->Name) == 0) { \r
Entry->Attributes = Attributes;\r
if (DataSize == 0) {\r
+ //\r
// Delete Case\r
+ //\r
if (Entry->DataSize != 0) {\r
FreePool (Entry->Data);\r
}\r
CopyMem (Entry->Data, Data, DataSize);\r
} else {\r
Entry->Data = AllocatePool (DataSize);\r
+ ASSERT (Entry->Data != NULL);\r
+\r
Entry->DataSize = DataSize;\r
CopyMem (Entry->Data, Data, DataSize);\r
}\r