From: AKASHI Takahiro <takahiro.akashi@linaro.org>
To: u-boot@lists.denx.de
Subject: [PATCH v10 03/11] efi_loader: capsule: add memory range capsule definitions
Date: Mon, 30 Nov 2020 18:12:10 +0900 [thread overview]
Message-ID: <20201130091218.66413-4-takahiro.akashi@linaro.org> (raw)
In-Reply-To: <20201130091218.66413-1-takahiro.akashi@linaro.org>
Memory range capsule gives us a way to notify that some memory regions
should be left untouched across the next reset.
See UEFI specification, section 8.5.3.
Since how we should handle this kind of capsule is totally up to
the system, no implementation will be added in this commit.
Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
---
include/efi_api.h | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
diff --git a/include/efi_api.h b/include/efi_api.h
index c128a0a66ce8..7a2a087c60ed 100644
--- a/include/efi_api.h
+++ b/include/efi_api.h
@@ -221,6 +221,10 @@ enum efi_reset_type {
EFI_GUID(0x39b68c46, 0xf7fb, 0x441b, 0xb6, 0xec, \
0x16, 0xb0, 0xf6, 0x98, 0x21, 0xf3)
+#define EFI_MEMORY_RANGE_CAPSULE_GUID \
+ EFI_GUID(0xde9f0ec, 0x88b6, 0x428f, 0x97, 0x7a, \
+ 0x25, 0x8f, 0x1d, 0xe, 0x5e, 0x72)
+
struct efi_capsule_header {
efi_guid_t capsule_guid;
u32 header_size;
@@ -236,6 +240,19 @@ struct efi_capsule_result_variable_header {
efi_status_t capsule_status;
} __packed;
+struct efi_memory_range {
+ efi_physical_addr_t address;
+ u64 length;
+};
+
+struct efi_memory_range_capsule {
+ struct efi_capsule_header *header;
+ /* EFI_MEMORY_TYPE: 0x80000000-0xFFFFFFFF */
+ enum efi_mem_type os_requested_memory_type;
+ u64 number_of_memory_ranges;
+ struct efi_memory_range memory_ranges[];
+} __packed;
+
#define EFI_RT_SUPPORTED_GET_TIME 0x0001
#define EFI_RT_SUPPORTED_SET_TIME 0x0002
#define EFI_RT_SUPPORTED_GET_WAKEUP_TIME 0x0004
--
2.28.0
next prev parent reply other threads:[~2020-11-30 9:12 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-30 9:12 [PATCH v10 00/11] efi_loader: add capsule update support AKASHI Takahiro
2020-11-30 9:12 ` [PATCH v10 01/11] efi_loader: define UpdateCapsule api AKASHI Takahiro
2020-11-30 9:12 ` [PATCH v10 02/11] efi_loader: capsule: add capsule_on_disk support AKASHI Takahiro
2021-02-16 10:24 ` Heinrich Schuchardt
2021-02-16 11:38 ` AKASHI Takahiro
2021-03-17 21:02 ` Heinrich Schuchardt
2020-11-30 9:12 ` AKASHI Takahiro [this message]
2020-11-30 9:12 ` [PATCH v10 04/11] efi_loader: capsule: support firmware update AKASHI Takahiro
2020-11-30 9:12 ` [PATCH v10 05/11] efi_loader: add firmware management protocol for FIT image AKASHI Takahiro
2020-11-30 9:12 ` [PATCH v10 06/11] efi_loader: add firmware management protocol for raw image AKASHI Takahiro
2020-11-30 9:12 ` [PATCH v10 07/11] cmd: add "efidebug capsule" command AKASHI Takahiro
2020-11-30 9:12 ` [PATCH v10 08/11] tools: add mkeficapsule command for UEFI capsule update AKASHI Takahiro
2020-11-30 9:12 ` [PATCH v10 09/11] test/py: efi_capsule: test for FIT image capsule AKASHI Takahiro
2020-11-30 9:12 ` [PATCH v10 10/11] test/py: efi_capsule: test for raw " AKASHI Takahiro
2020-11-30 9:12 ` [PATCH v10 11/11] sandbox: enable capsule update for testing AKASHI Takahiro
2020-12-02 14:37 ` Heinrich Schuchardt
2020-12-02 15:55 ` Tom Rini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201130091218.66413-4-takahiro.akashi@linaro.org \
--to=takahiro.akashi@linaro.org \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.