]>
git.proxmox.com Git - mirror_edk2.git/blob - MdeModulePkg/Include/Library/CapsuleLib.h
3 This library class defines a set of interfaces for how to process capsule image updates.
5 Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR>
6 SPDX-License-Identifier: BSD-2-Clause-Patent
10 #ifndef __CAPSULE_LIB_H__
11 #define __CAPSULE_LIB_H__
14 The firmware checks whether the capsule image is supported
15 by the CapsuleGuid in CapsuleHeader or if there is other specific information in
18 Caution: This function may receive untrusted input.
20 @param CapsuleHeader Pointer to the UEFI capsule image to be checked.
22 @retval EFI_SUCESS Input capsule is supported by firmware.
23 @retval EFI_UNSUPPORTED Input capsule is not supported by the firmware.
28 IN EFI_CAPSULE_HEADER
*CapsuleHeader
32 The firmware-specific implementation processes the capsule image
33 if it recognized the format of this capsule image.
35 Caution: This function may receive untrusted input.
37 @param CapsuleHeader Pointer to the UEFI capsule image to be processed.
39 @retval EFI_SUCESS Capsule Image processed successfully.
40 @retval EFI_UNSUPPORTED Capsule image is not supported by the firmware.
45 IN EFI_CAPSULE_HEADER
*CapsuleHeader
50 This routine is called to process capsules.
52 Caution: This function may receive untrusted input.
54 The capsules reported in EFI_HOB_UEFI_CAPSULE are processed.
55 If there is no EFI_HOB_UEFI_CAPSULE, this routine does nothing.
57 This routine should be called twice in BDS.
58 1) The first call must be before EndOfDxe. The system capsules is processed.
59 If device capsule FMP protocols are exposted at this time and device FMP
60 capsule has zero EmbeddedDriverCount, the device capsules are processed.
61 Each individual capsule result is recorded in capsule record variable.
62 System may reset in this function, if reset is required by capsule and
63 all capsules are processed.
64 If not all capsules are processed, reset will be defered to second call.
66 2) The second call must be after EndOfDxe and after ConnectAll, so that all
67 device capsule FMP protocols are exposed.
68 The system capsules are skipped. If the device capsules are NOT processed
69 in first call, they are processed here.
70 Each individual capsule result is recorded in capsule record variable.
71 System may reset in this function, if reset is required by capsule
72 processed in first call and second call.
74 @retval EFI_SUCCESS There is no error when processing capsules.
75 @retval EFI_OUT_OF_RESOURCES No enough resource to process capsules.