]> git.proxmox.com Git - mirror_edk2.git/blame - MdeModulePkg/Universal/CapsulePei/Capsule.h
MdeModulePkg: Add Capsule PEIM
[mirror_edk2.git] / MdeModulePkg / Universal / CapsulePei / Capsule.h
CommitLineData
da58b0db 1/** @file\r
2\r
3Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>\r
4\r
5This program and the accompanying materials\r
6are licensed and made available under the terms and conditions\r
7of the BSD License which accompanies this distribution. The\r
8full text of the license may be found at\r
9http://opensource.org/licenses/bsd-license.php\r
10\r
11THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
12WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
13\r
14**/\r
15\r
16#ifndef _CAPSULE_PEIM_H_\r
17#define _CAPSULE_PEIM_H_\r
18\r
19#include <PiPei.h>\r
20#include <Uefi/UefiSpec.h>\r
21\r
22#include <Ppi/Capsule.h>\r
23\r
24#include <Ppi/ReadOnlyVariable2.h>\r
25#include <Guid/CapsuleVendor.h>\r
26\r
27#include <Library/DebugLib.h>\r
28#include <Library/PeimEntryPoint.h>\r
29#include <Library/PeiServicesLib.h>\r
30#include <Library/BaseMemoryLib.h>\r
31#include <Library/HobLib.h>\r
32#include <Library/PeiServicesTablePointerLib.h>\r
33#include <Library/PrintLib.h>\r
34\r
35//\r
36// We want to avoid using memory at 0 for coalescing, so set a\r
37// min address.\r
38//\r
39#define MIN_COALESCE_ADDR 0x100000\r
40#define MAX_SUPPORT_CAPSULE_NUM 50\r
41\r
42//\r
43// This capsule PEIM puts its private data at the start of the\r
44// coalesced capsule. Here's the structure definition.\r
45//\r
46#define EFI_CAPSULE_PEIM_PRIVATE_DATA_SIGNATURE SIGNATURE_32 ('C', 'a', 'p', 'D')\r
47\r
48typedef struct {\r
49 UINT32 Signature;\r
50 UINTN CapsuleSize;\r
51} EFI_CAPSULE_PEIM_PRIVATE_DATA;\r
52\r
53#define CAPSULE_TEST_SIGNATURE SIGNATURE_32('T', 'E', 'S', 'T')\r
54\r
55#endif\r