tee: add sandbox driver
[oweals/u-boot.git] / include / efi.h
index cfdccd7693fb30a20e068794b6536abe11a01d1a..b1deb609b464e737459af802fd1728d8e785fd09 100644 (file)
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
 /*
  * Extensible Firmware Interface
  * Based on 'Extensible Firmware Interface Specification' version 0.9,
@@ -41,6 +42,9 @@
 #define efi_va_end va_end
 #endif /* __x86_64__ */
 
+#define EFI32_LOADER_SIGNATURE "EL32"
+#define EFI64_LOADER_SIGNATURE "EL64"
+
 struct efi_device_path;
 
 typedef struct {
@@ -178,6 +182,10 @@ enum efi_mem_type {
 #define EFI_MEMORY_WP          ((u64)0x0000000000001000ULL)    /* write-protect */
 #define EFI_MEMORY_RP          ((u64)0x0000000000002000ULL)    /* read-protect */
 #define EFI_MEMORY_XP          ((u64)0x0000000000004000ULL)    /* execute-protect */
+#define EFI_MEMORY_NV          ((u64)0x0000000000008000ULL)    /* non-volatile */
+#define EFI_MEMORY_MORE_RELIABLE \
+                               ((u64)0x0000000000010000ULL)    /* higher reliability */
+#define EFI_MEMORY_RO          ((u64)0x0000000000020000ULL)    /* read-only */
 #define EFI_MEMORY_RUNTIME     ((u64)0x8000000000000000ULL)    /* range requires runtime mapping */
 #define EFI_MEM_DESC_VERSION   1
 
@@ -244,6 +252,7 @@ enum efi_entry_t {
        EFIET_END,      /* Signals this is the last (empty) entry */
        EFIET_MEMORY_MAP,
        EFIET_GOP_MODE,
+       EFIET_SYS_TABLE,
 
        /* Number of entries */
        EFIET_MEMORY_COUNT,
@@ -334,6 +343,15 @@ struct efi_entry_gopmode {
        } info[];
 };
 
+/**
+ * struct efi_entry_systable - system table passed to U-Boot
+ *
+ * @sys_table: EFI system table address
+ */
+struct efi_entry_systable {
+       efi_physical_addr_t sys_table;
+};
+
 static inline struct efi_mem_desc *efi_get_next_mem_desc(
                struct efi_entry_memmap *map, struct efi_mem_desc *desc)
 {