| /* |
| * Copyright (c) 2025 The Fuchsia Authors |
| * |
| * SPDX-License-Identifier: BSD-3-Clause |
| */ |
| |
| #include <efi_api.h> |
| |
| #define GBL_EFI_FASTBOOT_TRANSPORT_PROTOCOL_REVISION 0x00000000 |
| |
| #define GBL_EFI_FASTBOOT_TRANSPORT_PROTOCOL_GUID \ |
| EFI_GUID(0xedade92c, 0x5c48, 0x440d, 0x84, 0x9c, 0xe2, 0xa0, 0xc7, \ |
| 0xe5, 0x51, 0x43) |
| |
| typedef enum GBL_EFI_FASTBOOT_RX_MODE { |
| SINGLE_PACKET = 0, |
| FIXED_LENGTH, |
| } GblEfiFastbootRxMode; |
| |
| typedef struct GblEfiFastbootTransportProtocol { |
| uint64_t revision; |
| const char *description; |
| EfiStatus (*start)(struct GblEfiFastbootTransportProtocol *self); |
| EfiStatus (*stop)(struct GblEfiFastbootTransportProtocol *self); |
| EfiStatus (*receive)(struct GblEfiFastbootTransportProtocol *self, |
| size_t *buffer_size, void *buffer, |
| GblEfiFastbootRxMode mode); |
| EfiStatus (*send)(struct GblEfiFastbootTransportProtocol *self, |
| size_t *buffer_size, const void *buffer); |
| EfiStatus (*flush)(struct GblEfiFastbootTransportProtocol *self); |
| } GblEfiFastbootTransportProtocol; |