TianoCore EDK2 master
Loading...
Searching...
No Matches
EraseBlock.h
Go to the documentation of this file.
1
12#ifndef __EFI_ERASE_BLOCK_PROTOCOL_H__
13#define __EFI_ERASE_BLOCK_PROTOCOL_H__
14
15#define EFI_ERASE_BLOCK_PROTOCOL_GUID \
16 { \
17 0x95a9a93e, 0xa86e, 0x4926, { 0xaa, 0xef, 0x99, 0x18, 0xe7, 0x72, 0xd9, 0x87 } \
18 }
19
21
22#define EFI_ERASE_BLOCK_PROTOCOL_REVISION ((2<<16) | (60))
23
27typedef struct {
28 //
29 // If Event is NULL, then blocking I/O is performed. If Event is not NULL and
30 // non-blocking I/O is supported, then non-blocking I/O is performed, and
31 // Event will be signaled when the erase request is completed.
32 //
33 EFI_EVENT Event;
34 //
35 // Defines whether the signaled event encountered an error.
36 //
37 EFI_STATUS TransactionStatus;
39
67typedef
69(EFIAPI *EFI_BLOCK_ERASE)(
71 IN UINT32 MediaId,
72 IN EFI_LBA LBA,
74 IN UINTN Size
75 );
76
83 //
84 // The revision to which the EFI_ERASE_BLOCK_PROTOCOL adheres. All future
85 // revisions must be backwards compatible. If a future version is not
86 // backwards compatible, it is not the same GUID.
87 //
88 UINT64 Revision;
89 //
90 // Returns the erase length granularity as a number of logical blocks. A
91 // value of 1 means the erase granularity is one logical block.
92 //
93 UINT32 EraseLengthGranularity;
94 EFI_BLOCK_ERASE EraseBlocks;
95};
96
97extern EFI_GUID gEfiEraseBlockProtocolGuid;
98
99#endif
UINT64 UINTN
EFI_STATUS(EFIAPI * EFI_BLOCK_ERASE)(IN EFI_ERASE_BLOCK_PROTOCOL *This, IN UINT32 MediaId, IN EFI_LBA LBA, IN OUT EFI_ERASE_BLOCK_TOKEN *Token, IN UINTN Size)
Definition: EraseBlock.h:69
#define IN
Definition: Base.h:279
#define OUT
Definition: Base.h:284
UINT64 EFI_LBA
Definition: UefiBaseType.h:45
RETURN_STATUS EFI_STATUS
Definition: UefiBaseType.h:29
VOID * EFI_EVENT
Definition: UefiBaseType.h:37
Definition: Base.h:213