-/*++\r
+/** @file\r
\r
-Copyright (c) 2006 - 2007, Intel Corporation\r
+ The internal header file includes the common header files, defines\r
+ internal structure and functions used by RuntimeVariable module.\r
+\r
+Copyright (c) 2006 - 2008, 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
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
\r
-Module Name:\r
-\r
- Variable.h\r
-\r
-Abstract:\r
-\r
---*/\r
+**/\r
\r
-#ifndef _VARIABLE_H\r
-#define _VARIABLE_H\r
+#ifndef _VARIABLE_H_\r
+#define _VARIABLE_H_\r
\r
#include <PiDxe.h>\r
#include <Protocol/VariableWrite.h>\r
#include <Library/UefiLib.h>\r
#include <Library/BaseLib.h>\r
#include <Library/MemoryAllocationLib.h>\r
-#include <Library/HobLib.h>\r
#include <Guid/VariableInfo.h>\r
#include <Guid/GlobalVariable.h>\r
#include <VariableFormat.h>\r
\r
-\r
-\r
#define VARIABLE_RECLAIM_THRESHOLD (1024)\r
\r
-#define VARIABLE_STORE_SIZE FixedPcdGet32(PcdVariableStoreSize)\r
-#define SCRATCH_SIZE FixedPcdGet32(PcdMaxVariableSize)\r
-\r
-//\r
-// Define GET_PAD_SIZE to optimize compiler\r
-//\r
-#if ((ALIGNMENT == 0) || (ALIGNMENT == 1))\r
-#define GET_PAD_SIZE(a) (0)\r
-#else\r
-#define GET_PAD_SIZE(a) (((~a) + 1) & (ALIGNMENT - 1))\r
-#endif\r
-\r
-#define HEADER_ALIGN(Header) (((UINTN) (Header) + HEADER_ALIGNMENT - 1) & (~(HEADER_ALIGNMENT - 1)))\r
-\r
-\r
typedef struct {\r
VARIABLE_HEADER *CurrPtr;\r
VARIABLE_HEADER *EndPtr;\r
VOID *Data;\r
} VARIABLE_CACHE_ENTRY;\r
\r
-\r
-//\r
-// Functions\r
-//\r
-\r
-EFI_STATUS\r
-EFIAPI\r
-VariableServiceInitialize (\r
- IN EFI_HANDLE ImageHandle,\r
- IN EFI_SYSTEM_TABLE *SystemTable\r
- );\r
-\r
-\r
-EFI_STATUS\r
-FtwVariableSpace (\r
- IN EFI_PHYSICAL_ADDRESS VariableBaseAddress,\r
- IN UINT8 *Buffer,\r
- IN UINTN BufferSize\r
- );\r
-\r
#endif\r