1libnvme(9) API Manual libnvme(9)
2
3
4
6 struct nvme_io_args - Arguments for NVMe I/O commands
7
9 struct nvme_io_args {
10 __u64 slba;
11 __u64 storage_tag;
12 __u32 *result;
13 void *data;
14 void *metadata;
15 int args_size;
16 int fd;
17 __u32 timeout;
18 __u32 nsid;
19 __u32 reftag;
20 __u32 data_len;
21 __u32 metadata_len;
22 __u16 nlb;
23 __u16 control;
24 __u16 apptag;
25 __u16 appmask;
26 __u16 dspec;
27 __u8 dsm;
28 };
29
30
32 slba Starting logical block
33
34 storage_tag This filed specifies Variable Sized Expected Logical Block
35 Storage Tag (ELBST) and Expected Logical Block Reference
36 Tag (ELBRT)
37
38 result The command completion result from CQE dword0
39
40 data Pointer to user address of the data buffer
41
42 metadata Pointer to user address of the metadata buffer
43
44 args_size Size of struct nvme_io_args
45
46 fd File descriptor of nvme device
47
48 timeout Timeout in ms
49
50 nsid Namespace ID
51
52 reftag This field specifies the Initial Logical Block Reference
53 Tag expected value. Used only if the namespace is formatted
54 to use end-to-end protection information.
55
56 data_len Length of user buffer, data, in bytes
57
58 metadata_len
59 Length of user buffer, metadata, in bytes
60
61 nlb Number of logical blocks to send (0's based value)
62
63 control Command control flags, see enum nvme_io_control_flags.
64
65 apptag This field specifies the Application Tag Mask expected
66 value. Used only if the namespace is formatted to use end-
67 to-end protection information.
68
69 appmask This field specifies the Application Tag expected value.
70 Used only if the namespace is formatted to use end-to-end
71 protection information.
72
73 dspec Directive specific value
74
75 dsm Data set management attributes, see enum nvme_io_dsm_flags
76
77
78
79April 2022 struct nvme_io_args libnvme(9)