title: nvme_mi_read_nvm_ss_info(2)

text:
# nvme_mi_read_nvm_ss_info(2)

## NAME
struct nvme_mi_read_nvm_ss_info - NVM Subsystem Information Data Structure

## SYNOPSIS
struct nvme_mi_read_nvm_ss_info {

__u8 nump;

__u8 mjr;

__u8 mnr;

__u8 rsvd3[29];

};

## Members
nump

Number of Ports

mjr

NVMe-MI Major Version Number

mnr

NVMe-MI Minor Version Number

rsvd3

Reserved


package: libnvme-devel

title: nvme_mi_read_port_info(2)

summary: Port Information Data Structure

text:
# nvme_mi_read_port_info(2)

## NAME
struct nvme_mi_read_port_info - Port Information Data Structure

## SYNOPSIS
struct nvme_mi_read_port_info {

__u8 portt;

__u8 rsvd1;

__le16 mmctptus;

__le32 meb;

union {

struct nvme_mi_port_pcie pcie;

struct nvme_mi_port_smb smb;

};

};

## Members
portt

Port Type

rsvd1

Reserved

mmctptus

Maximum MCTP Transmission Unit Size

meb

Management Endpoint Buffer Size

{unnamed_union}

anonymous

pcie

PCIe Port Specific Data

smb

SMBus Port Specific Data


title: nvme_mi_read_sc_list(2)

text:
# nvme_mi_read_sc_list(2)

## NAME
struct nvme_mi_read_sc_list - Management Endpoint Buffer Supported Command List Data Structure

## SYNOPSIS
struct nvme_mi_read_sc_list {

__le16 numcmd;

struct nvme_mi_osc cmds[];

};

## Members
numcmd

Number of Commands

cmds

MEB supported Command Data Structure. See struct nvme_mi_osc


title: nvme_mi_resp_status(2)

summary: values for the response status field

text:
# nvme_mi_resp_status(2)

## NAME
enum nvme_mi_resp_status - values for the response status field

## SYNOPSIS
enum nvme_mi_resp_status {

NVME_MI_RESP_SUCCESS ,

NVME_MI_RESP_MPR ,

NVME_MI_RESP_INTERNAL_ERR ,

NVME_MI_RESP_INVALID_OPCODE ,

NVME_MI_RESP_INVALID_PARAM ,

NVME_MI_RESP_INVALID_CMD_SIZE ,

NVME_MI_RESP_INVALID_INPUT_SIZE ,

NVME_MI_RESP_ACCESS_DENIED ,

NVME_MI_RESP_VPD_UPDATES_EXCEEDED ,

NVME_MI_RESP_PCIE_INACCESSIBLE ,

NVME_MI_RESP_MEB_SANITIZED ,

NVME_MI_RESP_ENC_SERV_FAILURE ,

NVME_MI_RESP_ENC_SERV_XFER_FAILURE ,

NVME_MI_RESP_ENC_FAILURE ,

NVME_MI_RESP_ENC_XFER_REFUSED ,

NVME_MI_RESP_ENC_FUNC_UNSUP ,

NVME_MI_RESP_ENC_SERV_UNAVAIL ,

NVME_MI_RESP_ENC_DEGRADED ,

NVME_MI_RESP_SANITIZE_IN_PROGRESS

};

## Constants
NVME_MI_RESP_SUCCESS

success

NVME_MI_RESP_MPR

More Processing Required

NVME_MI_RESP_INTERNAL_ERR

Internal Error

NVME_MI_RESP_INVALID_OPCODE

Invalid command opcode

NVME_MI_RESP_INVALID_PARAM

Invalid command parameter

NVME_MI_RESP_INVALID_CMD_SIZE

Invalid command size

NVME_MI_RESP_INVALID_INPUT_SIZE

Invalid command input data size

NVME_MI_RESP_ACCESS_DENIED

Access Denied

NVME_MI_RESP_VPD_UPDATES_EXCEEDED

More VPD updates than allowed

NVME_MI_RESP_PCIE_INACCESSIBLE

PCIe functionality currently unavailable

NVME_MI_RESP_MEB_SANITIZED

MEB has been cleared due to sanitize

NVME_MI_RESP_ENC_SERV_FAILURE

Enclosure services process failed

NVME_MI_RESP_ENC_SERV_XFER_FAILURE

Transfer with enclosure services failed

NVME_MI_RESP_ENC_FAILURE

Unreoverable enclosure failure

NVME_MI_RESP_ENC_XFER_REFUSED

Enclosure services transfer refused

NVME_MI_RESP_ENC_FUNC_UNSUP

Unsupported enclosure services function

NVME_MI_RESP_ENC_SERV_UNAVAIL

Enclosure services unavailable

NVME_MI_RESP_ENC_DEGRADED

Noncritical failure detected by enc. services

NVME_MI_RESP_SANITIZE_IN_PROGRESS

Command prohibited during sanitize


title: nvme_mi_set_probe_enabled(2)

text:
# nvme_mi_set_probe_enabled(2)

## NAME
nvme_mi_set_probe_enabled - enable/disable the probe for new endpoints

## SYNOPSIS
void nvme_mi_set_probe_enabled (nvme_root_t root , bool enabled );

## ARGUMENTS
root

nvme_root_t object

enabled

whether to probe new endpoints

## DESCRIPTION
Controls whether newly-created endpoints are probed for quirks on creation. Defaults to enabled, which results in some initial messaging with the endpoint to determine model-specific details.


title: nvme_mi_status_to_string(2)

text:
# nvme_mi_status_to_string(2)

## NAME
nvme_mi_status_to_string - return a string representation of the MI status.

## SYNOPSIS
const char * nvme_mi_status_to_string (int status );

## ARGUMENTS
status

MI response status

## DESCRIPTION
Gives a string description of status, as per section 4.1.2 of the NVMe-MI spec. The status value should be of type NVME_STATUS_MI, and extracted from the return value using nvme_status_get_value.

Returned string is const, and should not be freeed.

## RETURN
A string representing the status value


title: nvme_mi_vpd_hdr(2)

summary: Vital Product Data Common Header

text:
# nvme_mi_vpd_hdr(2)

## NAME
struct nvme_mi_vpd_hdr - Vital Product Data Common Header

## SYNOPSIS
struct nvme_mi_vpd_hdr {

__u8 ipmiver;

__u8 iuaoff;

__u8 ciaoff;

__u8 biaoff;

__u8 piaoff;

__u8 mrioff;

__u8 rsvd6;

__u8 chchk;

__u8 vpd[];

};

## Members
ipmiver

IPMI Format Version Number

iuaoff

Internal Use Area Starting Offset

ciaoff

Chassis Info Area Starting Offset

biaoff

Board Info Area Starting Offset

piaoff

Product Info Area Starting Offset

mrioff

MultiRecord Info Area Starting Offset

rsvd6

Reserved

chchk

Common Header Checksum

vpd

Vital Product Data


title: nvme_mi_vpd_mr_common(2)

summary: NVMe MultiRecord Area

text:
# nvme_mi_vpd_mr_common(2)

## NAME
struct nvme_mi_vpd_mr_common - NVMe MultiRecord Area

## SYNOPSIS
struct nvme_mi_vpd_mr_common {

__u8 type;

__u8 rf;

__u8 rlen;

__u8 rchksum;

__u8 hchksum;

union {

struct nvme_mi_vpd_mra nmra;

struct nvme_mi_vpd_ppmra ppmra;

struct nvme_mi_vpd_tra tmra;

};

};

## Members
type

NVMe Record Type ID

rf

Record Format

rlen

Record Length

rchksum

Record Checksum

hchksum

Header Checksum

{unnamed_union}

anonymous

nmra

NVMe MultiRecord Area

ppmra

NVMe PCIe Port MultiRecord Area

tmra

Topology MultiRecord Area


title: nvme_mi_vpd_mra(2)

summary: NVMe MultiRecord Area

text:
# nvme_mi_vpd_mra(2)

## NAME
struct nvme_mi_vpd_mra - NVMe MultiRecord Area

## SYNOPSIS
struct nvme_mi_vpd_mra {

__u8 nmravn;

__u8 ff;

__u8 rsvd7[6];

__u8 i18vpwr;

__u8 m18vpwr;

__u8 i33vpwr;

__u8 m33vpwr;

__u8 rsvd17;

__u8 m33vapsr;

__u8 i5vapsr;

__u8 m5vapsr;

__u8 i12vapsr;

__u8 m12vapsr;

__u8 mtl;

__u8 tnvmcap[16];

__u8 rsvd37[27];

};

## Members
nmravn

NVMe MultiRecord Area Version Number

ff

Form Factor

rsvd7

Reserved

i18vpwr

Initial 1.8 V Power Supply Requirements

m18vpwr

Maximum 1.8 V Power Supply Requirements

i33vpwr

Initial 3.3 V Power Supply Requirements

m33vpwr

Maximum 3.3 V Power Supply Requirements

rsvd17

Reserved

m33vapsr

Maximum 3.3 Vi aux Power Supply Requirements

i5vapsr

Initial 5 V Power Supply Requirements

m5vapsr

Maximum 5 V Power Supply Requirements

i12vapsr

Initial 12 V Power Supply Requirements

m12vapsr

Maximum 12 V Power Supply Requirements

mtl

Maximum Thermal Load

tnvmcap

Total NVM Capacity

rsvd37

Reserved


title: nvme_mi_vpd_ppmra(2)

summary: NVMe PCIe Port MultiRecord Area

text:
# nvme_mi_vpd_ppmra(2)

## NAME
struct nvme_mi_vpd_ppmra - NVMe PCIe Port MultiRecord Area

## SYNOPSIS
struct nvme_mi_vpd_ppmra {

__u8 nppmravn;

__u8 pn;

__u8 ppi;

__u8 ls;

__u8 mlw;

__u8 mctp;

__u8 refccap;

__u8 pi;

__u8 rsvd13[3];

};

## Members
nppmravn

NVMe PCIe Port MultiRecord Area Version Number

pn

PCIe Port Number

ppi

Port Information

ls

PCIe Link Speed

mlw

PCIe Maximum Link Width

mctp

MCTP Support

refccap

Ref Clk Capability

pi

Port Identifier

rsvd13

Reserved


title: nvme_mi_vpd_telem(2)

summary: Vital Product Data Element Descriptor

text:
# nvme_mi_vpd_telem(2)

## NAME
struct nvme_mi_vpd_telem - Vital Product Data Element Descriptor

## SYNOPSIS
struct nvme_mi_vpd_telem {

__u8 type;

__u8 rev;

__u8 len;

__u8 data[0];

};

## Members
type

Type of the Element Descriptor

rev

Revision of the Element Descriptor

len

Number of bytes in the Element Descriptor

data

Type-specific information associated with the Element Descriptor


title: nvme_mi_vpd_tra(2)

summary: Vital Product Data Topology MultiRecord

text:
# nvme_mi_vpd_tra(2)

## NAME
struct nvme_mi_vpd_tra - Vital Product Data Topology MultiRecord

## SYNOPSIS
struct nvme_mi_vpd_tra {

__u8 vn;

__u8 rsvd6;

__u8 ec;

struct nvme_mi_vpd_telem elems[0];

};

## Members
vn

Version Number

rsvd6

Reserved

ec

Element Count

elems

Element Descriptor


title: nvme_namespace_attach_ctrls(2)

summary: Attach namespace to controller(s)

text:
# nvme_namespace_attach_ctrls(2)

## NAME
nvme_namespace_attach_ctrls - Attach namespace to controller(s)

## SYNOPSIS
int nvme_namespace_attach_ctrls (int fd , __u32 nsid , __u16 num_ctrls , __u16 *ctrlist );

## ARGUMENTS
fd

File descriptor of nvme device

nsid

Namespace ID to attach

num_ctrls

Number of controllers in ctrlist

ctrlist

List of controller IDs to perform the attach action

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_namespace_detach_ctrls(2)

summary: Detach namespace from controller(s)

text:
# nvme_namespace_detach_ctrls(2)

## NAME
nvme_namespace_detach_ctrls - Detach namespace from controller(s)

## SYNOPSIS
int nvme_namespace_detach_ctrls (int fd , __u32 nsid , __u16 num_ctrls , __u16 *ctrlist );

## ARGUMENTS
fd

File descriptor of nvme device

nsid

Namespace ID to detach

num_ctrls

Number of controllers in ctrlist

ctrlist

List of controller IDs to perform the detach action

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_namespace_filter(2)

summary: Filter for namespaces

text:
# nvme_namespace_filter(2)

## NAME
nvme_namespace_filter - Filter for namespaces

## SYNOPSIS
int nvme_namespace_filter (const struct dirent *d );

## ARGUMENTS
d

dirent to check

## RETURN
1 if d matches, 0 otherwise


title: nvme_namespace_first_path(2)

summary: Start path iterator

text:
# nvme_namespace_first_path(2)

## NAME
nvme_namespace_first_path - Start path iterator

## SYNOPSIS
nvme_path_t nvme_namespace_first_path (nvme_ns_t ns );

## ARGUMENTS
ns

Namespace instance

## RETURN
First nvme_path_t object of an ns iterator


title: nvme_namespace_for_each_path(2)

summary: Traverse paths

text:
# nvme_namespace_for_each_path(2)

## NAME
nvme_namespace_for_each_path - Traverse paths

## SYNOPSIS
nvme_namespace_for_each_path (n , p );

## ARGUMENTS
n

Namespace instance

p

nvme_path_t object


title: nvme_namespace_for_each_path_safe(2)

summary: Traverse paths

text:
# nvme_namespace_for_each_path_safe(2)

## NAME
nvme_namespace_for_each_path_safe - Traverse paths

## SYNOPSIS
nvme_namespace_for_each_path_safe (n , p , _p );

## ARGUMENTS
n

Namespace instance

p

nvme_path_t object

_p

A nvme_path_t_node to use as temporary storage


title: nvme_namespace_next_path(2)

summary: Next path iterator

text:
# nvme_namespace_next_path(2)

## NAME
nvme_namespace_next_path - Next path iterator

## SYNOPSIS
nvme_path_t nvme_namespace_next_path (nvme_ns_t ns , nvme_path_t p );

## ARGUMENTS
ns

Namespace instance

p

Previous nvme_path_t object of an ns iterator

## RETURN
Next nvme_path_t object of an ns iterator


title: nvme_nbft_free(2)

text:
# nvme_nbft_free(2)

## NAME
nvme_nbft_free - Free the struct nbft_info and its contents

## SYNOPSIS
void nvme_nbft_free (struct nbft_info *nbft );

## ARGUMENTS
nbft

Parsed NBFT table data.


title: nvme_nbft_read(2)

text:
# nvme_nbft_read(2)

## NAME
nvme_nbft_read - Read and parse contents of an ACPI NBFT table

## SYNOPSIS
int nvme_nbft_read (struct nbft_info **nbft , const char *filename );

## ARGUMENTS
nbft

Parsed NBFT table data.

filename

Filename of the raw NBFT table to read.

## DESCRIPTION
Read and parse the specified NBFT file into a struct nbft_info. Free with nvme_nbft_free.

## RETURN
0 on success, errno otherwise.


title: nvme_nd_ns_fpi(2)

text:
# nvme_nd_ns_fpi(2)

## NAME
enum nvme_nd_ns_fpi - If a format operation is in progress, this field indicates the percentage of the namespace that remains to be formatted.

## SYNOPSIS
enum nvme_nd_ns_fpi {

NVME_NS_FPI_REMAINING ,

NVME_NS_FPI_SUPPORTED

};

## Constants
NVME_NS_FPI_REMAINING

Mask to get the format percent remaining value

NVME_NS_FPI_SUPPORTED

If set, indicates that the namespace supports the Format Progress Indicator defined for the field.


title: nvme_next_host(2)

summary: Next host iterator

text:
# nvme_next_host(2)

## NAME
nvme_next_host - Next host iterator

## SYNOPSIS
nvme_host_t nvme_next_host (nvme_root_t r , nvme_host_t h );

## ARGUMENTS
r

nvme_root_t object

h

Previous nvme_host_t iterator

## RETURN
Next nvme_host_t object in an iterator


title: nvme_next_subsystem(2)

summary: Next subsystem iterator

text:
# nvme_next_subsystem(2)

## NAME
nvme_next_subsystem - Next subsystem iterator

## SYNOPSIS
nvme_subsystem_t nvme_next_subsystem (nvme_host_t h , nvme_subsystem_t s );

## ARGUMENTS
h

nvme_host_t object

s

Previous nvme_subsystem_t iterator

## RETURN
next nvme_subsystem_t object in an iterator


title: nvme_ns_attach(2)

text:
# nvme_ns_attach(2)

## NAME
nvme_ns_attach - Attach or detach namespace to controller(s)

## SYNOPSIS
int nvme_ns_attach (struct nvme_ns_attach_args *args );

## ARGUMENTS
args

struct nvme_ns_attach_args Argument structure

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_ns_attach_ctrls(2)

summary: Attach namespace to controllers

text:
# nvme_ns_attach_ctrls(2)

## NAME
nvme_ns_attach_ctrls - Attach namespace to controllers

## SYNOPSIS
int nvme_ns_attach_ctrls (int fd , __u32 nsid , struct nvme_ctrl_list *ctrlist );

## ARGUMENTS
fd

File descriptor of nvme device

nsid

Namespace ID to attach

ctrlist

Controller list to modify attachment state of nsid

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_ns_attach_sel(2)

summary: Namespace Attachment - Select

text:
# nvme_ns_attach_sel(2)

## NAME
enum nvme_ns_attach_sel - Namespace Attachment - Select

## SYNOPSIS
enum nvme_ns_attach_sel {

NVME_NS_ATTACH_SEL_CTRL_ATTACH ,

NVME_NS_ATTACH_SEL_CTRL_DEATTACH

};

## Constants
NVME_NS_ATTACH_SEL_CTRL_ATTACH

Namespace attach selection

NVME_NS_ATTACH_SEL_CTRL_DEATTACH

Namespace detach selection


title: nvme_ns_compare(2)

summary: Compare data on a namespace

text:
# nvme_ns_compare(2)

## NAME
nvme_ns_compare - Compare data on a namespace

## SYNOPSIS
int nvme_ns_compare (nvme_ns_t n , void *buf , off_t offset , size_t count );

## ARGUMENTS
n

Namespace instance

buf

Buffer with data to be compared

offset

LBA offset of n

count

Number of sectors in buf

## RETURN
Number of sectors compared


title: nvme_ns_detach_ctrls(2)

summary: Detach namespace from controllers

text:
# nvme_ns_detach_ctrls(2)

## NAME
nvme_ns_detach_ctrls - Detach namespace from controllers

## SYNOPSIS
int nvme_ns_detach_ctrls (int fd , __u32 nsid , struct nvme_ctrl_list *ctrlist );

## ARGUMENTS
fd

File descriptor of nvme device

nsid

Namespace ID to detach

ctrlist

Controller list to modify attachment state of nsid

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_ns_flush(2)

summary: Flush data to a namespace

text:
# nvme_ns_flush(2)

## NAME
nvme_ns_flush - Flush data to a namespace

## SYNOPSIS
int nvme_ns_flush (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
0 on success, -1 on error.


title: nvme_ns_get_csi(2)

summary: Command set identifier of a namespace

text:
# nvme_ns_get_csi(2)

## NAME
nvme_ns_get_csi - Command set identifier of a namespace

## SYNOPSIS
enum nvme_csi nvme_ns_get_csi (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
The namespace's command set identifier in use


title: nvme_ns_get_ctrl(2)

summary: &nvme_ctrl_t of a namespace

text:
# nvme_ns_get_ctrl(2)

## NAME
nvme_ns_get_ctrl - &nvme_ctrl_t of a namespace

## SYNOPSIS
nvme_ctrl_t nvme_ns_get_ctrl (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## DESCRIPTION
nvme_ctrl_t object may be NULL for a multipathed namespace

## RETURN
nvme_ctrl_t object of n if present


title: nvme_ns_get_eui64(2)

summary: 64-bit eui of a namespace

text:
# nvme_ns_get_eui64(2)

## NAME
nvme_ns_get_eui64 - 64-bit eui of a namespace

## SYNOPSIS
const uint8_t * nvme_ns_get_eui64 (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
A pointer to the 64-bit eui


title: nvme_ns_get_fd(2)

summary: Get associated file descriptor

text:
# nvme_ns_get_fd(2)

## NAME
nvme_ns_get_fd - Get associated file descriptor

## SYNOPSIS
int nvme_ns_get_fd (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
File descriptor associated with n or -1


title: nvme_ns_get_firmware(2)

summary: Firmware string of a namespace

text:
# nvme_ns_get_firmware(2)

## NAME
nvme_ns_get_firmware - Firmware string of a namespace

## SYNOPSIS
const char * nvme_ns_get_firmware (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
Firmware string of n


title: nvme_ns_get_generic_name(2)

text:
# nvme_ns_get_generic_name(2)

## NAME
nvme_ns_get_generic_name - Returns name of generic namespace chardev.

## SYNOPSIS
const char * nvme_ns_get_generic_name (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
Name of generic namespace chardev


title: nvme_ns_get_lba_count(2)

summary: LBA count of a namespace

text:
# nvme_ns_get_lba_count(2)

## NAME
nvme_ns_get_lba_count - LBA count of a namespace

## SYNOPSIS
uint64_t nvme_ns_get_lba_count (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
LBA count of n


title: nvme_ns_get_lba_size(2)

summary: LBA size of a namespace

text:
# nvme_ns_get_lba_size(2)

## NAME
nvme_ns_get_lba_size - LBA size of a namespace

## SYNOPSIS
int nvme_ns_get_lba_size (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
LBA size of n


title: nvme_ns_get_lba_util(2)

summary: LBA utilization of a namespace

text:
# nvme_ns_get_lba_util(2)

## NAME
nvme_ns_get_lba_util - LBA utilization of a namespace

## SYNOPSIS
uint64_t nvme_ns_get_lba_util (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
LBA utilization of n


title: nvme_ns_get_meta_size(2)

summary: Metadata size of a namespace

text:
# nvme_ns_get_meta_size(2)

## NAME
nvme_ns_get_meta_size - Metadata size of a namespace

## SYNOPSIS
int nvme_ns_get_meta_size (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
Metadata size of n


title: nvme_ns_get_model(2)

summary: Model of a namespace

text:
# nvme_ns_get_model(2)

## NAME
nvme_ns_get_model - Model of a namespace

## SYNOPSIS
const char * nvme_ns_get_model (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
Model string of n


title: nvme_ns_get_name(2)

summary: sysfs name of a namespace

text:
# nvme_ns_get_name(2)

## NAME
nvme_ns_get_name - sysfs name of a namespace

## SYNOPSIS
const char * nvme_ns_get_name (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
sysfs name of n


title: nvme_ns_get_nguid(2)

summary: 128-bit nguid of a namespace

text:
# nvme_ns_get_nguid(2)

## NAME
nvme_ns_get_nguid - 128-bit nguid of a namespace

## SYNOPSIS
const uint8_t * nvme_ns_get_nguid (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
A pointer to the 128-bit nguid


title: nvme_ns_get_nsid(2)

summary: NSID of a namespace

text:
# nvme_ns_get_nsid(2)

## NAME
nvme_ns_get_nsid - NSID of a namespace

## SYNOPSIS
int nvme_ns_get_nsid (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
NSID of n


title: nvme_ns_get_serial(2)

summary: Serial number of a namespace

text:
# nvme_ns_get_serial(2)

## NAME
nvme_ns_get_serial - Serial number of a namespace

## SYNOPSIS
const char * nvme_ns_get_serial (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
Serial number string of n


title: nvme_ns_get_subsystem(2)

summary: &nvme_subsystem_t of a namespace

text:
# nvme_ns_get_subsystem(2)

## NAME
nvme_ns_get_subsystem - &nvme_subsystem_t of a namespace

## SYNOPSIS
nvme_subsystem_t nvme_ns_get_subsystem (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
nvme_subsystem_t object of n


title: nvme_ns_get_sysfs_dir(2)

summary: sysfs directory of a namespace

text:
# nvme_ns_get_sysfs_dir(2)

## NAME
nvme_ns_get_sysfs_dir - sysfs directory of a namespace

## SYNOPSIS
const char * nvme_ns_get_sysfs_dir (nvme_ns_t n );

## ARGUMENTS
n

Namespace instance

## RETURN
sysfs directory name of n


title: nvme_ns_get_uuid(2)

summary: UUID of a namespace

text:
# nvme_ns_get_uuid(2)

## NAME
nvme_ns_get_uuid - UUID of a namespace

## SYNOPSIS
void nvme_ns_get_uuid (nvme_ns_t n , unsigned char out[NVME_UUID_LEN] );

## ARGUMENTS
n

Namespace instance

out

buffer for the UUID

## DESCRIPTION
Copies the namespace's uuid into out


title: nvme_ns_id_desc(2)

summary: Namespace identifier type descriptor

text:
# nvme_ns_id_desc(2)

## NAME
struct nvme_ns_id_desc - Namespace identifier type descriptor

## SYNOPSIS
struct nvme_ns_id_desc {

__u8 nidt;

__u8 nidl;

__le16 rsvd;

__u8 nid[];

};

## Members
nidt

Namespace Identifier Type, see enum nvme_ns_id_desc_nidt

nidl

Namespace Identifier Length contains the length in bytes of the struct nvme_id_ns.nid.

rsvd

Reserved

nid

Namespace Identifier contains a value that is globally unique and assigned to the namespace when the namespace is created. The length is defined in struct nvme_id_ns.nidl.


title: nvme_ns_id_desc_nidt(2)

summary: Known namespace identifier types

text:
# nvme_ns_id_desc_nidt(2)

## NAME
enum nvme_ns_id_desc_nidt - Known namespace identifier types

## SYNOPSIS
enum nvme_ns_id_desc_nidt {

NVME_NIDT_EUI64 ,

NVME_NIDT_NGUID ,

NVME_NIDT_UUID ,

NVME_NIDT_CSI

};

## Constants
NVME_NIDT_EUI64

IEEE Extended Unique Identifier, the NID field contains a copy of the EUI64 field in the struct nvme_id_ns.eui64.

NVME_NIDT_NGUID

Namespace Globally Unique Identifier, the NID field contains a copy of the NGUID field in struct nvme_id_ns.nguid.

NVME_NIDT_UUID

The NID field contains a 128-bit Universally Unique Identifier (UUID) as specified in RFC 4122.

NVME_NIDT_CSI

The NID field contains the command set identifier.


title: nvme_ns_identify(2)

summary: Issue an 'identify namespace' command

text:
# nvme_ns_identify(2)

## NAME
nvme_ns_identify - Issue an 'identify namespace' command

## SYNOPSIS
int nvme_ns_identify (nvme_ns_t n , struct nvme_id_ns *ns );

## ARGUMENTS
n

Namespace instance

ns

nvme_id_ns buffer

## DESCRIPTION
Writes the data returned by the 'identify namespace' command into ns.

## RETURN
0 on success, -1 on error.


title: nvme_ns_identify_descs(2)

summary: Issue an 'identify descriptors' command

text:
# nvme_ns_identify_descs(2)

## NAME
nvme_ns_identify_descs - Issue an 'identify descriptors' command

## SYNOPSIS
int nvme_ns_identify_descs (nvme_ns_t n , struct nvme_ns_id_desc *descs );

## ARGUMENTS
n

Namespace instance

descs

List of identify descriptors

## DESCRIPTION
Writes the data returned by the 'identify descriptors' command into descs.

## RETURN
0 on success, -1 on error.


title: nvme_ns_list(2)

summary: Namespace List

text:
# nvme_ns_list(2)

## NAME
struct nvme_ns_list - Namespace List

## SYNOPSIS
struct nvme_ns_list {

__le32 ns[NVME_ID_NS_LIST_MAX];

};

## Members
ns

Namespace Identifier


title: nvme_ns_metadata_type(2)

summary: Namespace Metadata Element Types

text:
# nvme_ns_metadata_type(2)

## NAME
enum nvme_ns_metadata_type - Namespace Metadata Element Types

## SYNOPSIS
enum nvme_ns_metadata_type {

NVME_NS_METADATA_OS_NS_NAME ,

NVME_NS_METADATA_PRE_BOOT_NS_NAME ,

NVME_NS_METADATA_OS_NS_QUAL_1 ,

NVME_NS_METADATA_OS_NS_QUAL_2

};

## Constants
NVME_NS_METADATA_OS_NS_NAME

Name of the namespace in the operating system

NVME_NS_METADATA_PRE_BOOT_NS_NAME

Name of the namespace in the pre-boot environment.

NVME_NS_METADATA_OS_NS_QUAL_1

First qualifier of the Operating System Namespace Name.

NVME_NS_METADATA_OS_NS_QUAL_2

Second qualifier of the Operating System Namespace Name.


title: nvme_ns_mgmt(2)

summary: Issue a Namespace management command

text:
# nvme_ns_mgmt(2)

## NAME
nvme_ns_mgmt - Issue a Namespace management command

## SYNOPSIS
int nvme_ns_mgmt (struct nvme_ns_mgmt_args *args );

## ARGUMENTS
args

struct nvme_ns_mgmt_args Argument structure

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_ns_mgmt_create(2)

summary: Create a non attached namespace

text:
# nvme_ns_mgmt_create(2)

## NAME
nvme_ns_mgmt_create - Create a non attached namespace

## SYNOPSIS
int nvme_ns_mgmt_create (int fd , struct nvme_id_ns *ns , __u32 *nsid , __u32 timeout , __u8 csi , struct nvme_ns_mgmt_host_sw_specified *data );

## ARGUMENTS
fd

File descriptor of nvme device

ns

Namespace identification that defines ns creation parameters

nsid

On success, set to the namespace id that was created

timeout

Override the default timeout to this value in milliseconds; set to 0 to use the system default.

csi

Command Set Identifier

data

Host Software Specified Fields that defines ns creation parameters

## DESCRIPTION
On successful creation, the namespace exists in the subsystem, but is not attached to any controller. Use the nvme_ns_attach_ctrls to assign the namespace to one or more controllers.

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_ns_mgmt_delete(2)

summary: Delete a non attached namespace

text:
# nvme_ns_mgmt_delete(2)

## NAME
nvme_ns_mgmt_delete - Delete a non attached namespace

## SYNOPSIS
int nvme_ns_mgmt_delete (int fd , __u32 nsid );

## ARGUMENTS
fd

File descriptor of nvme device

nsid

Namespace identifier to delete

## DESCRIPTION
It is recommended that a namespace being deleted is not attached to any controller. Use the nvme_ns_detach_ctrls first if the namespace is still attached.

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_ns_mgmt_host_sw_specified(2)

text:
# nvme_ns_mgmt_host_sw_specified(2)

## NAME
struct nvme_ns_mgmt_host_sw_specified - Namespace management Host Software Specified Fields.

## SYNOPSIS
struct nvme_ns_mgmt_host_sw_specified {

__le64 nsze;

__le64 ncap;

__u8 rsvd16[10];

__u8 flbas;

__u8 rsvd27[2];

__u8 dps;

__u8 nmic;

__u8 rsvd31[61];

__le32 anagrpid;

__u8 rsvd96[4];

__le16 nvmsetid;

__le16 endgid;

__u8 rsvd104[280];

__le64 lbstm;

__le16 nphndls;

__u8 rsvd394[105];

union {

__u8 rsvd499[13];

struct {

__u8 znsco;

__le32 rar;

__le32 ror;

__le32 rnumzrwa;

} zns;

};

__le16 phndl[128];

__u8 rsvd768[3328];

};

## Members
nsze

Namespace Size indicates the total size of the namespace in logical blocks. The number of logical blocks is based on the formatted LBA size.

ncap

Namespace Capacity indicates the maximum number of logical blocks that may be allocated in the namespace at any point in time. The number of logical blocks is based on the formatted LBA size.

rsvd16

Reserved

flbas

Formatted LBA Size, see enum nvme_id_ns_flbas.

rsvd27

Reserved

dps

End-to-end Data Protection Type Settings, see enum nvme_id_ns_dps.

nmic

Namespace Multi-path I/O and Namespace Sharing Capabilities, see enum nvme_id_ns_nmic.

rsvd31

Reserved

anagrpid

ANA Group Identifier indicates the ANA Group Identifier of the ANA group of which the namespace is a member.

rsvd96

Reserved

nvmsetid

NVM Set Identifier indicates the NVM Set with which this namespace is associated.

endgid

Endurance Group Identifier indicates the Endurance Group with which this namespace is associated.

rsvd104

Reserved

lbstm

Logical Block Storage Tag Mask Identifies the mask for the Storage Tag field for the protection information

nphndls

Number of Placement Handles specifies the number of Placement Handles included in the Placement Handle List

rsvd394

Reserved

{unnamed_union}

anonymous

rsvd499

Reserved for I/O Command Sets that extend this specification.

zns

rsvd499( Zoned Namespace Command Set specific field )

phndl

Placement Handle Associated RUH : This field specifies the Reclaim Unit Handle Identifier to be associated with the Placement Handle value. If the Flexible Data Placement capability is not supported or not enabled in specified Endurance Group, then the controller shall ignore this field.

rsvd768

Reserved


title: nvme_ns_mgmt_sel(2)

summary: Namespace Management - Select

text:
# nvme_ns_mgmt_sel(2)

## NAME
enum nvme_ns_mgmt_sel - Namespace Management - Select

## SYNOPSIS
enum nvme_ns_mgmt_sel {

NVME_NS_MGMT_SEL_CREATE ,

NVME_NS_MGMT_SEL_DELETE

};

## Constants
NVME_NS_MGMT_SEL_CREATE

Namespace Create selection

NVME_NS_MGMT_SEL_DELETE

Namespace Delete selection


title: nvme_ns_read(2)

summary: Read from a namespace

text:
# nvme_ns_read(2)

## NAME
nvme_ns_read - Read from a namespace

## SYNOPSIS
int nvme_ns_read (nvme_ns_t n , void *buf , off_t offset , size_t count );

## ARGUMENTS
n

Namespace instance

buf

Buffer into which the data will be transferred

offset

LBA offset of n

count

Number of sectors in buf

## RETURN
Number of sectors read or -1 on error.


title: nvme_ns_rescan(2)

summary: Initiate a controller rescan

text:
# nvme_ns_rescan(2)

## NAME
nvme_ns_rescan - Initiate a controller rescan

## SYNOPSIS
int nvme_ns_rescan (int fd );

## ARGUMENTS
fd

File descriptor of nvme device

## DESCRIPTION
This should only be sent to controller handles, not to namespaces.

## RETURN
0 if a rescan was initiated or -1 with errno set otherwise.


title: nvme_ns_verify(2)

summary: Verify data on a namespace

text:
# nvme_ns_verify(2)

## NAME
nvme_ns_verify - Verify data on a namespace

## SYNOPSIS
int nvme_ns_verify (nvme_ns_t n , off_t offset , size_t count );

## ARGUMENTS
n

Namespace instance

offset

LBA offset of n

count

Number of sectors to be verified

## RETURN
Number of sectors verified


title: nvme_ns_write(2)

summary: Write to a namespace

text:
# nvme_ns_write(2)

## NAME
nvme_ns_write - Write to a namespace

## SYNOPSIS
int nvme_ns_write (nvme_ns_t n , void *buf , off_t offset , size_t count );

## ARGUMENTS
n

Namespace instance

buf

Buffer with data to be written

offset

LBA offset of n

count

Number of sectors in buf

## RETURN
Number of sectors written or -1 on error


title: nvme_ns_write_protect_cfg(2)

text:
# nvme_ns_write_protect_cfg(2)

## NAME
enum nvme_ns_write_protect_cfg - Write Protection - Write Protection State

## SYNOPSIS
enum nvme_ns_write_protect_cfg {

NVME_NS_WP_CFG_NONE ,

NVME_NS_WP_CFG_PROTECT ,

NVME_NS_WP_CFG_PROTECT_POWER_CYCLE ,

NVME_NS_WP_CFG_PROTECT_PERMANENT

};

## Constants
NVME_NS_WP_CFG_NONE

No Write Protect

NVME_NS_WP_CFG_PROTECT

Write Protect

NVME_NS_WP_CFG_PROTECT_POWER_CYCLE

Write Protect Until Power Cycle

NVME_NS_WP_CFG_PROTECT_PERMANENT

Permanent Write Protect


title: nvme_ns_write_uncorrectable(2)

summary: Issus a 'write uncorrectable' command

text:
# nvme_ns_write_uncorrectable(2)

## NAME
nvme_ns_write_uncorrectable - Issus a 'write uncorrectable' command

## SYNOPSIS
int nvme_ns_write_uncorrectable (nvme_ns_t n , off_t offset , size_t count );

## ARGUMENTS
n

Namespace instance

offset

LBA offset in n

count

Number of sectors to be written

## RETURN
Number of sectors written


title: nvme_ns_write_zeros(2)

summary: Write zeros to a namespace

text:
# nvme_ns_write_zeros(2)

## NAME
nvme_ns_write_zeros - Write zeros to a namespace

## SYNOPSIS
int nvme_ns_write_zeros (nvme_ns_t n , off_t offset , size_t count );

## ARGUMENTS
n

Namespace instance

offset

LBA offset in n

count

Number of sectors to be written

## RETURN
Number of sectors written


title: nvme_nss_hw_err_event(2)

summary: NVM Subsystem Hardware Error Event

text:
# nvme_nss_hw_err_event(2)

## NAME
struct nvme_nss_hw_err_event - NVM Subsystem Hardware Error Event

## SYNOPSIS
struct nvme_nss_hw_err_event {

__le16 nss_hw_err_event_code;

__u8 rsvd2[2];

__u8 *add_hw_err_info;

};

## Members
nss_hw_err_event_code

NVM Subsystem Hardware Error Event Code

rsvd2

Reserved

add_hw_err_info

Additional Hardware Error Information


title: nvme_nvm_id_ns(2)

text:
# nvme_nvm_id_ns(2)

## NAME
struct nvme_nvm_id_ns - NVME Command Set I/O Command Set Specific Identify Namespace Data Structure

## SYNOPSIS
struct nvme_nvm_id_ns {

__le64 lbstm;

__u8 pic;

__u8 rsvd9[3];

__le32 elbaf[64];

__u8 rsvd268[3828];

};

## Members
lbstm

Logical Block Storage Tag Mask

pic

Protection Information Capabilities

rsvd9

Reserved

elbaf

List of Extended LBA Format Support

rsvd268

Reserved


title: nvme_nvm_id_ns_elbaf(2)

text:
# nvme_nvm_id_ns_elbaf(2)

## NAME
enum nvme_nvm_id_ns_elbaf - This field indicates the extended LBA format

## SYNOPSIS
enum nvme_nvm_id_ns_elbaf {

NVME_NVM_ELBAF_STS_MASK ,

NVME_NVM_ELBAF_PIF_MASK

};

## Constants
NVME_NVM_ELBAF_STS_MASK

Mask to get the storage tag size used to determine the variable-sized storage tag/reference tag fields

NVME_NVM_ELBAF_PIF_MASK

Mask to get the protection information format for the extended LBA format.


title: nvme_nvm_identify_ctrl(2)

summary: Identify controller data

text:
# nvme_nvm_identify_ctrl(2)

## NAME
nvme_nvm_identify_ctrl - Identify controller data

## SYNOPSIS
int nvme_nvm_identify_ctrl (int fd , struct nvme_id_ctrl_nvm *id );

## ARGUMENTS
fd

File descriptor of nvme device

id

User space destination address to transfer the data

## DESCRIPTION
Return an identify controller data structure to the host of processing controller.

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_nvmeset_pl_status(2)

text:
# nvme_nvmeset_pl_status(2)

## NAME
enum nvme_nvmeset_pl_status - Predictable Latency Per NVM Set Log - Status

## SYNOPSIS
enum nvme_nvmeset_pl_status {

NVME_NVMSET_PL_STATUS_DISABLED ,

NVME_NVMSET_PL_STATUS_DTWIN ,

NVME_NVMSET_PL_STATUS_NDWIN

};

## Constants
NVME_NVMSET_PL_STATUS_DISABLED

Not used (Predictable Latency Mode not enabled)

NVME_NVMSET_PL_STATUS_DTWIN

Deterministic Window (DTWIN)

NVME_NVMSET_PL_STATUS_NDWIN

Non-Deterministic Window (NDWIN)


title: nvme_nvmset_attr(2)

summary: NVM Set Attributes Entry

text:
# nvme_nvmset_attr(2)

## NAME
struct nvme_nvmset_attr - NVM Set Attributes Entry

## SYNOPSIS
struct nvme_nvmset_attr {

__le16 nvmsetid;

__le16 endgid;

__u8 rsvd4[4];

__le32 rr4kt;

__le32 ows;

__u8 tnvmsetcap[16];

__u8 unvmsetcap[16];

__u8 rsvd48[80];

};

## Members
nvmsetid

NVM Set Identifier

endgid

Endurance Group Identifier

rsvd4

Reserved

rr4kt

Random 4 KiB Read Typical indicates the typical time to complete a 4 KiB random read in 100 nanosecond units when the NVM Set is in a Predictable Latency Mode Deterministic Window and there is 1 outstanding command per NVM Set.

ows

Optimal Write Size

tnvmsetcap

Total NVM Set Capacity

unvmsetcap

Unallocated NVM Set Capacity

rsvd48

Reserved


title: nvme_nvmset_pl_events(2)

text:
# nvme_nvmset_pl_events(2)

## NAME
enum nvme_nvmset_pl_events - Predictable Latency Per NVM Set Log - Event Type

## SYNOPSIS
enum nvme_nvmset_pl_events {

NVME_NVMSET_PL_EVENT_DTWIN_READ_WARN ,

NVME_NVMSET_PL_EVENT_DTWIN_WRITE_WARN ,

NVME_NVMSET_PL_EVENT_DTWIN_TIME_WARN ,

NVME_NVMSET_PL_EVENT_DTWIN_EXCEEDED ,

NVME_NVMSET_PL_EVENT_DTWIN_EXCURSION

};

## Constants
NVME_NVMSET_PL_EVENT_DTWIN_READ_WARN

DTWIN Reads Warning

NVME_NVMSET_PL_EVENT_DTWIN_WRITE_WARN

DTWIN Writes Warning

NVME_NVMSET_PL_EVENT_DTWIN_TIME_WARN

DTWIN Time Warning

NVME_NVMSET_PL_EVENT_DTWIN_EXCEEDED

Autonomous transition from DTWIN to NDWIN due to typical or maximum value exceeded

NVME_NVMSET_PL_EVENT_DTWIN_EXCURSION

Autonomous transition from DTWIN to NDWIN due to Deterministic Excursion


title: nvme_nvmset_predictable_lat_log(2)

text:
# nvme_nvmset_predictable_lat_log(2)

## NAME
struct nvme_nvmset_predictable_lat_log - Predictable Latency Mode - Deterministic Threshold Configuration Data

## SYNOPSIS
struct nvme_nvmset_predictable_lat_log {

__u8 status;

__u8 rsvd1;

__le16 event_type;

__u8 rsvd4[28];

__le64 dtwin_rt;

__le64 dtwin_wt;

__le64 dtwin_tmax;

__le64 ndwin_tmin_hi;

__le64 ndwin_tmin_lo;

__u8 rsvd72[56];

__le64 dtwin_re;

__le64 dtwin_we;

__le64 dtwin_te;

__u8 rsvd152[360];

};

## Members
status

Status

rsvd1

Reserved

event_type

Event Type

rsvd4

Reserved

dtwin_rt

DTWIN Reads Typical

dtwin_wt

DTWIN Writes Typical

dtwin_tmax

DTWIN Time Maximum

ndwin_tmin_hi

NDWIN Time Minimum High

ndwin_tmin_lo

NDWIN Time Minimum Low

rsvd72

Reserved

dtwin_re

DTWIN Reads Estimate

dtwin_we

DTWIN Writes Estimate

dtwin_te

DTWIN Time Estimate

rsvd152

Reserved


title: nvme_open(2)

text:
# nvme_open(2)

## NAME
nvme_open - Open an nvme controller or namespace device

## SYNOPSIS
int nvme_open (const char *name );

## ARGUMENTS
name

The basename of the device to open

## DESCRIPTION
This will look for the handle in /dev/ and validate the name and filetype match linux conventions.

## RETURN
A file descriptor for the device on a successful open, or -1 with errno set otherwise.


title: nvme_passthru_cmd(2)

summary: nvme passthrough command structure

text:
# nvme_passthru_cmd(2)

## NAME
struct nvme_passthru_cmd - nvme passthrough command structure

## SYNOPSIS
struct nvme_passthru_cmd {

__u8 opcode;

__u8 flags;

__u16 rsvd1;

__u32 nsid;

__u32 cdw2;

__u32 cdw3;

__u64 metadata;

__u64 addr;

__u32 metadata_len;

__u32 data_len;

__u32 cdw10;

__u32 cdw11;

__u32 cdw12;

__u32 cdw13;

__u32 cdw14;

__u32 cdw15;

__u32 timeout_ms;

__u32 result;

};

## Members
opcode

Operation code, see enum nvme_io_opcodes and enum nvme_admin_opcodes

flags

Not supported: intended for command flags (eg: SGL, FUSE)

rsvd1

Reserved for future use

nsid

Namespace Identifier, or Fabrics type

cdw2

Command Dword 2 (no spec defined use)

cdw3

Command Dword 3 (no spec defined use)

metadata

User space address to metadata buffer (NULL if not used)

addr

User space address to data buffer (NULL if not used)

metadata_len

Metadata buffer transfer length

data_len

Data buffer transfer length

cdw10

Command Dword 10 (command specific)

cdw11

Command Dword 11 (command specific)

cdw12

Command Dword 12 (command specific)

cdw13

Command Dword 13 (command specific)

cdw14

Command Dword 14 (command specific)

cdw15

Command Dword 15 (command specific)

timeout_ms

If non-zero, overrides system default timeout in milliseconds

result

Set on completion to the command's CQE DWORD 0 controller response


title: nvme_passthru_cmd64(2)

text:
# nvme_passthru_cmd64(2)

## NAME
struct nvme_passthru_cmd64 - 64-bit nvme passthrough command structure

## SYNOPSIS
struct nvme_passthru_cmd64 {

__u8 opcode;

__u8 flags;

__u16 rsvd1;

__u32 nsid;

__u32 cdw2;

__u32 cdw3;

__u64 metadata;

__u64 addr;

__u32 metadata_len;

__u32 data_len;

__u32 cdw10;

__u32 cdw11;

__u32 cdw12;

__u32 cdw13;

__u32 cdw14;

__u32 cdw15;

__u32 timeout_ms;

__u32 rsvd2;

__u64 result;

};

## Members
opcode

Operation code, see enum nvme_io_opcodes and enum nvme_admin_opcodes

flags

Not supported: intended for command flags (eg: SGL, FUSE)

rsvd1

Reserved for future use

nsid

Namespace Identifier, or Fabrics type

cdw2

Command Dword 2 (no spec defined use)

cdw3

Command Dword 3 (no spec defined use)

metadata

User space address to metadata buffer (NULL if not used)

addr

User space address to data buffer (NULL if not used)

metadata_len

Metadata buffer transfer length

data_len

Data buffer transfer length

cdw10

Command Dword 10 (command specific)

cdw11

Command Dword 11 (command specific)

cdw12

Command Dword 12 (command specific)

cdw13

Command Dword 13 (command specific)

cdw14

Command Dword 14 (command specific)

cdw15

Command Dword 15 (command specific)

timeout_ms

If non-zero, overrides system default timeout in milliseconds

rsvd2

Reserved for future use (and fills an implicit struct pad

result

Set on completion to the command's CQE DWORD 0-1 controller response


title: nvme_path_get_ana_state(2)

summary: ANA state of an nvme_path_t object

text:
# nvme_path_get_ana_state(2)

## NAME
nvme_path_get_ana_state - ANA state of an nvme_path_t object

## SYNOPSIS
const char * nvme_path_get_ana_state (nvme_path_t p );

## ARGUMENTS
p

nvme_path_t object

## RETURN
ANA (Asynchronous Namespace Access) state of p


title: nvme_path_get_ctrl(2)

text:
# nvme_path_get_ctrl(2)

## NAME
nvme_path_get_ctrl - Parent controller of an nvme_path_t object

## SYNOPSIS
nvme_ctrl_t nvme_path_get_ctrl (nvme_path_t p );

## ARGUMENTS
p

nvme_path_t object

## RETURN
Parent controller if present


title: nvme_path_get_name(2)

summary: sysfs name of an &nvme_path_t object

text:
# nvme_path_get_name(2)

## NAME
nvme_path_get_name - sysfs name of an &nvme_path_t object

## SYNOPSIS
const char * nvme_path_get_name (nvme_path_t p );

## ARGUMENTS
p

nvme_path_t object

## RETURN
sysfs name of p


title: nvme_path_get_ns(2)

text:
# nvme_path_get_ns(2)

## NAME
nvme_path_get_ns - Parent namespace of an nvme_path_t object

## SYNOPSIS
nvme_ns_t nvme_path_get_ns (nvme_path_t p );

## ARGUMENTS
p

nvme_path_t object

## RETURN
Parent namespace if present


title: nvme_path_get_sysfs_dir(2)

text:
# nvme_path_get_sysfs_dir(2)

## NAME
nvme_path_get_sysfs_dir - sysfs directory of an nvme_path_t object

## SYNOPSIS
const char * nvme_path_get_sysfs_dir (nvme_path_t p );

## ARGUMENTS
p

nvme_path_t object

## RETURN
sysfs directory of p


title: nvme_paths_filter(2)

summary: Filter for paths

text:
# nvme_paths_filter(2)

## NAME
nvme_paths_filter - Filter for paths

## SYNOPSIS
int nvme_paths_filter (const struct dirent *d );

## ARGUMENTS
d

dirent to check

## RETURN
1 if d matches, 0 otherwise


title: nvme_persistent_event_entry(2)

summary: Persistent Event

text:
# nvme_persistent_event_entry(2)

## NAME
struct nvme_persistent_event_entry - Persistent Event

## SYNOPSIS
struct nvme_persistent_event_entry {

__u8 etype;

__u8 etype_rev;

__u8 ehl;

__u8 ehai;

__le16 cntlid;

__le64 ets;

__le16 pelpid;

__u8 rsvd16[4];

__le16 vsil;

__le16 el;

};

## Members
etype

Event Type

etype_rev

Event Type Revision

ehl

Event Header Length

ehai

Event Header Additional Info

cntlid

Controller Identifier

ets

Event Timestamp

pelpid

Port Identifier

rsvd16

Reserved

vsil

Vendor Specific Information Length

el

Event Length


title: nvme_persistent_event_log(2)

summary: Persistent Event Log

text:
# nvme_persistent_event_log(2)

## NAME
struct nvme_persistent_event_log - Persistent Event Log

## SYNOPSIS
struct nvme_persistent_event_log {

__u8 lid;

__u8 rsvd1[3];

__le32 tnev;

__le64 tll;

__u8 rv;

__u8 rsvd17;

__le16 lhl;

__le64 ts;

__u8 poh[16];

__le64 pcc;

__le16 vid;

__le16 ssvid;

char sn[20];

char mn[40];

char subnqn[NVME_NQN_LENGTH];

__le16 gen_number;

__le32 rci;

__u8 rsvd378[102];

__u8 seb[32];

};

## Members
lid

Log Identifier

rsvd1

Reserved

tnev

Total Number of Events

tll

Total Log Length

rv

Log Revision

rsvd17

Reserved

lhl

Log Header Length

ts

Timestamp

poh

Power on Hours

pcc

Power Cycle Count

vid

PCI Vendor ID

ssvid

PCI Subsystem Vendor ID

sn

Serial Number

mn

Model Number

subnqn

NVM Subsystem NVMe Qualified Name

gen_number

Generation Number

rci

Reporting Context Information

rsvd378

Reserved

seb

Supported Events Bitmap


title: nvme_persistent_event_types(2)

summary: Persistent event log events

text:
# nvme_persistent_event_types(2)

## NAME
enum nvme_persistent_event_types - Persistent event log events

## SYNOPSIS
enum nvme_persistent_event_types {

NVME_PEL_SMART_HEALTH_EVENT ,

NVME_PEL_FW_COMMIT_EVENT ,

NVME_PEL_TIMESTAMP_EVENT ,

NVME_PEL_POWER_ON_RESET_EVENT ,

NVME_PEL_NSS_HW_ERROR_EVENT ,

NVME_PEL_CHANGE_NS_EVENT ,

NVME_PEL_FORMAT_START_EVENT ,

NVME_PEL_FORMAT_COMPLETION_EVENT ,

NVME_PEL_SANITIZE_START_EVENT ,

NVME_PEL_SANITIZE_COMPLETION_EVENT ,

NVME_PEL_SET_FEATURE_EVENT ,

NVME_PEL_TELEMETRY_CRT ,

NVME_PEL_THERMAL_EXCURSION_EVENT

};

## Constants
NVME_PEL_SMART_HEALTH_EVENT

SMART / Health Log Snapshot Event

NVME_PEL_FW_COMMIT_EVENT

Firmware Commit Event

NVME_PEL_TIMESTAMP_EVENT

Timestamp Change Event

NVME_PEL_POWER_ON_RESET_EVENT

Power-on or Reset Event

NVME_PEL_NSS_HW_ERROR_EVENT

NVM Subsystem Hardware Error Event

NVME_PEL_CHANGE_NS_EVENT

Change Namespace Event

NVME_PEL_FORMAT_START_EVENT

Format NVM Start Event

NVME_PEL_FORMAT_COMPLETION_EVENT

Format NVM Completion Event

NVME_PEL_SANITIZE_START_EVENT

Sanitize Start Event

NVME_PEL_SANITIZE_COMPLETION_EVENT

Sanitize Completion Event

NVME_PEL_SET_FEATURE_EVENT

Set Feature Event

NVME_PEL_TELEMETRY_CRT

Telemetry Log Create Event

NVME_PEL_THERMAL_EXCURSION_EVENT

Thermal Excursion Event


title: nvme_pevent_log_action(2)

summary: Persistent Event Log - Action

text:
# nvme_pevent_log_action(2)

## NAME
enum nvme_pevent_log_action - Persistent Event Log - Action

## SYNOPSIS
enum nvme_pevent_log_action {

NVME_PEVENT_LOG_READ ,

NVME_PEVENT_LOG_EST_CTX_AND_READ ,

NVME_PEVENT_LOG_RELEASE_CTX

};

## Constants
NVME_PEVENT_LOG_READ

Read Log Data

NVME_PEVENT_LOG_EST_CTX_AND_READ

Establish Context and Read Log Data

NVME_PEVENT_LOG_RELEASE_CTX

Release Context


title: nvme_plm_config(2)

text:
# nvme_plm_config(2)

## NAME
struct nvme_plm_config - Predictable Latency Mode - Deterministic Threshold Configuration Data Structure

## SYNOPSIS
struct nvme_plm_config {

__le16 ee;

__u8 rsvd2[30];

__le64 dtwinrt;

__le64 dtwinwt;

__le64 dtwintt;

__u8 rsvd56[456];

};

## Members
ee

Enable Event

rsvd2

Reserved

dtwinrt

DTWIN Reads Threshold

dtwinwt

DTWIN Writes Threshold

dtwintt

DTWIN Time Threshold

rsvd56

Reserved


title: nvme_pmr_size(2)

text:
# nvme_pmr_size(2)

## NAME
nvme_pmr_size - Calculate size of persistent memory region elasticity buffer

## SYNOPSIS
__u64 nvme_pmr_size (__u32 pmrebs );

## ARGUMENTS
pmrebs

Value from controller register NVME_REG_PMREBS

## RETURN
size of controller persistent memory buffer in bytes


title: nvme_pmr_throughput(2)

text:
# nvme_pmr_throughput(2)

## NAME
nvme_pmr_throughput - Calculate throughput of persistent memory buffer

## SYNOPSIS
__u64 nvme_pmr_throughput (__u32 pmrswtp );

## ARGUMENTS
pmrswtp

Value from controller register NVME_REG_PMRSWTP

## RETURN
throughput of controller persistent memory buffer in bytes/second


title: nvme_power_on_reset_info_list(2)

summary: Controller Reset Information

text:
# nvme_power_on_reset_info_list(2)

## NAME
struct nvme_power_on_reset_info_list - Controller Reset Information

## SYNOPSIS
struct nvme_power_on_reset_info_list {

__le16 cid;

__u8 fw_act;

__u8 op_in_prog;

__u8 rsvd4[12];

__le32 ctrl_power_cycle;

__le64 power_on_ml_seconds;

__le64 ctrl_time_stamp;

};

## Members
cid

Controller ID

fw_act

Firmware Activation

op_in_prog

Operation in Progress

rsvd4

Reserved

ctrl_power_cycle

Controller Power Cycle

power_on_ml_seconds

Power on milliseconds

ctrl_time_stamp

Controller Timestamp


title: nvme_primary_ctrl_cap(2)

text:
# nvme_primary_ctrl_cap(2)

## NAME
struct nvme_primary_ctrl_cap - Identify - Controller Capabilities Structure

## SYNOPSIS
struct nvme_primary_ctrl_cap {

__le16 cntlid;

__le16 portid;

__u8 crt;

__u8 rsvd5[27];

__le32 vqfrt;

__le32 vqrfa;

__le16 vqrfap;

__le16 vqprt;

__le16 vqfrsm;

__le16 vqgran;

__u8 rsvd48[16];

__le32 vifrt;

__le32 virfa;

__le16 virfap;

__le16 viprt;

__le16 vifrsm;

__le16 vigran;

__u8 rsvd80[4016];

};

## Members
cntlid

Controller Identifier

portid

Port Identifier

crt

Controller Resource Types

rsvd5

reserved

vqfrt

VQ Resources Flexible Total

vqrfa

VQ Resources Flexible Assigned

vqrfap

VQ Resources Flexible Allocated to Primary

vqprt

VQ Resources Private Total

vqfrsm

VQ Resources Flexible Secondary Maximum

vqgran

VQ Flexible Resource Preferred Granularity

rsvd48

reserved

vifrt

VI Resources Flexible Total

virfa

VI Resources Flexible Assigned

virfap

VI Resources Flexible Allocated to Primary

viprt

VI Resources Private Total

vifrsm

VI Resources Flexible Secondary Maximum

vigran

VI Flexible Resource Preferred Granularity

rsvd80

reserved


title: nvme_psd_flags(2)

text:
# nvme_psd_flags(2)

## NAME
enum nvme_psd_flags - Possible flag values in nvme power state descriptor

## SYNOPSIS
enum nvme_psd_flags {

NVME_PSD_FLAGS_MXPS ,

NVME_PSD_FLAGS_NOPS

};

## Constants
NVME_PSD_FLAGS_MXPS

Indicates the scale for the Maximum Power field. If this bit is cleared, then the scale of the Maximum Power field is in 0.01 Watts. If this bit is set, then the scale of the Maximum Power field is in 0.0001 Watts.

NVME_PSD_FLAGS_NOPS

Indicates whether the controller processes I/O commands in this power state. If this bit is cleared, then the controller processes I/O commands in this power state. If this bit is set, then the controller does not process I/O commands in this power state.


title: nvme_psd_power_scale(2)

summary: power scale occupies the upper 3 bits

text:
# nvme_psd_power_scale(2)

## NAME
nvme_psd_power_scale - power scale occupies the upper 3 bits

## SYNOPSIS
unsigned int nvme_psd_power_scale (__u8 ps );

## ARGUMENTS
ps

power scale value

## RETURN
power scale value


title: nvme_psd_ps(2)

text:
# nvme_psd_ps(2)

## NAME
enum nvme_psd_ps - Known values for &struct nvme_psd %ips and %aps. Use with nvme_psd_power_scale() to extract the power scale field to match this enum.

## SYNOPSIS
enum nvme_psd_ps {

NVME_PSD_PS_NOT_REPORTED ,

NVME_PSD_PS_100_MICRO_WATT ,

NVME_PSD_PS_10_MILLI_WATT

};

## Constants
NVME_PSD_PS_NOT_REPORTED

Not reported

NVME_PSD_PS_100_MICRO_WATT

0.0001 watt scale

NVME_PSD_PS_10_MILLI_WATT

0.01 watt scale


title: nvme_psd_workload(2)

text:
# nvme_psd_workload(2)

## NAME
enum nvme_psd_workload - Specifies a workload hint in the Power Management Feature (see &struct nvme_psd.apw) to inform the NVM subsystem or indicate the conditions for the active power level.

## SYNOPSIS
enum nvme_psd_workload {

NVME_PSD_WORKLOAD_NP ,

NVME_PSD_WORKLOAD_1 ,

NVME_PSD_WORKLOAD_2

};

## Constants
NVME_PSD_WORKLOAD_NP

The workload is unknown or not provided.

NVME_PSD_WORKLOAD_1

Extended Idle Period with a Burst of Random Write consists of five minutes of idle followed by thirty-two random write commands of size 1 MiB submitted to a single controller while all other controllers in the NVM subsystem are idle, and then thirty (30) seconds of idle.

NVME_PSD_WORKLOAD_2

Heavy Sequential Writes consists of 80,000 sequential write commands of size 128 KiB submitted to a single controller while all other controllers in the NVM subsystem are idle. The submission queue(s) should be sufficiently large allowing the host to ensure there are multiple commands pending at all times during the workload.


title: nvme_read(2)

summary: Submit an nvme user read command

text:
# nvme_read(2)

## NAME
nvme_read - Submit an nvme user read command

## SYNOPSIS
int nvme_read (struct nvme_io_args *args );

## ARGUMENTS
args

struct nvme_io_args argument structure

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_read_config(2)

summary: Read NVMe JSON configuration file

text:
# nvme_read_config(2)

## NAME
nvme_read_config - Read NVMe JSON configuration file

## SYNOPSIS
int nvme_read_config (nvme_root_t r , const char *config_file );

## ARGUMENTS
r

nvme_root_t object

config_file

JSON configuration file

## DESCRIPTION
Read in the contents of config_file and merge them with the elements in r.

## RETURN
0 on success, -1 on failure with errno set.


title: nvme_refresh_topology(2)

summary: Refresh nvme_root_t object contents

text:
# nvme_refresh_topology(2)

## NAME
nvme_refresh_topology - Refresh nvme_root_t object contents

## SYNOPSIS
void nvme_refresh_topology (nvme_root_t r );

## ARGUMENTS
r

nvme_root_t object

## DESCRIPTION
Removes all elements in r and rescans the existing topology.


title: nvme_register_offsets(2)

text:
# nvme_register_offsets(2)

## NAME
enum nvme_register_offsets - controller registers for all transports. This is the layout of BAR0/1 for PCIe, and properties for fabrics.

## SYNOPSIS
enum nvme_register_offsets {

NVME_REG_CAP ,

NVME_REG_VS ,

NVME_REG_INTMS ,

NVME_REG_INTMC ,

NVME_REG_CC ,

NVME_REG_CSTS ,

NVME_REG_NSSR ,

NVME_REG_AQA ,

NVME_REG_ASQ ,

NVME_REG_ACQ ,

NVME_REG_CMBLOC ,

NVME_REG_CMBSZ ,

NVME_REG_BPINFO ,

NVME_REG_BPRSEL ,

NVME_REG_BPMBL ,

NVME_REG_CMBMSC ,

NVME_REG_CMBSTS ,

NVME_REG_CRTO ,

NVME_REG_PMRCAP ,

NVME_REG_PMRCTL ,

NVME_REG_PMRSTS ,

NVME_REG_PMREBS ,

NVME_REG_PMRSWTP ,

NVME_REG_PMRMSCL ,

NVME_REG_PMRMSCU

};

## Constants
NVME_REG_CAP

Controller Capabilities

NVME_REG_VS

Version

NVME_REG_INTMS

Interrupt Mask Set

NVME_REG_INTMC

Interrupt Mask Clear

NVME_REG_CC

Controller Configuration

NVME_REG_CSTS

Controller Status

NVME_REG_NSSR

NVM Subsystem Reset

NVME_REG_AQA

Admin Queue Attributes

NVME_REG_ASQ

Admin SQ Base Address

NVME_REG_ACQ

Admin CQ Base Address

NVME_REG_CMBLOC

Controller Memory Buffer Location

NVME_REG_CMBSZ

Controller Memory Buffer Size

NVME_REG_BPINFO

Boot Partition Information

NVME_REG_BPRSEL

Boot Partition Read Select

NVME_REG_BPMBL

Boot Partition Memory Buffer Location

NVME_REG_CMBMSC

Controller Memory Buffer Memory Space Control

NVME_REG_CMBSTS

Controller Memory Buffer Status

NVME_REG_CRTO

Controller Ready Timeouts

NVME_REG_PMRCAP

Persistent Memory Capabilities

NVME_REG_PMRCTL

Persistent Memory Region Control

NVME_REG_PMRSTS

Persistent Memory Region Status

NVME_REG_PMREBS

Persistent Memory Region Elasticity Buffer Size

NVME_REG_PMRSWTP

Memory Region Sustained Write Throughput

NVME_REG_PMRMSCL

Persistent Memory Region Controller Memory Space Control Lower

NVME_REG_PMRMSCU

Persistent Memory Region Controller Memory Space Control Upper


title: nvme_registered_ctrl(2)

summary: Registered Controller Data Structure

text:
# nvme_registered_ctrl(2)

## NAME
struct nvme_registered_ctrl - Registered Controller Data Structure

## SYNOPSIS
struct nvme_registered_ctrl {

__le16 cntlid;

__u8 rcsts;

__u8 rsvd3[5];

__le64 hostid;

__le64 rkey;

};

## Members
cntlid

Controller ID

rcsts

Reservation Status

rsvd3

Reserved

hostid

Host Identifier

rkey

Reservation Key


title: nvme_registered_ctrl_ext(2)

text:
# nvme_registered_ctrl_ext(2)

## NAME
struct nvme_registered_ctrl_ext - Registered Controller Extended Data Structure

## SYNOPSIS
struct nvme_registered_ctrl_ext {

__le16 cntlid;

__u8 rcsts;

__u8 rsvd3[5];

__le64 rkey;

__u8 hostid[16];

__u8 rsvd32[32];

};

## Members
cntlid

Controller ID

rcsts

Reservation Status

rsvd3

Reserved

rkey

Reservation Key

hostid

Host Identifier

rsvd32

Reserved


title: nvme_rescan_ctrl(2)

summary: Rescan an existing controller

text:
# nvme_rescan_ctrl(2)

## NAME
nvme_rescan_ctrl - Rescan an existing controller

## SYNOPSIS
void nvme_rescan_ctrl (nvme_ctrl_t c );

## ARGUMENTS
c

Controller instance


title: nvme_resv_acquire(2)

summary: Send an nvme reservation acquire

text:
# nvme_resv_acquire(2)

## NAME
nvme_resv_acquire - Send an nvme reservation acquire

## SYNOPSIS
int nvme_resv_acquire (struct nvme_resv_acquire_args *args );

## ARGUMENTS
args

struct nvme_resv_acquire argument structure

## DESCRIPTION
The Reservation Acquire command acquires a reservation on a namespace, preempt a reservation held on a namespace, and abort a reservation held on a namespace.

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_resv_cptpl(2)

text:
# nvme_resv_cptpl(2)

## NAME
enum nvme_resv_cptpl - Reservation Register - Change Persist Through Power Loss State

## SYNOPSIS
enum nvme_resv_cptpl {

NVME_RESERVATION_CPTPL_NO_CHANGE ,

NVME_RESERVATION_CPTPL_CLEAR ,

NVME_RESERVATION_CPTPL_PERSIST

};

## Constants
NVME_RESERVATION_CPTPL_NO_CHANGE

No change to PTPL state

NVME_RESERVATION_CPTPL_CLEAR

Reservations are released and registrants are cleared on a power on

NVME_RESERVATION_CPTPL_PERSIST

Reservations and registrants persist across a power loss


title: nvme_resv_notification_log(2)

summary: Reservation Notification Log

text:
# nvme_resv_notification_log(2)

## NAME
struct nvme_resv_notification_log - Reservation Notification Log

## SYNOPSIS
struct nvme_resv_notification_log {

__le64 lpc;

__u8 rnlpt;

__u8 nalp;

__u8 rsvd9[2];

__le32 nsid;

__u8 rsvd16[48];

};

## Members
lpc

Log Page Count

rnlpt

See enum nvme_resv_notify_rnlpt.

nalp

Number of Available Log Pages

rsvd9

Reserved

nsid

Namespace ID

rsvd16

Reserved


title: nvme_resv_notify_rnlpt(2)

text:
# nvme_resv_notify_rnlpt(2)

## NAME
enum nvme_resv_notify_rnlpt - Reservation Notification Log - Reservation Notification Log Page Type

## SYNOPSIS
enum nvme_resv_notify_rnlpt {

NVME_RESV_NOTIFY_RNLPT_EMPTY ,

NVME_RESV_NOTIFY_RNLPT_REGISTRATION_PREEMPTED ,

NVME_RESV_NOTIFY_RNLPT_RESERVATION_RELEASED ,

NVME_RESV_NOTIFY_RNLPT_RESERVATION_PREEMPTED

};

## Constants
NVME_RESV_NOTIFY_RNLPT_EMPTY

Empty Log Page

NVME_RESV_NOTIFY_RNLPT_REGISTRATION_PREEMPTED

Registration Preempted

NVME_RESV_NOTIFY_RNLPT_RESERVATION_RELEASED

Reservation Released

NVME_RESV_NOTIFY_RNLPT_RESERVATION_PREEMPTED

Reservation Preempted


title: nvme_resv_racqa(2)

text:
# nvme_resv_racqa(2)

## NAME
enum nvme_resv_racqa - Reservation Acquire - Reservation Acquire Action

## SYNOPSIS
enum nvme_resv_racqa {

NVME_RESERVATION_RACQA_ACQUIRE ,

NVME_RESERVATION_RACQA_PREEMPT ,

NVME_RESERVATION_RACQA_PREEMPT_AND_ABORT

};

## Constants
NVME_RESERVATION_RACQA_ACQUIRE

Acquire

NVME_RESERVATION_RACQA_PREEMPT

Preempt

NVME_RESERVATION_RACQA_PREEMPT_AND_ABORT

Preempt and Abort


title: nvme_resv_register(2)

summary: Send an nvme reservation register

text:
# nvme_resv_register(2)

## NAME
nvme_resv_register - Send an nvme reservation register

## SYNOPSIS
int nvme_resv_register (struct nvme_resv_register_args *args );

## ARGUMENTS
args

struct nvme_resv_register_args argument structure

## DESCRIPTION
The Reservation Register command registers, unregisters, or replaces a reservation key.

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_resv_release(2)

summary: Send an nvme reservation release

text:
# nvme_resv_release(2)

## NAME
nvme_resv_release - Send an nvme reservation release

## SYNOPSIS
int nvme_resv_release (struct nvme_resv_release_args *args );

## ARGUMENTS
args

struct nvme_resv_release_args argument structure

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_resv_report(2)

summary: Send an nvme reservation report

text:
# nvme_resv_report(2)

## NAME
nvme_resv_report - Send an nvme reservation report

## SYNOPSIS
int nvme_resv_report (struct nvme_resv_report_args *args );

## ARGUMENTS
args

struct nvme_resv_report_args argument structure

## DESCRIPTION
Returns a Reservation Status data structure to memory that describes the registration and reservation status of a namespace. See the definition for the returned structure, struct nvme_reservation_status, for more details.

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_resv_rrega(2)

text:
# nvme_resv_rrega(2)

## NAME
enum nvme_resv_rrega - Reservation Register - Reservation Register Action

## SYNOPSIS
enum nvme_resv_rrega {

NVME_RESERVATION_RREGA_REGISTER_KEY ,

NVME_RESERVATION_RREGA_UNREGISTER_KEY ,

NVME_RESERVATION_RREGA_REPLACE_KEY

};

## Constants
NVME_RESERVATION_RREGA_REGISTER_KEY

Register Reservation Key

NVME_RESERVATION_RREGA_UNREGISTER_KEY

Unregister Reservation Key

NVME_RESERVATION_RREGA_REPLACE_KEY

Replace Reservation Key


title: nvme_resv_rrela(2)

text:
# nvme_resv_rrela(2)

## NAME
enum nvme_resv_rrela - Reservation Release - Reservation Release Action

## SYNOPSIS
enum nvme_resv_rrela {

NVME_RESERVATION_RRELA_RELEASE ,

NVME_RESERVATION_RRELA_CLEAR

};

## Constants
NVME_RESERVATION_RRELA_RELEASE

Release

NVME_RESERVATION_RRELA_CLEAR

Clear


title: nvme_resv_rtype(2)

summary: Reservation Type Encoding

text:
# nvme_resv_rtype(2)

## NAME
enum nvme_resv_rtype - Reservation Type Encoding

## SYNOPSIS
enum nvme_resv_rtype {

NVME_RESERVATION_RTYPE_WE ,

NVME_RESERVATION_RTYPE_EA ,

NVME_RESERVATION_RTYPE_WERO ,

NVME_RESERVATION_RTYPE_EARO ,

NVME_RESERVATION_RTYPE_WEAR ,

NVME_RESERVATION_RTYPE_EAAR

};

## Constants
NVME_RESERVATION_RTYPE_WE

Write Exclusive Reservation

NVME_RESERVATION_RTYPE_EA

Exclusive Access Reservation

NVME_RESERVATION_RTYPE_WERO

Write Exclusive - Registrants Only Reservation

NVME_RESERVATION_RTYPE_EARO

Exclusive Access - Registrants Only Reservation

NVME_RESERVATION_RTYPE_WEAR

Write Exclusive - All Registrants Reservation

NVME_RESERVATION_RTYPE_EAAR

Exclusive Access - All Registrants Reservation


title: nvme_resv_status(2)

summary: Reservation Status Data Structure

text:
# nvme_resv_status(2)

## NAME
struct nvme_resv_status - Reservation Status Data Structure

## SYNOPSIS
struct nvme_resv_status {

__le32 gen;

__u8 rtype;

__u8 regctl[2];

__u8 rsvd7[2];

__u8 ptpls;

__u8 rsvd10[14];

union {

struct {

__u8 rsvd24[40];

struct nvme_registered_ctrl_ext regctl_eds[0];

};

struct nvme_registered_ctrl regctl_ds[0];

};

};

## Members
gen

Generation

rtype

Reservation Type

regctl

Number of Registered Controllers

rsvd7

Reserved

ptpls

Persist Through Power Loss State

rsvd10

Reserved

{unnamed_union}

anonymous

{unnamed_struct}

anonymous

rsvd24

Reserved

regctl_eds

Registered Controller Extended Data Structure

regctl_ds

Registered Controller Data Structure


title: nvme_sanitize_compln_event(2)

summary: Sanitize Completion Event Data

text:
# nvme_sanitize_compln_event(2)

## NAME
struct nvme_sanitize_compln_event - Sanitize Completion Event Data

## SYNOPSIS
struct nvme_sanitize_compln_event {

__le16 sani_prog;

__le16 sani_status;

__le16 cmpln_info;

__u8 rsvd6[2];

};

## Members
sani_prog

Sanitize Progress

sani_status

Sanitize Status

cmpln_info

Completion Information

rsvd6

Reserved


title: nvme_sanitize_log_page(2)

summary: Sanitize Status (Log Identifier 81h)

text:
# nvme_sanitize_log_page(2)

## NAME
struct nvme_sanitize_log_page - Sanitize Status (Log Identifier 81h)

## SYNOPSIS
struct nvme_sanitize_log_page {

__le16 sprog;

__le16 sstat;

__le32 scdw10;

__le32 eto;

__le32 etbe;

__le32 etce;

__le32 etond;

__le32 etbend;

__le32 etcend;

__u8 rsvd32[480];

};

## Members
sprog

Sanitize Progress (SPROG): indicates the fraction complete of the sanitize operation. The value is a numerator of the fraction complete that has 65,536 (10000h) as its denominator. This value shall be set to FFFFh if the sstat field is not set to NVME_SANITIZE_SSTAT_STATUS_IN_PROGESS.

sstat

Sanitize Status (SSTAT): indicates the status associated with the most recent sanitize operation. See enum nvme_sanitize_sstat.

scdw10

Sanitize Command Dword 10 Information (SCDW10): contains the value of the Command Dword 10 field of the Sanitize command that started the sanitize operation.

eto

Estimated Time For Overwrite: indicates the number of seconds required to complete an Overwrite sanitize operation with 16 passes in the background when the No-Deallocate Modifies Media After Sanitize field is not set to 10b. A value of 0h indicates that the sanitize operation is expected to be completed in the background when the Sanitize command that started that operation is completed. A value of FFFFFFFFh indicates that no time period is reported.

etbe

Estimated Time For Block Erase: indicates the number of seconds required to complete a Block Erase sanitize operation in the background when the No-Deallocate Modifies Media After Sanitize field is not set to 10b. A value of 0h indicates that the sanitize operation is expected to be completed in the background when the Sanitize command that started that operation is completed. A value of FFFFFFFFh indicates that no time period is reported.

etce

Estimated Time For Crypto Erase: indicates the number of seconds required to complete a Crypto Erase sanitize operation in the background when the No-Deallocate Modifies Media After Sanitize field is not set to 10b. A value of 0h indicates that the sanitize operation is expected to be completed in the background when the Sanitize command that started that operation is completed. A value of FFFFFFFFh indicates that no time period is reported.

etond

Estimated Time For Overwrite With No-Deallocate Media Modification: indicates the number of seconds required to complete an Overwrite sanitize operation and the associated additional media modification after the Overwrite sanitize operation in the background when the No-Deallocate After Sanitize bit was set to 1 in the Sanitize command that requested the Overwrite sanitize operation; and the No-Deallocate Modifies Media After Sanitize field is set to 10b. A value of 0h indicates that the sanitize operation is expected to be completed in the background when the Sanitize command that started that operation is completed. A value of FFFFFFFFh indicates that no time period is reported.

etbend

Estimated Time For Block Erase With No-Deallocate Media Modification: indicates the number of seconds required to complete a Block Erase sanitize operation and the associated additional media modification after the Block Erase sanitize operation in the background when the No-Deallocate After Sanitize bit was set to 1 in the Sanitize command that requested the Overwrite sanitize operation; and the No-Deallocate Modifies Media After Sanitize field is set to 10b. A value of 0h indicates that the sanitize operation is expected to be completed in the background when the Sanitize command that started that operation is completed. A value of FFFFFFFFh indicates that no time period is reported.

etcend

Estimated Time For Crypto Erase With No-Deallocate Media Modification: indicates the number of seconds required to complete a Crypto Erase sanitize operation and the associated additional media modification after the Crypto Erase sanitize operation in the background when the No-Deallocate After Sanitize bit was set to 1 in the Sanitize command that requested the Overwrite sanitize operation; and the No-Deallocate Modifies Media After Sanitize field is set to 10b. A value of 0h indicates that the sanitize operation is expected to be completed in the background when the Sanitize command that started that operation is completed. A value of FFFFFFFFh indicates that no time period is reported.

rsvd32

Reserved


title: nvme_sanitize_nvm(2)

summary: Start a sanitize operation

text:
# nvme_sanitize_nvm(2)

## NAME
nvme_sanitize_nvm - Start a sanitize operation

## SYNOPSIS
int nvme_sanitize_nvm (struct nvme_sanitize_nvm_args *args );

## ARGUMENTS
args

struct nvme_sanitize_nvm_args argument structure

## DESCRIPTION
A sanitize operation alters all user data in the NVM subsystem such that recovery of any previous user data from any cache, the non-volatile media, or any Controller Memory Buffer is not possible.

The Sanitize command starts a sanitize operation or to recover from a previously failed sanitize operation. The sanitize operation types that may be supported are Block Erase, Crypto Erase, and Overwrite. All sanitize operations are processed in the background, i.e., completion of the sanitize command does not indicate completion of the sanitize operation.

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_sanitize_sanact(2)

summary: Sanitize Action

text:
# nvme_sanitize_sanact(2)

## NAME
enum nvme_sanitize_sanact - Sanitize Action

## SYNOPSIS
enum nvme_sanitize_sanact {

NVME_SANITIZE_SANACT_EXIT_FAILURE ,

NVME_SANITIZE_SANACT_START_BLOCK_ERASE ,

NVME_SANITIZE_SANACT_START_OVERWRITE ,

NVME_SANITIZE_SANACT_START_CRYPTO_ERASE

};

## Constants
NVME_SANITIZE_SANACT_EXIT_FAILURE

Exit Failure Mode.

NVME_SANITIZE_SANACT_START_BLOCK_ERASE

Start a Block Erase sanitize operation.

NVME_SANITIZE_SANACT_START_OVERWRITE

Start an Overwrite sanitize operation.

NVME_SANITIZE_SANACT_START_CRYPTO_ERASE

Start a Crypto Erase sanitize operation.


title: nvme_sanitize_sstat(2)

summary: Sanitize Status (SSTAT)

text:
# nvme_sanitize_sstat(2)

## NAME
enum nvme_sanitize_sstat - Sanitize Status (SSTAT)

## SYNOPSIS
enum nvme_sanitize_sstat {

NVME_SANITIZE_SSTAT_STATUS_SHIFT ,

NVME_SANITIZE_SSTAT_STATUS_MASK ,

NVME_SANITIZE_SSTAT_STATUS_NEVER_SANITIZED ,

NVME_SANITIZE_SSTAT_STATUS_COMPLETE_SUCCESS ,

NVME_SANITIZE_SSTAT_STATUS_IN_PROGESS ,

NVME_SANITIZE_SSTAT_STATUS_COMPLETED_FAILED ,

NVME_SANITIZE_SSTAT_STATUS_ND_COMPLETE_SUCCESS ,

NVME_SANITIZE_SSTAT_COMPLETED_PASSES_SHIFT ,

NVME_SANITIZE_SSTAT_COMPLETED_PASSES_MASK ,

NVME_SANITIZE_SSTAT_GLOBAL_DATA_ERASED_SHIFT ,

NVME_SANITIZE_SSTAT_GLOBAL_DATA_ERASED_MASK ,

NVME_SANITIZE_SSTAT_GLOBAL_DATA_ERASED

};

## Constants
NVME_SANITIZE_SSTAT_STATUS_SHIFT

Shift amount to get the status value of the most recent sanitize operation from the struct nvme_sanitize_log_page.sstat field.

NVME_SANITIZE_SSTAT_STATUS_MASK

Mask to get the status value of the most recent sanitize operation.

NVME_SANITIZE_SSTAT_STATUS_NEVER_SANITIZED

The NVM subsystem has never been sanitized.

NVME_SANITIZE_SSTAT_STATUS_COMPLETE_SUCCESS

The most recent sanitize operation completed successfully including any additional media modification.

NVME_SANITIZE_SSTAT_STATUS_IN_PROGESS

A sanitize operation is currently in progress.

NVME_SANITIZE_SSTAT_STATUS_COMPLETED_FAILED

The most recent sanitize operation failed.

NVME_SANITIZE_SSTAT_STATUS_ND_COMPLETE_SUCCESS

The most recent sanitize operation for which No-Deallocate After Sanitize was requested has completed successfully with deallocation of all user data.

NVME_SANITIZE_SSTAT_COMPLETED_PASSES_SHIFT

Shift amount to get the number of completed passes if the most recent sanitize operation was an Overwrite. This value shall be cleared to 0h if the most recent sanitize operation was not an Overwrite.

NVME_SANITIZE_SSTAT_COMPLETED_PASSES_MASK

Mask to get the number of completed passes.

NVME_SANITIZE_SSTAT_GLOBAL_DATA_ERASED_SHIFT

Shift amount to get the Global Data Erased value from the struct nvme_sanitize_log_page.sstat field.

NVME_SANITIZE_SSTAT_GLOBAL_DATA_ERASED_MASK

Mask to get the Global Data Erased value.

NVME_SANITIZE_SSTAT_GLOBAL_DATA_ERASED

Global Data Erased: if set, then no namespace user data in the NVM subsystem has been written to and no Persistent Memory Region in the NVM subsystem has been enabled since being manufactured and the NVM subsystem has never been sanitized; or since the most recent successful sanitize operation.


title: nvme_sanitize_start_event(2)

summary: Sanitize Start Event Data

text:
# nvme_sanitize_start_event(2)

## NAME
struct nvme_sanitize_start_event - Sanitize Start Event Data

## SYNOPSIS
struct nvme_sanitize_start_event {

__le32 sani_cap;

__le32 sani_cdw10;

__le32 sani_cdw11;

};

## Members
sani_cap

SANICAP

sani_cdw10

Sanitize CDW10

sani_cdw11

Sanitize CDW11


title: nvme_scan(2)

summary: Scan NVMe topology

text:
# nvme_scan(2)

## NAME
nvme_scan - Scan NVMe topology

## SYNOPSIS
nvme_root_t nvme_scan (const char *config_file );

## ARGUMENTS
config_file

Configuration file

## RETURN
nvme_root_t object of found elements


title: nvme_scan_ctrl(2)

summary: Scan on a controller

text:
# nvme_scan_ctrl(2)

## NAME
nvme_scan_ctrl - Scan on a controller

## SYNOPSIS
nvme_ctrl_t nvme_scan_ctrl (nvme_root_t r , const char *name );

## ARGUMENTS
r

nvme_root_t object

name

Name of the controller

## DESCRIPTION
Scans a controller with sysfs name name and add it to r.

## RETURN
nvme_ctrl_t object


title: nvme_scan_ctrl_namespace_paths(2)

text:
# nvme_scan_ctrl_namespace_paths(2)

## NAME
nvme_scan_ctrl_namespace_paths - Scan for namespace paths in a controller

## SYNOPSIS
int nvme_scan_ctrl_namespace_paths (nvme_ctrl_t c , struct dirent ***paths );

## ARGUMENTS
c

Controller to scan

paths

Pointer to array of dirents

## RETURN
number of entries in paths


title: nvme_scan_ctrl_namespaces(2)

summary: Scan for namespaces in a controller

text:
# nvme_scan_ctrl_namespaces(2)

## NAME
nvme_scan_ctrl_namespaces - Scan for namespaces in a controller

## SYNOPSIS
int nvme_scan_ctrl_namespaces (nvme_ctrl_t c , struct dirent ***ns );

## ARGUMENTS
c

Controller to scan

ns

Pointer to array of dirents

## RETURN
number of entries in ns


title: nvme_scan_ctrls(2)

summary: Scan for controllers

text:
# nvme_scan_ctrls(2)

## NAME
nvme_scan_ctrls - Scan for controllers

## SYNOPSIS
int nvme_scan_ctrls (struct dirent ***ctrls );

## ARGUMENTS
ctrls

Pointer to array of dirents

## RETURN
number of entries in ctrls


title: nvme_scan_namespace(2)

summary: scan namespace based on sysfs name

text:
# nvme_scan_namespace(2)

## NAME
nvme_scan_namespace - scan namespace based on sysfs name

## SYNOPSIS
nvme_ns_t nvme_scan_namespace (const char *name );

## ARGUMENTS
name

sysfs name of the namespace to scan

## RETURN
nvme_ns_t object or NULL if not found.


title: nvme_scan_subsystem_namespaces(2)

summary: Scan for namespaces in a subsystem

text:
# nvme_scan_subsystem_namespaces(2)

## NAME
nvme_scan_subsystem_namespaces - Scan for namespaces in a subsystem

## SYNOPSIS
int nvme_scan_subsystem_namespaces (nvme_subsystem_t s , struct dirent ***ns );

## ARGUMENTS
s

Subsystem to scan

ns

Pointer to array of dirents

## RETURN
number of entries in ns


title: nvme_scan_subsystems(2)

summary: Scan for subsystems

text:
# nvme_scan_subsystems(2)

## NAME
nvme_scan_subsystems - Scan for subsystems

## SYNOPSIS
int nvme_scan_subsystems (struct dirent ***subsys );

## ARGUMENTS
subsys

Pointer to array of dirents

## RETURN
number of entries in subsys


title: nvme_scan_topology(2)

summary: Scan NVMe topology and apply filter

text:
# nvme_scan_topology(2)

## NAME
nvme_scan_topology - Scan NVMe topology and apply filter

## SYNOPSIS
int nvme_scan_topology (nvme_root_t r , nvme_scan_filter_t f , void *f_args );

## ARGUMENTS
r

nvme_root_t object

f

filter to apply

f_args

user-specified argument to f

## DESCRIPTION
Scans the NVMe topology and filters out the resulting elements by applying f.

## RETURN
Number of elements scanned


title: nvme_secondary_ctrl(2)

summary: Secondary Controller Entry

text:
# nvme_secondary_ctrl(2)

## NAME
struct nvme_secondary_ctrl - Secondary Controller Entry

## SYNOPSIS
struct nvme_secondary_ctrl {

__le16 scid;

__le16 pcid;

__u8 scs;

__u8 rsvd5[3];

__le16 vfn;

__le16 nvq;

__le16 nvi;

__u8 rsvd14[18];

};

## Members
scid

Secondary Controller Identifier

pcid

Primary Controller Identifier

scs

Secondary Controller State

rsvd5

Reserved

vfn

Virtual Function Number

nvq

Number of VQ Flexible Resources Assigned

nvi

Number of VI Flexible Resources Assigned

rsvd14

Reserved


title: nvme_secondary_ctrl_list(2)

summary: Secondary Controller List

text:
# nvme_secondary_ctrl_list(2)

## NAME
struct nvme_secondary_ctrl_list - Secondary Controller List

## SYNOPSIS
struct nvme_secondary_ctrl_list {

__u8 num;

__u8 rsvd[31];

struct nvme_secondary_ctrl sc_entry[NVME_ID_SECONDARY_CTRL_MAX];

};

## Members
num

Number of Identifiers

rsvd

Reserved

sc_entry

Secondary Controller Entry


title: nvme_security_receive(2)

summary: Security Receive command

text:
# nvme_security_receive(2)

## NAME
nvme_security_receive - Security Receive command

## SYNOPSIS
int nvme_security_receive (struct nvme_security_receive_args *args );

## ARGUMENTS
args

struct nvme_security_receive argument structure

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_security_send(2)

summary: Security Send command

text:
# nvme_security_send(2)

## NAME
nvme_security_send - Security Send command

## SYNOPSIS
int nvme_security_send (struct nvme_security_send_args *args );

## ARGUMENTS
args

struct nvme_security_send argument structure

## DESCRIPTION
The Security Send command transfers security protocol data to the controller. The data structure transferred to the controller as part of this command contains security protocol specific commands to be performed by the controller. The data structure transferred may also contain data or parameters associated with the security protocol commands.

The security data is protocol specific and is not defined by the NVMe specification.

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_self_test_log(2)

summary: Device Self-test (Log Identifier 06h)

text:
# nvme_self_test_log(2)

## NAME
struct nvme_self_test_log - Device Self-test (Log Identifier 06h)

## SYNOPSIS
struct nvme_self_test_log {

__u8 current_operation;

__u8 completion;

__u8 rsvd[2];

struct nvme_st_result result[NVME_LOG_ST_MAX_RESULTS];

};

## Members
current_operation

Current Device Self-Test Operation: indicates the status of the current device self-test operation. If a device self-test operation is in process (i.e., this field is set to #NVME_ST_CURR_OP_SHORT or #NVME_ST_CURR_OP_EXTENDED), then the controller shall not set this field to #NVME_ST_CURR_OP_NOT_RUNNING until a new Self-test Result Data Structure is created (i.e., if a device self-test operation completes or is aborted, then the controller shall create a Self-test Result Data Structure prior to setting this field to #NVME_ST_CURR_OP_NOT_RUNNING). See enum nvme_st_curr_op.

completion

Current Device Self-Test Completion: indicates the percentage of the device self-test operation that is complete (e.g., a value of 25 indicates that 25% of the device self-test operation is complete and 75% remains to be tested). If the current_operation field is cleared to #NVME_ST_CURR_OP_NOT_RUNNING (indicating there is no device self-test operation in progress), then this field is ignored.

rsvd

Reserved

result

Self-test Result Data Structures, see struct nvme_st_result.


title: nvme_set_feature_event(2)

summary: Set Feature Event Data

text:
# nvme_set_feature_event(2)

## NAME
struct nvme_set_feature_event - Set Feature Event Data

## SYNOPSIS
struct nvme_set_feature_event {

__le32 layout;

__le32 cdw_mem[0];

};

## Members
layout

Set Feature Event Layout

cdw_mem

Command Dwords Memory buffer


title: nvme_set_features(2)

summary: Set a feature attribute

text:
# nvme_set_features(2)

## NAME
nvme_set_features - Set a feature attribute

## SYNOPSIS
int nvme_set_features (struct nvme_set_features_args *args );

## ARGUMENTS
args

struct nvme_set_features_args argument structure

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_arbitration(2)

summary: Set arbitration features

text:
# nvme_set_features_arbitration(2)

## NAME
nvme_set_features_arbitration - Set arbitration features

## SYNOPSIS
int nvme_set_features_arbitration (int fd , __u8 ab , __u8 lpw , __u8 mpw , __u8 hpw , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

ab

Arbitration Burst

lpw

Low Priority Weight

mpw

Medium Priority Weight

hpw

High Priority Weight

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_async_event(2)

summary: Set asynchronous event feature

text:
# nvme_set_features_async_event(2)

## NAME
nvme_set_features_async_event - Set asynchronous event feature

## SYNOPSIS
int nvme_set_features_async_event (int fd , __u32 events , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

events

Events to enable

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_auto_pst(2)

summary: Set autonomous power state feature

text:
# nvme_set_features_auto_pst(2)

## NAME
nvme_set_features_auto_pst - Set autonomous power state feature

## SYNOPSIS
int nvme_set_features_auto_pst (int fd , bool apste , bool save , struct nvme_feat_auto_pst *apst , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

apste

Autonomous Power State Transition Enable

save

Save value across power states

apst

Autonomous Power State Transition

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_data(2)

text:
# nvme_set_features_data(2)

## NAME
nvme_set_features_data - Helper function for @nvme_set_features()

## SYNOPSIS
int nvme_set_features_data (int fd , __u8 fid , __u32 nsid , __u32 cdw11 , bool save , __u32 data_len , void *data , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

fid

Feature identifier

nsid

Namespace ID, if applicable

cdw11

Value to set the feature to

save

Save value across power states

data_len

Length of feature data, if applicable, in bytes

data

User address of feature data, if applicable

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_endurance_evt_cfg(2)

summary: Set endurance event config feature

text:
# nvme_set_features_endurance_evt_cfg(2)

## NAME
nvme_set_features_endurance_evt_cfg - Set endurance event config feature

## SYNOPSIS
int nvme_set_features_endurance_evt_cfg (int fd , __u16 endgid , __u8 egwarn , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

endgid

Endurance Group Identifier

egwarn

Flags to enable warning, see enum nvme_eg_critical_warning_flags

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_err_recovery(2)

summary: Set error recovery feature

text:
# nvme_set_features_err_recovery(2)

## NAME
nvme_set_features_err_recovery - Set error recovery feature

## SYNOPSIS
int nvme_set_features_err_recovery (int fd , __u32 nsid , __u16 tler , bool dulbe , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

nsid

Namespace ID

tler

Time-limited error recovery value

dulbe

Deallocated or Unwritten Logical Block Error Enable

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_hctm(2)

summary: Set thermal management feature

text:
# nvme_set_features_hctm(2)

## NAME
nvme_set_features_hctm - Set thermal management feature

## SYNOPSIS
int nvme_set_features_hctm (int fd , __u16 tmt2 , __u16 tmt1 , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

tmt2

Thermal Management Temperature 2

tmt1

Thermal Management Temperature 1

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_host_behavior(2)

summary: Set host behavior feature

text:
# nvme_set_features_host_behavior(2)

## NAME
nvme_set_features_host_behavior - Set host behavior feature

## SYNOPSIS
int nvme_set_features_host_behavior (int fd , bool save , struct nvme_feat_host_behavior *data );

## ARGUMENTS
fd

File descriptor of nvme device

save

Save value across power states

data

Pointer to structure nvme_feat_host_behavior

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_host_id(2)

text:
# nvme_set_features_host_id(2)

## NAME
nvme_set_features_host_id - Set enable extended host identifiers feature

## SYNOPSIS
int nvme_set_features_host_id (int fd , bool exhid , bool save , __u8 *hostid );

## ARGUMENTS
fd

File descriptor of nvme device

exhid

Enable Extended Host Identifier

save

Save value across power states

hostid

Host ID to set

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_irq_coalesce(2)

summary: Set IRQ coalesce feature

text:
# nvme_set_features_irq_coalesce(2)

## NAME
nvme_set_features_irq_coalesce - Set IRQ coalesce feature

## SYNOPSIS
int nvme_set_features_irq_coalesce (int fd , __u8 thr , __u8 time , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

thr

Aggregation Threshold

time

Aggregation Time

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_irq_config(2)

summary: Set IRQ config feature

text:
# nvme_set_features_irq_config(2)

## NAME
nvme_set_features_irq_config - Set IRQ config feature

## SYNOPSIS
int nvme_set_features_irq_config (int fd , __u16 iv , bool cd , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

iv

Interrupt Vector

cd

Coalescing Disable

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_lba_range(2)

summary: Set LBA range feature

text:
# nvme_set_features_lba_range(2)

## NAME
nvme_set_features_lba_range - Set LBA range feature

## SYNOPSIS
int nvme_set_features_lba_range (int fd , __u32 nsid , __u32 nr_ranges , bool save , struct nvme_lba_range_type *data , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

nsid

Namespace ID

nr_ranges

Number of ranges in data

save

Save value across power states

data

User address of feature data

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_lba_sts_interval(2)

summary: Set LBA status information feature

text:
# nvme_set_features_lba_sts_interval(2)

## NAME
nvme_set_features_lba_sts_interval - Set LBA status information feature

## SYNOPSIS
int nvme_set_features_lba_sts_interval (int fd , __u16 lsiri , __u16 lsipi , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

lsiri

LBA Status Information Report Interval

lsipi

LBA Status Information Poll Interval

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_nopsc(2)

summary: Set non-operational power state feature

text:
# nvme_set_features_nopsc(2)

## NAME
nvme_set_features_nopsc - Set non-operational power state feature

## SYNOPSIS
int nvme_set_features_nopsc (int fd , bool noppme , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

noppme

Non-Operational Power State Permissive Mode Enable

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_plm_config(2)

summary: Set predictable latency feature

text:
# nvme_set_features_plm_config(2)

## NAME
nvme_set_features_plm_config - Set predictable latency feature

## SYNOPSIS
int nvme_set_features_plm_config (int fd , bool enable , __u16 nvmsetid , bool save , struct nvme_plm_config *data , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

enable

Predictable Latency Enable

nvmsetid

NVM Set Identifier

save

Save value across power states

data

Pointer to structure nvme_plm_config

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_plm_window(2)

summary: Set window select feature

text:
# nvme_set_features_plm_window(2)

## NAME
nvme_set_features_plm_window - Set window select feature

## SYNOPSIS
int nvme_set_features_plm_window (int fd , enum nvme_feat_plm_window_select sel , __u16 nvmsetid , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

sel

Window Select

nvmsetid

NVM Set Identifier

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_power_mgmt(2)

summary: Set power management feature

text:
# nvme_set_features_power_mgmt(2)

## NAME
nvme_set_features_power_mgmt - Set power management feature

## SYNOPSIS
int nvme_set_features_power_mgmt (int fd , __u8 ps , __u8 wh , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

ps

Power State

wh

Workload Hint

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_resv_mask(2)

text:
# nvme_set_features_resv_mask(2)

## NAME
nvme_set_features_resv_mask - Set reservation notification mask feature

## SYNOPSIS
int nvme_set_features_resv_mask (int fd , __u32 mask , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

mask

Reservation Notification Mask Field

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_resv_persist(2)

summary: Set persist through power loss feature

text:
# nvme_set_features_resv_persist(2)

## NAME
nvme_set_features_resv_persist - Set persist through power loss feature

## SYNOPSIS
int nvme_set_features_resv_persist (int fd , bool ptpl , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

ptpl

Persist Through Power Loss

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_rrl(2)

summary: Set read recovery level feature

text:
# nvme_set_features_rrl(2)

## NAME
nvme_set_features_rrl - Set read recovery level feature

## SYNOPSIS
int nvme_set_features_rrl (int fd , __u8 rrl , __u16 nvmsetid , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

rrl

Read recovery level setting

nvmsetid

NVM set id

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_sanitize(2)

summary: Set sanitize feature

text:
# nvme_set_features_sanitize(2)

## NAME
nvme_set_features_sanitize - Set sanitize feature

## SYNOPSIS
int nvme_set_features_sanitize (int fd , bool nodrm , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

nodrm

No-Deallocate Response Mode

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_simple(2)

text:
# nvme_set_features_simple(2)

## NAME
nvme_set_features_simple - Helper function for @nvme_set_features()

## SYNOPSIS
int nvme_set_features_simple (int fd , __u8 fid , __u32 nsid , __u32 cdw11 , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

fid

Feature identifier

nsid

Namespace ID, if applicable

cdw11

Value to set the feature to

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_sw_progress(2)

text:
# nvme_set_features_sw_progress(2)

## NAME
nvme_set_features_sw_progress - Set pre-boot software load count feature

## SYNOPSIS
int nvme_set_features_sw_progress (int fd , __u8 pbslc , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

pbslc

Pre-boot Software Load Count

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_temp_thresh(2)

summary: Set temperature threshold feature

text:
# nvme_set_features_temp_thresh(2)

## NAME
nvme_set_features_temp_thresh - Set temperature threshold feature

## SYNOPSIS
int nvme_set_features_temp_thresh (int fd , __u16 tmpth , __u8 tmpsel , enum nvme_feat_tmpthresh_thsel thsel , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

tmpth

Temperature Threshold

tmpsel

Threshold Temperature Select

thsel

Threshold Type Select

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_timestamp(2)

summary: Set timestamp feature

text:
# nvme_set_features_timestamp(2)

## NAME
nvme_set_features_timestamp - Set timestamp feature

## SYNOPSIS
int nvme_set_features_timestamp (int fd , bool save , __u64 timestamp );

## ARGUMENTS
fd

File descriptor of nvme device

save

Save value across power states

timestamp

The current timestamp value to assign to this feature

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_volatile_wc(2)

summary: Set volatile write cache feature

text:
# nvme_set_features_volatile_wc(2)

## NAME
nvme_set_features_volatile_wc - Set volatile write cache feature

## SYNOPSIS
int nvme_set_features_volatile_wc (int fd , bool wce , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

wce

Write cache enable

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_write_atomic(2)

summary: Set write atomic feature

text:
# nvme_set_features_write_atomic(2)

## NAME
nvme_set_features_write_atomic - Set write atomic feature

## SYNOPSIS
int nvme_set_features_write_atomic (int fd , bool dn , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

dn

Disable Normal

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_features_write_protect(2)

summary: Set write protect feature

text:
# nvme_set_features_write_protect(2)

## NAME
nvme_set_features_write_protect - Set write protect feature

## SYNOPSIS
int nvme_set_features_write_protect (int fd , enum nvme_feat_nswpcfg_state state , bool save , __u32 *result );

## ARGUMENTS
fd

File descriptor of nvme device

state

Write Protection State

save

Save value across power states

result

The command completion result from CQE dword0

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_set_keyring(2)

summary: Link keyring for lookup

text:
# nvme_set_keyring(2)

## NAME
nvme_set_keyring - Link keyring for lookup

## SYNOPSIS
int nvme_set_keyring (long keyring_id );

## ARGUMENTS
keyring_id

Keyring id

## DESCRIPTION
Links keyring_id into the session keyring such that its keys are available for further key lookups.

## RETURN
0 on success, a negative number on error with errno set.


title: nvme_set_property(2)

summary: Set controller property

text:
# nvme_set_property(2)

## NAME
nvme_set_property - Set controller property

## SYNOPSIS
int nvme_set_property (struct nvme_set_property_args *args );

## ARGUMENTS
args

struct nvme_set_property_args argument structure

## DESCRIPTION
This is an NVMe-over-Fabrics specific command, not applicable to PCIe. These properties align to the PCI MMIO controller registers.

## RETURN
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.


title: nvme_smart_crit(2)

summary: Critical Warning

text:
# nvme_smart_crit(2)

## NAME
enum nvme_smart_crit - Critical Warning

## SYNOPSIS
enum nvme_smart_crit {

NVME_SMART_CRIT_SPARE ,

NVME_SMART_CRIT_TEMPERATURE ,

NVME_SMART_CRIT_DEGRADED ,

NVME_SMART_CRIT_MEDIA ,

NVME_SMART_CRIT_VOLATILE_MEMORY ,

NVME_SMART_CRIT_PMR_RO

};

## Constants
NVME_SMART_CRIT_SPARE

If set, then the available spare capacity has fallen below the threshold.

NVME_SMART_CRIT_TEMPERATURE

If set, then a temperature is either greater than or equal to an over temperature threshold; or less than or equal to an under temperature threshold.

NVME_SMART_CRIT_DEGRADED

If set, then the NVM subsystem reliability has been degraded due to significant media related errors or any internal error that degrades NVM subsystem reliability.

NVME_SMART_CRIT_MEDIA

If set, then all of the media has been placed in read only mode. The controller shall not set this bit if the read-only condition on the media is a result of a change in the write protection state of a namespace.

NVME_SMART_CRIT_VOLATILE_MEMORY

If set, then the volatile memory backup device has failed. This field is only valid if the controller has a volatile memory backup solution.

NVME_SMART_CRIT_PMR_RO

If set, then the Persistent Memory Region has become read-only or unreliable.


title: nvme_smart_egcw(2)

text:
# nvme_smart_egcw(2)

## NAME
enum nvme_smart_egcw - Endurance Group Critical Warning Summary

## SYNOPSIS
enum nvme_smart_egcw {

NVME_SMART_EGCW_SPARE ,

NVME_SMART_EGCW_DEGRADED ,

NVME_SMART_EGCW_RO

};

## Constants
NVME_SMART_EGCW_SPARE

If set, then the available spare capacity of one or more Endurance Groups has fallen below the threshold.

NVME_SMART_EGCW_DEGRADED

If set, then the reliability of one or more Endurance Groups has been degraded due to significant media related errors or any internal error that degrades NVM subsystem reliability.

NVME_SMART_EGCW_RO

If set, then the namespaces in one or more Endurance Groups have been placed in read only mode not as a result of a change in the write protection state of a namespace.