On 9/7/22 13:36, Sunil V L wrote:
RISC-V UEFI platforms need to implement RISCV_EFI_BOOT_PROTOCOL.
Add header file with the definitions of this protocol.
Signed-off-by: Sunil V L <suni...@ventanamicro.com>
Reviewed-by: Heinrich Schuchardt <heinrich.schucha...@canonical.com>
---
MdePkg/Include/Protocol/RiscVBootProtocol.h | 35 ++++++++++++++++++++
1 file changed, 35 insertions(+)
diff --git a/MdePkg/Include/Protocol/RiscVBootProtocol.h
b/MdePkg/Include/Protocol/RiscVBootProtocol.h
new file mode 100644
index 000000000000..7ceb7d830924
--- /dev/null
+++ b/MdePkg/Include/Protocol/RiscVBootProtocol.h
@@ -0,0 +1,35 @@
+
+/** @file
+ RISC-V Boot Protocol mandatory for RISC-V UEFI platforms.
+
+ Specification available at
+
https://github.com/riscv-non-isa/riscv-uefi/releases/download/1.0.0/RISCV_UEFI_PROTOCOL-spec.pdf
+
+ Copyright (c) 2022, Ventana Micro Systems Inc. All rights reserved.<BR>
+ SPDX-License-Identifier: BSD-2-Clause-Patent
+
+**/
+
+#ifndef _RISCV_BOOT_PROTOCOL_H_
+#define _RISCV_BOOT_PROTOCOL_H_
+
+//extern EFI_GUID gRiscVEfiBootProtocolGuid;
+
+typedef struct _RISCV_EFI_BOOT_PROTOCOL RISCV_EFI_BOOT_PROTOCOL;
+
+#define RISCV_EFI_BOOT_PROTOCOL_REVISION 0x00010000
+#define RISCV_EFI_BOOT_PROTOCOL_LATEST_VERSION \
+ RISCV_EFI_BOOT_PROTOCOL_REVISION
+
+typedef EFI_STATUS
+(EFIAPI *EFI_GET_BOOT_HARTID) (
+ IN RISCV_EFI_BOOT_PROTOCOL *This,
+ OUT UINTN *BootHartId
+ );
+
+typedef struct _RISCV_EFI_BOOT_PROTOCOL {
+ UINT64 Revision;
+ EFI_GET_BOOT_HARTID GetBootHartId;
+} RISCV_EFI_BOOT_PROTOCOL;
+
+#endif
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#97125): https://edk2.groups.io/g/devel/message/97125
Mute This Topic: https://groups.io/mt/93522696/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-