2014-11-20 19:50:04 +00:00
|
|
|
From ed71ce3a579279c6f60d10c8aecef42292504d5c Mon Sep 17 00:00:00 2001
|
|
|
|
From: Peter Jones <pjones@redhat.com>
|
|
|
|
Date: Thu, 20 Nov 2014 13:43:18 -0500
|
|
|
|
Subject: [PATCH 3/5] Add the capsule API
|
|
|
|
|
|
|
|
Signed-off-by: Peter Jones <pjones@redhat.com>
|
|
|
|
---
|
2014-11-20 20:02:59 +00:00
|
|
|
inc/efiapi.h | 38 ++++++++++++++++++++++++++++++++++++++
|
2014-11-20 19:50:04 +00:00
|
|
|
1 file changed, 38 insertions(+)
|
|
|
|
|
2014-11-20 20:02:59 +00:00
|
|
|
diff --git a/inc/efiapi.h b/inc/efiapi.h
|
2014-11-20 19:50:04 +00:00
|
|
|
index 2ab9f1f..a3e3fd9 100644
|
2014-11-20 20:02:59 +00:00
|
|
|
--- a/inc/efiapi.h
|
|
|
|
+++ b/inc/efiapi.h
|
2014-11-20 19:50:04 +00:00
|
|
|
@@ -585,6 +585,42 @@ EFI_STATUS
|
|
|
|
OUT UINT32 *HighCount
|
|
|
|
);
|
|
|
|
|
|
|
|
+typedef struct {
|
|
|
|
+ UINT64 Length;
|
|
|
|
+ union {
|
|
|
|
+ EFI_PHYSICAL_ADDRESS DataBlock;
|
|
|
|
+ EFI_PHYSICAL_ADDRESS ContinuationPointer;
|
|
|
|
+ } Union;
|
|
|
|
+} EFI_CAPSULE_BLOCK_DESCRIPTOR;
|
|
|
|
+
|
|
|
|
+typedef struct {
|
|
|
|
+ EFI_GUID CapsuleGuid;
|
|
|
|
+ UINT32 HeaderSize;
|
|
|
|
+ UINT32 Flags;
|
|
|
|
+ UINT32 CapsuleImageSize;
|
|
|
|
+} EFI_CAPSULE_HEADER;
|
|
|
|
+
|
|
|
|
+#define CAPSULE_FLAGS_PERSIST_ACROSS_RESET 0x00010000
|
|
|
|
+#define CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE 0x00020000
|
|
|
|
+#define CAPSULE_FLAGS_INITIATE_RESET 0x00040000
|
|
|
|
+
|
|
|
|
+typedef
|
|
|
|
+EFI_STATUS
|
|
|
|
+(EFIAPI *EFI_UPDATE_CAPSULE) (
|
|
|
|
+ IN EFI_CAPSULE_HEADER **CapsuleHeaderArray,
|
|
|
|
+ IN UINTN CapsuleCount,
|
|
|
|
+ IN EFI_PHYSICAL_ADDRESS ScatterGatherList OPTIONAL
|
|
|
|
+ );
|
|
|
|
+
|
|
|
|
+typedef
|
|
|
|
+EFI_STATUS
|
|
|
|
+(EFIAPI *EFI_QUERY_CAPSULE_CAPABILITIES) (
|
|
|
|
+ IN EFI_CAPSULE_HEADER **CapsuleHeaderArray,
|
|
|
|
+ IN UINTN CapsuleCount,
|
|
|
|
+ OUT UINT64 *MaximumCapsuleSize,
|
|
|
|
+ OUT EFI_RESET_TYPE *ResetType
|
|
|
|
+ );
|
|
|
|
+
|
|
|
|
//
|
|
|
|
// Protocol handler functions
|
|
|
|
//
|
|
|
|
@@ -720,6 +756,8 @@ typedef struct {
|
|
|
|
EFI_GET_NEXT_HIGH_MONO_COUNT GetNextHighMonotonicCount;
|
|
|
|
EFI_RESET_SYSTEM ResetSystem;
|
|
|
|
|
|
|
|
+ EFI_UPDATE_CAPSULE UpdateCapsule;
|
|
|
|
+ EFI_QUERY_CAPSULE_CAPABILITIES QueryCapsuleCapabilities;
|
|
|
|
} EFI_RUNTIME_SERVICES;
|
|
|
|
|
|
|
|
|
|
|
|
--
|
|
|
|
2.1.0
|
|
|
|
|