TianoCore EDK2
master
Loading...
Searching...
No Matches
BlockFront.h
Go to the documentation of this file.
1
9
#include "
XenPvBlkDxe.h
"
10
11
#include <IndustryStandard/Xen/event_channel.h>
12
#include <IndustryStandard/Xen/io/blkif.h>
13
14
typedef
struct
_XEN_BLOCK_FRONT_DEVICE
XEN_BLOCK_FRONT_DEVICE
;
15
typedef
struct
_XEN_BLOCK_FRONT_IO
XEN_BLOCK_FRONT_IO
;
16
17
struct
_XEN_BLOCK_FRONT_IO
{
18
XEN_BLOCK_FRONT_DEVICE
*Dev;
19
UINT8 *Buffer;
20
UINTN
Size;
21
UINTN
Sector
;
22
23
grant_ref_t GrantRef[BLKIF_MAX_SEGMENTS_PER_REQUEST];
24
INT32 NumRef;
25
26
EFI_STATUS
Status;
27
};
28
29
typedef
struct
{
30
UINT64 Sectors;
31
UINT32 SectorSize;
32
UINT32 VDiskInfo;
33
BOOLEAN ReadWrite;
34
BOOLEAN CdRom;
35
BOOLEAN FeatureBarrier;
36
BOOLEAN FeatureFlushCache;
37
}
XEN_BLOCK_FRONT_MEDIA_INFO
;
38
39
#define XEN_BLOCK_FRONT_SIGNATURE SIGNATURE_32 ('X', 'p', 'v', 'B')
40
struct
_XEN_BLOCK_FRONT_DEVICE
{
41
UINT32 Signature;
42
EFI_BLOCK_IO_PROTOCOL
BlockIo;
43
domid_t DomainId;
44
45
blkif_front_ring_t Ring;
46
grant_ref_t RingRef;
47
evtchn_port_t EventChannel;
48
blkif_vdev_t DeviceId;
49
50
CONST
CHAR8 *NodeName;
51
XEN_BLOCK_FRONT_MEDIA_INFO
MediaInfo;
52
53
VOID *StateWatchToken;
54
55
XENBUS_PROTOCOL
*XenBusIo;
56
};
57
58
#define XEN_BLOCK_FRONT_FROM_BLOCK_IO(b) \
59
CR (b, XEN_BLOCK_FRONT_DEVICE, BlockIo, XEN_BLOCK_FRONT_SIGNATURE)
60
61
EFI_STATUS
62
XenPvBlockFrontInitialization (
63
IN
XENBUS_PROTOCOL
*XenBusIo,
64
IN
CONST
CHAR8 *NodeName,
65
OUT
XEN_BLOCK_FRONT_DEVICE
**DevPtr
66
);
67
68
VOID
69
XenPvBlockFrontShutdown (
70
IN
XEN_BLOCK_FRONT_DEVICE
*Dev
71
);
72
73
VOID
74
XenPvBlockAsyncIo (
75
IN
OUT
XEN_BLOCK_FRONT_IO
*IoData,
76
IN
BOOLEAN IsWrite
77
);
78
79
EFI_STATUS
80
XenPvBlockIo (
81
IN
OUT
XEN_BLOCK_FRONT_IO
*IoData,
82
IN
BOOLEAN IsWrite
83
);
84
85
VOID
86
XenPvBlockAsyncIoPoll (
87
IN
XEN_BLOCK_FRONT_DEVICE
*Dev
88
);
89
90
VOID
91
XenPvBlockSync (
92
IN
XEN_BLOCK_FRONT_DEVICE
*Dev
93
);
UINTN
UINT64 UINTN
Definition:
ProcessorBind.h:112
CONST
#define CONST
Definition:
Base.h:259
IN
#define IN
Definition:
Base.h:279
OUT
#define OUT
Definition:
Base.h:284
EFI_STATUS
RETURN_STATUS EFI_STATUS
Definition:
UefiBaseType.h:29
XenPvBlkDxe.h
_EFI_BLOCK_IO_PROTOCOL
Definition:
BlockIo.h:214
_XEN_BLOCK_FRONT_DEVICE
Definition:
BlockFront.h:40
_XEN_BLOCK_FRONT_IO
Definition:
BlockFront.h:17
_XEN_BLOCK_FRONT_IO::Sector
UINTN Sector
512 bytes sector.
Definition:
BlockFront.h:21
_XENBUS_PROTOCOL
Definition:
XenBus.h:375
XEN_BLOCK_FRONT_MEDIA_INFO
Definition:
BlockFront.h:29
OvmfPkg
XenPvBlkDxe
BlockFront.h
Generated on Fri Nov 15 2024 18:01:22 for TianoCore EDK2 by
1.9.6