| 1 |
.TH "nvme_admin_passthru" 9 "nvme_admin_passthru" "November 2025" "libnvme API manual" LINUX |
| 2 |
.SH NAME |
| 3 |
nvme_admin_passthru \- Submit an nvme passthrough command |
| 4 |
.SH SYNOPSIS |
| 5 |
.B "int" nvme_admin_passthru |
| 6 |
.BI "(int fd " "," |
| 7 |
.BI "__u8 opcode " "," |
| 8 |
.BI "__u8 flags " "," |
| 9 |
.BI "__u16 rsvd " "," |
| 10 |
.BI "__u32 nsid " "," |
| 11 |
.BI "__u32 cdw2 " "," |
| 12 |
.BI "__u32 cdw3 " "," |
| 13 |
.BI "__u32 cdw10 " "," |
| 14 |
.BI "__u32 cdw11 " "," |
| 15 |
.BI "__u32 cdw12 " "," |
| 16 |
.BI "__u32 cdw13 " "," |
| 17 |
.BI "__u32 cdw14 " "," |
| 18 |
.BI "__u32 cdw15 " "," |
| 19 |
.BI "__u32 data_len " "," |
| 20 |
.BI "void *data " "," |
| 21 |
.BI "__u32 metadata_len " "," |
| 22 |
.BI "void *metadata " "," |
| 23 |
.BI "__u32 timeout_ms " "," |
| 24 |
.BI "__u32 *result " ");" |
| 25 |
.SH ARGUMENTS |
| 26 |
.IP "fd" 12 |
| 27 |
File descriptor of nvme device |
| 28 |
.IP "opcode" 12 |
| 29 |
The nvme io command to send |
| 30 |
.IP "flags" 12 |
| 31 |
NVMe command flags (not used) |
| 32 |
.IP "rsvd" 12 |
| 33 |
Reserved for future use |
| 34 |
.IP "nsid" 12 |
| 35 |
Namespace identifier |
| 36 |
.IP "cdw2" 12 |
| 37 |
Command dword 2 |
| 38 |
.IP "cdw3" 12 |
| 39 |
Command dword 3 |
| 40 |
.IP "cdw10" 12 |
| 41 |
Command dword 10 |
| 42 |
.IP "cdw11" 12 |
| 43 |
Command dword 11 |
| 44 |
.IP "cdw12" 12 |
| 45 |
Command dword 12 |
| 46 |
.IP "cdw13" 12 |
| 47 |
Command dword 13 |
| 48 |
.IP "cdw14" 12 |
| 49 |
Command dword 14 |
| 50 |
.IP "cdw15" 12 |
| 51 |
Command dword 15 |
| 52 |
.IP "data_len" 12 |
| 53 |
Length of the data transferred in this command in bytes |
| 54 |
.IP "data" 12 |
| 55 |
Pointer to user address of the data buffer |
| 56 |
.IP "metadata_len" 12 |
| 57 |
Length of metadata transferred in this command |
| 58 |
.IP "metadata" 12 |
| 59 |
Pointer to user address of the metadata buffer |
| 60 |
.IP "timeout_ms" 12 |
| 61 |
How long the kernel waits for the command to complete |
| 62 |
.IP "result" 12 |
| 63 |
Optional field to return the result from the CQE dword 0 |
| 64 |
.SH "DESCRIPTION" |
| 65 |
Parameterized form of \fBnvme_submit_admin_passthru\fP. This sets up and |
| 66 |
submits a \fIstruct nvme_passthru_cmd\fP. |
| 67 |
|
| 68 |
Known values for \fIopcode\fP are defined in \fIenum nvme_admin_opcode\fP. |
| 69 |
.SH "RETURN" |
| 70 |
The nvme command status if a response was received (see |
| 71 |
\fIenum nvme_status_field\fP) or -1 with errno set otherwise. |