\r
**/\r
\r
-#include <Uefi.h>\r
-\r
-#include <Protocol/Capsule.h>\r
-#include <Guid/CapsuleVendor.h>\r
-#include <Guid/FmpCapsule.h>\r
-\r
-#include <Library/DebugLib.h>\r
-#include <Library/PcdLib.h>\r
-#include <Library/CapsuleLib.h>\r
-#include <Library/UefiDriverEntryPoint.h>\r
-#include <Library/UefiBootServicesTableLib.h>\r
-#include <Library/UefiRuntimeServicesTableLib.h>\r
-#include <Library/UefiRuntimeLib.h>\r
-#include <Library/BaseLib.h>\r
-#include <Library/PrintLib.h>\r
-#include <Library/BaseMemoryLib.h>\r
+#include "CapsuleService.h"\r
+\r
//\r
// Handle for the installation of Capsule Architecture Protocol.\r
//\r
UINT32 mMaxSizePopulateCapsule = 0;\r
UINT32 mMaxSizeNonPopulateCapsule = 0;\r
\r
-/**\r
- Create the variable to save the base address of page table and stack\r
- for transferring into long mode in IA32 PEI.\r
-**/\r
-VOID\r
-SaveLongModeContext (\r
- VOID\r
- );\r
-\r
/**\r
Passes capsules to the firmware with both virtual and physical mapping. Depending on the intended\r
consumption, the firmware may process the capsule immediately. If the payload should persist\r
//\r
// Check if the platform supports update capsule across a system reset\r
//\r
- if (!FeaturePcdGet(PcdSupportUpdateCapsuleReset)) {\r
+ if (!IsPersistAcrossResetCapsuleSupported ()) {\r
return EFI_UNSUPPORTED;\r
}\r
\r
+ CapsuleCacheWriteBack (ScatterGatherList);\r
+\r
//\r
// Construct variable name CapsuleUpdateData, CapsuleUpdateData1, CapsuleUpdateData2...\r
// if user calls UpdateCapsule multiple times.\r
//\r
//Check if the platform supports update capsule across a system reset\r
//\r
- if (!FeaturePcdGet(PcdSupportUpdateCapsuleReset)) {\r
+ if (!IsPersistAcrossResetCapsuleSupported ()) {\r
return EFI_UNSUPPORTED;\r
}\r
*ResetType = EfiResetWarm;\r