Debian Codegraph @

doc/man/nvme_status_type.2

raw
1 .TH "libnvme" 9 "enum nvme_status_type" "November 2025" "API Manual" LINUX
2 .SH NAME
3 enum nvme_status_type \- type encoding for NVMe return values, when represented as an int.
4 .SH SYNOPSIS
5 enum nvme_status_type {
6 .br
7 .BI " NVME_STATUS_TYPE_SHIFT"
8 ,
9 .br
10 .br
11 .BI " NVME_STATUS_TYPE_MASK"
12 ,
13 .br
14 .br
15 .BI " NVME_STATUS_TYPE_NVME"
16 ,
17 .br
18 .br
19 .BI " NVME_STATUS_TYPE_MI"
20
21 };
22 .SH Constants
23 .IP "NVME_STATUS_TYPE_SHIFT" 12
24 shift value for status bits
25 .IP "NVME_STATUS_TYPE_MASK" 12
26 mask value for status bits
27 .IP "NVME_STATUS_TYPE_NVME" 12
28 NVMe command status value, typically from CDW3
29 .IP "NVME_STATUS_TYPE_MI" 12
30 NVMe-MI header status
31 .SH "Description"
32
33 The nvme_* api returns an int, with negative values indicating an internal
34 or syscall error, zero signifying success, positive values representing
35 the NVMe status.
36
37 That latter case (the NVMe status) may represent status values from
38 different parts of the transport/controller/etc, and are at most 16 bits of
39 data. So, we use the most-significant 3 bits of the signed int to indicate
40 which type of status this is.