From: Keith Busch Date: Thu, 13 Feb 2020 21:00:03 +0000 (-0800) Subject: Add man pages for exports X-Git-Tag: v1.0-rc0~171 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=e4ac4459ae98e7bee9f5292c7d96eb0528838092;p=users%2Fsagi%2Flibnvme.git Add man pages for exports Generate man-pages from existing source. This will likely change soon as the types (struct and enum) should probably be grouped in the same manual as the primary function that uses it rather than have their own, and similiar functions can in turn be grouped in the same manual as well. Signed-off-by: Keith Busch --- diff --git a/doc/libnvme.rst b/doc/libnvme.rst index 39c23592..7a18d40a 100644 --- a/doc/libnvme.rst +++ b/doc/libnvme.rst @@ -1,692 +1,737 @@ -**NVMe Admin command enums** +.. c:type:: struct nvme_fabrics_config -.. c:type:: enum nvme_admin_opcode +**Definition** - Known NVMe admin opcodes +:: -**Constants** + struct nvme_fabrics_config { + const char *transport; + const char *traddr; + const char *trsvcid; + const char *nqn; + const char *hostnqn; + const char *host_traddr; + const char *hostid; + int queue_size; + int nr_io_queues; + int reconnect_delay; + int ctrl_loss_tmo; + int keep_alive_tmo; + int nr_write_queues; + int nr_poll_queues; + int tos; + bool duplicate_connect; + bool disable_sqflow; + bool hdr_digest; + bool data_digest; + uint8_t rsvd[0x200]; + }; -``nvme_admin_delete_sq`` - *undescribed* +**Members** -``nvme_admin_create_sq`` - *undescribed* -``nvme_admin_get_log_page`` - *undescribed* -``nvme_admin_delete_cq`` - *undescribed* +.. c:function:: int nvmf_add_ctrl_opts (struct nvme_fabrics_config * cfg) -``nvme_admin_create_cq`` - *undescribed* -``nvme_admin_identify`` - *undescribed* +**Parameters** -``nvme_admin_abort_cmd`` +``struct nvme_fabrics_config * cfg`` *undescribed* -``nvme_admin_set_features`` - *undescribed* -``nvme_admin_get_features`` - *undescribed* +.. c:function:: nvme_ctrl_t nvmf_add_ctrl (struct nvme_fabrics_config * cfg) -``nvme_admin_async_event`` - *undescribed* -``nvme_admin_ns_mgmt`` - *undescribed* +**Parameters** -``nvme_admin_fw_commit`` +``struct nvme_fabrics_config * cfg`` *undescribed* -``nvme_admin_fw_download`` - *undescribed* -``nvme_admin_dev_self_test`` - *undescribed* +.. c:function:: int nvmf_get_discovery_log (nvme_ctrl_t c, struct nvmf_discovery_log ** logp, int max_retries) -``nvme_admin_ns_attach`` - *undescribed* -``nvme_admin_keep_alive`` - *undescribed* +**Parameters** -``nvme_admin_directive_send`` +``nvme_ctrl_t c`` *undescribed* -``nvme_admin_directive_recv`` +``struct nvmf_discovery_log ** logp`` *undescribed* -``nvme_admin_virtual_mgmt`` +``int max_retries`` *undescribed* -``nvme_admin_nvme_mi_send`` - *undescribed* -``nvme_admin_nvme_mi_recv`` - *undescribed* +.. c:function:: char * nvmf_hostnqn_generate () -``nvme_admin_dbbuf`` - *undescribed* -``nvme_admin_fabrics`` - *undescribed* +**Parameters** -``nvme_admin_format_nvm`` - *undescribed* -``nvme_admin_security_send`` - *undescribed* +.. c:function:: char * nvmf_hostnqn_from_file () -``nvme_admin_security_recv`` - *undescribed* -``nvme_admin_sanitize_nvm`` - *undescribed* +**Parameters** -``nvme_admin_get_lba_status`` - *undescribed* +.. c:function:: char * nvmf_hostid_from_file () +**Parameters** -.. c:type:: enum nvme_identify_cns +.. c:function:: const char * nvmf_trtype_str (__u8 trtype) -**Constants** -``NVME_IDENTIFY_CNS_NS`` - *undescribed* +**Parameters** -``NVME_IDENTIFY_CNS_CTRL`` +``__u8 trtype`` *undescribed* -``NVME_IDENTIFY_CNS_NS_ACTIVE_LIST`` - *undescribed* -``NVME_IDENTIFY_CNS_NS_DESC_LIST`` - *undescribed* +.. c:function:: const char * nvmf_adrfam_str (__u8 adrfam) -``NVME_IDENTIFY_CNS_NVMSET_LIST`` - *undescribed* -``NVME_IDENTIFY_CNS_ALLOCATED_NS_LIST`` - *undescribed* +**Parameters** -``NVME_IDENTIFY_CNS_ALLOCATED_NS`` +``__u8 adrfam`` *undescribed* -``NVME_IDENTIFY_CNS_NS_CTRL_LIST`` - *undescribed* -``NVME_IDENTIFY_CNS_CTRL_LIST`` - *undescribed* +.. c:function:: const char * nvmf_subtype_str (__u8 subtype) -``NVME_IDENTIFY_CNS_PRIMARY_CTRL_CAP`` - *undescribed* -``NVME_IDENTIFY_CNS_SECONDARY_CTRL_LIST`` - *undescribed* +**Parameters** -``NVME_IDENTIFY_CNS_NS_GRANULARITY`` +``__u8 subtype`` *undescribed* -``NVME_IDENTIFY_CNS_UUID_LIST`` - *undescribed* +.. c:function:: const char * nvmf_treq_str (__u8 treq) +**Parameters** -.. c:type:: enum nvme_cmd_get_log_lid +``__u8 treq`` + *undescribed* -**Constants** +.. c:function:: const char * nvmf_sectype_str (__u8 sectype) -``NVME_LOG_LID_ERROR`` - *undescribed* -``NVME_LOG_LID_SMART`` - *undescribed* +**Parameters** -``NVME_LOG_LID_FW_SLOT`` +``__u8 sectype`` *undescribed* -``NVME_LOG_LID_CHANGED_NS`` - *undescribed* -``NVME_LOG_LID_CMD_EFFECTS`` - *undescribed* +.. c:function:: const char * nvmf_prtype_str (__u8 prtype) -``NVME_LOG_LID_DEVICE_SELF_TEST`` - *undescribed* -``NVME_LOG_LID_TELEMETRY_HOST`` - *undescribed* +**Parameters** -``NVME_LOG_LID_TELEMETRY_CTRL`` +``__u8 prtype`` *undescribed* -``NVME_LOG_LID_ENDURANCE_GROUP`` - *undescribed* -``NVME_LOG_LID_PREDICTABLE_LAT_NVMSET`` - *undescribed* +.. c:function:: const char * nvmf_qptype_str (__u8 qptype) -``NVME_LOG_LID_PREDICTABLE_LAT_AGG`` - *undescribed* -``NVME_LOG_LID_ANA`` - *undescribed* +**Parameters** -``NVME_LOG_LID_PERSISTENT_EVENT`` +``__u8 qptype`` *undescribed* -``NVME_LOG_LID_LBA_STATUS`` - *undescribed* -``NVME_LOG_LID_ENDURANCE_GRP_EVT`` - *undescribed* +.. c:function:: const char * nvmf_cms_str (__u8 cm) -``NVME_LOG_LID_DISCOVER`` - *undescribed* -``NVME_LOG_LID_RESERVATION`` - *undescribed* +**Parameters** -``NVME_LOG_LID_SANITIZE`` +``__u8 cm`` *undescribed* +.. c:function:: nvme_ctrl_t nvmf_connect_disc_entry (struct nvmf_disc_log_entry * e, const struct nvme_fabrics_config * defcfg, bool * discover) -.. c:type:: enum nvme_features_id - - -**Constants** +**Parameters** -``NVME_FEAT_FID_ARBITRATION`` +``struct nvmf_disc_log_entry * e`` *undescribed* -``NVME_FEAT_FID_POWER_MGMT`` +``const struct nvme_fabrics_config * defcfg`` *undescribed* -``NVME_FEAT_FID_LBA_RANGE`` +``bool * discover`` *undescribed* -``NVME_FEAT_FID_TEMP_THRESH`` - *undescribed* -``NVME_FEAT_FID_ERR_RECOVERY`` - *undescribed* +.. c:function:: int nvme_namespace_filter (const struct dirent * d) -``NVME_FEAT_FID_VOLATILE_WC`` - *undescribed* -``NVME_FEAT_FID_NUM_QUEUES`` - *undescribed* +**Parameters** -``NVME_FEAT_FID_IRQ_COALESCE`` - *undescribed* +``const struct dirent * d`` -``NVME_FEAT_FID_IRQ_CONFIG`` - *undescribed* -``NVME_FEAT_FID_WRITE_ATOMIC`` - *undescribed* +.. c:function:: int nvme_paths_filter (const struct dirent * d) -``NVME_FEAT_FID_ASYNC_EVENT`` - *undescribed* -``NVME_FEAT_FID_AUTO_PST`` - *undescribed* +**Parameters** -``NVME_FEAT_FID_HOST_MEM_BUF`` - *undescribed* +``const struct dirent * d`` -``NVME_FEAT_FID_TIMESTAMP`` - *undescribed* -``NVME_FEAT_FID_KATO`` - *undescribed* +.. c:function:: int nvme_ctrls_filter (const struct dirent * d) -``NVME_FEAT_FID_HCTM`` - *undescribed* -``NVME_FEAT_FID_NOPSC`` - *undescribed* +**Parameters** -``NVME_FEAT_FID_RRL`` - *undescribed* +``const struct dirent * d`` -``NVME_FEAT_FID_PLM_CONFIG`` - *undescribed* -``NVME_FEAT_FID_PLM_WINDOW`` - *undescribed* +.. c:function:: int nvme_subsys_filter (const struct dirent * d) -``NVME_FEAT_FID_LBA_STS_INTERVAL`` - *undescribed* -``NVME_FEAT_FID_HOST_BEHAVIOR`` - *undescribed* +**Parameters** -``NVME_FEAT_FID_SANITIZE`` - *undescribed* +``const struct dirent * d`` -``NVME_FEAT_FID_ENDURANCE_EVT_CFG`` - *undescribed* -``NVME_FEAT_FID_SW_PROGRESS`` - *undescribed* +.. c:function:: int nvme_scan_subsystems (struct dirent *** subsys) -``NVME_FEAT_FID_HOST_ID`` - *undescribed* -``NVME_FEAT_FID_RESV_MASK`` - *undescribed* +**Parameters** -``NVME_FEAT_RESV_PERSIST`` - *undescribed* - -``NVME_FEAT_FID_WRITE_PROTECT`` - *undescribed* +``struct dirent *** subsys`` +.. c:function:: int nvme_scan_subsystem_ctrls (nvme_subsystem_t s, struct dirent *** ctrls) -.. c:type:: enum nvme_get_features_sel +**Parameters** +``nvme_subsystem_t s`` + *undescribed* -**Constants** +``struct dirent *** ctrls`` -``NVME_GET_FEATURES_SEL_CURRENT`` - *undescribed* -``NVME_GET_FEATURES_SEL_DEFAULT`` - *undescribed* +.. c:function:: int nvme_scan_subsystem_namespaces (nvme_subsystem_t s, struct dirent *** namespaces) -``NVME_GET_FEATURES_SEL_SAVED`` - *undescribed* +**Parameters** +``nvme_subsystem_t s`` + *undescribed* +``struct dirent *** namespaces`` -.. c:type:: enum nvme_cmd_format_mset +.. c:function:: int nvme_scan_ctrl_namespace_paths (nvme_ctrl_t c, struct dirent *** namespaces) -**Constants** -``NVME_FORMAT_MSET_SEPARATE`` - *undescribed* +**Parameters** -``NVME_FORMAT_MSET_EXTENEDED`` +``nvme_ctrl_t c`` *undescribed* +``struct dirent *** namespaces`` - -.. c:type:: enum nvme_cmd_format_pi +.. c:function:: int nvme_scan_ctrl_namespaces (nvme_ctrl_t c, struct dirent *** namespaces) -**Constants** +**Parameters** -``NVME_FORMAT_PI_DISABLE`` +``nvme_ctrl_t c`` *undescribed* -``NVME_FORMAT_PI_TYPE1`` - *undescribed* +``struct dirent *** namespaces`` -``NVME_FORMAT_PI_TYPE2`` - *undescribed* -``NVME_FORMAT_PI_TYPE3`` - *undescribed* +.. c:type:: struct nvme_passthru_cmd -.. c:type:: enum nvme_cmd_format_ses +**Definition** +:: -**Constants** + 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; + }; -``NVME_FORMAT_SES_NONE`` - *undescribed* +**Members** -``NVME_FORMAT_SES_USER_DATA_ERASE`` - *undescribed* +``opcode`` + Operation code, see :c:type:`enum nvme_io_opcodes ` and :c:type:`enum nvme_admin_opcodes ` -``NVME_FORMAT_SES_CRYPTO_ERASE`` - *undescribed* +``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) -.. c:type:: enum nvme_ns_mgmt_sel +``cdw3`` + Command Dword 3 (no spec defined use) +``metadata`` + User space address to metadata buffer (NULL if not used) -**Constants** +``addr`` + User space address to data buffer (NULL if not used) -``NVME_NS_MGMT_SEL_CREATE`` - *undescribed* +``metadata_len`` + Metadata buffer transfer length -``NVME_NS_MGMT_SEL_DELETE`` - *undescribed* +``data_len`` + Data buffer transfer length +``cdw10`` + Command Dword 10 (command specific) +``cdw11`` + Command Dword 11 (command specific) +``cdw12`` + Command Dword 12 (command specific) -.. c:type:: enum nvme_ns_attach_sel +``cdw13`` + Command Dword 13 (command specific) - NVME_NS_ATTACH_SEL_CTRL_ATTACH: NVME_NP_ATTACH_SEL_CTRL_DEATTACH: +``cdw14`` + Command Dword 14 (command specific) -**Constants** +``cdw15`` + Command Dword 15 (command specific) -``NVME_NS_ATTACH_SEL_CTRL_ATTACH`` - *undescribed* +``timeout_ms`` + If non-zero, overrides system default timeout in milliseconds -``NVME_NS_ATTACH_SEL_CTRL_DEATTACH`` - *undescribed* +``result`` + Set on completion to the command's CQE DWORD 0 controller response -.. c:type:: enum nvme_fw_commit_ca +.. c:type:: struct nvme_passthru_cmd64 -**Constants** -``NVME_FW_COMMIT_CA_REPLACE`` - *undescribed* +**Definition** -``NVME_FW_COMMIT_CA_REPLACE_AND_ACTIVATE`` - *undescribed* +:: -``NVME_FW_COMMIT_CA_SET_ACTIVE`` - *undescribed* + 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; + }; -``NVME_FW_COMMIT_CA_REPLACE_AND_ACTIVATE_IMMEDIATE`` - *undescribed* +**Members** -``NVME_FW_COMMIT_CA_REPLACE_BOOT_PARTITION`` - *undescribed* +``opcode`` + Operation code, see :c:type:`enum nvme_io_opcodes ` and :c:type:`enum nvme_admin_opcodes ` -``NVME_FW_COMMIT_CA_ACTIVATE_BOOT_PARTITION`` - *undescribed* +``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) -.. c:type:: enum nvme_directive_dtype +``cdw3`` + Command Dword 3 (no spec defined use) +``metadata`` + User space address to metadata buffer (NULL if not used) -**Constants** +``addr`` + User space address to data buffer (NULL if not used) -``NVME_DIRECTIVE_DTYPE_IDENTIFY`` - *undescribed* +``metadata_len`` + Metadata buffer transfer length -``NVME_DIRECTIVE_DTYPE_STREAMS`` - *undescribed* +``data_len`` + Data buffer transfer length +``cdw10`` + Command Dword 10 (command specific) +``cdw11`` + Command Dword 11 (command specific) +``cdw12`` + Command Dword 12 (command specific) -.. c:type:: enum nvme_cmd_directive_receive_identify_doper +``cdw13`` + Command Dword 13 (command specific) +``cdw14`` + Command Dword 14 (command specific) -**Constants** +``cdw15`` + Command Dword 15 (command specific) -``NVME_DIRECTIVE_RECEIVE_IDENTIFY_DOPER_PARAM`` - *undescribed* +``timeout_ms`` + If non-zero, overrides system default timeout in milliseconds +``rsvd2`` + Reserved for future use (and fills an impicit struct pad +``result`` + Set on completion to the command's CQE DWORD 0-1 controller response -.. c:type:: enum nvme_cmd_directive_receive_streams_doper +.. c:function:: int nvme_submit_admin_passthru64 (int fd, struct nvme_passthru_cmd64 * cmd, __u64 * result) -**Constants** + Submit a 64-bit nvme passthrough admin command -``NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_PARAM`` - *undescribed* +**Parameters** -``NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_STATUS`` - *undescribed* +``int fd`` + File descriptor of nvme device -``NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_RESOURCE`` - *undescribed* +``struct nvme_passthru_cmd64 * cmd`` + The nvme admin command to send +``__u64 * result`` + Optional field to return the result from the CQE DW0-1 +**Description** +Uses NVME_IOCTL_ADMIN64_CMD for the ioctl request. -.. c:type:: enum nvme_cmd_directive_send_identify_doper +**Return** +The nvme command status if a response was received or -1 + with errno set otherwise. -**Constants** -``NVME_DIRECTIVE_SEND_IDENTIFY_DOPER_ENDIR`` - *undescribed* +.. c:function:: int nvme_admin_passthru64 (int fd, __u8 opcode, __u8 flags, __u16 rsvd, __u32 nsid, __u32 cdw2, __u32 cdw3, __u32 cdw10, __u32 cdw11, __u32 cdw12, __u32 cdw13, __u32 cdw14, __u32 cdw15, __u32 data_len, void * data, __u32 metadata_len, void * metadata, __u32 timeout_ms, __u64 * result) + Submit an nvme passthrough command +**Parameters** +``int fd`` + File descriptor of nvme device -.. c:type:: enum nvme_cmd_directive_send_identify_endir +``__u8 opcode`` + The nvme io command to send +``__u8 flags`` + NVMe command flags (not used) -**Constants** +``__u16 rsvd`` + Reserevd for future use -``NVME_DIRECTIVE_SEND_IDENTIFY_ENDIR_DISABLE`` - *undescribed* - -``NVME_DIRECTIVE_SEND_IDENTIFY_ENDIR_ENABLE`` - *undescribed* - - - - -.. c:type:: enum nvme_cmd_directive_send_streams_doper +``__u32 nsid`` + Namespace identifier +``__u32 cdw2`` + Command dword 2 -**Constants** +``__u32 cdw3`` + Command dword 3 -``NVME_DIRECTIVE_SEND_STREAMS_DOPER_RELEASE_IDENTIFIER`` - *undescribed* +``__u32 cdw10`` + Command dword 10 -``NVME_DIRECTIVE_SEND_STREAMS_DOPER_RELEASE_RESOURCE`` - *undescribed* +``__u32 cdw11`` + Command dword 11 +``__u32 cdw12`` + Command dword 12 +``__u32 cdw13`` + Command dword 13 +``__u32 cdw14`` + Command dword 14 -.. c:type:: enum nvme_sanitize_sanact +``__u32 cdw15`` + Command dword 15 +``__u32 data_len`` + Length of the data transfered in this command in bytes -**Constants** +``void * data`` + Pointer to user address of the data buffer -``NVME_SANITIZE_SANACT_EXIT_FAILURE`` - *undescribed* +``__u32 metadata_len`` + Length of metadata transfered in this command -``NVME_SANITIZE_SANACT_START_BLOCK_ERASE`` - *undescribed* +``void * metadata`` + Pointer to user address of the metadata buffer -``NVME_SANITIZE_SANACT_START_OVERWRITE`` - *undescribed* +``__u32 timeout_ms`` + How long the kernel waits for the command to complete -``NVME_SANITIZE_SANACT_START_CRYPTO_ERASE`` - *undescribed* +``__u64 * result`` + Optional field to return the result from the CQE dword 0 +**Description** +Parameterized form of nvme_submit_admin_passthru64(). This sets up and +submits a :c:type:`struct nvme_passthru_cmd64 `. +Known values for **opcode** are defined in :c:type:`enum nvme_admin_opcode `. -.. c:type:: enum nvme_dst_stc +**Return** +The nvme command status if a response was received or -1 + with errno set otherwise. -**Constants** -``NVME_DST_STC_SHORT`` - *undescribed* +.. c:function:: int nvme_submit_admin_passthru (int fd, struct nvme_passthru_cmd * cmd, __u32 * result) -``NVME_DST_STC_LONG`` - *undescribed* + Submit an nvme passthrough admin command -``NVME_DST_STC_VS`` - *undescribed* +**Parameters** -``NVME_DST_STC_ABORT`` - *undescribed* +``int fd`` + File descriptor of nvme device +``struct nvme_passthru_cmd * cmd`` + The nvme admin command to send +``__u32 * result`` + Optional field to return the result from the CQE DW0 +**Description** -.. c:type:: enum nvme_virt_mgmt_act +Uses NVME_IOCTL_ADMIN_CMD for the ioctl request. +**Return** -**Constants** +The nvme command status if a response was received or -1 + with errno set otherwise. -``NVME_VIRT_MGMT_ACT_PRIM_CTRL_FLEX_ALLOC`` - *undescribed* -``NVME_VIRT_MGMT_ACT_OFFLINE_SEC_CTRL`` - *undescribed* +.. c:function:: int nvme_admin_passthru (int fd, __u8 opcode, __u8 flags, __u16 rsvd, __u32 nsid, __u32 cdw2, __u32 cdw3, __u32 cdw10, __u32 cdw11, __u32 cdw12, __u32 cdw13, __u32 cdw14, __u32 cdw15, __u32 data_len, void * data, __u32 metadata_len, void * metadata, __u32 timeout_ms, __u32 * result) -``NVME_VIRT_MGMT_ACT_ASSIGN_SEC_CTRL`` - *undescribed* + Submit an nvme passthrough command -``NVME_VIRT_MGMT_ACT_ONLINE_SEC_CTRL`` - *undescribed* +**Parameters** +``int fd`` + File descriptor of nvme device +``__u8 opcode`` + The nvme io command to send +``__u8 flags`` + NVMe command flags (not used) -.. c:type:: enum nvme_virt_mgmt_rt +``__u16 rsvd`` + Reserevd for future use +``__u32 nsid`` + Namespace identifier -**Constants** +``__u32 cdw2`` + Command dword 2 -``NVME_VIRT_MGMT_RT_VQ_RESOURCE`` - *undescribed* +``__u32 cdw3`` + Command dword 3 -``NVME_VIRT_MGMT_RT_VI_RESOURCE`` - *undescribed* +``__u32 cdw10`` + Command dword 10 +``__u32 cdw11`` + Command dword 11 -.. c:function:: int nvme_identify (int fd, enum nvme_identify_cns cns, __u32 nsid, __u16 cntid, __u16 nvmsetid, __u8 uuidx, void * data) +``__u32 cdw12`` + Command dword 12 - Send the NVMe Identify command +``__u32 cdw13`` + Command dword 13 -**Parameters** +``__u32 cdw14`` + Command dword 14 -``int fd`` - File descriptor of nvme device +``__u32 cdw15`` + Command dword 15 -``enum nvme_identify_cns cns`` - The Controller or Namespace structure, see **enum** nvme_identify_cns +``__u32 data_len`` + Length of the data transfered in this command in bytes -``__u32 nsid`` - Namespace identifier, if applicable +``void * data`` + Pointer to user address of the data buffer -``__u16 cntid`` - The Controller Identifier, if applicable +``__u32 metadata_len`` + Length of metadata transfered in this command -``__u16 nvmsetid`` - The NVMe Set ID if CNS is 04h +``void * metadata`` + Pointer to user address of the metadata buffer -``__u8 uuidx`` - UUID Index if controller supports this id selection method +``__u32 timeout_ms`` + How long the kernel waits for the command to complete -``void * data`` - User space destination address to transfer the data +``__u32 * result`` + Optional field to return the result from the CQE dword 0 **Description** -The Identify command returns a data buffer that describes information about -the NVM subsystem, the controller or the namespace(s). +Parameterized form of nvme_submit_admin_passthru(). This sets up and +submits a :c:type:`struct nvme_passthru_cmd `. + +Known values for **opcode** are defined in :c:type:`enum nvme_admin_opcode `. **Return** -The nvme command status if a response was received or -1 with errno - set otherwise. +The nvme command status if a response was received or -1 + with errno set otherwise. -.. c:function:: int nvme_identify_ctrl (int fd, struct nvme_id_ctrl * id) +.. c:function:: int nvme_submit_io_passthru64 (int fd, struct nvme_passthru_cmd64 * cmd, __u64 * result) - Retrieves nvme identify controller + Submit a 64-bit nvme passthrough command **Parameters** ``int fd`` File descriptor of nvme device - id: User space destination address to transfer the data, -``struct nvme_id_ctrl * id`` - *undescribed* +``struct nvme_passthru_cmd64 * cmd`` + The nvme io command to send -**Description** +``__u64 * result`` + Optional field to return the result from the CQE DW0-1 -Sends nvme identify with CNS value ``NVME_IDENTIFY_CNS_CTRL``. +**Description** -See :c:type:`struct nvme_id_ctrl ` for details on the data returned. +Uses NVME_IOCTL_IO64_CMD for the ioctl request. **Return** -The nvme command status if a response was received or -1 with errno - set otherwise. +The nvme command status if a response was received or -1 + with errno set otherwise. -.. c:function:: int nvme_identify_ns (int fd, __u32 nsid, struct nvme_id_ns * ns) +.. c:function:: int nvme_io_passthru64 (int fd, __u8 opcode, __u8 flags, __u16 rsvd, __u32 nsid, __u32 cdw2, __u32 cdw3, __u32 cdw10, __u32 cdw11, __u32 cdw12, __u32 cdw13, __u32 cdw14, __u32 cdw15, __u32 data_len, void * data, __u32 metadata_len, void * metadata, __u32 timeout_ms, __u64 * result) - Retrieves nvme identify namespace + Submit an nvme io passthrough command **Parameters** ``int fd`` File descriptor of nvme device +``__u8 opcode`` + The nvme io command to send + +``__u8 flags`` + NVMe command flags (not used) + +``__u16 rsvd`` + Reserevd for future use + ``__u32 nsid`` - Namespace to identify + Namespace identifier -``struct nvme_id_ns * ns`` - User space destination address to transfer the data +``__u32 cdw2`` + Command dword 2 -**Description** +``__u32 cdw3`` + Command dword 3 -If the Namespace Identifier (NSID) field specifies an active NSID, then the -Identify Namespace data structure is returned to the host for that specified -namespace. +``__u32 cdw10`` + Command dword 10 -If the controller supports the Namespace Management capability and the NSID -field is set to ``NVME_NSID_ALL``, then the controller returns an Identify Namespace -data structure that specifies capabilities that are common across namespaces -for this controller. +``__u32 cdw11`` + Command dword 11 -See :c:type:`struct nvme_id_ns ` for details on the structure returned. +``__u32 cdw12`` + Command dword 12 -**Return** +``__u32 cdw13`` + Command dword 13 -The nvme command status if a response was received or -1 with errno - set otherwise. +``__u32 cdw14`` + Command dword 14 +``__u32 cdw15`` + Command dword 15 -.. c:function:: int nvme_identify_allocated_ns (int fd, __u32 nsid, struct nvme_id_ns * ns) +``__u32 data_len`` + Length of the data transfered in this command in bytes - Same as nvme_identify_ns, but only for allocated namespaces +``void * data`` + Pointer to user address of the data buffer -**Parameters** +``__u32 metadata_len`` + Length of metadata transfered in this command -``int fd`` - File descriptor of nvme device +``void * metadata`` + Pointer to user address of the metadata buffer -``__u32 nsid`` - Namespace to identify +``__u32 timeout_ms`` + How long the kernel waits for the command to complete -``struct nvme_id_ns * ns`` - User space destination address to transfer the data +``__u64 * result`` + Optional field to return the result from the CQE dword 0 + +**Description** + +Parameterized form of nvme_submit_io_passthru64(). This sets up and submits +a :c:type:`struct nvme_passthru_cmd64 `. + +Known values for **opcode** are defined in :c:type:`enum nvme_io_opcode `. **Return** @@ -694,869 +739,774 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_identify_active_ns_list (int fd, __u32 nsid, struct nvme_ns_list * list) +.. c:function:: int nvme_submit_io_passthru (int fd, struct nvme_passthru_cmd * cmd, __u32 * result) - Retrieves active namespaces id list + Submit an nvme passthrough command **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Return namespaces greater than this identifer +``struct nvme_passthru_cmd * cmd`` + The nvme io command to send -``struct nvme_ns_list * list`` - *undescribed* +``__u32 * result`` + Optional field to return the result from the CQE DW0 **Description** -A list of 1024 namespace IDs is returned to the host containing NSIDs in -increasing order that are greater than the value specified in the Namespace -Identifier (nsid) field of the command. - -See :c:type:`struct nvme_ns_list ` for the definition of the returned structure. +Uses NVME_IOCTL_IO_CMD for the ioctl request. **Return** -The nvme command status if a response was received or -1 with errno - set otherwise. +The nvme command status if a response was received or -1 + with errno set otherwise. -.. c:function:: int nvme_identify_allocated_ns_list (int fd, __u32 nsid, struct nvme_ns_list * list) +.. c:function:: int nvme_io_passthru (int fd, __u8 opcode, __u8 flags, __u16 rsvd, __u32 nsid, __u32 cdw2, __u32 cdw3, __u32 cdw10, __u32 cdw11, __u32 cdw12, __u32 cdw13, __u32 cdw14, __u32 cdw15, __u32 data_len, void * data, __u32 metadata_len, void * metadata, __u32 timeout_ms, __u32 * result) - Retrieves allocated namespace id list + Submit an nvme io passthrough command **Parameters** ``int fd`` File descriptor of nvme device +``__u8 opcode`` + The nvme io command to send + +``__u8 flags`` + NVMe command flags (not used) + +``__u16 rsvd`` + Reserevd for future use + ``__u32 nsid`` - Return namespaces greater than this identifer + Namespace identifier -``struct nvme_ns_list * list`` - *undescribed* +``__u32 cdw2`` + Command dword 2 -**Description** +``__u32 cdw3`` + Command dword 3 -A list of 1024 namespace IDs is returned to the host containing NSIDs in -increasing order that are greater than the value specified in the Namespace -Identifier (nsid) field of the command. +``__u32 cdw10`` + Command dword 10 -See :c:type:`struct nvme_ns_list ` for the definition of the returned structure. +``__u32 cdw11`` + Command dword 11 -**Return** +``__u32 cdw12`` + Command dword 12 -The nvme command status if a response was received or -1 with errno - set otherwise. +``__u32 cdw13`` + Command dword 13 +``__u32 cdw14`` + Command dword 14 -.. c:function:: int nvme_identify_ctrl_list (int fd, __u16 cntid, struct nvme_ctrl_list * ctrlist) +``__u32 cdw15`` + Command dword 15 - Retrieves identify controller list +``__u32 data_len`` + Length of the data transfered in this command in bytes -**Parameters** +``void * data`` + Pointer to user address of the data buffer -``int fd`` - File descriptor of nvme device +``__u32 metadata_len`` + Length of metadata transfered in this command -``__u16 cntid`` - *undescribed* +``void * metadata`` + Pointer to user address of the metadata buffer -``struct nvme_ctrl_list * ctrlist`` - *undescribed* +``__u32 timeout_ms`` + How long the kernel waits for the command to complete + +``__u32 * result`` + Optional field to return the result from the CQE dword 0 **Description** -Up to 2047 controller identifiers is returned containing a controller -identifier greater than or equal to the controller identifier specified in -**cntid**. +Parameterized form of nvme_submit_io_passthru(). This sets up and submits +a :c:type:`struct nvme_passthru_cmd `. -See :c:type:`struct nvme_ctrl_list ` for a definition of the structure returned. +Known values for **opcode** are defined in :c:type:`enum nvme_io_opcode `. **Return** -The nvme command status if a response was received or -1 with errno - set otherwise. +The nvme command status if a response was received or -1 + with errno set otherwise. -.. c:function:: int nvme_identify_nsid_ctrl_list (int fd, __u32 nsid, __u16 cntid, struct nvme_ctrl_list * ctrlist) +.. c:function:: int nvme_subsystem_reset (int fd) + Initiate a subsystem reset **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Return controllers that are attached to this nsid - -``__u16 cntid`` - *undescribed* - -``struct nvme_ctrl_list * ctrlist`` - *undescribed* - **Description** -Up to 2047 controller identifiers is returned containing a controller -identifier greater than or equal to the controller identifier specified in -**cntid**. - -See :c:type:`struct nvme_ctrl_list ` for a definition of the structure returned. +This should only be sent to controller handles, not to namespaces. **Return** -The nvme command status if a response was received or -1 +Zero if a subsystem reset was initiated or -1 with errno set + otherwise. -.. c:function:: int nvme_identify_ns_descs (int fd, __u32 nsid, struct nvme_ns_id_desc * descs) +.. c:function:: int nvme_ctrl_reset (int fd) - Retrieves namespace descriptor list + Initiate a controller reset **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - The namespace id to retrieve destriptors - -``struct nvme_ns_id_desc * descs`` - User space destination address to transfer the data - **Description** -A list of Namespace Identification Descriptor structures is returned to the -host for the namespace specified in the Namespace Identifier (NSID) field if -it is an active NSID. - -The data returned is in the form of an arrray of 'struct nvme_ns_id_desc'. - -See :c:type:`struct nvme_ns_id_desc ` for the definition of the returned structure. +This should only be sent to controller handles, not to namespaces. **Return** -The nvme command status if a response was received or -1 with errno - set otherwise. +Zero if a reset was initiated or -1 with errno set otherwise. -.. c:function:: int nvme_identify_nvmset_list (int fd, __u16 nvmsetid, struct nvme_id_nvmset_list * nvmset) +.. c:function:: int nvme_ns_rescan (int fd) - Retrieves NVM Set List + Initiate a controller rescan **Parameters** ``int fd`` File descriptor of nvme device -``__u16 nvmsetid`` - *undescribed* - -``struct nvme_id_nvmset_list * nvmset`` - User space destination address to transfer the data - **Description** -Retrieves an NVM Set List, struct nvme_id_nvmset. The data structure is an -ordered list by NVM Set Identifier, starting with the first NVM Set -Identifier supported by the NVM subsystem that is equal to or greater than -the NVM Set Identifier. - -See :c:type:`struct nvme_id_nvmset_list ` for the defintion of the returned structure. +This should only be sent to controller handles, not to namespaces. **Return** -The nvme command status if a response was received or -1 with errno - set otherwise. +Zero if a rescan was initiated or -1 with errno set otherwise. -.. c:function:: int nvme_identify_primary_ctrl (int fd, __u16 cntid, struct nvme_primary_ctrl_cap * cap) +.. c:function:: int nvme_get_nsid (int fd) - Retrieve NVMe Primary Controller identification :c:type:`fd`: + Retrieve the NSID from a namespace file descriptor **Parameters** ``int fd`` - *undescribed* - -``__u16 cntid`` - *undescribed* - -``struct nvme_primary_ctrl_cap * cap`` + File descriptor of nvme namespace **Description** -See :c:type:`struct nvme_primary_ctrl_cap ` for the defintion of the returned structure, **cap**. +This should only be sent to namespace handles, not to controllers. **Return** -The nvme command status if a response was received or -1 - with errno set otherwise. - - -.. c:function:: int nvme_identify_secondary_ctrl_list (int fd, __u16 cntid, struct nvme_secondary_ctrl_list * list) - - Retrieves secondary controller list +The namespace identifier if a succecssful or -1 with errno set + otherwise. -**Parameters** -``int fd`` - File descriptor of nvme device +**NVMe Admin command enums** -``__u16 cntid`` - Return controllers starting at this identifier -``struct nvme_secondary_ctrl_list * list`` - *undescribed* -**Description** -A Secondary Controller List is returned to the host for up to 127 secondary -controllers associated with the primary controller processing this command. -The list contains entries for controller identifiers greater than or equal -to the value specified in the Controller Identifier (cntid). +.. c:type:: enum nvme_admin_opcode -See :c:type:`struct nvme_secondary_ctrls_list ` for a defintion of the returned -structure. + Known NVMe admin opcodes -**Return** +**Constants** -The nvme command status if a response was received or -1 with errno - set otherwise. +``nvme_admin_delete_sq`` + *undescribed* +``nvme_admin_create_sq`` + *undescribed* -.. c:function:: int nvme_identify_ns_granularity (int fd, struct nvme_id_ns_granularity_list * list) +``nvme_admin_get_log_page`` + *undescribed* - Retrieves namespace granularity identification +``nvme_admin_delete_cq`` + *undescribed* -**Parameters** +``nvme_admin_create_cq`` + *undescribed* -``int fd`` - File descriptor of nvme device +``nvme_admin_identify`` + *undescribed* -``struct nvme_id_ns_granularity_list * list`` +``nvme_admin_abort_cmd`` *undescribed* -**Description** +``nvme_admin_set_features`` + *undescribed* -If the controller supports reporting of Namespace Granularity, then a -Namespace Granularity List is returned to the host for up to sixteen -namespace granularity descriptors +``nvme_admin_get_features`` + *undescribed* -See :c:type:`struct nvme_id_ns_granularity_list ` for the definition of the returned -structure. +``nvme_admin_async_event`` + *undescribed* -**Return** +``nvme_admin_ns_mgmt`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``nvme_admin_fw_commit`` + *undescribed* +``nvme_admin_fw_download`` + *undescribed* -.. c:function:: int nvme_identify_uuid (int fd, struct nvme_id_uuid_list * list) +``nvme_admin_dev_self_test`` + *undescribed* - Retrieves device's UUIDs +``nvme_admin_ns_attach`` + *undescribed* -**Parameters** +``nvme_admin_keep_alive`` + *undescribed* -``int fd`` - File descriptor of nvme device +``nvme_admin_directive_send`` + *undescribed* -``struct nvme_id_uuid_list * list`` +``nvme_admin_directive_recv`` *undescribed* -**Description** +``nvme_admin_virtual_mgmt`` + *undescribed* -Each UUID List entry is either 0h, the NVMe Invalid UUID, or a valid UUID. -Valid UUIDs are those which are non-zero and are not the NVMe Invalid UUID. +``nvme_admin_nvme_mi_send`` + *undescribed* -See :c:type:`struct nvme_id_uuid_list ` for the definition of the returned structure. +``nvme_admin_nvme_mi_recv`` + *undescribed* -**Return** +``nvme_admin_dbbuf`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``nvme_admin_fabrics`` + *undescribed* +``nvme_admin_format_nvm`` + *undescribed* -.. c:function:: int nvme_get_log (int fd, enum nvme_cmd_get_log_lid lid, __u32 nsid, __u64 lpo, __u8 lsp, __u16 lsi, bool rae, __u8 uuidx, __u32 len, void * log) +``nvme_admin_security_send`` + *undescribed* - NVMe Admin Get Log command +``nvme_admin_security_recv`` + *undescribed* -**Parameters** +``nvme_admin_sanitize_nvm`` + *undescribed* -``int fd`` - File descriptor of nvme device +``nvme_admin_get_lba_status`` + *undescribed* -``enum nvme_cmd_get_log_lid lid`` - Log page identifier, see :c:type:`enum nvme_cmd_get_log_lid ` for known values -``__u32 nsid`` - Namespace identifier, if applicable -``__u64 lpo`` - Log page offset for partial log transfers -``__u8 lsp`` - Log specific field +.. c:type:: enum nvme_identify_cns -``__u16 lsi`` - Endurance group information -``bool rae`` - Retain asynchronous events +**Constants** -``__u8 uuidx`` - UUID selection, if supported +``NVME_IDENTIFY_CNS_NS`` + *undescribed* -``__u32 len`` - Length of provided user buffer to hold the log data in bytes +``NVME_IDENTIFY_CNS_CTRL`` + *undescribed* -``void * log`` - User space destination address to transfer the data +``NVME_IDENTIFY_CNS_NS_ACTIVE_LIST`` + *undescribed* -**Return** +``NVME_IDENTIFY_CNS_NS_DESC_LIST`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_IDENTIFY_CNS_NVMSET_LIST`` + *undescribed* +``NVME_IDENTIFY_CNS_ALLOCATED_NS_LIST`` + *undescribed* -.. c:function:: int nvme_get_log_error (int fd, unsigned nr_entries, bool rae, struct nvme_error_log_page * log) +``NVME_IDENTIFY_CNS_ALLOCATED_NS`` + *undescribed* - Retrieve nvme error log +``NVME_IDENTIFY_CNS_NS_CTRL_LIST`` + *undescribed* -**Parameters** +``NVME_IDENTIFY_CNS_CTRL_LIST`` + *undescribed* -``int fd`` - File descriptor of nvme device +``NVME_IDENTIFY_CNS_PRIMARY_CTRL_CAP`` + *undescribed* -``unsigned nr_entries`` +``NVME_IDENTIFY_CNS_SECONDARY_CTRL_LIST`` *undescribed* -``bool rae`` - Retain asynchronous events +``NVME_IDENTIFY_CNS_NS_GRANULARITY`` + *undescribed* -``struct nvme_error_log_page * log`` +``NVME_IDENTIFY_CNS_UUID_LIST`` *undescribed* -**Description** -This log page is used to describe extended error information for a command -that completed with error, or may report an error that is not specific to a -particular command. -**Return** -The nvme command status if a response was received or -1 with errno - set otherwise. +.. c:type:: enum nvme_cmd_get_log_lid -.. c:function:: int nvme_get_log_smart (int fd, __u32 nsid, bool rae, struct nvme_smart_log * log) +**Constants** - Retrieve nvme smart log +``NVME_LOG_LID_ERROR`` + *undescribed* -**Parameters** +``NVME_LOG_LID_SMART`` + *undescribed* -``int fd`` - File descriptor of nvme device +``NVME_LOG_LID_FW_SLOT`` + *undescribed* -``__u32 nsid`` - Optional namespace identifier +``NVME_LOG_LID_CHANGED_NS`` + *undescribed* -``bool rae`` - Retain asynchronous events +``NVME_LOG_LID_CMD_EFFECTS`` + *undescribed* -``struct nvme_smart_log * log`` +``NVME_LOG_LID_DEVICE_SELF_TEST`` *undescribed* -**Description** +``NVME_LOG_LID_TELEMETRY_HOST`` + *undescribed* -This log page is used to provide SMART and general health information. The -information provided is over the life of the controller and is retained -across power cycles. To request the controller log page, the namespace -identifier specified is FFFFFFFFh. The controller may also support -requesting the log page on a per namespace basis, as indicated by bit 0 of -the LPA field in the Identify Controller data structure. +``NVME_LOG_LID_TELEMETRY_CTRL`` + *undescribed* -**Return** +``NVME_LOG_LID_ENDURANCE_GROUP`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_LOG_LID_PREDICTABLE_LAT_NVMSET`` + *undescribed* +``NVME_LOG_LID_PREDICTABLE_LAT_AGG`` + *undescribed* -.. c:function:: int nvme_get_log_fw_slot (int fd, bool rae, struct nvme_firmware_slot * log) +``NVME_LOG_LID_ANA`` + *undescribed* - Retrieves the controller firmware log +``NVME_LOG_LID_PERSISTENT_EVENT`` + *undescribed* -**Parameters** +``NVME_LOG_LID_LBA_STATUS`` + *undescribed* -``int fd`` - File descriptor of nvme device +``NVME_LOG_LID_ENDURANCE_GRP_EVT`` + *undescribed* -``bool rae`` - Retain asynchronous events +``NVME_LOG_LID_DISCOVER`` + *undescribed* -``struct nvme_firmware_slot * log`` +``NVME_LOG_LID_RESERVATION`` *undescribed* -**Description** +``NVME_LOG_LID_SANITIZE`` + *undescribed* -This log page is used to describe the firmware revision stored in each -firmware slot supported. The firmware revision is indicated as an ASCII -string. The log page also indicates the active slot number. -**Return** -The nvme command status if a response was received or -1 with errno - set otherwise. +.. c:type:: enum nvme_features_id -.. c:function:: int nvme_get_log_changed_ns_list (int fd, bool rae, struct nvme_ns_list * log) - Retrieve namespace changed list +**Constants** -**Parameters** +``NVME_FEAT_FID_ARBITRATION`` + *undescribed* -``int fd`` - File descriptor of nvme device +``NVME_FEAT_FID_POWER_MGMT`` + *undescribed* -``bool rae`` - Retain asynchronous events +``NVME_FEAT_FID_LBA_RANGE`` + *undescribed* -``struct nvme_ns_list * log`` +``NVME_FEAT_FID_TEMP_THRESH`` *undescribed* -**Description** +``NVME_FEAT_FID_ERR_RECOVERY`` + *undescribed* -This log page is used to describe namespaces attached to this controller -that have changed since the last time the namespace was identified, been -added, or deleted. +``NVME_FEAT_FID_VOLATILE_WC`` + *undescribed* -**Return** +``NVME_FEAT_FID_NUM_QUEUES`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_FEAT_FID_IRQ_COALESCE`` + *undescribed* +``NVME_FEAT_FID_IRQ_CONFIG`` + *undescribed* -.. c:function:: int nvme_get_log_cmd_effects (int fd, struct nvme_cmd_effects_log * log) +``NVME_FEAT_FID_WRITE_ATOMIC`` + *undescribed* - Retrieve nvme command effects log +``NVME_FEAT_FID_ASYNC_EVENT`` + *undescribed* -**Parameters** +``NVME_FEAT_FID_AUTO_PST`` + *undescribed* -``int fd`` - File descriptor of nvme device +``NVME_FEAT_FID_HOST_MEM_BUF`` + *undescribed* -``struct nvme_cmd_effects_log * log`` +``NVME_FEAT_FID_TIMESTAMP`` *undescribed* -**Description** +``NVME_FEAT_FID_KATO`` + *undescribed* -This log page is used to describe the commands that the controller supports -and the effects of those commands on the state of the NVM subsystem. +``NVME_FEAT_FID_HCTM`` + *undescribed* -**Return** +``NVME_FEAT_FID_NOPSC`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_FEAT_FID_RRL`` + *undescribed* +``NVME_FEAT_FID_PLM_CONFIG`` + *undescribed* -.. c:function:: int nvme_get_log_device_self_test (int fd, struct nvme_self_test_log * log) +``NVME_FEAT_FID_PLM_WINDOW`` + *undescribed* - Retrieve the device self test log +``NVME_FEAT_FID_LBA_STS_INTERVAL`` + *undescribed* -**Parameters** +``NVME_FEAT_FID_HOST_BEHAVIOR`` + *undescribed* -``int fd`` - File descriptor of nvme device +``NVME_FEAT_FID_SANITIZE`` + *undescribed* -``struct nvme_self_test_log * log`` - Userspace address of the log payload +``NVME_FEAT_FID_ENDURANCE_EVT_CFG`` + *undescribed* -**Description** +``NVME_FEAT_FID_SW_PROGRESS`` + *undescribed* -The log page is used to indicate the status of an in progress self test and -the percent complete of that operation, and the results of the previous 20 -self-test operations. +``NVME_FEAT_FID_HOST_ID`` + *undescribed* -**Return** - -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_FEAT_FID_RESV_MASK`` + *undescribed* +``NVME_FEAT_RESV_PERSIST`` + *undescribed* -.. c:function:: int nvme_get_log_create_telemetry_host (int fd, struct nvme_telemetry_log * log) +``NVME_FEAT_FID_WRITE_PROTECT`` + *undescribed* -**Parameters** -``int fd`` - *undescribed* -``struct nvme_telemetry_log * log`` - *undescribed* +.. c:type:: enum nvme_get_features_sel -.. c:function:: int nvme_get_log_telemetry_host (int fd, __u64 offset, __u32 len, void * log) +**Constants** +``NVME_GET_FEATURES_SEL_CURRENT`` + *undescribed* -**Parameters** +``NVME_GET_FEATURES_SEL_DEFAULT`` + *undescribed* -``int fd`` - File descriptor of nvme device +``NVME_GET_FEATURES_SEL_SAVED`` + *undescribed* -``__u64 offset`` - Offset into the telemetry data -``__u32 len`` - Length of provided user buffer to hold the log data in bytes -``void * log`` - User address for log page data -**Description** +.. c:type:: enum nvme_cmd_format_mset -Retreives the Telemetry Host-Initiated log page at the requested offset -using the previously existing capture. -**Return** +**Constants** -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_FORMAT_MSET_SEPARATE`` + *undescribed* +``NVME_FORMAT_MSET_EXTENEDED`` + *undescribed* -.. c:function:: int nvme_get_log_telemetry_ctrl (int fd, bool rae, __u64 offset, __u32 len, void * log) -**Parameters** -``int fd`` - File descriptor of nvme device +.. c:type:: enum nvme_cmd_format_pi -``bool rae`` - Retain asynchronous events -``__u64 offset`` - Offset into the telemetry data +**Constants** -``__u32 len`` - Length of provided user buffer to hold the log data in bytes +``NVME_FORMAT_PI_DISABLE`` + *undescribed* -``void * log`` - User address for log page data +``NVME_FORMAT_PI_TYPE1`` + *undescribed* +``NVME_FORMAT_PI_TYPE2`` + *undescribed* -.. c:function:: int nvme_get_log_endurance_group (int fd, __u16 endgid, struct nvme_endurance_group_log * log) +``NVME_FORMAT_PI_TYPE3`` + *undescribed* -**Parameters** -``int fd`` - File descriptor of nvme device -``__u16 endgid`` - Starting group identifier to return in the list +.. c:type:: enum nvme_cmd_format_ses -``struct nvme_endurance_group_log * log`` - User address to store the endurance log -**Description** +**Constants** -This log page indicates if an Endurance Group Event has occurred for a -particular Endurance Group. If an Endurance Group Event has occurred, the -details of the particular event are included in the Endurance Group -Information log page for that Endurance Group. An asynchronous event is -generated when an entry for an Endurance Group is newly added to this log -page. +``NVME_FORMAT_SES_NONE`` + *undescribed* -**Return** +``NVME_FORMAT_SES_USER_DATA_ERASE`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_FORMAT_SES_CRYPTO_ERASE`` + *undescribed* -.. c:function:: int nvme_get_log_predictable_lat_nvmset (int fd, __u16 nvmsetid, struct nvme_nvmset_predictable_lat_log * log) -**Parameters** +.. c:type:: enum nvme_ns_mgmt_sel -``int fd`` - *undescribed* -``__u16 nvmsetid`` +**Constants** -``struct nvme_nvmset_predictable_lat_log * log`` +``NVME_NS_MGMT_SEL_CREATE`` *undescribed* -**Return** - -The nvme command status if a response was received or -1 with errno - set otherwise. - +``NVME_NS_MGMT_SEL_DELETE`` + *undescribed* -.. c:function:: int nvme_get_log_predictable_lat_event (int fd, bool rae, __u32 offset, __u32 len, void * log) -**Parameters** -``int fd`` - File descriptor of nvme device +.. c:type:: enum nvme_ns_attach_sel -``bool rae`` - Retain asynchronous events + NVME_NS_ATTACH_SEL_CTRL_ATTACH: NVME_NP_ATTACH_SEL_CTRL_DEATTACH: -``__u32 offset`` - *undescribed* +**Constants** -``__u32 len`` +``NVME_NS_ATTACH_SEL_CTRL_ATTACH`` *undescribed* -``void * log`` +``NVME_NS_ATTACH_SEL_CTRL_DEATTACH`` *undescribed* -.. c:function:: int nvme_get_log_ana (int fd, enum nvme_log_ana_lsp lsp, bool rae, __u64 offset, __u32 len, void * log) - -**Parameters** -``int fd`` - File descriptor of nvme device +.. c:type:: enum nvme_fw_commit_ca -``enum nvme_log_ana_lsp lsp`` - Log specific, see :c:type:`enum nvme_get_log_ana_lsp ` -``bool rae`` - Retain asynchronous events +**Constants** -``__u64 offset`` +``NVME_FW_COMMIT_CA_REPLACE`` *undescribed* -``__u32 len`` - The allocated length of the log page - -``void * log`` - User address to store the ana log - -**Description** +``NVME_FW_COMMIT_CA_REPLACE_AND_ACTIVATE`` + *undescribed* -This log consists of a header describing the log and descriptors containing -the asymmetric namespace access information for ANA Groups that contain -namespaces that are attached to the controller processing the command. +``NVME_FW_COMMIT_CA_SET_ACTIVE`` + *undescribed* -See :c:type:`struct nvme_ana_rsp_hdr ` for the defintion of the returned structure. +``NVME_FW_COMMIT_CA_REPLACE_AND_ACTIVATE_IMMEDIATE`` + *undescribed* -**Return** +``NVME_FW_COMMIT_CA_REPLACE_BOOT_PARTITION`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_FW_COMMIT_CA_ACTIVATE_BOOT_PARTITION`` + *undescribed* -.. c:function:: int nvme_get_log_ana_groups (int fd, bool rae, __u32 len, struct nvme_ana_group_desc * log) -**Parameters** +.. c:type:: enum nvme_directive_dtype -``int fd`` - File descriptor of nvme device -``bool rae`` - Retain asynchronous events +**Constants** -``__u32 len`` +``NVME_DIRECTIVE_DTYPE_IDENTIFY`` *undescribed* -``struct nvme_ana_group_desc * log`` +``NVME_DIRECTIVE_DTYPE_STREAMS`` *undescribed* -**Description** - -See :c:type:`struct nvme_ana_group_desc ` for the defintion of the returned structure. -.. c:function:: int nvme_get_log_lba_status (int fd, bool rae, __u64 offset, __u32 len, void * log) +.. c:type:: enum nvme_directive_receive_doper -**Parameters** -``int fd`` - File descriptor of nvme device +**Constants** -``bool rae`` - Retain asynchronous events +``NVME_DIRECTIVE_RECEIVE_IDENTIFY_DOPER_PARAM`` + *undescribed* -``__u64 offset`` +``NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_PARAM`` *undescribed* -``__u32 len`` +``NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_STATUS`` *undescribed* -``void * log`` +``NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_RESOURCE`` *undescribed* -.. c:function:: int nvme_get_log_endurance_grp_evt (int fd, bool rae, __u32 offset, __u32 len, void * log) -**Parameters** +.. c:type:: enum nvme_directive_send_doper -``int fd`` - File descriptor of nvme device -``bool rae`` - Retain asynchronous events +**Constants** -``__u32 offset`` +``NVME_DIRECTIVE_SEND_IDENTIFY_DOPER_ENDIR`` *undescribed* -``__u32 len`` +``NVME_DIRECTIVE_SEND_STREAMS_DOPER_RELEASE_IDENTIFIER`` *undescribed* -``void * log`` +``NVME_DIRECTIVE_SEND_STREAMS_DOPER_RELEASE_RESOURCE`` *undescribed* -.. c:function:: int nvme_get_log_discovery (int fd, bool rae, __u32 offset, __u32 len, void * log) - - -**Parameters** -``int fd`` - File descriptor of nvme device -``bool rae`` - Retain asynchronous events +.. c:type:: enum nvme_directive_send_identify_endir -``__u32 offset`` - Offset of this log to retrieve -``__u32 len`` - The allocated size for this portion of the log +**Constants** -``void * log`` - User address to store the discovery log +``NVME_DIRECTIVE_SEND_IDENTIFY_ENDIR_DISABLE`` + *undescribed* -**Description** +``NVME_DIRECTIVE_SEND_IDENTIFY_ENDIR_ENABLE`` + *undescribed* -Supported only by fabrics discovery controllers, returning discovery -records. -**Return** -The nvme command status if a response was received or -1 with errno - set otherwise. +.. c:type:: enum nvme_sanitize_sanact -.. c:function:: int nvme_get_log_reservation (int fd, bool rae, struct nvme_resv_notification_log * log) +**Constants** -**Parameters** +``NVME_SANITIZE_SANACT_EXIT_FAILURE`` + *undescribed* -``int fd`` - File descriptor of nvme device +``NVME_SANITIZE_SANACT_START_BLOCK_ERASE`` + *undescribed* -``bool rae`` - Retain asynchronous events +``NVME_SANITIZE_SANACT_START_OVERWRITE`` + *undescribed* -``struct nvme_resv_notification_log * log`` +``NVME_SANITIZE_SANACT_START_CRYPTO_ERASE`` *undescribed* -.. c:function:: int nvme_get_log_sanitize (int fd, bool rae, struct nvme_sanitize_log_page * log) -**Parameters** +.. c:type:: enum nvme_dst_stc -``int fd`` - File descriptor of nvme device -``bool rae`` - Retain asynchronous events +**Constants** -``struct nvme_sanitize_log_page * log`` - User address to store the sanitize log +``NVME_DST_STC_SHORT`` + *undescribed* -**Description** +``NVME_DST_STC_LONG`` + *undescribed* -The Sanitize Status log page is used to report sanitize operation time -estimates and information about the most recent sanitize operation. +``NVME_DST_STC_VS`` + *undescribed* -**Return** +``NVME_DST_STC_ABORT`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. -.. c:function:: int nvme_set_features (int fd, __u8 fid, __u32 nsid, __u32 cdw11, __u32 cdw12, bool save, __u8 uuidx, __u32 cdw15, __u32 data_len, void * data, __u32 * result) - Set a feature attribute +.. c:type:: enum nvme_virt_mgmt_act -**Parameters** -``int fd`` - File descriptor of nvme device +**Constants** -``__u8 fid`` - Feature identifier +``NVME_VIRT_MGMT_ACT_PRIM_CTRL_FLEX_ALLOC`` + *undescribed* -``__u32 nsid`` - Namespace ID, if applicable +``NVME_VIRT_MGMT_ACT_OFFLINE_SEC_CTRL`` + *undescribed* -``__u32 cdw11`` - Value to set the feature to +``NVME_VIRT_MGMT_ACT_ASSIGN_SEC_CTRL`` + *undescribed* -``__u32 cdw12`` - Feature specific command dword12 field +``NVME_VIRT_MGMT_ACT_ONLINE_SEC_CTRL`` + *undescribed* -``bool save`` - Save value across power states -``__u8 uuidx`` - UUID Index for differentiating vendor specific encoding -``__u32 cdw15`` - *undescribed* -``__u32 data_len`` - Length of feature data, if applicable, in bytes +.. c:type:: enum nvme_virt_mgmt_rt -``void * data`` - User address of feature data, if applicable -``__u32 * result`` - The command completion result from CQE dword0 +**Constants** -**Return** +``NVME_VIRT_MGMT_RT_VQ_RESOURCE`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_VIRT_MGMT_RT_VI_RESOURCE`` + *undescribed* -.. c:function:: int nvme_set_features_arbitration (int fd, __u8 ab, __u8 lpw, __u8 mpw, __u8 hpw, bool save, __u32 * result) +.. c:function:: int nvme_identify (int fd, enum nvme_identify_cns cns, __u32 nsid, __u16 cntid, __u16 nvmsetid, __u8 uuidx, void * data) + Send the NVMe Identify command **Parameters** ``int fd`` File descriptor of nvme device -``__u8 ab`` - *undescribed* +``enum nvme_identify_cns cns`` + The Controller or Namespace structure, see **enum** nvme_identify_cns -``__u8 lpw`` - *undescribed* +``__u32 nsid`` + Namespace identifier, if applicable -``__u8 mpw`` - *undescribed* +``__u16 cntid`` + The Controller Identifier, if applicable -``__u8 hpw`` - *undescribed* +``__u16 nvmsetid`` + The NVMe Set ID if CNS is 04h -``bool save`` - Save value across power states +``__u8 uuidx`` + UUID Index if controller supports this id selection method -``__u32 * result`` - The command completion result from CQE dword0 +``void * data`` + User space destination address to transfer the data + +**Description** + +The Identify command returns a data buffer that describes information about +the NVM subsystem, the controller or the namespace(s). **Return** @@ -1564,25 +1514,24 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_power_mgmt (int fd, __u8 ps, __u8 wh, bool save, __u32 * result) +.. c:function:: int nvme_identify_ctrl (int fd, struct nvme_id_ctrl * id) + Retrieves nvme identify controller **Parameters** ``int fd`` File descriptor of nvme device + id: User space destination address to transfer the data, -``__u8 ps`` +``struct nvme_id_ctrl * id`` *undescribed* -``__u8 wh`` - *undescribed* +**Description** -``bool save`` - Save value across power states +Sends nvme identify with CNS value ``NVME_IDENTIFY_CNS_CTRL``. -``__u32 * result`` - The command completion result from CQE dword0 +See :c:type:`struct nvme_id_ctrl ` for details on the data returned. **Return** @@ -1590,8 +1539,9 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_lba_range (int fd, __u32 nsid, __u32 nr_ranges, bool save, struct nvme_lba_range_type * data, __u32 * result) +.. c:function:: int nvme_identify_ns (int fd, __u32 nsid, struct nvme_id_ns * ns) + Retrieves nvme identify namespace **Parameters** @@ -1599,19 +1549,23 @@ The nvme command status if a response was received or -1 with errno File descriptor of nvme device ``__u32 nsid`` - *undescribed* + Namespace to identify -``__u32 nr_ranges`` - *undescribed* +``struct nvme_id_ns * ns`` + User space destination address to transfer the data -``bool save`` - Save value across power states +**Description** -``struct nvme_lba_range_type * data`` - *undescribed* +If the Namespace Identifier (NSID) field specifies an active NSID, then the +Identify Namespace data structure is returned to the host for that specified +namespace. -``__u32 * result`` - The command completion result from CQE dword0 +If the controller supports the Namespace Management capability and the NSID +field is set to ``NVME_NSID_ALL``, then the controller returns an Identify Namespace +data structure that specifies capabilities that are common across namespaces +for this controller. + +See :c:type:`struct nvme_id_ns ` for details on the structure returned. **Return** @@ -1619,42 +1573,49 @@ The nvme command status if a response was received or -1 with errno set otherwise. +.. c:function:: int nvme_identify_allocated_ns (int fd, __u32 nsid, struct nvme_id_ns * ns) + Same as nvme_identify_ns, but only for allocated namespaces -.. c:type:: enum nvme_feat_tmpthresh_thsel +**Parameters** +``int fd`` + File descriptor of nvme device -**Constants** +``__u32 nsid`` + Namespace to identify -``NVME_FEATURE_TEMPTHRESH_THSEL_OVER`` - *undescribed* +``struct nvme_id_ns * ns`` + User space destination address to transfer the data -``NVME_FEATURETEMPTHRESH__THSEL_UNDER`` - *undescribed* +**Return** + +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_set_features_temp_thresh (int fd, __u16 tmpth, __u8 tmpsel, enum nvme_feat_tmpthresh_thsel thsel, bool save, __u32 * result) +.. c:function:: int nvme_identify_active_ns_list (int fd, __u32 nsid, struct nvme_ns_list * list) + Retrieves active namespaces id list **Parameters** ``int fd`` File descriptor of nvme device -``__u16 tmpth`` - *undescribed* +``__u32 nsid`` + Return namespaces greater than this identifer -``__u8 tmpsel`` +``struct nvme_ns_list * list`` *undescribed* -``enum nvme_feat_tmpthresh_thsel thsel`` - *undescribed* +**Description** -``bool save`` - Save value across power states +A list of 1024 namespace IDs is returned to the host containing NSIDs in +increasing order that are greater than the value specified in the Namespace +Identifier (nsid) field of the command. -``__u32 * result`` - The command completion result from CQE dword0 +See :c:type:`struct nvme_ns_list ` for the definition of the returned structure. **Return** @@ -1662,8 +1623,9 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_err_recovery (int fd, __u32 nsid, __u16 tler, bool dulbe, bool save, __u32 * result) +.. c:function:: int nvme_identify_allocated_ns_list (int fd, __u32 nsid, struct nvme_ns_list * list) + Retrieves allocated namespace id list **Parameters** @@ -1671,19 +1633,18 @@ The nvme command status if a response was received or -1 with errno File descriptor of nvme device ``__u32 nsid`` - *undescribed* + Return namespaces greater than this identifer -``__u16 tler`` +``struct nvme_ns_list * list`` *undescribed* -``bool dulbe`` - *undescribed* +**Description** -``bool save`` - Save value across power states +A list of 1024 namespace IDs is returned to the host containing NSIDs in +increasing order that are greater than the value specified in the Namespace +Identifier (nsid) field of the command. -``__u32 * result`` - The command completion result from CQE dword0 +See :c:type:`struct nvme_ns_list ` for the definition of the returned structure. **Return** @@ -1691,22 +1652,28 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_volatile_wc (int fd, bool wce, bool save, __u32 * result) +.. c:function:: int nvme_identify_ctrl_list (int fd, __u16 cntid, struct nvme_ctrl_list * ctrlist) + Retrieves identify controller list **Parameters** ``int fd`` File descriptor of nvme device -``bool wce`` +``__u16 cntid`` *undescribed* -``bool save`` - Save value across power states +``struct nvme_ctrl_list * ctrlist`` + *undescribed* -``__u32 * result`` - The command completion result from CQE dword0 +**Description** + +Up to 2047 controller identifiers is returned containing a controller +identifier greater than or equal to the controller identifier specified in +**cntid**. + +See :c:type:`struct nvme_ctrl_list ` for a definition of the structure returned. **Return** @@ -1714,7 +1681,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_irq_coalesce (int fd, __u8 thr, __u8 time, bool save, __u32 * result) +.. c:function:: int nvme_identify_nsid_ctrl_list (int fd, __u32 nsid, __u16 cntid, struct nvme_ctrl_list * ctrlist) **Parameters** @@ -1722,43 +1689,52 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u8 thr`` +``__u32 nsid`` + Return controllers that are attached to this nsid + +``__u16 cntid`` *undescribed* -``__u8 time`` +``struct nvme_ctrl_list * ctrlist`` *undescribed* -``bool save`` - Save value across power states +**Description** -``__u32 * result`` - The command completion result from CQE dword0 +Up to 2047 controller identifiers is returned containing a controller +identifier greater than or equal to the controller identifier specified in +**cntid**. + +See :c:type:`struct nvme_ctrl_list ` for a definition of the structure returned. **Return** -The nvme command status if a response was received or -1 with errno - set otherwise. +The nvme command status if a response was received or -1 -.. c:function:: int nvme_set_features_irq_config (int fd, __u16 iv, bool cd, bool save, __u32 * result) +.. c:function:: int nvme_identify_ns_descs (int fd, __u32 nsid, struct nvme_ns_id_desc * descs) + Retrieves namespace descriptor list **Parameters** ``int fd`` File descriptor of nvme device -``__u16 iv`` - *undescribed* +``__u32 nsid`` + The namespace id to retrieve destriptors -``bool cd`` - *undescribed* +``struct nvme_ns_id_desc * descs`` + User space destination address to transfer the data -``bool save`` - Save value across power states +**Description** -``__u32 * result`` - The command completion result from CQE dword0 +A list of Namespace Identification Descriptor structures is returned to the +host for the namespace specified in the Namespace Identifier (NSID) field if +it is an active NSID. + +The data returned is in the form of an arrray of 'struct nvme_ns_id_desc'. + +See :c:type:`struct nvme_ns_id_desc ` for the definition of the returned structure. **Return** @@ -1766,22 +1742,29 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_write_atomic (int fd, bool dn, bool save, __u32 * result) +.. c:function:: int nvme_identify_nvmset_list (int fd, __u16 nvmsetid, struct nvme_id_nvmset_list * nvmset) + Retrieves NVM Set List **Parameters** ``int fd`` File descriptor of nvme device -``bool dn`` +``__u16 nvmsetid`` *undescribed* -``bool save`` - Save value across power states +``struct nvme_id_nvmset_list * nvmset`` + User space destination address to transfer the data -``__u32 * result`` - The command completion result from CQE dword0 +**Description** + +Retrieves an NVM Set List, struct nvme_id_nvmset. The data structure is an +ordered list by NVM Set Identifier, starting with the first NVM Set +Identifier supported by the NVM subsystem that is equal to or greater than +the NVM Set Identifier. + +See :c:type:`struct nvme_id_nvmset_list ` for the defintion of the returned structure. **Return** @@ -1789,72 +1772,54 @@ The nvme command status if a response was received or -1 with errno set otherwise. +.. c:function:: int nvme_identify_primary_ctrl (int fd, __u16 cntid, struct nvme_primary_ctrl_cap * cap) + Retrieve NVMe Primary Controller identification :c:type:`fd`: -.. c:type:: enum nvme_features_async_event_config_flags - - -**Constants** - -``NVME_FEATURE_AENCFG_SMART_CRIT_SPARE`` - *undescribed* - -``NVME_FEATURE_AENCFG_SMART_CRIT_TEMPERATURE`` - *undescribed* - -``NVME_FEATURE_AENCFG_SMART_CRIT_DEGRADED`` - *undescribed* - -``NVME_FEATURE_AENCFG_SMART_CRIT_READ_ONLY`` - *undescribed* - -``NVME_FEATURE_AENCFG_SMART_CRIT_VOLATILE_BACKUP`` - *undescribed* - -``NVME_FEATURE_AENCFG_SMART_CRIT_READ_ONLY_PMR`` - *undescribed* - -``NVME_FEATURE_AENCFG_NOTICE_NAMESPACE_ATTRIBUTES`` - *undescribed* +**Parameters** -``NVME_FEATURE_AENCFG_NOTICE_FIRMWARE_ACTIVATION`` +``int fd`` *undescribed* -``NVME_FEATURE_AENCFG_NOTICE_TELEMETRY_LOG`` +``__u16 cntid`` *undescribed* -``NVME_FEATURE_AENCFG_NOTICE_ANA_CHANGE`` - *undescribed* +``struct nvme_primary_ctrl_cap * cap`` -``NVME_FEATURE_AENCFG_NOTICE_PL_EVENT`` - *undescribed* +**Description** -``NVME_FEATURE_AENCFG_NOTICE_LBA_STATUS`` - *undescribed* +See :c:type:`struct nvme_primary_ctrl_cap ` for the defintion of the returned structure, **cap**. -``NVME_FEATURE_AENCFG_NOTICE_EG_EVENT`` - *undescribed* +**Return** -``NVME_FEATURE_AENCFG_NOTICE_DISCOVERY_CHANGE`` - *undescribed* +The nvme command status if a response was received or -1 + with errno set otherwise. -.. c:function:: int nvme_set_features_async_event (int fd, __u32 events, bool save, __u32 * result) +.. c:function:: int nvme_identify_secondary_ctrl_list (int fd, __u16 cntid, struct nvme_secondary_ctrl_list * list) + Retrieves secondary controller list **Parameters** ``int fd`` File descriptor of nvme device -``__u32 events`` +``__u16 cntid`` + Return controllers starting at this identifier + +``struct nvme_secondary_ctrl_list * list`` *undescribed* -``bool save`` - Save value across power states +**Description** -``__u32 * result`` - The command completion result from CQE dword0 +A Secondary Controller List is returned to the host for up to 127 secondary +controllers associated with the primary controller processing this command. +The list contains entries for controller identifiers greater than or equal +to the value specified in the Controller Identifier (cntid). + +See :c:type:`struct nvme_secondary_ctrls_list ` for a defintion of the returned +structure. **Return** @@ -1862,25 +1827,26 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_auto_pst (int fd, bool apste, bool save, struct nvme_feat_auto_pst * apst, __u32 * result) +.. c:function:: int nvme_identify_ns_granularity (int fd, struct nvme_id_ns_granularity_list * list) + Retrieves namespace granularity identification **Parameters** ``int fd`` File descriptor of nvme device -``bool apste`` +``struct nvme_id_ns_granularity_list * list`` *undescribed* -``bool save`` - Save value across power states +**Description** -``struct nvme_feat_auto_pst * apst`` - *undescribed* +If the controller supports reporting of Namespace Granularity, then a +Namespace Granularity List is returned to the host for up to sixteen +namespace granularity descriptors -``__u32 * result`` - The command completion result from CQE dword0 +See :c:type:`struct nvme_id_ns_granularity_list ` for the definition of the returned +structure. **Return** @@ -1888,19 +1854,24 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_timestamp (int fd, bool save, __u64 timestamp) +.. c:function:: int nvme_identify_uuid (int fd, struct nvme_id_uuid_list * list) + Retrieves device's UUIDs **Parameters** ``int fd`` File descriptor of nvme device -``bool save`` - Save value across power states +``struct nvme_id_uuid_list * list`` + *undescribed* -``__u64 timestamp`` - The current timestamp value to assign to this this feature +**Description** + +Each UUID List entry is either 0h, the NVMe Invalid UUID, or a valid UUID. +Valid UUIDs are those which are non-zero and are not the NVMe Invalid UUID. + +See :c:type:`struct nvme_id_uuid_list ` for the definition of the returned structure. **Return** @@ -1908,69 +1879,71 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_hctm (int fd, __u16 tmt2, __u16 tmt1, bool save, __u32 * result) +.. c:function:: int nvme_get_log (int fd, enum nvme_cmd_get_log_lid lid, __u32 nsid, __u64 lpo, __u8 lsp, __u16 lsi, bool rae, __u8 uuidx, __u32 len, void * log) + NVMe Admin Get Log command **Parameters** ``int fd`` File descriptor of nvme device -``__u16 tmt2`` - *undescribed* - -``__u16 tmt1`` - *undescribed* - -``bool save`` - Save value across power states - -``__u32 * result`` - The command completion result from CQE dword0 +``enum nvme_cmd_get_log_lid lid`` + Log page identifier, see :c:type:`enum nvme_cmd_get_log_lid ` for known values -**Return** +``__u32 nsid`` + Namespace identifier, if applicable -The nvme command status if a response was received or -1 with errno - set otherwise. +``__u64 lpo`` + Log page offset for partial log transfers +``__u8 lsp`` + Log specific field -.. c:function:: int nvme_set_features_nopsc (int fd, bool noppme, bool save, __u32 * result) +``__u16 lsi`` + Endurance group information +``bool rae`` + Retain asynchronous events -**Parameters** +``__u8 uuidx`` + UUID selection, if supported -``int fd`` - *undescribed* +``__u32 len`` + Length of provided user buffer to hold the log data in bytes -``bool noppme`` - *undescribed* +``void * log`` + User space destination address to transfer the data -``bool save`` - *undescribed* +**Return** -``__u32 * result`` - *undescribed* +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_set_features_rrl (int fd, __u8 rrl, __u16 nvmsetid, bool save, __u32 * result) +.. c:function:: int nvme_get_log_error (int fd, unsigned nr_entries, bool rae, struct nvme_error_log_page * log) + Retrieve nvme error log **Parameters** ``int fd`` File descriptor of nvme device -``__u8 rrl`` +``unsigned nr_entries`` *undescribed* -``__u16 nvmsetid`` +``bool rae`` + Retain asynchronous events + +``struct nvme_error_log_page * log`` *undescribed* -``bool save`` - Save value across power states +**Description** -``__u32 * result`` - The command completion result from CQE dword0 +This log page is used to describe extended error information for a command +that completed with error, or may report an error that is not specific to a +particular command. **Return** @@ -1978,28 +1951,32 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_plm_config (int fd, bool enable, __u16 nvmsetid, bool save, struct nvme_plm_config * data, __u32 * result) +.. c:function:: int nvme_get_log_smart (int fd, __u32 nsid, bool rae, struct nvme_smart_log * log) + Retrieve nvme smart log **Parameters** ``int fd`` File descriptor of nvme device -``bool enable`` - *undescribed* - -``__u16 nvmsetid`` - *undescribed* +``__u32 nsid`` + Optional namespace identifier -``bool save`` - Save value across power states +``bool rae`` + Retain asynchronous events -``struct nvme_plm_config * data`` +``struct nvme_smart_log * log`` *undescribed* -``__u32 * result`` - The command completion result from CQE dword0 +**Description** + +This log page is used to provide SMART and general health information. The +information provided is over the life of the controller and is retained +across power cycles. To request the controller log page, the namespace +identifier specified is FFFFFFFFh. The controller may also support +requesting the log page on a per namespace basis, as indicated by bit 0 of +the LPA field in the Identify Controller data structure. **Return** @@ -2007,39 +1984,26 @@ The nvme command status if a response was received or -1 with errno set otherwise. +.. c:function:: int nvme_get_log_fw_slot (int fd, bool rae, struct nvme_firmware_slot * log) - -.. c:type:: enum nvme_feat_plm_window_select - - -**Constants** - -``NVME_FEATURE_PLM_DTWIN`` - *undescribed* - -``NVME_FEATURE_PLM_NDWIN`` - *undescribed* - - -.. c:function:: int nvme_set_features_plm_window (int fd, enum nvme_feat_plm_window_select sel, __u16 nvmsetid, bool save, __u32 * result) - + Retrieves the controller firmware log **Parameters** ``int fd`` File descriptor of nvme device -``enum nvme_feat_plm_window_select sel`` - *undescribed* +``bool rae`` + Retain asynchronous events -``__u16 nvmsetid`` +``struct nvme_firmware_slot * log`` *undescribed* -``bool save`` - Save value across power states +**Description** -``__u32 * result`` - The command completion result from CQE dword0 +This log page is used to describe the firmware revision stored in each +firmware slot supported. The firmware revision is indicated as an ASCII +string. The log page also indicates the active slot number. **Return** @@ -2047,25 +2011,26 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_lba_sts_interval (int fd, __u16 lsiri, __u16 lsipi, bool save, __u32 * result) +.. c:function:: int nvme_get_log_changed_ns_list (int fd, bool rae, struct nvme_ns_list * log) + Retrieve namespace changed list **Parameters** ``int fd`` File descriptor of nvme device -``__u16 lsiri`` - *undescribed* +``bool rae`` + Retain asynchronous events -``__u16 lsipi`` +``struct nvme_ns_list * log`` *undescribed* -``bool save`` - Save value across power states +**Description** -``__u32 * result`` - The command completion result from CQE dword0 +This log page is used to describe namespaces attached to this controller +that have changed since the last time the namespace was identified, been +added, or deleted. **Return** @@ -2073,42 +2038,46 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_host_behavior (int fd, bool save, struct nvme_feat_host_behavior * data) +.. c:function:: int nvme_get_log_cmd_effects (int fd, struct nvme_cmd_effects_log * log) + Retrieve nvme command effects log **Parameters** ``int fd`` File descriptor of nvme device -``bool save`` - Save value across power states - -``struct nvme_feat_host_behavior * data`` +``struct nvme_cmd_effects_log * log`` *undescribed* +**Description** + +This log page is used to describe the commands that the controller supports +and the effects of those commands on the state of the NVM subsystem. + **Return** The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_sanitize (int fd, bool nodrm, bool save, __u32 * result) +.. c:function:: int nvme_get_log_device_self_test (int fd, struct nvme_self_test_log * log) + Retrieve the device self test log **Parameters** ``int fd`` File descriptor of nvme device -``bool nodrm`` - *undescribed* +``struct nvme_self_test_log * log`` + Userspace address of the log payload -``bool save`` - Save value across power states +**Description** -``__u32 * result`` - The command completion result from CQE dword0 +The log page is used to indicate the status of an in progress self test and +the percent complete of that operation, and the results of the previous 20 +self-test operations. **Return** @@ -2116,33 +2085,19 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_endurance_evt_cfg (int fd, __u16 endgid, __u8 egwarn, bool save, __u32 * result) +.. c:function:: int nvme_get_log_create_telemetry_host (int fd, struct nvme_telemetry_log * log) **Parameters** ``int fd`` - File descriptor of nvme device - -``__u16 endgid`` *undescribed* -``__u8 egwarn`` - Flags to enable warning, see :c:type:`enum nvme_eg_critical_warning_flags ` - -``bool save`` - Save value across power states - -``__u32 * result`` - The command completion result from CQE dword0 - -**Return** - -The nvme command status if a response was received or -1 with errno - set otherwise. +``struct nvme_telemetry_log * log`` + *undescribed* -.. c:function:: int nvme_set_features_sw_progress (int fd, __u8 pbslc, bool save, __u32 * result) +.. c:function:: int nvme_get_log_telemetry_host (int fd, __u64 offset, __u32 len, void * log) **Parameters** @@ -2150,14 +2105,19 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u8 pbslc`` - *undescribed* +``__u64 offset`` + Offset into the telemetry data -``bool save`` - Save value across power states +``__u32 len`` + Length of provided user buffer to hold the log data in bytes -``__u32 * result`` - The command completion result from CQE dword0 +``void * log`` + User address for log page data + +**Description** + +Retreives the Telemetry Host-Initiated log page at the requested offset +using the previously existing capture. **Return** @@ -2165,7 +2125,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_host_id (int fd, bool exhid, bool save, __u8 * hostid) +.. c:function:: int nvme_get_log_telemetry_ctrl (int fd, bool rae, __u64 offset, __u32 len, void * log) **Parameters** @@ -2173,22 +2133,20 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``bool exhid`` - *undescribed* - -``bool save`` - Save value across power states +``bool rae`` + Retain asynchronous events -``__u8 * hostid`` - *undescribed* +``__u64 offset`` + Offset into the telemetry data -**Return** +``__u32 len`` + Length of provided user buffer to hold the log data in bytes -The nvme command status if a response was received or -1 with errno - set otherwise. +``void * log`` + User address for log page data -.. c:function:: int nvme_set_features_resv_mask (int fd, __u32 mask, bool save, __u32 * result) +.. c:function:: int nvme_get_log_endurance_group (int fd, __u16 endgid, struct nvme_endurance_group_log * log) **Parameters** @@ -2196,14 +2154,20 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 mask`` - *undescribed* +``__u16 endgid`` + Starting group identifier to return in the list -``bool save`` - Save value across power states +``struct nvme_endurance_group_log * log`` + User address to store the endurance log -``__u32 * result`` - The command completion result from CQE dword0 +**Description** + +This log page indicates if an Endurance Group Event has occurred for a +particular Endurance Group. If an Endurance Group Event has occurred, the +details of the particular event are included in the Endurance Group +Information log page for that Endurance Group. An asynchronous event is +generated when an entry for an Endurance Group is newly added to this log +page. **Return** @@ -2211,22 +2175,18 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_set_features_resv_persist (int fd, bool ptpl, bool save, __u32 * result) +.. c:function:: int nvme_get_log_predictable_lat_nvmset (int fd, __u16 nvmsetid, struct nvme_nvmset_predictable_lat_log * log) **Parameters** ``int fd`` - File descriptor of nvme device - -``bool ptpl`` *undescribed* -``bool save`` - Save value across power states +``__u16 nvmsetid`` -``__u32 * result`` - The command completion result from CQE dword0 +``struct nvme_nvmset_predictable_lat_log * log`` + *undescribed* **Return** @@ -2234,27 +2194,28 @@ The nvme command status if a response was received or -1 with errno set otherwise. +.. c:function:: int nvme_get_log_predictable_lat_event (int fd, bool rae, __u32 offset, __u32 len, void * log) -.. c:type:: enum nvme_feat_nswpcfg_state - +**Parameters** -**Constants** +``int fd`` + File descriptor of nvme device -``NVME_FEAT_NS_NO_WRITE_PROTECT`` - *undescribed* +``bool rae`` + Retain asynchronous events -``NVME_FEAT_NS_WRITE_PROTECT`` +``__u32 offset`` *undescribed* -``NVME_FEAT_NS_WRITE_PROTECT_PWR_CYCLE`` +``__u32 len`` *undescribed* -``NVME_FEAT_NS_WRITE_PROTECT_PERMANENT`` +``void * log`` *undescribed* -.. c:function:: int nvme_set_features_write_protect (int fd, enum nvme_feat_nswpcfg_state state, bool save, __u32 * result) +.. c:function:: int nvme_get_log_ana (int fd, enum nvme_log_ana_lsp lsp, bool rae, __u64 offset, __u32 len, void * log) **Parameters** @@ -2262,14 +2223,28 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_feat_nswpcfg_state state`` +``enum nvme_log_ana_lsp lsp`` + Log specific, see :c:type:`enum nvme_get_log_ana_lsp ` + +``bool rae`` + Retain asynchronous events + +``__u64 offset`` *undescribed* -``bool save`` - Save value across power states +``__u32 len`` + The allocated length of the log page -``__u32 * result`` - The command completion result from CQE dword0 +``void * log`` + User address to store the ana log + +**Description** + +This log consists of a header describing the log and descriptors containing +the asymmetric namespace access information for ANA Groups that contain +namespaces that are attached to the controller processing the command. + +See :c:type:`struct nvme_ana_rsp_hdr ` for the defintion of the returned structure. **Return** @@ -2277,46 +2252,29 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features (int fd, enum nvme_features_id fid, __u32 nsid, enum nvme_get_features_sel sel, __u32 cdw11, __u8 uuidx, __u32 data_len, void * data, __u32 * result) +.. c:function:: int nvme_get_log_ana_groups (int fd, bool rae, __u32 len, struct nvme_ana_group_desc * log) - Retrieve a feature attribute **Parameters** ``int fd`` File descriptor of nvme device -``enum nvme_features_id fid`` - Feature identifier - -``__u32 nsid`` - Namespace ID, if applicable - -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` - -``__u32 cdw11`` - Feature specific command dword11 field - -``__u8 uuidx`` - UUID Index for differentiating vendor specific encoding - -``__u32 data_len`` - Length of feature data, if applicable, in bytes +``bool rae`` + Retain asynchronous events -``void * data`` - User address of feature data, if applicable +``__u32 len`` + *undescribed* -``__u32 * result`` - The command completion result from CQE dword0 +``struct nvme_ana_group_desc * log`` + *undescribed* -**Return** +**Description** -The nvme command status if a response was received or -1 with errno - set otherwise. +See :c:type:`struct nvme_ana_group_desc ` for the defintion of the returned structure. -.. c:function:: int nvme_get_features_arbitration (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_get_log_lba_status (int fd, bool rae, __u64 offset, __u32 len, void * log) **Parameters** @@ -2324,19 +2282,20 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``bool rae`` + Retain asynchronous events -``__u32 * result`` - The command completion result from CQE dword0 +``__u64 offset`` + *undescribed* -**Return** +``__u32 len`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``void * log`` + *undescribed* -.. c:function:: int nvme_get_features_power_mgmt (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_get_log_endurance_grp_evt (int fd, bool rae, __u32 offset, __u32 len, void * log) **Parameters** @@ -2344,19 +2303,20 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``bool rae`` + Retain asynchronous events -``__u32 * result`` - The command completion result from CQE dword0 +``__u32 offset`` + *undescribed* -**Return** +``__u32 len`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``void * log`` + *undescribed* -.. c:function:: int nvme_get_features_lba_range (int fd, enum nvme_get_features_sel sel, struct nvme_lba_range_type * data, __u32 * result) +.. c:function:: int nvme_get_log_discovery (int fd, bool rae, __u32 offset, __u32 len, void * log) **Parameters** @@ -2364,14 +2324,22 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``bool rae`` + Retain asynchronous events -``struct nvme_lba_range_type * data`` - *undescribed* +``__u32 offset`` + Offset of this log to retrieve -``__u32 * result`` - The command completion result from CQE dword0 +``__u32 len`` + The allocated size for this portion of the log + +``void * log`` + User address to store the discovery log + +**Description** + +Supported only by fabrics discovery controllers, returning discovery +records. **Return** @@ -2379,7 +2347,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_temp_thresh (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_get_log_reservation (int fd, bool rae, struct nvme_resv_notification_log * log) **Parameters** @@ -2387,19 +2355,14 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``bool rae`` + Retain asynchronous events -``__u32 * result`` - The command completion result from CQE dword0 - -**Return** - -The nvme command status if a response was received or -1 with errno - set otherwise. +``struct nvme_resv_notification_log * log`` + *undescribed* -.. c:function:: int nvme_get_features_err_recovery (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_get_log_sanitize (int fd, bool rae, struct nvme_sanitize_log_page * log) **Parameters** @@ -2407,11 +2370,16 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``bool rae`` + Retain asynchronous events -``__u32 * result`` - The command completion result from CQE dword0 +``struct nvme_sanitize_log_page * log`` + User address to store the sanitize log + +**Description** + +The Sanitize Status log page is used to report sanitize operation time +estimates and information about the most recent sanitize operation. **Return** @@ -2419,36 +2387,41 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_volatile_wc (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features (int fd, __u8 fid, __u32 nsid, __u32 cdw11, __u32 cdw12, bool save, __u8 uuidx, __u32 cdw15, __u32 data_len, void * data, __u32 * result) + Set a feature attribute **Parameters** ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` - -``__u32 * result`` - The command completion result from CQE dword0 +``__u8 fid`` + Feature identifier -**Return** +``__u32 nsid`` + Namespace ID, if applicable -The nvme command status if a response was received or -1 with errno - set otherwise. +``__u32 cdw11`` + Value to set the feature to +``__u32 cdw12`` + Feature specific command dword12 field -.. c:function:: int nvme_get_features_num_queues (int fd, enum nvme_get_features_sel sel, __u32 * result) +``bool save`` + Save value across power states +``__u8 uuidx`` + UUID Index for differentiating vendor specific encoding -**Parameters** +``__u32 cdw15`` + *undescribed* -``int fd`` - File descriptor of nvme device +``__u32 data_len`` + Length of feature data, if applicable, in bytes -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``void * data`` + User address of feature data, if applicable ``__u32 * result`` The command completion result from CQE dword0 @@ -2459,7 +2432,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_irq_coalesce (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_arbitration (int fd, __u8 ab, __u8 lpw, __u8 mpw, __u8 hpw, bool save, __u32 * result) **Parameters** @@ -2467,8 +2440,20 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u8 ab`` + *undescribed* + +``__u8 lpw`` + *undescribed* + +``__u8 mpw`` + *undescribed* + +``__u8 hpw`` + *undescribed* + +``bool save`` + Save value across power states ``__u32 * result`` The command completion result from CQE dword0 @@ -2479,7 +2464,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_irq_config (int fd, enum nvme_get_features_sel sel, __u16 iv, __u32 * result) +.. c:function:: int nvme_set_features_power_mgmt (int fd, __u8 ps, __u8 wh, bool save, __u32 * result) **Parameters** @@ -2487,12 +2472,15 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u8 ps`` + *undescribed* -``__u16 iv`` +``__u8 wh`` *undescribed* +``bool save`` + Save value across power states + ``__u32 * result`` The command completion result from CQE dword0 @@ -2502,7 +2490,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_write_atomic (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_lba_range (int fd, __u32 nsid, __u32 nr_ranges, bool save, struct nvme_lba_range_type * data, __u32 * result) **Parameters** @@ -2510,8 +2498,17 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u32 nsid`` + *undescribed* + +``__u32 nr_ranges`` + *undescribed* + +``bool save`` + Save value across power states + +``struct nvme_lba_range_type * data`` + *undescribed* ``__u32 * result`` The command completion result from CQE dword0 @@ -2522,27 +2519,21 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_async_event (int fd, enum nvme_get_features_sel sel, __u32 * result) - -**Parameters** -``int fd`` - File descriptor of nvme device +.. c:type:: enum nvme_feat_tmpthresh_thsel -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``__u32 * result`` - The command completion result from CQE dword0 +**Constants** -**Return** +``NVME_FEATURE_TEMPTHRESH_THSEL_OVER`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_FEATURETEMPTHRESH__THSEL_UNDER`` + *undescribed* -.. c:function:: int nvme_get_features_auto_pst (int fd, enum nvme_get_features_sel sel, struct nvme_feat_auto_pst * apst, __u32 * result) +.. c:function:: int nvme_set_features_temp_thresh (int fd, __u16 tmpth, __u8 tmpsel, enum nvme_feat_tmpthresh_thsel thsel, bool save, __u32 * result) **Parameters** @@ -2550,12 +2541,18 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u16 tmpth`` + *undescribed* -``struct nvme_feat_auto_pst * apst`` +``__u8 tmpsel`` + *undescribed* + +``enum nvme_feat_tmpthresh_thsel thsel`` *undescribed* +``bool save`` + Save value across power states + ``__u32 * result`` The command completion result from CQE dword0 @@ -2565,7 +2562,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_host_mem_buf (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_err_recovery (int fd, __u32 nsid, __u16 tler, bool dulbe, bool save, __u32 * result) **Parameters** @@ -2573,8 +2570,17 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u32 nsid`` + *undescribed* + +``__u16 tler`` + *undescribed* + +``bool dulbe`` + *undescribed* + +``bool save`` + Save value across power states ``__u32 * result`` The command completion result from CQE dword0 @@ -2585,7 +2591,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_timestamp (int fd, enum nvme_get_features_sel sel, struct nvme_timestamp * ts) +.. c:function:: int nvme_set_features_volatile_wc (int fd, bool wce, bool save, __u32 * result) **Parameters** @@ -2593,19 +2599,22 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` - -``struct nvme_timestamp * ts`` +``bool wce`` *undescribed* +``bool save`` + Save value across power states + +``__u32 * result`` + The command completion result from CQE dword0 + **Return** The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_kato (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_irq_coalesce (int fd, __u8 thr, __u8 time, bool save, __u32 * result) **Parameters** @@ -2613,8 +2622,14 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u8 thr`` + *undescribed* + +``__u8 time`` + *undescribed* + +``bool save`` + Save value across power states ``__u32 * result`` The command completion result from CQE dword0 @@ -2625,7 +2640,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_hctm (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_irq_config (int fd, __u16 iv, bool cd, bool save, __u32 * result) **Parameters** @@ -2633,8 +2648,14 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u16 iv`` + *undescribed* + +``bool cd`` + *undescribed* + +``bool save`` + Save value across power states ``__u32 * result`` The command completion result from CQE dword0 @@ -2645,7 +2666,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_nopsc (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_write_atomic (int fd, bool dn, bool save, __u32 * result) **Parameters** @@ -2653,8 +2674,11 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``bool dn`` + *undescribed* + +``bool save`` + Save value across power states ``__u32 * result`` The command completion result from CQE dword0 @@ -2665,53 +2689,57 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_rrl (int fd, enum nvme_get_features_sel sel, __u32 * result) -**Parameters** +.. c:type:: enum nvme_features_async_event_config_flags -``int fd`` - File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +**Constants** -``__u32 * result`` - The command completion result from CQE dword0 +``NVME_FEATURE_AENCFG_SMART_CRIT_SPARE`` + *undescribed* -**Return** +``NVME_FEATURE_AENCFG_SMART_CRIT_TEMPERATURE`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_FEATURE_AENCFG_SMART_CRIT_DEGRADED`` + *undescribed* +``NVME_FEATURE_AENCFG_SMART_CRIT_READ_ONLY`` + *undescribed* -.. c:function:: int nvme_get_features_plm_config (int fd, enum nvme_get_features_sel sel, __u16 nvmsetid, struct nvme_plm_config * data, __u32 * result) +``NVME_FEATURE_AENCFG_SMART_CRIT_VOLATILE_BACKUP`` + *undescribed* +``NVME_FEATURE_AENCFG_SMART_CRIT_READ_ONLY_PMR`` + *undescribed* -**Parameters** +``NVME_FEATURE_AENCFG_NOTICE_NAMESPACE_ATTRIBUTES`` + *undescribed* -``int fd`` - File descriptor of nvme device +``NVME_FEATURE_AENCFG_NOTICE_FIRMWARE_ACTIVATION`` + *undescribed* -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``NVME_FEATURE_AENCFG_NOTICE_TELEMETRY_LOG`` + *undescribed* -``__u16 nvmsetid`` +``NVME_FEATURE_AENCFG_NOTICE_ANA_CHANGE`` *undescribed* -``struct nvme_plm_config * data`` +``NVME_FEATURE_AENCFG_NOTICE_PL_EVENT`` *undescribed* -``__u32 * result`` - The command completion result from CQE dword0 +``NVME_FEATURE_AENCFG_NOTICE_LBA_STATUS`` + *undescribed* -**Return** +``NVME_FEATURE_AENCFG_NOTICE_EG_EVENT`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_FEATURE_AENCFG_NOTICE_DISCOVERY_CHANGE`` + *undescribed* -.. c:function:: int nvme_get_features_plm_window (int fd, enum nvme_get_features_sel sel, __u16 nvmsetid, __u32 * result) +.. c:function:: int nvme_set_features_async_event (int fd, __u32 events, bool save, __u32 * result) **Parameters** @@ -2719,13 +2747,13 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` - -``__u16 nvmsetid`` +``__u32 events`` *undescribed* -``__u32 * result`` +``bool save`` + Save value across power states + +``__u32 * result`` The command completion result from CQE dword0 **Return** @@ -2734,7 +2762,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_lba_sts_interval (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_auto_pst (int fd, bool apste, bool save, struct nvme_feat_auto_pst * apst, __u32 * result) **Parameters** @@ -2742,8 +2770,14 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``bool apste`` + *undescribed* + +``bool save`` + Save value across power states + +``struct nvme_feat_auto_pst * apst`` + *undescribed* ``__u32 * result`` The command completion result from CQE dword0 @@ -2754,7 +2788,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_host_behavior (int fd, enum nvme_get_features_sel sel, struct nvme_feat_host_behavior * data, __u32 * result) +.. c:function:: int nvme_set_features_timestamp (int fd, bool save, __u64 timestamp) **Parameters** @@ -2762,14 +2796,11 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` - -``struct nvme_feat_host_behavior * data`` - *undescribed* +``bool save`` + Save value across power states -``__u32 * result`` - The command completion result from CQE dword0 +``__u64 timestamp`` + The current timestamp value to assign to this this feature **Return** @@ -2777,7 +2808,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_sanitize (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_hctm (int fd, __u16 tmt2, __u16 tmt1, bool save, __u32 * result) **Parameters** @@ -2785,8 +2816,14 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u16 tmt2`` + *undescribed* + +``__u16 tmt1`` + *undescribed* + +``bool save`` + Save value across power states ``__u32 * result`` The command completion result from CQE dword0 @@ -2797,7 +2834,25 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_endurance_event_cfg (int fd, enum nvme_get_features_sel sel, __u16 endgid, __u32 * result) +.. c:function:: int nvme_set_features_nopsc (int fd, bool noppme, bool save, __u32 * result) + + +**Parameters** + +``int fd`` + *undescribed* + +``bool noppme`` + *undescribed* + +``bool save`` + *undescribed* + +``__u32 * result`` + *undescribed* + + +.. c:function:: int nvme_set_features_rrl (int fd, __u8 rrl, __u16 nvmsetid, bool save, __u32 * result) **Parameters** @@ -2805,12 +2860,15 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u8 rrl`` + *undescribed* -``__u16 endgid`` +``__u16 nvmsetid`` *undescribed* +``bool save`` + Save value across power states + ``__u32 * result`` The command completion result from CQE dword0 @@ -2820,7 +2878,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_sw_progress (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_plm_config (int fd, bool enable, __u16 nvmsetid, bool save, struct nvme_plm_config * data, __u32 * result) **Parameters** @@ -2828,8 +2886,17 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``bool enable`` + *undescribed* + +``__u16 nvmsetid`` + *undescribed* + +``bool save`` + Save value across power states + +``struct nvme_plm_config * data`` + *undescribed* ``__u32 * result`` The command completion result from CQE dword0 @@ -2840,7 +2907,21 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_host_id (int fd, enum nvme_get_features_sel sel, bool exhid, __u32 len, __u8 * hostid) + + +.. c:type:: enum nvme_feat_plm_window_select + + +**Constants** + +``NVME_FEATURE_PLM_DTWIN`` + *undescribed* + +``NVME_FEATURE_PLM_NDWIN`` + *undescribed* + + +.. c:function:: int nvme_set_features_plm_window (int fd, enum nvme_feat_plm_window_select sel, __u16 nvmsetid, bool save, __u32 * result) **Parameters** @@ -2848,17 +2929,17 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` - -``bool exhid`` +``enum nvme_feat_plm_window_select sel`` *undescribed* -``__u32 len`` +``__u16 nvmsetid`` *undescribed* -``__u8 * hostid`` - *undescribed* +``bool save`` + Save value across power states + +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -2866,7 +2947,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_resv_mask (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_lba_sts_interval (int fd, __u16 lsiri, __u16 lsipi, bool save, __u32 * result) **Parameters** @@ -2874,8 +2955,14 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u16 lsiri`` + *undescribed* + +``__u16 lsipi`` + *undescribed* + +``bool save`` + Save value across power states ``__u32 * result`` The command completion result from CQE dword0 @@ -2886,7 +2973,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_resv_persist (int fd, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_host_behavior (int fd, bool save, struct nvme_feat_host_behavior * data) **Parameters** @@ -2894,11 +2981,11 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``bool save`` + Save value across power states -``__u32 * result`` - The command completion result from CQE dword0 +``struct nvme_feat_host_behavior * data`` + *undescribed* **Return** @@ -2906,7 +2993,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_features_write_protect (int fd, __u32 nsid, enum nvme_get_features_sel sel, __u32 * result) +.. c:function:: int nvme_set_features_sanitize (int fd, bool nodrm, bool save, __u32 * result) **Parameters** @@ -2914,11 +3001,11 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID +``bool nodrm`` + *undescribed* -``enum nvme_get_features_sel sel`` - Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``bool save`` + Save value across power states ``__u32 * result`` The command completion result from CQE dword0 @@ -2929,43 +3016,25 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_format_nvm (int fd, __u32 nsid, __u8 lbaf, enum nvme_cmd_format_mset mset, enum nvme_cmd_format_pi pi, enum nvme_cmd_format_pil pil, enum nvme_cmd_format_ses ses, __u32 timeout) +.. c:function:: int nvme_set_features_endurance_evt_cfg (int fd, __u16 endgid, __u8 egwarn, bool save, __u32 * result) - Format nvme namespace(s) **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID to format - -``__u8 lbaf`` - Logical block address format - -``enum nvme_cmd_format_mset mset`` - Metadata settings (extended or separated), true if extended - -``enum nvme_cmd_format_pi pi`` - Protection information type - -``enum nvme_cmd_format_pil pil`` - Protection information location (beginning or end), true if end - -``enum nvme_cmd_format_ses ses`` - Secure erase settings +``__u16 endgid`` + *undescribed* -``__u32 timeout`` - Set to override default timeout to this value in milliseconds; - useful for long running formats. 0 will use system default. +``__u8 egwarn`` + Flags to enable warning, see :c:type:`enum nvme_eg_critical_warning_flags ` -**Description** +``bool save`` + Save value across power states -The Format NVM command is used to low level format the NVM media. This -command is used by the host to change the LBA data size and/or metadata -size. A low level format may destroy all data and metadata associated with -all namespaces or only the specific namespace associated with the command +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -2973,7 +3042,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_ns_mgmt (int fd, __u32 nsid, enum nvme_ns_mgmt_sel sel, struct nvme_id_ns * ns, __u32 * result, __u32 timeout) +.. c:function:: int nvme_set_features_sw_progress (int fd, __u8 pbslc, bool save, __u32 * result) **Parameters** @@ -2981,23 +3050,22 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - *undescribed* - -``enum nvme_ns_mgmt_sel sel`` +``__u8 pbslc`` *undescribed* -``struct nvme_id_ns * ns`` - *undescribed* +``bool save`` + Save value across power states ``__u32 * result`` - *undescribed* + The command completion result from CQE dword0 -``__u32 timeout`` - *undescribed* +**Return** + +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_ns_mgmt_create (int fd, struct nvme_id_ns * ns, __u32 * nsid, __u32 timeout) +.. c:function:: int nvme_set_features_host_id (int fd, bool exhid, bool save, __u8 * hostid) **Parameters** @@ -3005,21 +3073,14 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``struct nvme_id_ns * ns`` - Namespace identifiaction that defines creation parameters - -``__u32 * nsid`` - On success, set to the namespace id that was created - -``__u32 timeout`` - Overide the default timeout to this value in milliseconds; - set to 0 to use the system default. +``bool exhid`` + *undescribed* -**Description** +``bool save`` + Save value across power states -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. +``__u8 * hostid`` + *undescribed* **Return** @@ -3027,7 +3088,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_ns_mgmt_delete (int fd, __u32 nsid) +.. c:function:: int nvme_set_features_resv_mask (int fd, __u32 mask, bool save, __u32 * result) **Parameters** @@ -3035,14 +3096,14 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace identifier to delete +``__u32 mask`` + *undescribed* -**Description** +``bool save`` + Save value across power states -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. +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3050,87 +3111,65 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_ns_attach (int fd, __u32 nsid, enum nvme_ns_attach_sel sel, struct nvme_ctrl_list * ctrlist) +.. c:function:: int nvme_set_features_resv_persist (int fd, bool ptpl, bool save, __u32 * result) - Attach or detach namespace to controller(s) **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID to execute attach selection +``bool ptpl`` + *undescribed* -``enum nvme_ns_attach_sel sel`` - Attachment selection, see :c:type:`enum nvme_ns_attach_sel ` +``bool save`` + Save value across power states -``struct nvme_ctrl_list * ctrlist`` - Controller list to modify attachment state of nsid +``__u32 * result`` + The command completion result from CQE dword0 +**Return** -.. c:function:: int nvme_ns_attach_ctrls (int fd, __u32 nsid, struct nvme_ctrl_list * ctrlist) +The nvme command status if a response was received or -1 with errno + set otherwise. -**Parameters** - -``int fd`` - File descriptor of nvme device -``__u32 nsid`` - Namespace ID to attach - -``struct nvme_ctrl_list * ctrlist`` - Controller list to modify attachment state of nsid +.. c:type:: enum nvme_feat_nswpcfg_state -.. c:function:: int nvme_ns_dettach_ctrls (int fd, __u32 nsid, struct nvme_ctrl_list * ctrlist) +**Constants** -**Parameters** +``NVME_FEAT_NS_NO_WRITE_PROTECT`` + *undescribed* -``int fd`` - File descriptor of nvme device +``NVME_FEAT_NS_WRITE_PROTECT`` + *undescribed* -``__u32 nsid`` - Namespace ID to dettach +``NVME_FEAT_NS_WRITE_PROTECT_PWR_CYCLE`` + *undescribed* -``struct nvme_ctrl_list * ctrlist`` - Controller list to modify attachment state of nsid +``NVME_FEAT_NS_WRITE_PROTECT_PERMANENT`` + *undescribed* -.. c:function:: int nvme_fw_download (int fd, __u32 offset, __u32 data_len, void * data) +.. c:function:: int nvme_set_features_write_protect (int fd, enum nvme_feat_nswpcfg_state state, bool save, __u32 * result) - Download part or all of a firmware image to the controller **Parameters** ``int fd`` File descriptor of nvme device -``__u32 offset`` - Offset in the firmware data - -``__u32 data_len`` - Length of data in this command in bytes - -``void * data`` - Userspace address of the firmware data - -**Description** - -The Firmware Image Download command is used to download all or a portion of -an image for a future update to the controller. The Firmware Image Download -command downloads a new image (in whole or in part) to the controller. +``enum nvme_feat_nswpcfg_state state`` + *undescribed* -The image may be constructed of multiple pieces that are individually -downloaded with separate Firmware Image Download commands. Each Firmware -Image Download command includes a Dword Offset and Number of Dwords that -specify a dword range. +``bool save`` + Save value across power states -The new firmware image is not activated as part of the Firmware Image -Download command. Use the nvme_fw_commit() to activate a newly downloaded -image. +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3138,37 +3177,46 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_fw_commit (int fd, __u8 slot, enum nvme_fw_commit_ca action, bool bpid) +.. c:function:: int nvme_get_features (int fd, enum nvme_features_id fid, __u32 nsid, enum nvme_get_features_sel sel, __u32 cdw11, __u8 uuidx, __u32 data_len, void * data, __u32 * result) - Commit firmware using the specified action + Retrieve a feature attribute **Parameters** ``int fd`` File descriptor of nvme device -``__u8 slot`` - Firmware slot to commit the downloaded image +``enum nvme_features_id fid`` + Feature identifier -``enum nvme_fw_commit_ca action`` - Action to use for the firmware image, see :c:type:`enum nvme_fw_commit_ca ` +``__u32 nsid`` + Namespace ID, if applicable -``bool bpid`` - Set to true to select the boot partition id +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -**Description** +``__u32 cdw11`` + Feature specific command dword11 field -The Firmware Commit command is used to modify the firmware image or Boot -Partitions. +``__u8 uuidx`` + UUID Index for differentiating vendor specific encoding + +``__u32 data_len`` + Length of feature data, if applicable, in bytes + +``void * data`` + User address of feature data, if applicable + +``__u32 * result`` + The command completion result from CQE dword0 **Return** The nvme command status if a response was received or -1 with errno - set otherwise. The command status response may specify additional - reset actions required to complete the commit process. + set otherwise. -.. c:function:: int nvme_security_send (int fd, __u32 nsid, __u8 nssf, __u8 spsp0, __u8 spsp1, __u8 secp, __u32 tl, __u32 data_len, void * data, __u32 * result) +.. c:function:: int nvme_get_features_arbitration (int fd, enum nvme_get_features_sel sel, __u32 * result) **Parameters** @@ -3176,51 +3224,19 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID to issue security command on - -``__u8 nssf`` - NVMe Security Specific field - -``__u8 spsp0`` - Security Protocol Specific field - -``__u8 spsp1`` - Security Protocol Specific field - -``__u8 secp`` - Security Protocol - -``__u32 tl`` - Protocol specific transfer length - -``__u32 data_len`` - Data length of the payload in bytes - -``void * data`` - Security data payload to send +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` ``__u32 * result`` The command completion result from CQE dword0 -**Description** - -The Security Send command is used to transfer 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 or -1 with errno set otherwise. -.. c:function:: int nvme_security_receive (int fd, __u32 nsid, __u8 nssf, __u8 spsp0, __u8 spsp1, __u8 secp, __u32 al, __u32 data_len, void * data, __u32 * result) +.. c:function:: int nvme_get_features_power_mgmt (int fd, enum nvme_get_features_sel sel, __u32 * result) **Parameters** @@ -3228,29 +3244,8 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID to issue security command on - -``__u8 nssf`` - NVMe Security Specific field - -``__u8 spsp0`` - Security Protocol Specific field - -``__u8 spsp1`` - Security Protocol Specific field - -``__u8 secp`` - Security Protocol - -``__u32 al`` - Protocol specific allocation length - -``__u32 data_len`` - Data length of the payload in bytes - -``void * data`` - Security data payload to send +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` ``__u32 * result`` The command completion result from CQE dword0 @@ -3261,38 +3256,22 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_lba_status (int fd, __u32 nsid, __u64 slba, __u32 mndw, __u16 rl, enum nvme_lba_status_atype atype, struct nvme_lba_status * lbas) +.. c:function:: int nvme_get_features_lba_range (int fd, enum nvme_get_features_sel sel, struct nvme_lba_range_type * data, __u32 * result) - Retrieve information on possibly unrecoverable LBAs **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID to retrieve LBA status - -``__u64 slba`` - Starting logical block address to check statuses - -``__u32 mndw`` - Maximum number of dwords to return - -``__u16 rl`` - Range length from slba to perform the action - -``enum nvme_lba_status_atype atype`` - Action type mechanism to determine LBA status desctriptors to - return, see :c:type:`enum nvme_lba_status_atype ` - -``struct nvme_lba_status * lbas`` - Data payload to return status descriptors +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -**Description** +``struct nvme_lba_range_type * data`` + *undescribed* -The Get LBA Status command requests information about Potentially -Unrecoverable LBAs. Refer to the specification for action type descriptions. +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3300,46 +3279,19 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_directive_send (int fd, __u32 nsid, __u16 dspec, __u8 doper, enum nvme_directive_dtype dtype, __u32 cdw12, __u32 data_len, void * data, __u32 * result) +.. c:function:: int nvme_get_features_temp_thresh (int fd, enum nvme_get_features_sel sel, __u32 * result) - Send directive command **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID, if applicable - -``__u16 dspec`` - Directive specific field - -``__u8 doper`` - Directive operation - -``enum nvme_directive_dtype dtype`` - Directive type, see :c:type:`enum nvme_directive_dtype ` - -``__u32 cdw12`` - *undescribed* - -``__u32 data_len`` - Length of data payload in bytes - -``void * data`` - Usespace address of data payload +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` ``__u32 * result`` - If successful, the CQE dword0 value - -**Description** - -Directives is a mechanism to enable host and NVM subsystem or controller -information exchange. The Directive Send command is used to transfer data -related to a specific Directive Type from the host to the controller. - -See the NVMe specification for more information. + The command completion result from CQE dword0 **Return** @@ -3347,7 +3299,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_directive_send_id_endir (int fd, __u32 nsid, bool endir, enum nvme_directive_dtype dtype, struct nvme_id_directives * id) +.. c:function:: int nvme_get_features_err_recovery (int fd, enum nvme_get_features_sel sel, __u32 * result) **Parameters** @@ -3355,17 +3307,11 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID - -``bool endir`` - *undescribed* - -``enum nvme_directive_dtype dtype`` - *undescribed* +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``struct nvme_id_directives * id`` - *undescribed* +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3373,7 +3319,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_directive_send_stream_release_identifier (int fd, __u32 nsid, __u16 stream_id) +.. c:function:: int nvme_get_features_volatile_wc (int fd, enum nvme_get_features_sel sel, __u32 * result) **Parameters** @@ -3381,11 +3327,11 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``__u16 stream_id`` - *undescribed* +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3393,7 +3339,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_directive_send_stream_release_resource (int fd, __u32 nsid) +.. c:function:: int nvme_get_features_num_queues (int fd, enum nvme_get_features_sel sel, __u32 * result) **Parameters** @@ -3401,8 +3347,11 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` + +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3410,38 +3359,42 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_directive_recv (int fd, __u32 nsid, __u16 dspec, __u8 doper, enum nvme_directive_dtype dtype, __u32 cdw12, __u32 data_len, void * data, __u32 * result) +.. c:function:: int nvme_get_features_irq_coalesce (int fd, enum nvme_get_features_sel sel, __u32 * result) - Receive directive specific data **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID, if applicable +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``__u16 dspec`` - Directive specific field +``__u32 * result`` + The command completion result from CQE dword0 -``__u8 doper`` - Directive operation +**Return** -``enum nvme_directive_dtype dtype`` - Directive type, see :c:type:`enum nvme_directive_dtype ` +The nvme command status if a response was received or -1 with errno + set otherwise. -``__u32 cdw12`` - *undescribed* -``__u32 data_len`` - Length of data payload +.. c:function:: int nvme_get_features_irq_config (int fd, enum nvme_get_features_sel sel, __u16 iv, __u32 * result) -``void * data`` - Usespace address of data payload in bytes + +**Parameters** + +``int fd`` + File descriptor of nvme device + +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` + +``__u16 iv`` + *undescribed* ``__u32 * result`` - If successful, the CQE dword0 value + The command completion result from CQE dword0 **Return** @@ -3449,7 +3402,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_directive_recv_identify_parameters (int fd, __u32 nsid, struct nvme_id_directives * id) +.. c:function:: int nvme_get_features_write_atomic (int fd, enum nvme_get_features_sel sel, __u32 * result) **Parameters** @@ -3457,11 +3410,11 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``struct nvme_id_directives * id`` - *undescribed* +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3469,7 +3422,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_directive_recv_stream_parameters (int fd, __u32 nsid, struct nvme_streams_directive_params * parms) +.. c:function:: int nvme_get_features_async_event (int fd, enum nvme_get_features_sel sel, __u32 * result) **Parameters** @@ -3477,11 +3430,11 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``struct nvme_streams_directive_params * parms`` - *undescribed* +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3489,7 +3442,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_directive_recv_stream_status (int fd, __u32 nsid, unsigned nr_entries, struct nvme_streams_directive_status * id) +.. c:function:: int nvme_get_features_auto_pst (int fd, enum nvme_get_features_sel sel, struct nvme_feat_auto_pst * apst, __u32 * result) **Parameters** @@ -3497,14 +3450,14 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``unsigned nr_entries`` +``struct nvme_feat_auto_pst * apst`` *undescribed* -``struct nvme_streams_directive_status * id`` - *undescribed* +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3512,7 +3465,7 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_directive_recv_stream_allocate (int fd, __u32 nsid, __u16 nsr, __u32 * result) +.. c:function:: int nvme_get_features_host_mem_buf (int fd, enum nvme_get_features_sel sel, __u32 * result) **Parameters** @@ -3520,14 +3473,11 @@ The nvme command status if a response was received or -1 with errno ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID - -``__u16 nsr`` - *undescribed* +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` ``__u32 * result`` - *undescribed* + The command completion result from CQE dword0 **Return** @@ -3535,51 +3485,39 @@ The nvme command status if a response was received or -1 with errno set otherwise. +.. c:function:: int nvme_get_features_timestamp (int fd, enum nvme_get_features_sel sel, struct nvme_timestamp * ts) -.. c:type:: enum nvme_fctype - - -**Constants** - -``nvme_fabrics_type_property_set`` - *undescribed* +**Parameters** -``nvme_fabrics_type_connect`` - *undescribed* +``int fd`` + File descriptor of nvme device -``nvme_fabrics_type_property_get`` - *undescribed* +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``nvme_fabrics_type_auth_send`` +``struct nvme_timestamp * ts`` *undescribed* -``nvme_fabrics_type_auth_receive`` - *undescribed* +**Return** -``nvme_fabrics_type_disconnect`` - *undescribed* +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_set_property (int fd, int offset, __u64 value) +.. c:function:: int nvme_get_features_kato (int fd, enum nvme_get_features_sel sel, __u32 * result) - Set controller property **Parameters** ``int fd`` File descriptor of nvme device -``int offset`` - Property offset from the base to set - -``__u64 value`` - The value to set the property - -**Description** +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -This is an NVMe-over-Fabrics specific command, not applicable to PCIe. These -properties align to the PCI MMIO controller registers. +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3587,25 +3525,19 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_get_property (int fd, int offset, __u64 * value) +.. c:function:: int nvme_get_features_hctm (int fd, enum nvme_get_features_sel sel, __u32 * result) - Get a controller property **Parameters** ``int fd`` File descriptor of nvme device -``int offset`` - Property offset from the base to retrieve - -``__u64 * value`` - Where the property's value will be stored on success - -**Description** +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -This is an NVMe-over-Fabrics specific command, not applicable to PCIe. These -properties align to the PCI MMIO controller registers. +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3613,44 +3545,39 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_sanitize_nvm (int fd, enum nvme_sanitize_sanact sanact, bool ause, __u8 owpass, bool oipbp, bool nodas, __u32 ovrpat) +.. c:function:: int nvme_get_features_nopsc (int fd, enum nvme_get_features_sel sel, __u32 * result) - Start a sanitize operation **Parameters** ``int fd`` File descriptor of nvme device -``enum nvme_sanitize_sanact sanact`` - Sanitize action, see :c:type:`enum nvme_sanitize_sanact ` +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``bool ause`` - Set to allow unrestriced sanitize exit +``__u32 * result`` + The command completion result from CQE dword0 -``__u8 owpass`` - Overwrite pass count +**Return** -``bool oipbp`` - Set to overwrite invert pattern between passes +The nvme command status if a response was received or -1 with errno + set otherwise. -``bool nodas`` - Set to not deallocate blocks after sanitizing -``__u32 ovrpat`` - Overwrite pattern +.. c:function:: int nvme_get_features_rrl (int fd, enum nvme_get_features_sel sel, __u32 * result) -**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. +**Parameters** -The Sanitize command is used to start 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. +``int fd`` + File descriptor of nvme device + +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` + +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3658,33 +3585,25 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_dev_self_test (int fd, __u32 nsid, enum nvme_dst_stc stc) +.. c:function:: int nvme_get_features_plm_config (int fd, enum nvme_get_features_sel sel, __u16 nvmsetid, struct nvme_plm_config * data, __u32 * result) - Start or abort a self test **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID to test - -``enum nvme_dst_stc stc`` - Self test code, see :c:type:`enum nvme_dst_stc ` +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -**Description** +``__u16 nvmsetid`` + *undescribed* -The Device Self-test command is used to start a device self-test operation -or abort a device self-test operation. A device self-test operation is a -diagnostic testing sequence that tests the integrity and functionality of -the controller and may include testing of the media associated with -namespaces. The controller may return a response to this command immediately -while running the self-test in the background. +``struct nvme_plm_config * data`` + *undescribed* -Set the 'nsid' field to 0 to not include namepsaces in the test. Set to -0xffffffff to test all namespaces. All other values tests a specific -namespace, if present. +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3692,109 +3611,85 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_virtual_mgmt (int fd, enum nvme_virt_mgmt_act act, enum nvme_virt_mgmt_rt rt, __u16 cntlid, __u16 nr, __u32 * result) +.. c:function:: int nvme_get_features_plm_window (int fd, enum nvme_get_features_sel sel, __u16 nvmsetid, __u32 * result) - Virtualization resource management **Parameters** ``int fd`` File descriptor of nvme device -``enum nvme_virt_mgmt_act act`` - Virtual resource action, see :c:type:`enum nvme_virt_mgmt_act ` - -``enum nvme_virt_mgmt_rt rt`` - Resource type to modify, see :c:type:`enum nvme_virt_mgmt_rt ` - -``__u16 cntlid`` - Controller id for which resources are bing modified +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``__u16 nr`` - Number of resources being allocated or assigned +``__u16 nvmsetid`` + *undescribed* ``__u32 * result`` - If successful, the CQE dword0 - -**Description** + The command completion result from CQE dword0 -The Virtualization Management command is supported by primary controllers -that support the Virtualization Enhancements capability. This command is -used for several functions: +**Return** - - Modifying Flexible Resource allocation for the primary controller - - Assigning Flexible Resources for secondary controllers - - Setting the Online and Offline state for secondary controllers +The nvme command status if a response was received or -1 with errno + set otherwise. -**Return** -The nvme command status if a response was received or -1 - with errno set otherwise. +.. c:function:: int nvme_get_features_lba_sts_interval (int fd, enum nvme_get_features_sel sel, __u32 * result) -**NVMe IO command** +**Parameters** +``int fd`` + File descriptor of nvme device +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u32 * result`` + The command completion result from CQE dword0 -.. c:type:: enum nvme_io_opcode +**Return** +The nvme command status if a response was received or -1 with errno + set otherwise. -**Constants** -``nvme_cmd_flush`` - *undescribed* +.. c:function:: int nvme_get_features_host_behavior (int fd, enum nvme_get_features_sel sel, struct nvme_feat_host_behavior * data, __u32 * result) -``nvme_cmd_write`` - *undescribed* -``nvme_cmd_read`` - *undescribed* +**Parameters** -``nvme_cmd_write_uncor`` - *undescribed* - -``nvme_cmd_compare`` - *undescribed* - -``nvme_cmd_write_zeroes`` - *undescribed* - -``nvme_cmd_dsm`` - *undescribed* +``int fd`` + File descriptor of nvme device -``nvme_cmd_verify`` - *undescribed* +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``nvme_cmd_resv_register`` +``struct nvme_feat_host_behavior * data`` *undescribed* -``nvme_cmd_resv_report`` - *undescribed* +``__u32 * result`` + The command completion result from CQE dword0 -``nvme_cmd_resv_acquire`` - *undescribed* +**Return** -``nvme_cmd_resv_release`` - *undescribed* +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_flush (int fd, __u32 nsid) +.. c:function:: int nvme_get_features_sanitize (int fd, enum nvme_get_features_sel sel, __u32 * result) - Send an nvme flush command **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace identifier - -**Description** +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -The Flush command is used to request that the contents of volatile write -cache be made non-volatile. +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3802,142 +3697,131 @@ The nvme command status if a response was received or -1 with errno set otherwise. +.. c:function:: int nvme_get_features_endurance_event_cfg (int fd, enum nvme_get_features_sel sel, __u16 endgid, __u32 * result) -.. c:type:: enum nvme_io_control_flags +**Parameters** +``int fd`` + File descriptor of nvme device -**Constants** +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``NVME_IO_DTYPE_STREAMS`` +``__u16 endgid`` *undescribed* -``NVME_IO_DEAC`` - *undescribed* +``__u32 * result`` + The command completion result from CQE dword0 -``NVME_IO_PRINFO_PRCHK_REF`` - *undescribed* +**Return** -``NVME_IO_PRINFO_PRCHK_APP`` - *undescribed* +The nvme command status if a response was received or -1 with errno + set otherwise. -``NVME_IO_PRINFO_PRCHK_GUARD`` - *undescribed* -``NVME_IO_PRINFO_PRACT`` - *undescribed* +.. c:function:: int nvme_get_features_sw_progress (int fd, enum nvme_get_features_sel sel, __u32 * result) -``NVME_IO_FUA`` - *undescribed* -``NVME_IO_LR`` - *undescribed* +**Parameters** +``int fd`` + File descriptor of nvme device +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` +``__u32 * result`` + The command completion result from CQE dword0 -.. c:type:: enum nvme_io_dsm_flags +**Return** +The nvme command status if a response was received or -1 with errno + set otherwise. -**Constants** -``NVME_IO_DSM_FREQ_UNSPEC`` - *undescribed* +.. c:function:: int nvme_get_features_host_id (int fd, enum nvme_get_features_sel sel, bool exhid, __u32 len, __u8 * hostid) -``NVME_IO_DSM_FREQ_TYPICAL`` - *undescribed* -``NVME_IO_DSM_FREQ_RARE`` - *undescribed* +**Parameters** -``NVME_IO_DSM_FREQ_READS`` - *undescribed* +``int fd`` + File descriptor of nvme device -``NVME_IO_DSM_FREQ_WRITES`` - *undescribed* +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``NVME_IO_DSM_FREQ_RW`` +``bool exhid`` *undescribed* -``NVME_IO_DSM_FREQ_ONCE`` +``__u32 len`` *undescribed* -``NVME_IO_DSM_FREQ_PREFETCH`` +``__u8 * hostid`` *undescribed* -``NVME_IO_DSM_FREQ_TEMP`` - *undescribed* +**Return** -``NVME_IO_DSM_LATENCY_NONE`` - *undescribed* +The nvme command status if a response was received or -1 with errno + set otherwise. -``NVME_IO_DSM_LATENCY_IDLE`` - *undescribed* -``NVME_IO_DSM_LATENCY_NORM`` - *undescribed* +.. c:function:: int nvme_get_features_resv_mask (int fd, enum nvme_get_features_sel sel, __u32 * result) -``NVME_IO_DSM_LATENCY_LOW`` - *undescribed* -``NVME_IO_DSM_SEQ_REQ`` - *undescribed* +**Parameters** -``NVME_IO_DSM_COMPRESSED`` - *undescribed* +``int fd`` + File descriptor of nvme device +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -.. c:function:: int nvme_read (int fd, __u32 nsid, __u64 slba, __u16 nlb, __u16 control, __u8 dsm, __u32 reftag, __u16 apptag, __u16 appmask, __u32 data_len, void * data, __u32 metadata_len, void * metadata) +``__u32 * result`` + The command completion result from CQE dword0 + +**Return** + +The nvme command status if a response was received or -1 with errno + set otherwise. + + +.. c:function:: int nvme_get_features_resv_persist (int fd, enum nvme_get_features_sel sel, __u32 * result) - Submit an nvme user read command **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace ID +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``__u64 slba`` - Starting logical block +``__u32 * result`` + The command completion result from CQE dword0 -``__u16 nlb`` - *undescribed* +**Return** -``__u16 control`` - Command control flags, see :c:type:`enum nvme_io_control_flags `. +The nvme command status if a response was received or -1 with errno + set otherwise. -``__u8 dsm`` - Data set management attributes, see :c:type:`enum nvme_io_dsm_flags ` -``__u32 reftag`` - This field specifies the Initial Logical Block Reference Tag - expected value. Used only if the namespace is formatted to use - end-to-end protection information. +.. c:function:: int nvme_get_features_write_protect (int fd, __u32 nsid, enum nvme_get_features_sel sel, __u32 * result) -``__u16 apptag`` - This field specifies the Application Tag Mask expected value. - Used only if the namespace is formatted to use end-to-end - protection information. -``__u16 appmask`` - This field specifies the Application Tag expected value. Used - only if the namespace is formatted to use end-to-end protection - information. +**Parameters** -``__u32 data_len`` - Length of user buffer, **data**, in bytes +``int fd`` + File descriptor of nvme device -``void * data`` - Pointer to user address of the data buffer - metadata_len:Length of user buffer, **metadata**, in bytes +``__u32 nsid`` + Namespace ID -``__u32 metadata_len`` - *undescribed* +``enum nvme_get_features_sel sel`` + Select which type of attribute to return, see :c:type:`enum nvme_get_features_sel ` -``void * metadata`` - Pointer to user address of the metadata buffer +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -3945,9 +3829,9 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_write (int fd, __u32 nsid, __u64 slba, __u16 nlb, __u16 control, __u8 dsm, __u16 dspec, __u32 reftag, __u16 apptag, __u16 appmask, __u32 data_len, void * data, __u32 metadata_len, void * metadata) +.. c:function:: int nvme_format_nvm (int fd, __u32 nsid, __u8 lbaf, enum nvme_cmd_format_mset mset, enum nvme_cmd_format_pi pi, enum nvme_cmd_format_pil pil, enum nvme_cmd_format_ses ses, __u32 timeout) - Submit an nvme user write command + Format nvme namespace(s) **Parameters** @@ -3955,50 +3839,33 @@ The nvme command status if a response was received or -1 with errno File descriptor of nvme device ``__u32 nsid`` - Namespace ID - -``__u64 slba`` - Starting logical block - -``__u16 nlb`` - *undescribed* - -``__u16 control`` - Command control flags, see :c:type:`enum nvme_io_control_flags `. - -``__u8 dsm`` - Data set management attributes, see :c:type:`enum nvme_io_dsm_flags ` + Namespace ID to format -``__u16 dspec`` - Directive specific command, eg: stream identifier +``__u8 lbaf`` + Logical block address format -``__u32 reftag`` - This field specifies the Initial Logical Block Reference Tag - expected value. Used only if the namespace is formatted to use - end-to-end protection information. +``enum nvme_cmd_format_mset mset`` + Metadata settings (extended or separated), true if extended -``__u16 apptag`` - This field specifies the Application Tag Mask expected value. - Used only if the namespace is formatted to use end-to-end - protection information. +``enum nvme_cmd_format_pi pi`` + Protection information type -``__u16 appmask`` - This field specifies the Application Tag expected value. Used - only if the namespace is formatted to use end-to-end protection - information. +``enum nvme_cmd_format_pil pil`` + Protection information location (beginning or end), true if end -``__u32 data_len`` - Length of user buffer, **data**, in bytes +``enum nvme_cmd_format_ses ses`` + Secure erase settings -``void * data`` - Pointer to user address of the data buffer - metadata_len:Length of user buffer, **metadata**, in bytes +``__u32 timeout`` + Set to override default timeout to this value in milliseconds; + useful for long running formats. 0 will use system default. -``__u32 metadata_len`` - *undescribed* +**Description** -``void * metadata`` - Pointer to user address of the metadata buffer +The Format NVM command is used to low level format the NVM media. This +command is used by the host to change the LBA data size and/or metadata +size. A low level format may destroy all data and metadata associated with +all namespaces or only the specific namespace associated with the command **Return** @@ -4006,9 +3873,8 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_compare (int fd, __u32 nsid, __u64 slba, __u16 nlb, __u16 control, __u32 reftag, __u16 apptag, __u16 appmask, __u32 data_len, void * data, __u32 metadata_len, void * metadata) +.. c:function:: int nvme_ns_mgmt (int fd, __u32 nsid, enum nvme_ns_mgmt_sel sel, struct nvme_id_ns * ns, __u32 * result, __u32 timeout) - Submit an nvme user compare command **Parameters** @@ -4016,93 +3882,44 @@ The nvme command status if a response was received or -1 with errno File descriptor of nvme device ``__u32 nsid`` - Namespace ID + *undescribed* -``__u64 slba`` - Starting logical block - -``__u16 nlb`` +``enum nvme_ns_mgmt_sel sel`` *undescribed* -``__u16 control`` - Command control flags, see :c:type:`enum nvme_io_control_flags `. - -``__u32 reftag`` - This field specifies the Initial Logical Block Reference Tag - expected value. Used only if the namespace is formatted to use - end-to-end protection information. - -``__u16 apptag`` - This field specifies the Application Tag Mask expected value. - Used only if the namespace is formatted to use end-to-end - protection information. - -``__u16 appmask`` - This field specifies the Application Tag expected value. Used - only if the namespace is formatted to use end-to-end protection - information. - -``__u32 data_len`` - Length of user buffer, **data**, in bytes - -``void * data`` - Pointer to user address of the data buffer - metadata_len:Length of user buffer, **metadata**, in bytes - -``__u32 metadata_len`` +``struct nvme_id_ns * ns`` *undescribed* -``void * metadata`` - Pointer to user address of the metadata buffer - -**Return** +``__u32 * result`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``__u32 timeout`` + *undescribed* -.. c:function:: int nvme_write_zeros (int fd, __u32 nsid, __u64 slba, __u16 nlb, __u16 control, __u32 reftag, __u16 apptag, __u16 appmask) +.. c:function:: int nvme_ns_mgmt_create (int fd, struct nvme_id_ns * ns, __u32 * nsid, __u32 timeout) - Submit an nvme write zeroes command **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace identifier - -``__u64 slba`` - Starting logical block - -``__u16 nlb`` - Number of logical blocks to clear (0's based value) - -``__u16 control`` - Command control flags, see :c:type:`enum nvme_io_control_flags `. - -``__u32 reftag`` - This field specifies the Initial Logical Block Reference Tag - expected value. Used only if the namespace is formatted to use - end-to-end protection information. +``struct nvme_id_ns * ns`` + Namespace identifiaction that defines creation parameters -``__u16 apptag`` - This field specifies the Application Tag Mask expected value. - Used only if the namespace is formatted to use end-to-end - protection information. +``__u32 * nsid`` + On success, set to the namespace id that was created -``__u16 appmask`` - This field specifies the Application Tag expected value. Used - only if the namespace is formatted to use end-to-end protection - information. +``__u32 timeout`` + Overide the default timeout to this value in milliseconds; + set to 0 to use the system default. **Description** -The Write Zeroes command is used to set a range of logical blocks to zero. -After successful completion of this command, the value returned by -subsequent reads of logical blocks in this range shall be all bytes cleared -to 0h until a write occurs to this LBA range. +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** @@ -4110,9 +3927,8 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_write_uncorrectable (int fd, __u32 nsid, __u64 slba, __u16 nlb) +.. c:function:: int nvme_ns_mgmt_delete (int fd, __u32 nsid) - Submit an nvme write uncorrectable command **Parameters** @@ -4120,21 +3936,13 @@ The nvme command status if a response was received or -1 with errno File descriptor of nvme device ``__u32 nsid`` - Namespace identifier - -``__u64 slba`` - Starting logical block - -``__u16 nlb`` - Number of logical blocks to invalidate (0's based value) + Namespace identifier to delete **Description** -The Write Uncorrectable command is used to mark a range of logical blocks as -invalid. When the specified logical block(s) are read after this operation, -a failure is returned with Unrecovered Read Error status. To clear the -invalid logical block status, a write operation on those logical blocks is -required. +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** @@ -4142,9 +3950,9 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_verify (int fd, __u32 nsid, __u64 slba, __u16 nlb, __u16 control, __u32 reftag, __u16 apptag, __u16 appmask) +.. c:function:: int nvme_ns_attach (int fd, __u32 nsid, enum nvme_ns_attach_sel sel, struct nvme_ctrl_list * ctrlist) - Send an nvme verify command + Attach or detach namespace to controller(s) **Parameters** @@ -4152,90 +3960,77 @@ The nvme command status if a response was received or -1 with errno File descriptor of nvme device ``__u32 nsid`` - Namespace identifier - -``__u64 slba`` - Starting logical block - -``__u16 nlb`` - Number of logical blocks to verify (0's based value) - -``__u16 control`` - Command control flags, see :c:type:`enum nvme_io_control_flags `. + Namespace ID to execute attach selection -``__u32 reftag`` - This field specifies the Initial Logical Block Reference Tag - expected value. Used only if the namespace is formatted to use - end-to-end protection information. +``enum nvme_ns_attach_sel sel`` + Attachment selection, see :c:type:`enum nvme_ns_attach_sel ` -``__u16 apptag`` - This field specifies the Application Tag Mask expected value. - Used only if the namespace is formatted to use end-to-end - protection information. +``struct nvme_ctrl_list * ctrlist`` + Controller list to modify attachment state of nsid -``__u16 appmask`` - This field specifies the Application Tag expected value. Used - only if the namespace is formatted to use end-to-end protection - information. -**Description** +.. c:function:: int nvme_ns_attach_ctrls (int fd, __u32 nsid, struct nvme_ctrl_list * ctrlist) -The Verify command verifies integrity of stored information by reading data -and metadata, if applicable, for the LBAs indicated without transferring any -data or metadata to the host. -**Return** +**Parameters** -The nvme command status if a response was received or -1 with errno - set otherwise. +``int fd`` + File descriptor of nvme device +``__u32 nsid`` + Namespace ID to attach +``struct nvme_ctrl_list * ctrlist`` + Controller list to modify attachment state of nsid -.. c:type:: enum nvme_dsm_attributes +.. c:function:: int nvme_ns_dettach_ctrls (int fd, __u32 nsid, struct nvme_ctrl_list * ctrlist) -**Constants** +**Parameters** -``NVME_DSMGMT_IDR`` - *undescribed* +``int fd`` + File descriptor of nvme device -``NVME_DSMGMT_IDW`` - *undescribed* +``__u32 nsid`` + Namespace ID to dettach -``NVME_DSMGMT_AD`` - *undescribed* +``struct nvme_ctrl_list * ctrlist`` + Controller list to modify attachment state of nsid -.. c:function:: int nvme_dsm (int fd, __u32 nsid, __u32 attrs, __u16 nr_ranges, struct nvme_dsm_range * dsm) +.. c:function:: int nvme_fw_download (int fd, __u32 offset, __u32 data_len, void * data) - Send an nvme data set management command + Download part or all of a firmware image to the controller **Parameters** ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace identifier - -``__u32 attrs`` - DSM attributes, see :c:type:`enum nvme_dsm_attributes ` - :c:type:`nr_ranges`: Number of block ranges in the data set management attributes +``__u32 offset`` + Offset in the firmware data -``__u16 nr_ranges`` - *undescribed* +``__u32 data_len`` + Length of data in this command in bytes -``struct nvme_dsm_range * dsm`` - The data set management attributes +``void * data`` + Userspace address of the firmware data **Description** -The Dataset Management command is used by the host to indicate attributes -for ranges of logical blocks. This includes attributes like frequency that -data is read or written, access size, and other information that may be used -to optimize performance and reliability, and may be used to -deallocate/unmap/trim those logical blocks. +The Firmware Image Download command is used to download all or a portion of +an image for a future update to the controller. The Firmware Image Download +command downloads a new image (in whole or in part) to the controller. + +The image may be constructed of multiple pieces that are individually +downloaded with separate Firmware Image Download commands. Each Firmware +Image Download command includes a Dword Offset and Number of Dwords that +specify a dword range. + +The new firmware image is not activated as part of the Firmware Image +Download command. Use the nvme_fw_commit() to activate a newly downloaded +image. **Return** @@ -4243,52 +4038,90 @@ The nvme command status if a response was received or -1 with errno set otherwise. +.. c:function:: int nvme_fw_commit (int fd, __u8 slot, enum nvme_fw_commit_ca action, bool bpid) + Commit firmware using the specified action -.. c:type:: enum nvme_reservation_rtype +**Parameters** +``int fd`` + File descriptor of nvme device -**Constants** +``__u8 slot`` + Firmware slot to commit the downloaded image -``NVME_RESERVATION_RTYPE_WE`` - *undescribed* +``enum nvme_fw_commit_ca action`` + Action to use for the firmware image, see :c:type:`enum nvme_fw_commit_ca ` -``NVME_RESERVATION_RTYPE_EA`` - *undescribed* +``bool bpid`` + Set to true to select the boot partition id -``NVME_RESERVATION_RTYPE_WERO`` - *undescribed* +**Description** -``NVME_RESERVATION_RTYPE_EARO`` - *undescribed* +The Firmware Commit command is used to modify the firmware image or Boot +Partitions. -``NVME_RESERVATION_RTYPE_WEAR`` - *undescribed* +**Return** -``NVME_RESERVATION_RTYPE_EAAR`` - *undescribed* +The nvme command status if a response was received or -1 with errno + set otherwise. The command status response may specify additional + reset actions required to complete the commit process. +.. c:function:: int nvme_security_send (int fd, __u32 nsid, __u8 nssf, __u8 spsp0, __u8 spsp1, __u8 secp, __u32 tl, __u32 data_len, void * data, __u32 * result) -.. c:type:: enum nvme_reservation_racqa +**Parameters** +``int fd`` + File descriptor of nvme device -**Constants** +``__u32 nsid`` + Namespace ID to issue security command on -``NVME_RESERVATION_RACQA_ACQUIRE`` - *undescribed* +``__u8 nssf`` + NVMe Security Specific field -``NVME_RESERVATION_RACQA_PREEMPT`` - *undescribed* +``__u8 spsp0`` + Security Protocol Specific field -``NVME_RESERVATION_RACQA_PREEMPT_AND_ABORT`` - *undescribed* +``__u8 spsp1`` + Security Protocol Specific field +``__u8 secp`` + Security Protocol -.. c:function:: int nvme_resv_acquire (int fd, __u32 nsid, enum nvme_reservation_rtype rtype, enum nvme_reservation_racqa racqa, bool iekey, __u64 crkey, __u64 nrkey) +``__u32 tl`` + Protocol specific transfer length + +``__u32 data_len`` + Data length of the payload in bytes + +``void * data`` + Security data payload to send + +``__u32 * result`` + The command completion result from CQE dword0 + +**Description** + +The Security Send command is used to transfer 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 or -1 with errno + set otherwise. + + +.. c:function:: int nvme_security_receive (int fd, __u32 nsid, __u8 nssf, __u8 spsp0, __u8 spsp1, __u8 secp, __u32 al, __u32 data_len, void * data, __u32 * result) - Send an nvme reservation acquire **Parameters** @@ -4296,29 +4129,31 @@ The nvme command status if a response was received or -1 with errno File descriptor of nvme device ``__u32 nsid`` - Namespace identifier + Namespace ID to issue security command on -``enum nvme_reservation_rtype rtype`` - The type of reservation to be create, see :c:type:`enum nvme_reservation_rtype ` +``__u8 nssf`` + NVMe Security Specific field -``enum nvme_reservation_racqa racqa`` - The action that is performed by the command, see :c:type:`enum nvme_reservation_racqa ` +``__u8 spsp0`` + Security Protocol Specific field -``bool iekey`` - Set to ignore the existing key +``__u8 spsp1`` + Security Protocol Specific field -``__u64 crkey`` - The current reservation key associated with the host +``__u8 secp`` + Security Protocol -``__u64 nrkey`` - The reservation key to be unregistered from the namespace if - the action is preempt +``__u32 al`` + Protocol specific allocation length -**Description** +``__u32 data_len`` + Data length of the payload in bytes -The Reservation Acquire command is used to acquire a reservation on a -namespace, preempt a reservation held on a namespace, and abort a -reservation held on a namespace. +``void * data`` + Security data payload to send + +``__u32 * result`` + The command completion result from CQE dword0 **Return** @@ -4326,43 +4161,48 @@ The nvme command status if a response was received or -1 with errno set otherwise. +.. c:function:: int nvme_get_lba_status (int fd, __u32 nsid, __u64 slba, __u32 mndw, __u16 rl, enum nvme_lba_status_atype atype, struct nvme_lba_status * lbas) + Retrieve information on possibly unrecoverable LBAs -.. c:type:: enum nvme_reservation_rrega - - -**Constants** - -``NVME_RESERVATION_RREGA_REGISTER_KEY`` - *undescribed* +**Parameters** -``NVME_RESERVATION_RREGA_UNREGISTER_KEY`` - *undescribed* +``int fd`` + File descriptor of nvme device -``NVME_RESERVATION_RREGA_REPLACE_KEY`` - *undescribed* +``__u32 nsid`` + Namespace ID to retrieve LBA status +``__u64 slba`` + Starting logical block address to check statuses +``__u32 mndw`` + Maximum number of dwords to return +``__u16 rl`` + Range length from slba to perform the action -.. c:type:: enum nvme_reservation_cptpl +``enum nvme_lba_status_atype atype`` + Action type mechanism to determine LBA status desctriptors to + return, see :c:type:`enum nvme_lba_status_atype ` +``struct nvme_lba_status * lbas`` + Data payload to return status descriptors -**Constants** +**Description** -``NVME_RESERVATION_CPTPL_NO_CHANGE`` - *undescribed* +The Get LBA Status command requests information about Potentially +Unrecoverable LBAs. Refer to the specification for action type descriptions. -``NVME_RESERVATION_CPTPL_CLEAR`` - *undescribed* +**Return** -``NVME_RESERVATION_CPTPL_PERSIST`` - *undescribed* +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_resv_register (int fd, __u32 nsid, enum nvme_reservation_rrega rrega, enum nvme_reservation_cptpl cptpl, bool iekey, __u64 crkey, __u64 nrkey) +.. c:function:: int nvme_directive_send (int fd, __u32 nsid, __u16 dspec, enum nvme_directive_send_doper doper, enum nvme_directive_dtype dtype, __u32 cdw12, __u32 data_len, void * data, __u32 * result) - Send an nvme reservation register + Send directive command **Parameters** @@ -4370,28 +4210,36 @@ The nvme command status if a response was received or -1 with errno File descriptor of nvme device ``__u32 nsid`` - Namespace identifier + Namespace ID, if applicable -``enum nvme_reservation_rrega rrega`` - The registration action, see :c:type:`enum nvme_reservation_rrega ` +``__u16 dspec`` + Directive specific field -``enum nvme_reservation_cptpl cptpl`` - Change persist through power loss, see :c:type:`enum nvme_reservation_cptpl ` +``enum nvme_directive_send_doper doper`` + Directive send operation, see :c:type:`enum nvme_directive_send_doper ` -``bool iekey`` - Set to ignore the existing key +``enum nvme_directive_dtype dtype`` + Directive type, see :c:type:`enum nvme_directive_dtype ` -``__u64 crkey`` - The current reservation key associated with the host +``__u32 cdw12`` + *undescribed* -``__u64 nrkey`` - The new reservation key to be register if action is register or - replace +``__u32 data_len`` + Length of data payload in bytes + +``void * data`` + Usespace address of data payload + +``__u32 * result`` + If successful, the CQE dword0 value **Description** -The Reservation Register command is used to register, unregister, or replace -a reservation key. +Directives is a mechanism to enable host and NVM subsystem or controller +information exchange. The Directive Send command is used to transfer data +related to a specific Directive Type from the host to the controller. + +See the NVMe specification for more information. **Return** @@ -4399,23 +4247,34 @@ The nvme command status if a response was received or -1 with errno set otherwise. +.. c:function:: int nvme_directive_send_id_endir (int fd, __u32 nsid, bool endir, enum nvme_directive_dtype dtype, struct nvme_id_directives * id) -.. c:type:: enum nvme_reservation_rrela +**Parameters** +``int fd`` + File descriptor of nvme device -**Constants** +``__u32 nsid`` + Namespace ID -``NVME_RESERVATION_RRELA_RELEASE`` +``bool endir`` *undescribed* -``NVME_RESERVATION_RRELA_CLEAR`` +``enum nvme_directive_dtype dtype`` *undescribed* +``struct nvme_id_directives * id`` + *undescribed* -.. c:function:: int nvme_resv_release (int fd, __u32 nsid, enum nvme_reservation_rtype rtype, enum nvme_reservation_rrela rrela, bool iekey, __u64 crkey) +**Return** + +The nvme command status if a response was received or -1 with errno + set otherwise. + + +.. c:function:: int nvme_directive_send_stream_release_identifier (int fd, __u32 nsid, __u16 stream_id) - Send an nvme reservation release **Parameters** @@ -4423,19 +4282,10 @@ The nvme command status if a response was received or -1 with errno File descriptor of nvme device ``__u32 nsid`` - Namespace identifier - -``enum nvme_reservation_rtype rtype`` - The type of reservation to be create, see :c:type:`enum nvme_reservation_rtype ` - -``enum nvme_reservation_rrela rrela`` - Reservation releast action, see :c:type:`enum nvme_reservation_rrela ` - -``bool iekey`` - Set to ignore the existing key + Namespace ID -``__u64 crkey`` - The current reservation key to release +``__u16 stream_id`` + *undescribed* **Return** @@ -4443,9 +4293,8 @@ The nvme command status if a response was received or -1 with errno set otherwise. -.. c:function:: int nvme_resv_report (int fd, __u32 nsid, bool eds, __u32 len, struct nvme_reservation_status * report) +.. c:function:: int nvme_directive_send_stream_release_resource (int fd, __u32 nsid) - Send an nvme reservation report **Parameters** @@ -4453,22 +4302,7 @@ The nvme command status if a response was received or -1 with errno File descriptor of nvme device ``__u32 nsid`` - Namespace identifier - -``bool eds`` - Request extended Data Structure - -``__u32 len`` - Number of bytes to request transfered with this command - -``struct nvme_reservation_status * report`` - The user space destination address to store the reservation report - -**Description** - -Returns a Reservation Status data structure to memory that describes the -registration and reservation status of a namespace. See the defintion for -the returned structure, :c:type:`struct nvme_reservation_status `, for more details. + Namespace ID **Return** @@ -4476,929 +4310,1070 @@ The nvme command status if a response was received or -1 with errno set otherwise. +.. c:function:: int nvme_directive_recv (int fd, __u32 nsid, __u16 dspec, enum nvme_directive_receive_doper doper, enum nvme_directive_dtype dtype, __u32 cdw12, __u32 data_len, void * data, __u32 * result) + Receive directive specific data -.. c:type:: struct nvme_fabrics_config +**Parameters** +``int fd`` + File descriptor of nvme device -**Definition** +``__u32 nsid`` + Namespace ID, if applicable -:: +``__u16 dspec`` + Directive specific field - struct nvme_fabrics_config { - const char *transport; - const char *traddr; - const char *trsvcid; - const char *nqn; - const char *hostnqn; - const char *host_traddr; - const char *hostid; - int queue_size; - int nr_io_queues; - int reconnect_delay; - int ctrl_loss_tmo; - int keep_alive_tmo; - int nr_write_queues; - int nr_poll_queues; - int tos; - bool duplicate_connect; - bool disable_sqflow; - bool hdr_digest; - bool data_digest; - uint8_t rsvd[0x200]; - }; +``enum nvme_directive_receive_doper doper`` + Directive receive operation, see :c:type:`enum nvme_directive_receive_doper ` -**Members** +``enum nvme_directive_dtype dtype`` + Directive type, see :c:type:`enum nvme_directive_dtype ` +``__u32 cdw12`` + *undescribed* +``__u32 data_len`` + Length of data payload -.. c:function:: int nvmf_add_ctrl_opts (struct nvme_fabrics_config * cfg) +``void * data`` + Usespace address of data payload in bytes +``__u32 * result`` + If successful, the CQE dword0 value -**Parameters** +**Return** -``struct nvme_fabrics_config * cfg`` - *undescribed* +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: nvme_ctrl_t nvmf_add_ctrl (struct nvme_fabrics_config * cfg) +.. c:function:: int nvme_directive_recv_identify_parameters (int fd, __u32 nsid, struct nvme_id_directives * id) **Parameters** -``struct nvme_fabrics_config * cfg`` - *undescribed* - - -.. c:function:: int nvmf_get_discovery_log (nvme_ctrl_t c, struct nvmf_discovery_log ** logp, int max_retries) - +``int fd`` + File descriptor of nvme device -**Parameters** +``__u32 nsid`` + Namespace ID -``nvme_ctrl_t c`` +``struct nvme_id_directives * id`` *undescribed* -``struct nvmf_discovery_log ** logp`` - *undescribed* +**Return** -``int max_retries`` - *undescribed* +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: char * nvmf_hostnqn_generate () +.. c:function:: int nvme_directive_recv_stream_parameters (int fd, __u32 nsid, struct nvme_streams_directive_params * parms) **Parameters** +``int fd`` + File descriptor of nvme device -.. c:function:: char * nvmf_hostnqn_from_file () - +``__u32 nsid`` + Namespace ID -**Parameters** +``struct nvme_streams_directive_params * parms`` + *undescribed* +**Return** -.. c:function:: char * nvmf_hostid_from_file () +The nvme command status if a response was received or -1 with errno + set otherwise. -**Parameters** +.. c:function:: int nvme_directive_recv_stream_status (int fd, __u32 nsid, unsigned nr_entries, struct nvme_streams_directive_status * id) -.. c:function:: const char * nvmf_trtype_str (__u8 trtype) +**Parameters** +``int fd`` + File descriptor of nvme device -**Parameters** +``__u32 nsid`` + Namespace ID -``__u8 trtype`` +``unsigned nr_entries`` *undescribed* +``struct nvme_streams_directive_status * id`` + *undescribed* -.. c:function:: const char * nvmf_adrfam_str (__u8 adrfam) +**Return** +The nvme command status if a response was received or -1 with errno + set otherwise. -**Parameters** -``__u8 adrfam`` - *undescribed* +.. c:function:: int nvme_directive_recv_stream_allocate (int fd, __u32 nsid, __u16 nsr, __u32 * result) -.. c:function:: const char * nvmf_subtype_str (__u8 subtype) +**Parameters** +``int fd`` + File descriptor of nvme device -**Parameters** +``__u32 nsid`` + Namespace ID -``__u8 subtype`` +``__u16 nsr`` *undescribed* +``__u32 * result`` + *undescribed* -.. c:function:: const char * nvmf_treq_str (__u8 treq) +**Return** +The nvme command status if a response was received or -1 with errno + set otherwise. -**Parameters** -``__u8 treq`` - *undescribed* -.. c:function:: const char * nvmf_sectype_str (__u8 sectype) +.. c:type:: enum nvme_fctype -**Parameters** +**Constants** -``__u8 sectype`` +``nvme_fabrics_type_property_set`` *undescribed* +``nvme_fabrics_type_connect`` + *undescribed* -.. c:function:: const char * nvmf_prtype_str (__u8 prtype) +``nvme_fabrics_type_property_get`` + *undescribed* +``nvme_fabrics_type_auth_send`` + *undescribed* -**Parameters** +``nvme_fabrics_type_auth_receive`` + *undescribed* -``__u8 prtype`` +``nvme_fabrics_type_disconnect`` *undescribed* -.. c:function:: const char * nvmf_qptype_str (__u8 qptype) +.. c:function:: int nvme_set_property (int fd, int offset, __u64 value) + Set controller property **Parameters** -``__u8 qptype`` - *undescribed* +``int fd`` + File descriptor of nvme device +``int offset`` + Property offset from the base to set -.. c:function:: const char * nvmf_cms_str (__u8 cm) +``__u64 value`` + The value to set the property +**Description** -**Parameters** +This is an NVMe-over-Fabrics specific command, not applicable to PCIe. These +properties align to the PCI MMIO controller registers. -``__u8 cm`` - *undescribed* +**Return** +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: nvme_ctrl_t nvmf_connect_disc_entry (struct nvmf_disc_log_entry * e, const struct nvme_fabrics_config * defcfg, bool * discover) +.. c:function:: int nvme_get_property (int fd, int offset, __u64 * value) -**Parameters** + Get a controller property -``struct nvmf_disc_log_entry * e`` - *undescribed* +**Parameters** -``const struct nvme_fabrics_config * defcfg`` - *undescribed* +``int fd`` + File descriptor of nvme device -``bool * discover`` - *undescribed* +``int offset`` + Property offset from the base to retrieve +``__u64 * value`` + Where the property's value will be stored on success -.. c:function:: int nvme_namespace_filter (const struct dirent * d) +**Description** +This is an NVMe-over-Fabrics specific command, not applicable to PCIe. These +properties align to the PCI MMIO controller registers. -**Parameters** +**Return** -``const struct dirent * d`` - *undescribed* +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_paths_filter (const struct dirent * d) +.. c:function:: int nvme_sanitize_nvm (int fd, enum nvme_sanitize_sanact sanact, bool ause, __u8 owpass, bool oipbp, bool nodas, __u32 ovrpat) + Start a sanitize operation **Parameters** -``const struct dirent * d`` - *undescribed* +``int fd`` + File descriptor of nvme device +``enum nvme_sanitize_sanact sanact`` + Sanitize action, see :c:type:`enum nvme_sanitize_sanact ` -.. c:function:: int nvme_ctrls_filter (const struct dirent * d) +``bool ause`` + Set to allow unrestriced sanitize exit + +``__u8 owpass`` + Overwrite pass count +``bool oipbp`` + Set to overwrite invert pattern between passes -**Parameters** +``bool nodas`` + Set to not deallocate blocks after sanitizing -``const struct dirent * d`` - *undescribed* +``__u32 ovrpat`` + Overwrite pattern +**Description** -.. c:function:: int nvme_subsys_filter (const struct dirent * d) +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 is used to start 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. -**Parameters** +**Return** -``const struct dirent * d`` - *undescribed* +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_scan_subsystems (struct dirent *** subsys) +.. c:function:: int nvme_dev_self_test (int fd, __u32 nsid, enum nvme_dst_stc stc) + Start or abort a self test **Parameters** -``struct dirent *** subsys`` - *undescribed* +``int fd`` + File descriptor of nvme device +``__u32 nsid`` + Namespace ID to test -.. c:function:: int nvme_scan_subsystem_ctrls (nvme_subsystem_t s, struct dirent *** ctrls) +``enum nvme_dst_stc stc`` + Self test code, see :c:type:`enum nvme_dst_stc ` +**Description** -**Parameters** +The Device Self-test command is used to start a device self-test operation +or abort a device self-test operation. A device self-test operation is a +diagnostic testing sequence that tests the integrity and functionality of +the controller and may include testing of the media associated with +namespaces. The controller may return a response to this command immediately +while running the self-test in the background. -``nvme_subsystem_t s`` - *undescribed* +Set the 'nsid' field to 0 to not include namepsaces in the test. Set to +0xffffffff to test all namespaces. All other values tests a specific +namespace, if present. -``struct dirent *** ctrls`` - *undescribed* +**Return** + +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_scan_subsystem_namespaces (nvme_subsystem_t s, struct dirent *** namespaces) +.. c:function:: int nvme_virtual_mgmt (int fd, enum nvme_virt_mgmt_act act, enum nvme_virt_mgmt_rt rt, __u16 cntlid, __u16 nr, __u32 * result) + Virtualization resource management **Parameters** -``nvme_subsystem_t s`` - *undescribed* - -``struct dirent *** namespaces`` - *undescribed* +``int fd`` + File descriptor of nvme device +``enum nvme_virt_mgmt_act act`` + Virtual resource action, see :c:type:`enum nvme_virt_mgmt_act ` -.. c:function:: int nvme_scan_ctrl_namespace_paths (nvme_ctrl_t c, struct dirent *** namespaces) +``enum nvme_virt_mgmt_rt rt`` + Resource type to modify, see :c:type:`enum nvme_virt_mgmt_rt ` +``__u16 cntlid`` + Controller id for which resources are bing modified -**Parameters** +``__u16 nr`` + Number of resources being allocated or assigned -``nvme_ctrl_t c`` - *undescribed* +``__u32 * result`` + If successful, the CQE dword0 -``struct dirent *** namespaces`` - *undescribed* +**Description** +The Virtualization Management command is supported by primary controllers +that support the Virtualization Enhancements capability. This command is +used for several functions: -.. c:function:: int nvme_scan_ctrl_namespaces (nvme_ctrl_t c, struct dirent *** namespaces) + - Modifying Flexible Resource allocation for the primary controller + - Assigning Flexible Resources for secondary controllers + - Setting the Online and Offline state for secondary controllers +**Return** -**Parameters** +The nvme command status if a response was received or -1 + with errno set otherwise. -``nvme_ctrl_t c`` - *undescribed* -``struct dirent *** namespaces`` - *undescribed* +**NVMe IO command** -.. c:type:: struct nvme_passthru_cmd +.. c:type:: enum nvme_io_opcode -**Definition** +**Constants** -:: +``nvme_cmd_flush`` + *undescribed* - 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; - }; +``nvme_cmd_write`` + *undescribed* -**Members** +``nvme_cmd_read`` + *undescribed* -``opcode`` - Operation code, see :c:type:`enum nvme_io_opcodes ` and :c:type:`enum nvme_admin_opcodes ` +``nvme_cmd_write_uncor`` + *undescribed* -``flags`` - Not supported: intended for command flags (eg: SGL, FUSE) +``nvme_cmd_compare`` + *undescribed* -``rsvd1`` - Reserved for future use +``nvme_cmd_write_zeroes`` + *undescribed* -``nsid`` - Namespace Identifier, or Fabrics type +``nvme_cmd_dsm`` + *undescribed* -``cdw2`` - Command Dword 2 (no spec defined use) +``nvme_cmd_verify`` + *undescribed* -``cdw3`` - Command Dword 3 (no spec defined use) +``nvme_cmd_resv_register`` + *undescribed* -``metadata`` - User space address to metadata buffer (NULL if not used) +``nvme_cmd_resv_report`` + *undescribed* -``addr`` - User space address to data buffer (NULL if not used) +``nvme_cmd_resv_acquire`` + *undescribed* -``metadata_len`` - Metadata buffer transfer length +``nvme_cmd_resv_release`` + *undescribed* -``data_len`` - Data buffer transfer length -``cdw10`` - Command Dword 10 (command specific) +.. c:function:: int nvme_flush (int fd, __u32 nsid) -``cdw11`` - Command Dword 11 (command specific) + Send an nvme flush command -``cdw12`` - Command Dword 12 (command specific) +**Parameters** -``cdw13`` - Command Dword 13 (command specific) +``int fd`` + File descriptor of nvme device -``cdw14`` - Command Dword 14 (command specific) +``__u32 nsid`` + Namespace identifier -``cdw15`` - Command Dword 15 (command specific) +**Description** -``timeout_ms`` - If non-zero, overrides system default timeout in milliseconds +The Flush command is used to request that the contents of volatile write +cache be made non-volatile. -``result`` - Set on completion to the command's CQE DWORD 0 controller response +**Return** +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:type:: struct nvme_passthru_cmd64 +.. c:type:: enum nvme_io_control_flags -**Definition** +**Constants** -:: +``NVME_IO_DTYPE_STREAMS`` + *undescribed* - 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; - }; +``NVME_IO_DEAC`` + *undescribed* -**Members** +``NVME_IO_PRINFO_PRCHK_REF`` + *undescribed* -``opcode`` - Operation code, see :c:type:`enum nvme_io_opcodes ` and :c:type:`enum nvme_admin_opcodes ` +``NVME_IO_PRINFO_PRCHK_APP`` + *undescribed* -``flags`` - Not supported: intended for command flags (eg: SGL, FUSE) +``NVME_IO_PRINFO_PRCHK_GUARD`` + *undescribed* -``rsvd1`` - Reserved for future use +``NVME_IO_PRINFO_PRACT`` + *undescribed* -``nsid`` - Namespace Identifier, or Fabrics type +``NVME_IO_FUA`` + *undescribed* -``cdw2`` - Command Dword 2 (no spec defined use) +``NVME_IO_LR`` + *undescribed* -``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 +.. c:type:: enum nvme_io_dsm_flags -``data_len`` - Data buffer transfer length -``cdw10`` - Command Dword 10 (command specific) +**Constants** -``cdw11`` - Command Dword 11 (command specific) +``NVME_IO_DSM_FREQ_UNSPEC`` + *undescribed* -``cdw12`` - Command Dword 12 (command specific) +``NVME_IO_DSM_FREQ_TYPICAL`` + *undescribed* -``cdw13`` - Command Dword 13 (command specific) +``NVME_IO_DSM_FREQ_RARE`` + *undescribed* -``cdw14`` - Command Dword 14 (command specific) +``NVME_IO_DSM_FREQ_READS`` + *undescribed* -``cdw15`` - Command Dword 15 (command specific) +``NVME_IO_DSM_FREQ_WRITES`` + *undescribed* -``timeout_ms`` - If non-zero, overrides system default timeout in milliseconds +``NVME_IO_DSM_FREQ_RW`` + *undescribed* -``rsvd2`` - Reserved for future use (and fills an impicit struct pad +``NVME_IO_DSM_FREQ_ONCE`` + *undescribed* -``result`` - Set on completion to the command's CQE DWORD 0-1 controller response +``NVME_IO_DSM_FREQ_PREFETCH`` + *undescribed* +``NVME_IO_DSM_FREQ_TEMP`` + *undescribed* +``NVME_IO_DSM_LATENCY_NONE`` + *undescribed* -.. c:function:: int nvme_submit_admin_passthru64 (int fd, struct nvme_passthru_cmd64 * cmd, __u64 * result) +``NVME_IO_DSM_LATENCY_IDLE`` + *undescribed* - Submit a 64-bit nvme passthrough admin command +``NVME_IO_DSM_LATENCY_NORM`` + *undescribed* + +``NVME_IO_DSM_LATENCY_LOW`` + *undescribed* + +``NVME_IO_DSM_SEQ_REQ`` + *undescribed* + +``NVME_IO_DSM_COMPRESSED`` + *undescribed* + + +.. c:function:: int nvme_read (int fd, __u32 nsid, __u64 slba, __u16 nlb, __u16 control, __u8 dsm, __u32 reftag, __u16 apptag, __u16 appmask, __u32 data_len, void * data, __u32 metadata_len, void * metadata) + + Submit an nvme user read command **Parameters** ``int fd`` File descriptor of nvme device -``struct nvme_passthru_cmd64 * cmd`` - The nvme admin command to send +``__u32 nsid`` + Namespace ID -``__u64 * result`` - Optional field to return the result from the CQE DW0-1 +``__u64 slba`` + Starting logical block -**Description** +``__u16 nlb`` + *undescribed* + +``__u16 control`` + Command control flags, see :c:type:`enum nvme_io_control_flags `. + +``__u8 dsm`` + Data set management attributes, see :c:type:`enum nvme_io_dsm_flags ` + +``__u32 reftag`` + This field specifies the Initial Logical Block Reference Tag + expected value. Used only if the namespace is formatted to use + end-to-end protection information. + +``__u16 apptag`` + This field specifies the Application Tag Mask expected value. + Used only if the namespace is formatted to use end-to-end + protection information. + +``__u16 appmask`` + This field specifies the Application Tag expected value. Used + only if the namespace is formatted to use end-to-end protection + information. + +``__u32 data_len`` + Length of user buffer, **data**, in bytes + +``void * data`` + Pointer to user address of the data buffer + metadata_len:Length of user buffer, **metadata**, in bytes + +``__u32 metadata_len`` + *undescribed* + +``void * metadata`` + Pointer to user address of the metadata buffer + +**Return** + +The nvme command status if a response was received or -1 with errno + set otherwise. + + +.. c:function:: int nvme_write (int fd, __u32 nsid, __u64 slba, __u16 nlb, __u16 control, __u8 dsm, __u16 dspec, __u32 reftag, __u16 apptag, __u16 appmask, __u32 data_len, void * data, __u32 metadata_len, void * metadata) + + Submit an nvme user write command + +**Parameters** + +``int fd`` + File descriptor of nvme device + +``__u32 nsid`` + Namespace ID + +``__u64 slba`` + Starting logical block + +``__u16 nlb`` + *undescribed* + +``__u16 control`` + Command control flags, see :c:type:`enum nvme_io_control_flags `. + +``__u8 dsm`` + Data set management attributes, see :c:type:`enum nvme_io_dsm_flags ` + +``__u16 dspec`` + Directive specific command, eg: stream identifier + +``__u32 reftag`` + This field specifies the Initial Logical Block Reference Tag + expected value. Used only if the namespace is formatted to use + end-to-end protection information. + +``__u16 apptag`` + This field specifies the Application Tag Mask expected value. + Used only if the namespace is formatted to use end-to-end + protection information. + +``__u16 appmask`` + This field specifies the Application Tag expected value. Used + only if the namespace is formatted to use end-to-end protection + information. + +``__u32 data_len`` + Length of user buffer, **data**, in bytes + +``void * data`` + Pointer to user address of the data buffer + metadata_len:Length of user buffer, **metadata**, in bytes + +``__u32 metadata_len`` + *undescribed* + +``void * metadata`` + Pointer to user address of the metadata buffer + +**Return** + +The nvme command status if a response was received or -1 with errno + set otherwise. + + +.. c:function:: int nvme_compare (int fd, __u32 nsid, __u64 slba, __u16 nlb, __u16 control, __u32 reftag, __u16 apptag, __u16 appmask, __u32 data_len, void * data, __u32 metadata_len, void * metadata) + + Submit an nvme user compare command + +**Parameters** + +``int fd`` + File descriptor of nvme device + +``__u32 nsid`` + Namespace ID + +``__u64 slba`` + Starting logical block + +``__u16 nlb`` + *undescribed* + +``__u16 control`` + Command control flags, see :c:type:`enum nvme_io_control_flags `. + +``__u32 reftag`` + This field specifies the Initial Logical Block Reference Tag + expected value. Used only if the namespace is formatted to use + end-to-end protection information. + +``__u16 apptag`` + This field specifies the Application Tag Mask expected value. + Used only if the namespace is formatted to use end-to-end + protection information. + +``__u16 appmask`` + This field specifies the Application Tag expected value. Used + only if the namespace is formatted to use end-to-end protection + information. + +``__u32 data_len`` + Length of user buffer, **data**, in bytes + +``void * data`` + Pointer to user address of the data buffer + metadata_len:Length of user buffer, **metadata**, in bytes + +``__u32 metadata_len`` + *undescribed* -Uses NVME_IOCTL_ADMIN64_CMD for the ioctl request. +``void * metadata`` + Pointer to user address of the metadata buffer **Return** -The nvme command status if a response was received or -1 - with errno set otherwise. +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_admin_passthru64 (int fd, __u8 opcode, __u8 flags, __u16 rsvd, __u32 nsid, __u32 cdw2, __u32 cdw3, __u32 cdw10, __u32 cdw11, __u32 cdw12, __u32 cdw13, __u32 cdw14, __u32 cdw15, __u32 data_len, void * data, __u32 metadata_len, void * metadata, __u32 timeout_ms, __u64 * result) +.. c:function:: int nvme_write_zeros (int fd, __u32 nsid, __u64 slba, __u16 nlb, __u16 control, __u32 reftag, __u16 apptag, __u16 appmask) - Submit an nvme passthrough command + Submit an nvme write zeroes command **Parameters** ``int fd`` File descriptor of nvme device -``__u8 opcode`` - The nvme io command to send - -``__u8 flags`` - NVMe command flags (not used) - -``__u16 rsvd`` - Reserevd for future use - ``__u32 nsid`` Namespace identifier -``__u32 cdw2`` - Command dword 2 - -``__u32 cdw3`` - Command dword 3 - -``__u32 cdw10`` - Command dword 10 - -``__u32 cdw11`` - Command dword 11 - -``__u32 cdw12`` - Command dword 12 - -``__u32 cdw13`` - Command dword 13 - -``__u32 cdw14`` - Command dword 14 - -``__u32 cdw15`` - Command dword 15 - -``__u32 data_len`` - Length of the data transfered in this command in bytes +``__u64 slba`` + Starting logical block -``void * data`` - Pointer to user address of the data buffer +``__u16 nlb`` + Number of logical blocks to clear (0's based value) -``__u32 metadata_len`` - Length of metadata transfered in this command +``__u16 control`` + Command control flags, see :c:type:`enum nvme_io_control_flags `. -``void * metadata`` - Pointer to user address of the metadata buffer +``__u32 reftag`` + This field specifies the Initial Logical Block Reference Tag + expected value. Used only if the namespace is formatted to use + end-to-end protection information. -``__u32 timeout_ms`` - How long the kernel waits for the command to complete +``__u16 apptag`` + This field specifies the Application Tag Mask expected value. + Used only if the namespace is formatted to use end-to-end + protection information. -``__u64 * result`` - Optional field to return the result from the CQE dword 0 +``__u16 appmask`` + This field specifies the Application Tag expected value. Used + only if the namespace is formatted to use end-to-end protection + information. **Description** -Parameterized form of nvme_submit_admin_passthru64(). This sets up and -submits a :c:type:`struct nvme_passthru_cmd64 `. - -Known values for **opcode** are defined in :c:type:`enum nvme_admin_opcode `. +The Write Zeroes command is used to set a range of logical blocks to zero. +After successful completion of this command, the value returned by +subsequent reads of logical blocks in this range shall be all bytes cleared +to 0h until a write occurs to this LBA range. **Return** -The nvme command status if a response was received or -1 - with errno set otherwise. +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_submit_admin_passthru (int fd, struct nvme_passthru_cmd * cmd, __u32 * result) +.. c:function:: int nvme_write_uncorrectable (int fd, __u32 nsid, __u64 slba, __u16 nlb) - Submit an nvme passthrough admin command + Submit an nvme write uncorrectable command **Parameters** ``int fd`` File descriptor of nvme device -``struct nvme_passthru_cmd * cmd`` - The nvme admin command to send +``__u32 nsid`` + Namespace identifier -``__u32 * result`` - Optional field to return the result from the CQE DW0 +``__u64 slba`` + Starting logical block + +``__u16 nlb`` + Number of logical blocks to invalidate (0's based value) **Description** -Uses NVME_IOCTL_ADMIN_CMD for the ioctl request. +The Write Uncorrectable command is used to mark a range of logical blocks as +invalid. When the specified logical block(s) are read after this operation, +a failure is returned with Unrecovered Read Error status. To clear the +invalid logical block status, a write operation on those logical blocks is +required. **Return** -The nvme command status if a response was received or -1 - with errno set otherwise. +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_admin_passthru (int fd, __u8 opcode, __u8 flags, __u16 rsvd, __u32 nsid, __u32 cdw2, __u32 cdw3, __u32 cdw10, __u32 cdw11, __u32 cdw12, __u32 cdw13, __u32 cdw14, __u32 cdw15, __u32 data_len, void * data, __u32 metadata_len, void * metadata, __u32 timeout_ms, __u32 * result) +.. c:function:: int nvme_verify (int fd, __u32 nsid, __u64 slba, __u16 nlb, __u16 control, __u32 reftag, __u16 apptag, __u16 appmask) - Submit an nvme passthrough command + Send an nvme verify command **Parameters** ``int fd`` File descriptor of nvme device -``__u8 opcode`` - The nvme io command to send - -``__u8 flags`` - NVMe command flags (not used) - -``__u16 rsvd`` - Reserevd for future use - ``__u32 nsid`` Namespace identifier -``__u32 cdw2`` - Command dword 2 +``__u64 slba`` + Starting logical block -``__u32 cdw3`` - Command dword 3 +``__u16 nlb`` + Number of logical blocks to verify (0's based value) -``__u32 cdw10`` - Command dword 10 +``__u16 control`` + Command control flags, see :c:type:`enum nvme_io_control_flags `. -``__u32 cdw11`` - Command dword 11 +``__u32 reftag`` + This field specifies the Initial Logical Block Reference Tag + expected value. Used only if the namespace is formatted to use + end-to-end protection information. -``__u32 cdw12`` - Command dword 12 +``__u16 apptag`` + This field specifies the Application Tag Mask expected value. + Used only if the namespace is formatted to use end-to-end + protection information. -``__u32 cdw13`` - Command dword 13 +``__u16 appmask`` + This field specifies the Application Tag expected value. Used + only if the namespace is formatted to use end-to-end protection + information. -``__u32 cdw14`` - Command dword 14 +**Description** -``__u32 cdw15`` - Command dword 15 +The Verify command verifies integrity of stored information by reading data +and metadata, if applicable, for the LBAs indicated without transferring any +data or metadata to the host. -``__u32 data_len`` - Length of the data transfered in this command in bytes +**Return** -``void * data`` - Pointer to user address of the data buffer +The nvme command status if a response was received or -1 with errno + set otherwise. -``__u32 metadata_len`` - Length of metadata transfered in this command -``void * metadata`` - Pointer to user address of the metadata buffer -``__u32 timeout_ms`` - How long the kernel waits for the command to complete -``__u32 * result`` - Optional field to return the result from the CQE dword 0 +.. c:type:: enum nvme_dsm_attributes -**Description** -Parameterized form of nvme_submit_admin_passthru(). This sets up and -submits a :c:type:`struct nvme_passthru_cmd `. +**Constants** -Known values for **opcode** are defined in :c:type:`enum nvme_admin_opcode `. +``NVME_DSMGMT_IDR`` + *undescribed* -**Return** +``NVME_DSMGMT_IDW`` + *undescribed* -The nvme command status if a response was received or -1 - with errno set otherwise. +``NVME_DSMGMT_AD`` + *undescribed* -.. c:function:: int nvme_submit_io_passthru64 (int fd, struct nvme_passthru_cmd64 * cmd, __u64 * result) +.. c:function:: int nvme_dsm (int fd, __u32 nsid, __u32 attrs, __u16 nr_ranges, struct nvme_dsm_range * dsm) - Submit a 64-bit nvme passthrough command + Send an nvme data set management command **Parameters** ``int fd`` File descriptor of nvme device -``struct nvme_passthru_cmd64 * cmd`` - The nvme io command to send - -``__u64 * result`` - Optional field to return the result from the CQE DW0-1 - -**Description** - -Uses NVME_IOCTL_IO64_CMD for the ioctl request. - -**Return** - -The nvme command status if a response was received or -1 - with errno set otherwise. +``__u32 nsid`` + Namespace identifier +``__u32 attrs`` + DSM attributes, see :c:type:`enum nvme_dsm_attributes ` + :c:type:`nr_ranges`: Number of block ranges in the data set management attributes -.. c:function:: int nvme_io_passthru64 (int fd, __u8 opcode, __u8 flags, __u16 rsvd, __u32 nsid, __u32 cdw2, __u32 cdw3, __u32 cdw10, __u32 cdw11, __u32 cdw12, __u32 cdw13, __u32 cdw14, __u32 cdw15, __u32 data_len, void * data, __u32 metadata_len, void * metadata, __u32 timeout_ms, __u64 * result) +``__u16 nr_ranges`` + *undescribed* - Submit an nvme io passthrough command +``struct nvme_dsm_range * dsm`` + The data set management attributes -**Parameters** +**Description** -``int fd`` - File descriptor of nvme device +The Dataset Management command is used by the host to indicate attributes +for ranges of logical blocks. This includes attributes like frequency that +data is read or written, access size, and other information that may be used +to optimize performance and reliability, and may be used to +deallocate/unmap/trim those logical blocks. -``__u8 opcode`` - The nvme io command to send +**Return** -``__u8 flags`` - NVMe command flags (not used) +The nvme command status if a response was received or -1 with errno + set otherwise. -``__u16 rsvd`` - Reserevd for future use -``__u32 nsid`` - Namespace identifier -``__u32 cdw2`` - Command dword 2 -``__u32 cdw3`` - Command dword 3 +.. c:type:: enum nvme_reservation_rtype -``__u32 cdw10`` - Command dword 10 -``__u32 cdw11`` - Command dword 11 +**Constants** -``__u32 cdw12`` - Command dword 12 +``NVME_RESERVATION_RTYPE_WE`` + *undescribed* -``__u32 cdw13`` - Command dword 13 +``NVME_RESERVATION_RTYPE_EA`` + *undescribed* -``__u32 cdw14`` - Command dword 14 +``NVME_RESERVATION_RTYPE_WERO`` + *undescribed* -``__u32 cdw15`` - Command dword 15 +``NVME_RESERVATION_RTYPE_EARO`` + *undescribed* -``__u32 data_len`` - Length of the data transfered in this command in bytes +``NVME_RESERVATION_RTYPE_WEAR`` + *undescribed* -``void * data`` - Pointer to user address of the data buffer +``NVME_RESERVATION_RTYPE_EAAR`` + *undescribed* -``__u32 metadata_len`` - Length of metadata transfered in this command -``void * metadata`` - Pointer to user address of the metadata buffer -``__u32 timeout_ms`` - How long the kernel waits for the command to complete -``__u64 * result`` - Optional field to return the result from the CQE dword 0 +.. c:type:: enum nvme_reservation_racqa -**Description** -Parameterized form of nvme_submit_io_passthru64(). This sets up and submits -a :c:type:`struct nvme_passthru_cmd64 `. +**Constants** -Known values for **opcode** are defined in :c:type:`enum nvme_io_opcode `. +``NVME_RESERVATION_RACQA_ACQUIRE`` + *undescribed* -**Return** +``NVME_RESERVATION_RACQA_PREEMPT`` + *undescribed* -The nvme command status if a response was received or -1 with errno - set otherwise. +``NVME_RESERVATION_RACQA_PREEMPT_AND_ABORT`` + *undescribed* -.. c:function:: int nvme_submit_io_passthru (int fd, struct nvme_passthru_cmd * cmd, __u32 * result) +.. c:function:: int nvme_resv_acquire (int fd, __u32 nsid, enum nvme_reservation_rtype rtype, enum nvme_reservation_racqa racqa, bool iekey, __u64 crkey, __u64 nrkey) - Submit an nvme passthrough command + Send an nvme reservation acquire **Parameters** ``int fd`` File descriptor of nvme device -``struct nvme_passthru_cmd * cmd`` - The nvme io command to send +``__u32 nsid`` + Namespace identifier -``__u32 * result`` - Optional field to return the result from the CQE DW0 +``enum nvme_reservation_rtype rtype`` + The type of reservation to be create, see :c:type:`enum nvme_reservation_rtype ` -**Description** +``enum nvme_reservation_racqa racqa`` + The action that is performed by the command, see :c:type:`enum nvme_reservation_racqa ` -Uses NVME_IOCTL_IO_CMD for the ioctl request. +``bool iekey`` + Set to ignore the existing key -**Return** +``__u64 crkey`` + The current reservation key associated with the host -The nvme command status if a response was received or -1 - with errno set otherwise. +``__u64 nrkey`` + The reservation key to be unregistered from the namespace if + the action is preempt +**Description** -.. c:function:: int nvme_io_passthru (int fd, __u8 opcode, __u8 flags, __u16 rsvd, __u32 nsid, __u32 cdw2, __u32 cdw3, __u32 cdw10, __u32 cdw11, __u32 cdw12, __u32 cdw13, __u32 cdw14, __u32 cdw15, __u32 data_len, void * data, __u32 metadata_len, void * metadata, __u32 timeout_ms, __u32 * result) +The Reservation Acquire command is used to acquire a reservation on a +namespace, preempt a reservation held on a namespace, and abort a +reservation held on a namespace. - Submit an nvme io passthrough command +**Return** -**Parameters** +The nvme command status if a response was received or -1 with errno + set otherwise. -``int fd`` - File descriptor of nvme device -``__u8 opcode`` - The nvme io command to send -``__u8 flags`` - NVMe command flags (not used) -``__u16 rsvd`` - Reserevd for future use +.. c:type:: enum nvme_reservation_rrega -``__u32 nsid`` - Namespace identifier -``__u32 cdw2`` - Command dword 2 +**Constants** -``__u32 cdw3`` - Command dword 3 +``NVME_RESERVATION_RREGA_REGISTER_KEY`` + *undescribed* -``__u32 cdw10`` - Command dword 10 +``NVME_RESERVATION_RREGA_UNREGISTER_KEY`` + *undescribed* -``__u32 cdw11`` - Command dword 11 +``NVME_RESERVATION_RREGA_REPLACE_KEY`` + *undescribed* -``__u32 cdw12`` - Command dword 12 -``__u32 cdw13`` - Command dword 13 -``__u32 cdw14`` - Command dword 14 -``__u32 cdw15`` - Command dword 15 +.. c:type:: enum nvme_reservation_cptpl -``__u32 data_len`` - Length of the data transfered in this command in bytes -``void * data`` - Pointer to user address of the data buffer +**Constants** -``__u32 metadata_len`` - Length of metadata transfered in this command +``NVME_RESERVATION_CPTPL_NO_CHANGE`` + *undescribed* -``void * metadata`` - Pointer to user address of the metadata buffer +``NVME_RESERVATION_CPTPL_CLEAR`` + *undescribed* -``__u32 timeout_ms`` - How long the kernel waits for the command to complete +``NVME_RESERVATION_CPTPL_PERSIST`` + *undescribed* -``__u32 * result`` - Optional field to return the result from the CQE dword 0 -**Description** +.. c:function:: int nvme_resv_register (int fd, __u32 nsid, enum nvme_reservation_rrega rrega, enum nvme_reservation_cptpl cptpl, bool iekey, __u64 crkey, __u64 nrkey) -Parameterized form of nvme_submit_io_passthru(). This sets up and submits -a :c:type:`struct nvme_passthru_cmd `. + Send an nvme reservation register -Known values for **opcode** are defined in :c:type:`enum nvme_io_opcode `. +**Parameters** -**Return** +``int fd`` + File descriptor of nvme device -The nvme command status if a response was received or -1 - with errno set otherwise. +``__u32 nsid`` + Namespace identifier +``enum nvme_reservation_rrega rrega`` + The registration action, see :c:type:`enum nvme_reservation_rrega ` -.. c:function:: int nvme_subsystem_reset (int fd) +``enum nvme_reservation_cptpl cptpl`` + Change persist through power loss, see :c:type:`enum nvme_reservation_cptpl ` - Initiate a subsystem reset +``bool iekey`` + Set to ignore the existing key -**Parameters** +``__u64 crkey`` + The current reservation key associated with the host -``int fd`` - File descriptor of nvme device +``__u64 nrkey`` + The new reservation key to be register if action is register or + replace **Description** -This should only be sent to controller handles, not to namespaces. +The Reservation Register command is used to register, unregister, or replace +a reservation key. **Return** -Zero if a subsystem reset was initiated or -1 with errno set - otherwise. - +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_ctrl_reset (int fd) - Initiate a controller reset -**Parameters** -``int fd`` - File descriptor of nvme device +.. c:type:: enum nvme_reservation_rrela -**Description** -This should only be sent to controller handles, not to namespaces. +**Constants** -**Return** +``NVME_RESERVATION_RRELA_RELEASE`` + *undescribed* -Zero if a reset was initiated or -1 with errno set otherwise. +``NVME_RESERVATION_RRELA_CLEAR`` + *undescribed* -.. c:function:: int nvme_ns_rescan (int fd) +.. c:function:: int nvme_resv_release (int fd, __u32 nsid, enum nvme_reservation_rtype rtype, enum nvme_reservation_rrela rrela, bool iekey, __u64 crkey) - Initiate a controller rescan + Send an nvme reservation release **Parameters** ``int fd`` File descriptor of nvme device -**Description** +``__u32 nsid`` + Namespace identifier -This should only be sent to controller handles, not to namespaces. +``enum nvme_reservation_rtype rtype`` + The type of reservation to be create, see :c:type:`enum nvme_reservation_rtype ` + +``enum nvme_reservation_rrela rrela`` + Reservation releast action, see :c:type:`enum nvme_reservation_rrela ` + +``bool iekey`` + Set to ignore the existing key + +``__u64 crkey`` + The current reservation key to release **Return** -Zero if a rescan was initiated or -1 with errno set otherwise. +The nvme command status if a response was received or -1 with errno + set otherwise. -.. c:function:: int nvme_get_nsid (int fd) +.. c:function:: int nvme_resv_report (int fd, __u32 nsid, bool eds, __u32 len, struct nvme_reservation_status * report) - Retrieve the NSID from a namespace file descriptor + Send an nvme reservation report **Parameters** ``int fd`` - File descriptor of nvme namespace + File descriptor of nvme device + +``__u32 nsid`` + Namespace identifier + +``bool eds`` + Request extended Data Structure + +``__u32 len`` + Number of bytes to request transfered with this command + +``struct nvme_reservation_status * report`` + The user space destination address to store the reservation report **Description** -This should only be sent to namespace handles, not to controllers. +Returns a Reservation Status data structure to memory that describes the +registration and reservation status of a namespace. See the defintion for +the returned structure, :c:type:`struct nvme_reservation_status `, for more details. **Return** -The namespace identifier if a succecssful or -1 with errno set - otherwise. +The nvme command status if a response was received or -1 with errno + set otherwise. .. c:function:: nvme_subsystem_t nvme_first_subsystem (nvme_root_t r) @@ -5407,7 +5382,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_root_t r`` - *undescribed* .. c:function:: nvme_subsystem_t nvme_next_subsystem (nvme_root_t r, nvme_subsystem_t s) @@ -5419,7 +5393,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``nvme_subsystem_t s`` - *undescribed* .. c:function:: nvme_ns_t nvme_ctrl_first_ns (nvme_ctrl_t c) @@ -5428,7 +5401,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: nvme_ns_t nvme_ctrl_next_ns (nvme_ctrl_t c, nvme_ns_t n) @@ -5440,7 +5412,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``nvme_ns_t n`` - *undescribed* .. c:function:: nvme_path_t nvme_ctrl_first_path (nvme_ctrl_t c) @@ -5449,7 +5420,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: nvme_path_t nvme_ctrl_next_path (nvme_ctrl_t c, nvme_path_t p) @@ -5461,7 +5431,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``nvme_path_t p`` - *undescribed* .. c:function:: nvme_ctrl_t nvme_subsystem_first_ctrl (nvme_subsystem_t s) @@ -5470,7 +5439,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_subsystem_t s`` - *undescribed* .. c:function:: nvme_ctrl_t nvme_subsystem_next_ctrl (nvme_subsystem_t s, nvme_ctrl_t c) @@ -5482,7 +5450,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``nvme_ctrl_t c`` - *undescribed* .. c:function:: nvme_ns_t nvme_subsystem_first_ns (nvme_subsystem_t s) @@ -5491,7 +5458,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_subsystem_t s`` - *undescribed* .. c:function:: nvme_ns_t nvme_subsystem_next_ns (nvme_subsystem_t s, nvme_ns_t n) @@ -5503,7 +5469,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``nvme_ns_t n`` - *undescribed* .. c:function:: nvme_for_each_subsystem_safe ( r, s, _s) @@ -5647,7 +5612,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ns_t n`` - *undescribed* .. c:function:: int nvme_ns_get_nsid (nvme_ns_t n) @@ -5656,7 +5620,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ns_t n`` - *undescribed* .. c:function:: int nvme_ns_get_lba_size (nvme_ns_t n) @@ -5665,7 +5628,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ns_t n`` - *undescribed* .. c:function:: uint64_t nvme_ns_get_lba_count (nvme_ns_t n) @@ -5674,7 +5636,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ns_t n`` - *undescribed* .. c:function:: uint64_t nvme_ns_get_lba_util (nvme_ns_t n) @@ -5683,7 +5644,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ns_t n`` - *undescribed* .. c:function:: const char * nvme_ns_get_sysfs_dir (nvme_ns_t n) @@ -5692,7 +5652,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ns_t n`` - *undescribed* .. c:function:: const char * nvme_ns_get_name (nvme_ns_t n) @@ -5701,7 +5660,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ns_t n`` - *undescribed* .. c:function:: nvme_subsystem_t nvme_ns_get_subsystem (nvme_ns_t n) @@ -5710,7 +5668,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ns_t n`` - *undescribed* .. c:function:: nvme_ctrl_t nvme_ns_get_ctrl (nvme_ns_t n) @@ -5719,7 +5676,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ns_t n`` - *undescribed* .. c:function:: int nvme_ns_read (nvme_ns_t n, void * buf, off_t offset, size_t count) @@ -5737,7 +5693,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``size_t count`` - *undescribed* .. c:function:: int nvme_ns_write (nvme_ns_t n, void * buf, off_t offset, size_t count) @@ -5755,7 +5710,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``size_t count`` - *undescribed* .. c:function:: int nvme_ns_verify (nvme_ns_t n, off_t offset, size_t count) @@ -5770,7 +5724,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``size_t count`` - *undescribed* .. c:function:: int nvme_ns_compare (nvme_ns_t n, void * buf, off_t offset, size_t count) @@ -5788,7 +5741,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``size_t count`` - *undescribed* .. c:function:: int nvme_ns_write_zeros (nvme_ns_t n, off_t offset, size_t count) @@ -5803,7 +5755,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``size_t count`` - *undescribed* .. c:function:: int nvme_ns_write_uncorrectable (nvme_ns_t n, off_t offset, size_t count) @@ -5818,7 +5769,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``size_t count`` - *undescribed* .. c:function:: int nvme_ns_flush (nvme_ns_t n) @@ -5827,7 +5777,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ns_t n`` - *undescribed* .. c:function:: int nvme_ns_identify (nvme_ns_t n, struct nvme_id_ns * ns) @@ -5839,7 +5788,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``struct nvme_id_ns * ns`` - *undescribed* .. c:function:: const char * nvme_path_get_name (nvme_path_t p) @@ -5848,7 +5796,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_path_t p`` - *undescribed* .. c:function:: const char * nvme_path_get_sysfs_dir (nvme_path_t p) @@ -5857,7 +5804,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_path_t p`` - *undescribed* .. c:function:: const char * nvme_path_get_ana_state (nvme_path_t p) @@ -5866,7 +5812,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_path_t p`` - *undescribed* .. c:function:: nvme_ctrl_t nvme_path_get_subsystem (nvme_path_t p) @@ -5875,7 +5820,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_path_t p`` - *undescribed* .. c:function:: nvme_ns_t nvme_path_get_ns (nvme_path_t p) @@ -5884,7 +5828,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_path_t p`` - *undescribed* .. c:function:: int nvme_ctrl_get_fd (nvme_ctrl_t c) @@ -5893,7 +5836,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_name (nvme_ctrl_t c) @@ -5902,7 +5844,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_sysfs_dir (nvme_ctrl_t c) @@ -5911,7 +5852,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_address (nvme_ctrl_t c) @@ -5920,7 +5860,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_firmware (nvme_ctrl_t c) @@ -5929,7 +5868,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_model (nvme_ctrl_t c) @@ -5938,7 +5876,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_state (nvme_ctrl_t c) @@ -5947,7 +5884,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_numa_node (nvme_ctrl_t c) @@ -5956,7 +5892,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_queue_count (nvme_ctrl_t c) @@ -5965,7 +5900,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_serial (nvme_ctrl_t c) @@ -5974,7 +5908,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_sqsize (nvme_ctrl_t c) @@ -5983,7 +5916,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_transport (nvme_ctrl_t c) @@ -5992,7 +5924,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_nqn (nvme_ctrl_t c) @@ -6001,7 +5932,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: const char * nvme_ctrl_get_subsysnqn (nvme_ctrl_t c) @@ -6010,7 +5940,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: nvme_subsystem_t nvme_ctrl_get_subsystem (nvme_ctrl_t c) @@ -6019,7 +5948,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: int nvme_ctrl_identify (nvme_ctrl_t c, struct nvme_id_ctrl * id) @@ -6031,7 +5959,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``struct nvme_id_ctrl * id`` - *undescribed* .. c:function:: int nvme_ctrl_disconnect (nvme_ctrl_t c) @@ -6040,7 +5967,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_ctrl_t c`` - *undescribed* .. c:function:: nvme_ctrl_t nvme_scan_ctrl (const char * name) @@ -6049,7 +5975,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``const char * name`` - *undescribed* .. c:function:: void nvme_free_ctrl (struct nvme_ctrl * c) @@ -6076,7 +6001,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_subsystem_t s`` - *undescribed* .. c:function:: const char * nvme_subsystem_get_sysfs_dir (nvme_subsystem_t s) @@ -6085,7 +6009,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_subsystem_t s`` - *undescribed* .. c:function:: const char * nvme_subsystem_get_name (nvme_subsystem_t s) @@ -6094,7 +6017,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_subsystem_t s`` - *undescribed* .. c:function:: nvme_root_t nvme_scan_filter (nvme_scan_filter_t f) @@ -6103,7 +6025,6 @@ The namespace identifier if a succecssful or -1 with errno set **Parameters** ``nvme_scan_filter_t f`` - *undescribed* .. c:function:: nvme_root_t nvme_scan () @@ -6148,7 +6069,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``const char * attr`` - *undescribed* .. c:function:: char * nvme_get_ctrl_attr (nvme_ctrl_t c, const char * attr) @@ -6160,7 +6080,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``const char * attr`` - *undescribed* .. c:function:: char * nvme_get_ns_attr (nvme_ns_t n, const char * attr) @@ -6172,7 +6091,6 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``const char * attr`` - *undescribed* .. c:function:: char * nvme_get_path_attr (nvme_path_t p, const char * attr) @@ -6184,72 +6102,83 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``const char * attr`` - *undescribed* .. c:type:: enum nvme_constants + A place to stash various constant nvme values **Constants** ``NVME_NSID_ALL`` - *undescribed* + A broadcast value that is used to specify all + namespaces ``NVME_NSID_NONE`` - *undescribed* + The invalid namespace id, for when the nsid + parameter is not used in a command ``NVME_UUID_NONE`` - *undescribed* + Use to omit the uuid command parameter ``NVME_CNTLID_NONE`` - *undescribed* + Use to omit the cntlid command parameter ``NVME_NVMSETID_NONE`` - *undescribed* + Use to omit the nvmsetid command parameter ``NVME_LOG_LSP_NONE`` - *undescribed* + Use to omit the log lsp command parameter ``NVME_LOG_LSI_NONE`` - *undescribed* + Use to omit the log lsi command parameter ``NVME_IDENTIFY_DATA_SIZE`` - *undescribed* + The transfer size for nvme identify commands ``NVME_ID_NVMSET_LIST_MAX`` - *undescribed* + The largest possible nvmset index in identify + nvmeset ``NVME_ID_UUID_LIST_MAX`` - *undescribed* + The largest possible uuid index in identify + uuid list ``NVME_ID_CTRL_LIST_MAX`` - *undescribed* + The largest possible controller index in + identify controller list ``NVME_ID_NS_LIST_MAX`` - *undescribed* + The largest possible namespace index in + identify namespace list ``NVME_ID_SECONDARY_CTRL_MAX`` + The largest possible secondary controller index + in identify secondary controller + +``NVME_ID_ND_DESCRIPTOR_MAX`` *undescribed* ``NVME_FEAT_LBA_RANGE_MAX`` - *undescribed* + The largest possible LBA range index in feature + lba range type ``NVME_LOG_ST_MAX_RESULTS`` - *undescribed* + The largest possible self test result index in the + device self test log ``NVME_DSM_MAX_RANGES`` - *undescribed* - - -**NVMe controller registers/properties** + The largest possible range index in a data-set + management command .. c:type:: enum nvme_registers + The nvme controller registers for all transports. This is the layout of BAR0/1 for PCIe, and properties for fabrics. **Constants** @@ -6326,87 +6255,97 @@ The namespace identifier if a succecssful or -1 with errno set SQ 0 Tail Doorbell +.. c:function:: bool is_64bit_reg (__u32 offset) + Checks if offset of the controller register is 64bit or not. -.. c:type:: enum +**Parameters** +``__u32 offset`` + Offset of controller register field in bytes -**Constants** +**Description** -``NVME_CC_ENABLE`` - *undescribed* +This function does not care about transport so that the offset is not going +to be checked inside of this function for the unsupported fields in a +specific transport. For example, BPMBL(Boot Partition Memory Buffer +Location) register is not supported by fabrics, but it can be chcked here. -``NVME_CC_CSS_NVM`` - *undescribed* +Returns true if given offset is 64bit register, otherwise it returns false. -``NVME_CC_EN_SHIFT`` - *undescribed* -``NVME_CC_CSS_SHIFT`` - *undescribed* -``NVME_CC_MPS_SHIFT`` - *undescribed* -``NVME_CC_AMS_SHIFT`` - *undescribed* +.. c:type:: enum nvme_psd_flags -``NVME_CC_SHN_SHIFT`` - *undescribed* + Possible flag values in nvme power state descriptor -``NVME_CC_IOSQES_SHIFT`` - *undescribed* +**Constants** -``NVME_CC_IOCQES_SHIFT`` - *undescribed* +``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_CC_AMS_RR`` - *undescribed* +``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. -``NVME_CC_AMS_WRRU`` - *undescribed* -``NVME_CC_AMS_VS`` - *undescribed* -``NVME_CC_SHN_NONE`` - *undescribed* -``NVME_CC_SHN_NORMAL`` - *undescribed* +.. c:type:: enum nvme_psd_ps -``NVME_CC_SHN_ABRUPT`` - *undescribed* + Known values for :c:type:`struct nvme_psd ` #ips and #aps. Use with nvme_psd_power_scale() to extract the power scale field to match this enum. NVME_PSD_IPS_100_MICRO_WATT: 0.0001 watt scale NVME_PSD_IPS_10_MILLI_WATT: 0.01 watt scale -``NVME_CC_SHN_MASK`` - *undescribed* +**Constants** -``NVME_CSTS_RDY`` +``NVME_PSD_PS_100_MICRO_WATT`` *undescribed* -``NVME_CSTS_CFS`` +``NVME_PSD_PS_10_MILLI_WATT`` *undescribed* -``NVME_CSTS_NSSRO`` - *undescribed* -``NVME_CSTS_PP`` - *undescribed* +.. c:function:: unsigned nvme_psd_power_scale (__u8 ps) -``NVME_CSTS_SHST_NORMAL`` - *undescribed* + power scale occupies the upper 3 bits -``NVME_CSTS_SHST_OCCUR`` - *undescribed* +**Parameters** -``NVME_CSTS_SHST_CMPLT`` +``__u8 ps`` *undescribed* -``NVME_CSTS_SHST_MASK`` - *undescribed* -**NVMe Identify** + +.. c:type:: enum nvme_psd_workload + + Specifies a workload hint in the Power Management Feature (see :c:type:`struct nvme_psd `.apw) to inform the NVM subsystem or indicate the conditions for the active power level. + +**Constants** + +``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. @@ -6439,36 +6378,68 @@ The namespace identifier if a succecssful or -1 with errno set **Members** +``mp`` + Maximum Power indicates the sustained maximum power consumed by the + NVM subsystem in this power state. The power in Watts is equal to + the value in this field multiplied by the scale specified in the Max + Power Scale bit (see :c:type:`enum nvme_psd_flags `). A value of 0 indicates + Maximum Power is not reported. +``flags`` + Additional decoding flags, see :c:type:`enum nvme_psd_flags `. -.. c:function:: unsigned nvme_psd_power_scale (__u8 ps) - - power scale occupies the upper 3 bits - -**Parameters** +``enlat`` + Entry Latency indicates the maximum latency in microseconds + associated with entering this power state. A value of 0 indicates + Entry Latency is not reported. -``__u8 ps`` - *undescribed* +``exlat`` + Exit Latency indicates the maximum latency in microseconds + associated with exiting this power state. A value of 0 indicates + Exit Latency is not reported. +``rrt`` + Relative Read Throughput indicates the read throughput rank + associated with this power state relative to others. The value in + this is less than the number of supported power states. +``rrl`` + Relative Reade Latency indicates the read latency rank associated + with this power state relative to others. The value in this field is + less than the number of supported power states. +``rwt`` + Relative Write Throughput indicates write throughput rank associated + with this power state relative to others. The value in this field is + less than the number of supported power states -.. c:type:: enum +``rwl`` + Relative Write Latency indicates the write latency rank associated + with this power state relative to others. The value in this field is + less than the number of supported power states +``idlp`` + Idle Power indicates the typical power consumed by the NVM + subsystem over 30 seconds in this power state when idle. -**Constants** +``ips`` + Idle Power Scale indicates the scale for :c:type:`struct nvme_id_psd `.idlp, + see :c:type:`enum nvme_psd_ps ` for decoding this field. -``NVME_PSD_FLAGS_MAX_POWER_SCALE`` - *undescribed* +``actp`` + Active Power indicates the largest average power consumed by the + NVM subsystem over a 10 second period in this power state with + the workload indicated in the Active Power Workload field. -``NVME_PSD_FLAGS_NON_OP_STATE`` - *undescribed* +``apw`` + Active Power Workload indicates the workload used to calculate + maximum power for this power state. See :c:type:`enum nvme_psd_workload ` for + decoding this field. -``NVME_PSD_RELATIVE_MASK`` - *undescribed* +``aps`` + Active Power Scale indicates the scale for the :c:type:`struct + nvme_id_psd `.actp, see :c:type:`enum nvme_psd_ps ` for decoding this value. -``NVME_PSD_APW_MASK`` - *undescribed* @@ -6576,88 +6547,356 @@ The namespace identifier if a succecssful or -1 with errno set **Members** ``vid`` - Vendor ID + PCI Vendor ID, the company vendor identifier that is assigned by + the PCI SIG. ``ssvid`` - Subsystem Vendor Id + PCI Subsystem Vendor ID, the company vendor identifier that is + assigned by the PCI SIG for the subsystem. ``sn`` - Serial Number + Serial Number in ascii ``mn`` - Model Number + Model Number in ascii ``fr`` - Firmware Revision + Firmware Revision in ascii, the currently active firmware + revision for the NVM subsystem ``rab`` - Recommended Arbitration Burst + Recommended Arbitration Burst, reported as a power of two ``ieee`` - IEEE + IEEE assigned Organization Unique Identifier ``cmic`` - Controller Mulitpathing Capabilities + Controller Multipath IO and Namespace Sharing Capabilities of + the controller and NVM subsystem. See :c:type:`enum nvme_id_ctrl_cmic `. ``mdts`` - Max Data Transfer Size + Max Data Transfer Size is the largest data transfer size. The + host should not submit a command that exceeds this maximum data + transfer size. The value is in units of the minimum memory page + size (CAP.MPSMIN) and is reported as a power of two ``cntlid`` - Controller Identifier + Controller ID, the NVM subsystem unique controller identifier + associated with the controller. ``ver`` - Version + Version, this field contains the value reported in the Version + register, or property (see :c:type:`enum nvme_registers ` ``NVME_REG_VS``). ``rtd3r`` - Runtime D3 Resume + RTD3 Resume Latency, the expected latency in microseconds to resume + from Runtime D3 ``rtd3e`` - Runtime D3 Exit + RTD3 Exit Latency, the typical latency in microseconds to enter + Runtime D3. ``oaes`` - Optional Async Events Supported + Optional Async Events Supported, see **enum** nvme_id_ctrl_oaes . ``ctratt`` - Controller Attributes + Controller Attributes, see **enum** nvme_id_ctrl_ctratt ``rrls`` - Read Recovery Levels + Read Recovery Levels. If a bit is set, then the corresponding + Read Recovery Level is supported. If a bit is cleared, then the + corresponding Read Recovery Level is not supported. ``cntrltype`` - Controller Type + Controller Type, see :c:type:`enum nvme_id_ctrl_cntrltype ` ``fguid`` - FRU GUID + FRU GUID, a 128-bit value that is globally unique for a given + Field Replaceable Unit ``crdt1`` - Controller Retry Delay 1 + Controller Retry Delay time in 100 millisecod units if CQE CRD + field is 1 ``crdt2`` - Controller Retry Delay 2 + Controller Retry Delay time in 100 millisecod units if CQE CRD + field is 2 ``crdt3`` - Controller Retry Delay 3 + Controller Retry Delay time in 100 millisecod units if CQE CRD + field is 3 + +``nvmsr`` + NVM Subsystem Report, see :c:type:`enum nvme_id_ctrl_nvmsr ` + +``vwci`` + VPD Write Cycle Information, see :c:type:`enum nvme_id_ctrl_vwci ` + +``mec`` + Management Endpoint Capabilities, see :c:type:`enum nvme_id_ctrl_mec ` ``oacs`` - Optional Admin Commands Supported + Optional Admin Command Support,the optional Admin commands and + features supported by the controller, see :c:type:`enum nvme_id_ctrl_oacs `. ``acl`` - Abort Command Limit + Abort Command Limit, the maximum number of concurrently + executing Abort commands supported by the controller. This is a + 0's based value. ``aerl`` - Async Event Request Limit + Async Event Request Limit, the maximum number of concurrently + outstanding Asynchronous Event Request commands supported by the + controller This is a 0's based value. + +``frmw`` + Firmware Updates indicates capabilities regarding firmware + updates. See :c:type:`enum nvme_id_ctrl_frmw `. ``lpa`` - Log Page Attributes + Log Page Attributes, see :c:type:`enum nvme_id_ctrl_lpa `. + +``elpe`` + Error Log Page Entries, the maximum number of Error Information + log entries that are stored by the controller. This field is a + 0's based value. ``npss`` - Number of Power States Supported + Number of Power States Supported, the number of NVM Express + power states supported by the controller, indicating the number + of valid entries in :c:type:`struct nvme_id_ctrl `.psd. This is a 0's + based value. + +``avscc`` + Admin Vendor Specific Command Configuration, see :c:type:`enum + nvme_id_ctrl_avscc `. + +``apsta`` + Autonomous Power State Transition Attributes, see :c:type:`enum + nvme_id_ctrl_apsta `. + +``wctemp`` + Warning Composite Temperature Threshold indicates + the minimum Composite Temperature field value (see :c:type:`struct + nvme_smart_log `.critical_comp_time) that indicates an overheating + condition during which controller operation continues. + +``cctemp`` + Critical Composite Temperature Threshold, field indicates the + minimum Composite Temperature field value (see :c:type:`struct + nvme_smart_log `.critical_comp_time) that indicates a critical + overheating condition. + +``mtfa`` + Maximum Time for Firmware Activation indicates the maximum time + the controller temporarily stops processing commands to activate + the firmware image, specified in 100 millisecond units. This + field is always valid if the controller supports firmware + activation without a reset. + +``hmpre`` + Host Memory Buffer Preferred Size indicates the preferred size + that the host is requested to allocate for the Host Memory + Buffer feature in 4 KiB units. + +``hmmin`` + Host Memory Buffer Minimum Size indicates the minimum size that + the host is requested to allocate for the Host Memory Buffer + feature in 4 KiB units. + +``tnvmcap`` + Total NVM Capacity, the total NVM capacity in the NVM subsystem. + The value is in bytes. + +``unvmcap`` + Unallocated NVM Capacity, the unallocated NVM capacity in the + NVM subsystem. The value is in bytes. + **rpmbs** Replay Protected Memory Block Support, see :c:type:`enum + nvme_id_ctrl_rpmbs `. + **edstt** Extended Device Self-test Time, if Device Self-test command is + supported (see :c:type:`struct nvme_id_ctrl `.oacs, ``NVME_CTRL_OACS_SELF_TEST``), + then this field indicates the nominal amount of time in one + minute units that the controller takes to complete an extended + device self-test operation when in power state 0. + +``dsto`` + Device Self-test Options, see :c:type:`enum nvme_id_ctrl_dsto `. + +``fwug`` + Firmware Update Granularity indicates the granularity and + alignment requirement of the firmware image being updated by the + Firmware Image Download command. The value is reported in 4 KiB + units. A value of 0h indicates no information on granularity is + provided. A value of FFh indicates no restriction + +``kas`` + Keep Alive Support indicates the granularity of the Keep Alive + Timer in 100 millisecond units. + +``hctma`` + Host Controlled Thermal Management Attributes, see :c:type:`enum nvme_id_ctrl_hctm `. + +``mntmt`` + Minimum Thermal Management Temperature indicates the minimum + temperature, in degrees Kelvin, that the host may request in the + Thermal Management Temperature 1 field and Thermal Management + Temperature 2 field of a Set Features command with the Feature + Identifier field set to #NVME_FEAT_FID_HCTM. + +``mxtmt`` + Maximum Thermal Management Temperature indicates the maximum + temperature, in degrees Kelvin, that the host may request in the + Thermal Management Temperature 1 field and Thermal Management + Temperature 2 field of the Set Features command with the Feature + Identifier set to #NVME_FEAT_FID_HCTM. + +``sanicap`` + Sanitize Capabilities, see :c:type:`enum nvme_id_ctrl_sanicap ` + +``hmminds`` + Host Memory Buffer Minimum Descriptor Entry Size indicates the + minimum usable size of a Host Memory Buffer Descriptor Entry in + 4 KiB units. + +``hmmaxd`` + Host Memory Maximum Descriptors Entries indicates the number of + usable Host Memory Buffer Descriptor Entries. + +``nsetidmax`` + NVM Set Identifier Maximum, defines the maximum value of a valid + NVM Set Identifier for any controller in the NVM subsystem. + +``endgidmax`` + Endurance Group Identifier Maximum, defines the maximum value of + a valid Endurance Group Identifier for any controller in the NVM + subsystem. + +``anatt`` + ANA Transition Time indicates the maximum amount of time, in + seconds, for a transition between ANA states or the maximum + amount of time, in seconds, that the controller reports the ANA + change state. + +``anacap`` + Asymmetric Namespace Access Capabilities, see :c:type:`enum + nvme_id_ctrl_anacap `. + +``anagrpmax`` + ANA Group Identifier Maximum indicates the maximum value of a + valid ANA Group Identifier for any controller in the NVM + subsystem. + +``nanagrpid`` + Number of ANA Group Identifiers indicates the number of ANA + groups supported by this controller. + +``pels`` + Persistent Event Log Size indicates the maximum reportable size + for the Persistent Event Log. + +``sqes`` + Submission Queue Entry Size, see :c:type:`enum nvme_id_ctrl_sqes `. + +``cqes`` + Completion Queue Entry Size, see :c:type:`enum nvme_id_ctrl_cqes `. + +``maxcmd`` + Maximum Outstanding Commands indicates the maximum number of + commands that the controller processes at one time for a + particular queue. +``nn`` + Number of Namespaces indicates the maximum value of a valid + nsid for the NVM subsystem. If the MNAN (:c:type:`struct nvme_id_ctrl `.mnan + field is cleared to 0h, then this field also indicates the + maximum number of namespaces supported by the NVM. subsystem. +``oncs`` + Optional NVM Command Support, see :c:type:`enum nvme_id_ctrl_oncs `. +``fuses`` + Fused Operation Support, see :c:type:`enum nvme_id_ctrl_fuses `. +``fna`` + Format NVM Attributes, see :c:type:`enum nvme_id_ctrl_fna `. -.. c:type:: enum +``vwc`` + Volatile Write Cache, see :c:type:`enum nvme_id_ctrl_vwc `. + +``awun`` + Atomic Write Unit Normal indicates the size of the write + operation guaranteed to be written atomically to the NVM across + all namespaces with any supported namespace format during normal + operation. This field is specified in logical blocks and is a + 0's based value. + +``awupf`` + Atomic Write Unit Power Fail indicates the size of the write + operation guaranteed to be written atomically to the NVM across + all namespaces with any supported namespace format during a + power fail or error condition. This field is specified in + logical blocks and is a 0’s based value. + +``nvscc`` + NVM Vendor Specific Command Configuration, see :c:type:`enum + nvme_id_ctrl_nvscc `. + +``nwpc`` + Namespace Write Protection Capabilities, see :c:type:`enum + nvme_id_ctrl_nwpc `. + +``acwu`` + Atomic Compare & Write Unit indicates the size of the write + operation guaranteed to be written atomically to the NVM across + all namespaces with any supported namespace format for a Compare + and Write fused operation. This field is specified in logical + blocks and is a 0’s based value. + +``sgls`` + SGL Support, see :c:type:`enum nvme_id_ctrl_sgls ` + +``mnan`` + Maximum Number of Allowed Namespaces indicates the maximum + number of namespaces supported by the NVM subsystem. + +``subnqn`` + NVM Subsystem NVMe Qualified Name, UTF-8 null terminated string + +``ioccsz`` + I/O Queue Command Capsule Supported Size, defines the maximum + I/O command capsule size in 16 byte units. + +``iorcsz`` + I/O Queue Response Capsule Supported Size, defines the maximum + I/O response capsule size in 16 byte units. + +``icdoff`` + In Capsule Data Offset, defines the offset where data starts + within a capsule. This value is applicable to I/O Queues only. + +``fcatt`` + Fabrics Controller Attributes, see :c:type:`enum nvme_id_ctrl_fcatt `. + +``msdbd`` + Maximum SGL Data Block Descriptors indicates the maximum + number of SGL Data Block or Keyed SGL Data Block descriptors + that a host is allowed to place in a capsule. A value of 0h + indicates no limit. + +``ofcs`` + Optional Fabric Commands Support, see :c:type:`enum nvme_id_ctrl_ofcs `. + +``psd`` + Power State Descriptors, see :c:type:`struct nvme_id_psd `. + +``vs`` + Vendor Specific + + + + + +.. c:type:: enum nvme_id_ctrl_cmic **Constants** @@ -6677,8 +6916,9 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_oaes + The typical latency in microseconds to enter Runtime D3 **Constants** @@ -6695,7 +6935,7 @@ The namespace identifier if a succecssful or -1 with errno set *undescribed* ``NVME_CTRL_OAES_LBAS`` - *undescribed* + : ``NVME_CTRL_OAES_EGE`` *undescribed* @@ -6703,7 +6943,7 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_ctratt **Constants** @@ -6741,14 +6981,11 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_cntrltype **Constants** -``NVME_CTRL_CNTRLTYPE_RESERVED`` - *undescribed* - ``NVME_CTRL_CNTRLTYPE_IO`` *undescribed* @@ -6761,105 +6998,140 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_nvmsr + This field reports information associated with the NVM Subsystem, see :c:type:`struct nvme_id_ctrl `.nvmsr. **Constants** ``NVME_CTRL_NVMSR_NVMESD`` - *undescribed* + If set, then the NVM Subsystem is part of an NVMe + Storage Device; if cleared, then the NVM Subsystem + is not part of an NVMe Storage Device. ``NVME_CTRL_NVMSR_NVMEE`` - *undescribed* + If set’, then the NVM Subsystem is part of an NVMe + Enclosure; if cleared, then the NVM Subsystem is + not part of an NVMe Enclosure. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_vwci + This field indicates information about remaining number of times that VPD contents are able to be updated using the VPD Write command, see :c:type:`struct nvme_id_ctrl `.vwci. **Constants** ``NVME_CTRL_VWCI_VWCR`` - *undescribed* + Mask to get value of VPD Write Cycles Remaining. If + the VPD Write Cycle Remaining Valid bit is set, then + this field contains a value indicating the remaining + number of times that VPD contents are able to be + updated using the VPD Write command. If this field is + set to 7Fh, then the remaining number of times that + VPD contents are able to be updated using the VPD + Write command is greater than or equal to 7Fh. ``NVME_CTRL_VWCI_VWCRV`` - *undescribed* + VPD Write Cycle Remaining Valid. If this bit is set, + then the VPD Write Cycle Remaining field is valid. If + this bit is cleared, then the VPD Write Cycles + Remaining field is invalid and cleared to 0h. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_mec + Flags indicatings the capabilities of the Management Endpoint in the Controller, :c:type:`struct nvme_id_ctrl `.mec. **Constants** ``NVME_CTRL_MEC_SMBUSME`` - *undescribed* + If set, then the NVM Subsystem contains a Management + Endpoint on an SMBus/I2C port. ``NVME_CTRL_MEC_PCIEME`` - *undescribed* + If set, then the NVM Subsystem contains a Management + Endpoint on a PCIe port. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_oacs + Flags indicating the optional Admin commands and features supported by the controller, see :c:type:`struct nvme_id_ctrl `.oacs. **Constants** ``NVME_CTRL_OACS_SECURITY`` - *undescribed* + If set, then the controller supports the + Security Send and Security Receive commands. ``NVME_CTRL_OACS_FORMAT`` - *undescribed* + If set then the controller supports the Format + NVM command. ``NVME_CTRL_OACS_FW`` - *undescribed* + If set, then the controller supports the + Firmware Commit and Firmware Image Download commands. ``NVME_CTRL_OACS_NS_MGMT`` - *undescribed* + If set, then the controller supports the + Namespace Management capability ``NVME_CTRL_OACS_SELF_TEST`` - *undescribed* + If set, then the controller supports the Device + Self-test command. ``NVME_CTRL_OACS_DIRECTIVES`` - *undescribed* + If set, then the controller supports Directives + and the Directive Send and Directive Receive + commands. ``NVME_CTRL_OACS_NVME_MI`` - *undescribed* + If set, then the controller supports the NVMe-MI + Send and NVMe-MI Receive commands. ``NVME_CTRL_OACS_VIRT_MGMT`` - *undescribed* + If set, then the controller supports the + Virtualization Management command. ``NVME_CTRL_OACS_DBBUF_CFG`` - *undescribed* + If set, then the controller supports the + Doorbell Buffer Config command. ``NVME_CTRL_OACS_LBA_STATUS`` - *undescribed* + If set, then the controller supports the Get LBA + Status capability. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_frmw + Flags and values indicates capabilities regarding firmware updates from :c:type:`struct nvme_id_ctrl `.frmw. **Constants** ``NVME_CTRL_FRMW_1ST_RO`` - *undescribed* + If set, the first firmware slot is readonly ``NVME_CTRL_FRMW_NR_SLOTS`` - *undescribed* + Mask to get the value of the number of + firmware slots that the controller supports. ``NVME_CTRL_FRMW_FW_ACT_NO_RESET`` - *undescribed* + If set, the controller supports firmware + activation without a reset. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_lpa + Flags indicating optional attributes for log pages that are accessed via the Get Log Page command. **Constants** @@ -6881,254 +7153,342 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_avscc + Flags indicating the configuration settings for Admin Vendor Specific command handling. **Constants** ``NVME_CTRL_AVSCC_AVS`` - *undescribed* + If set, all Admin Vendor Specific Commands use the + optional vendor specific command format with NDT and + NDM fields. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_apsta + Flags indicating the attributes of the autonomous power state transition feature. **Constants** ``NVME_CTRL_APSTA_APST`` - *undescribed* + If set, then the controller supports autonomous power + state transitions. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_rpmbs + This field indicates if the controller supports one or more Replay Protected Memory Blocks, from :c:type:`struct nvme_id_ctrl `.rpmbs. **Constants** ``NVME_CTRL_RPMBS_NR_UNITS`` - *undescribed* + Mask to get the value of the Number of RPMB Units ``NVME_CTRL_RPMBS_AUTH_METHOD`` - *undescribed* + Mask to get the value of the Authentication Method ``NVME_CTRL_RPMBS_TOTAL_SIZE`` - *undescribed* + Mask to get the value of Total Size ``NVME_CTRL_RPMBS_ACCESS_SIZE`` - *undescribed* + Mask to get the value of Access Size -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_dsto + Flags indicating the optional Device Self-test command or operation behaviors supported by the controller or NVM subsystem. **Constants** ``NVME_CTRL_DSTO_ONE_DST`` - *undescribed* + If set, then the NVM subsystem supports only one + device self-test operation in progress at a time. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_hctm + Flags indicate the attributes of the host controlled thermal management feature **Constants** ``NVME_CTRL_HCTMA_HCTM`` - *undescribed* + then the controller supports host controlled thermal + management, and the Set Features command and Get + Features command with the Feature Identifier field + set to ``NVME_FEAT_FID_HCTM``. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_sanicap + Indicates attributes for sanitize operations. **Constants** ``NVME_CTRL_SANICAP_CES`` - *undescribed* + Crypto Erase Support. If set, then the + controller supports the Crypto Erase sanitize operation. ``NVME_CTRL_SANICAP_BES`` - *undescribed* + Block Erase Support. If set, then the controller + supports the Block Erase sanitize operation. ``NVME_CTRL_SANICAP_OWS`` - *undescribed* + Overwrite Support. If set, then the controller + supports the Overwrite sanitize operation. ``NVME_CTRL_SANICAP_NDI`` - *undescribed* + No-Deallocate Inhibited. If set and the No- + Deallocate Response Mode bit is set, then the + controller deallocates after the sanitize + operation even if the No-Deallocate After + Sanitize bit is set in a Sanitize command. ``NVME_CTRL_SANICAP_NODMMAS`` - *undescribed* + No-Deallocate Modifies Media After Sanitize, + mask to extract value. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_anacap + This field indicates the capabilities associated with Asymmetric Namespace Access Reporting. **Constants** ``NVME_CTRL_ANACAP_OPT`` - *undescribed* + If set, then the controller is able to + report ANA Optimized state. ``NVME_CTRL_ANACAP_NON_OPT`` - *undescribed* + If set, then the controller is able to + report ANA Non-Optimized state. ``NVME_CTRL_ANACAP_INACCESSIBLE`` - *undescribed* + If set, then the controller is able to + report ANA Inaccessible state. ``NVME_CTRL_ANACAP_PERSISTENT_LOSS`` - *undescribed* + If set, then the controller is able to + report ANA Persistent Loss state. ``NVME_CTRL_ANACAP_CHANGE`` - *undescribed* + If set, then the controller is able to + report ANA Change state. ``NVME_CTRL_ANACAP_GRPID_NO_CHG`` - *undescribed* + If set, then the ANAGRPID field in the + Identify Namespace data structure + (:c:type:`struct nvme_id_ns `.anagrpid), does not + change while the namespace is attached to + any controller. ``NVME_CTRL_ANACAP_GRPID_MGMT`` - *undescribed* + If set, then the controller supports a + non-zero value in the ANAGRPID field of + the Namespace Management command. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_sqes + Defines the required and maximum Submission Queue entry size when using the NVM Command Set. **Constants** ``NVME_CTRL_SQES_MIN`` - *undescribed* + Mask to get the value of the required Submission Queue + Entry size when using the NVM Command Set. ``NVME_CTRL_SQES_MAX`` - *undescribed* + Mask to get the value of the maximum Submission Queue + entry size when using the NVM Command Set. .. c:type:: enum + Defines the required and maximum Completion Queue entry size when using the NVM Command Set. **Constants** ``NVME_CTRL_CQES_MIN`` - *undescribed* + Mask to get the value of the required Completion Queue + Entry size when using the NVM Command Set. ``NVME_CTRL_CQES_MAX`` - *undescribed* + Mask to get the value of the maximum Completion Queue + entry size when using the NVM Command Set. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_oncs + This field indicates the optional NVM commands and features supported by the controller. **Constants** ``NVME_CTRL_ONCS_COMPARE`` - *undescribed* + If set, then the controller supports + the Compare command. ``NVME_CTRL_ONCS_WRITE_UNCORRECTABLE`` - *undescribed* + If set, then the controller supports + the Write Uncorrectable command. ``NVME_CTRL_ONCS_DSM`` - *undescribed* + If set, then the controller supports + the Dataset Management command. ``NVME_CTRL_ONCS_WRITE_ZEROES`` - *undescribed* + If set, then the controller supports + the Write Zeroes command. ``NVME_CTRL_ONCS_SAVE_FEATURES`` - *undescribed* + If set, then the controller supports + the Save field set to a non-zero value + in the Set Features command and the + Select field set to a non-zero value in + the Get Features command. ``NVME_CTRL_ONCS_RESERVATIONS`` - *undescribed* + If set, then the controller supports + reservations. ``NVME_CTRL_ONCS_TIMESTAMP`` - *undescribed* + If set, then the controller supports + the Timestamp feature. ``NVME_CTRL_ONCS_VERIFY`` - *undescribed* + If set, then the controller supports + the Verify command. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_fuses + This field indicates the fused operations that the controller supports. **Constants** ``NVME_CTRL_FUSES_COMPARE_AND_WRITE`` - *undescribed* + If set, then the controller supports the + Compare and Write fused operation. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_fna + This field indicates attributes for the Format NVM command. **Constants** ``NVME_CTRL_FNA_FMT_ALL_NAMESPACES`` - *undescribed* + If set, then all namespaces in an NVM + subsystem shall be configured with the + same attributes and a format (excluding + secure erase) of any namespace results in + a format of all namespaces in an NVM + subsystem. If cleared, then the + controller supports format on a per + namespace basis. ``NVME_CTRL_FNA_SEC_ALL_NAMESPACES`` - *undescribed* + If set, then any secure erase performed + as part of a format operation results in + a secure erase of all namespaces in the + NVM subsystem. If cleared, then any + secure erase performed as part of a + format results in a secure erase of the + particular namespace specified. ``NVME_CTRL_FNA_CRYPTO_ERASE`` - *undescribed* + If set, then cryptographic erase is + supported. If cleared, then cryptographic + erase is not supported. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_vwc **Constants** ``NVME_CTRL_VWC_PRESENT`` - *undescribed* + If set, indicates a volatile write cache is present. + If a volatile write cache is present, then the host + controls whether the volatile write cache is enabled + with a Set Features command specifying the value + ``NVME_FEAT_FID_VOLATILE_WC``. ``NVME_CTRL_VWC_FLUSH`` - *undescribed* + Mask to get the value of the flush command behavior. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_nvscc + This field indicates the configuration settings for NVM Vendor Specific command handling. **Constants** ``NVME_CTRL_NVSCC_FMT`` - *undescribed* + If set, all NVM Vendor Specific Commands use the + format format with NDT and NDM fields. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_nwpc + This field indicates the optional namespace write protection capabilities supported by the controller. **Constants** ``NVME_CTRL_NWPC_WRITE_PROTECT`` - *undescribed* + If set, then the controller shall + support the No Write Protect and + Write Protect namespace write + protection states and may support + the Write Protect Until Power + Cycle state and Permanent Write + Protect namespace write + protection states. ``NVME_CTRL_NWPC_WRITE_PROTECT_POWER_CYCLE`` - *undescribed* + If set, then the controller + supports the Write Protect Until + Power Cycle state. ``NVME_CTRL_NWPC_WRITE_PROTECT_PERMANENT`` - *undescribed* + If set, then the controller + supports the Permanent Write + Protect state. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_sgls + This field indicates if SGLs are supported for the NVM Command Set and the particular SGL types supported. **Constants** @@ -7159,30 +7519,37 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_fcatt + This field indicates attributes of the controller that are specific to NVMe over Fabrics. **Constants** ``NVME_CTRL_FCATT_DYNAMIC`` - *undescribed* + If cleared, then the NVM subsystem uses a dynamic + controller model. If set, then the NVM subsystem + uses a static controller model. -.. c:type:: enum +.. c:type:: enum nvme_id_ctrl_ofcs + Indicate whether the controller supports optional fabric commands. **Constants** ``NVME_CTRL_OFCS_DISCONNECT`` - *undescribed* + If set, then the controller supports the + Disconnect command and deletion of individual + I/O Queues. .. c:type:: struct nvme_lbaf + LBA Format Data Structure **Definition** @@ -7196,35 +7563,49 @@ The namespace identifier if a succecssful or -1 with errno set **Members** +``ms`` + Metadata Size indicates the number of metadata bytes provided per LBA + based on the LBA Data Size indicated. +``ds`` + LBA Data Size indicates the LBA data size supported, reported as a + power of two. + +``rp`` + Relative Performance, see :c:type:`enum nvme_lbaf_rp `. -.. c:type:: enum +.. c:type:: enum nvme_lbaf_rp + + This field indicates the relative performance of the LBA format indicated relative to other LBA formats supported by the controller. + **Constants** ``NVME_LBAF_RP_BEST`` - *undescribed* + Best performance ``NVME_LBAF_RP_BETTER`` - *undescribed* + Better performance ``NVME_LBAF_RP_GOOD`` - *undescribed* + Good performance ``NVME_LBAF_RP_DEGRADED`` - *undescribed* + Degraded performance ``NVME_LBAF_RP_MASK`` - *undescribed* + Mask to get the relative performance value from the + field .. c:type:: struct nvme_id_ns + Identify Namespace data structure **Definition** @@ -7272,200 +7653,415 @@ The namespace identifier if a succecssful or -1 with errno set **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. + +``nuse`` + Namespace Utilization indicates the current number of logical + blocks allocated in the namespace. This field is smaller than or + equal to the Namespace Capacity. The number of logical blocks is + based on the formatted LBA size. + +``nsfeat`` + Namespace Features, see :c:type:`enum nvme_id_nsfeat `. + +``nlbaf`` + Number of LBA Formats defines the number of supported LBA data + size and metadata size combinations supported by the namespace + and the highest possible index to :c:type:`struct nvme_id_ns `.labf. + +``flbas`` + Formatted LBA Size, see :c:type:`enum nvme_id_ns_flbas `. + +``mc`` + Metadata Capabilities, see :c:type:`enum nvme_id_ns_mc `. + +``dpc`` + End-to-end Data Protection Capabilities, see :c:type:`enum + nvme_id_ns_dpc `. + +``dps`` + End-to-end Data Protection Type Settings, see :c:type:`enum + nvme_id_ns_dps `. + +``nmic`` + Namespace Multi-path I/O and Namespace Sharing Capabilities, see + :c:type:`enum nvme_id_ns_nmic `. + +``rescap`` + Reservation Capabilities, see :c:type:`enum nvme_id_ns_rescap `. + +``fpi`` + Format Progress Indicator, see :c:type:`enum nvme_nd_ns_fpi `. + +``dlfeat`` + Deallocate Logical Block Features, see :c:type:`enum nvme_id_ns_dlfeat `. + +``nawun`` + Namespace Atomic Write Unit Normal indicates the + namespace specific size of the write operation guaranteed to be + written atomically to the NVM during normal operation. + +``nawupf`` + Namespace Atomic Write Unit Power Fail indicates the + namespace specific size of the write operation guaranteed to be + written atomically to the NVM during a power fail or error + condition. + +``nacwu`` + Namespace Atomic Compare & Write Unit indicates the namespace + specific size of the write operation guaranteed to be written + atomically to the NVM for a Compare and Write fused command. + +``nabsn`` + Namespace Atomic Boundary Size Normal indicates the atomic + boundary size for this namespace for the NAWUN value. This field + is specified in logical blocks. + +``nabo`` + Namespace Atomic Boundary Offset indicates the LBA on this + namespace where the first atomic boundary starts. + +``nabspf`` + Namespace Atomic Boundary Size Power Fail indicates the atomic + boundary size for this namespace specific to the Namespace Atomic + Write Unit Power Fail value. This field is specified in logical + blocks. + +``noiob`` + Namespace Optimal I/O Boundary indicates the optimal I/O boundary + for this namespace. This field is specified in logical blocks. + The host should construct Read and Write commands that do not + cross the I/O boundary to achieve optimal performance. + +``nvmcap`` + NVM Capacity indicates the total size of the NVM allocated to + this namespace. The value is in bytes. + +``npwg`` + Namespace Preferred Write Granularity indicates the smallest + recommended write granularity in logical blocks for this + namespace. This is a 0's based value. + +``npwa`` + Namespace Preferred Write Alignment indicates the recommended + write alignment in logical blocks for this namespace. This is a + 0's based value. + +``npdg`` + Namespace Preferred Deallocate Granularity indicates the + recommended granularity in logical blocks for the Dataset + Management command with the Attribute - Deallocate bit. + +``npda`` + Namespace Preferred Deallocate Alignment indicates the + recommended alignment in logical blocks for the Dataset + Management command with the Attribute - Deallocate bit + +``nows`` + Namespace Optimal Write Size indicates the size in logical blocks + for optimal write performance for this namespace. This is a 0's + based value. + +``anagrpid`` + ANA Group Identifier indicates the ANA Group Identifier of the + ANA group of which the namespace is a member. + +``nsattr`` + Namespace Attributes, see :c:type:`enum nvme_id_ns_attr `. + +``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. + +``nguid`` + Namespace Globally Unique Identifier contains a 128-bit value + that is globally unique and assigned to the namespace when the + namespace is created. This field remains fixed throughout the + life of the namespace and is preserved across namespace and + controller operations + +``eui64`` + IEEE Extended Unique Identifier contains a 64-bit IEEE Extended + Unique Identifier (EUI-64) that is globally unique and assigned + to the namespace when the namespace is created. This field + remains fixed throughout the life of the namespace and is + preserved across namespace and controller operations + +``lbaf`` + LBA Format, see :c:type:`struct nvme_lbaf `. + +``vs`` + Vendor Specific + -.. c:type:: enum +.. c:type:: enum nvme_id_nsfeat + This field defines features of the namespace. **Constants** ``NVME_NS_FEAT_THIN`` - *undescribed* + If set, indicates that the namespace supports thin + provisioning. Specifically, the Namespace Capacity + reported may be less than the Namespace Size. ``NVME_NS_FEAT_NATOMIC`` - *undescribed* + If set, indicates that the fields NAWUN, NAWUPF, and + NACWU are defined for this namespace and should be + used by the host for this namespace instead of the + AWUN, AWUPF, and ACWU fields in the Identify + Controller data structure. ``NVME_NS_FEAT_DULBE`` - *undescribed* + If set, indicates that the controller supports the + Deallocated or Unwritten Logical Block error for + this namespace. **NVME_NS_FEAT_ID_REUSE**: If set, + indicates that the value in the NGUID field for this + namespace, if non- zero, is never reused by the + controller and that the value in the EUI64 field for + this namespace, if non-zero, is never reused by the + controller. ``NVME_NS_FEAT_ID_REUSE`` *undescribed* ``NVME_NS_FEAT_IO_OPT`` - *undescribed* + If set, indicates that the fields NPWG, NPWA, NPDG, + NPDA, and NOWS are defined for this namespace and + should be used by the host for I/O optimization -.. c:type:: enum +.. c:type:: enum nvme_id_ns_flbas + This field indicates the LBA data size & metadata size combination that the namespace has been formatted with **Constants** ``NVME_NS_FLBAS_LBA_MASK`` - *undescribed* + Mask to get the index of one of the 16 supported + LBA Formats indicated in :c:type:`struct nvme_id_ns `.lbaf. ``NVME_NS_FLBAS_META_EXT`` - *undescribed* + Applicable only if format contains metadata. If + this bit is set, indicates that the metadata is + transferred at the end of the data LBA, creating an + extended data LBA. If cleared, indicates that all + of the metadata for a command is transferred as a + separate contiguous buffer of data. -.. c:type:: enum +.. c:type:: enum nvme_id_ns_mc + This field indicates the capabilities for metadata. **Constants** ``NVME_NS_MC_EXTENDED`` - *undescribed* + If set, indicates the namespace supports the metadata + being transferred as part of a separate buffer that is + specified in the Metadata Pointer. ``NVME_NS_MC_SEPARATE`` - *undescribed* + If set, indicates that the namespace supports the + metadata being transferred as part of an extended data LBA. -.. c:type:: enum +.. c:type:: enum nvme_id_ns_dpc + This field indicates the capabilities for the end-to-end data protection feature. **Constants** ``NVME_NS_DPC_PI_TYPE1`` - *undescribed* + If set, indicates that the namespace supports + Protection Information Type 1. ``NVME_NS_DPC_PI_TYPE2`` - *undescribed* + If set, indicates that the namespace supports + Protection Information Type 2. ``NVME_NS_DPC_PI_TYPE3`` - *undescribed* + If set, indicates that the namespace supports + Protection Information Type 3. ``NVME_NS_DPC_PI_FIRST`` - *undescribed* + If set, indicates that the namespace supports + protection information transferred as the first eight + bytes of metadata. ``NVME_NS_DPC_PI_LAST`` - *undescribed* + If set, indicates that the namespace supports + protection information transferred as the last eight + bytes of metadata. -.. c:type:: enum +.. c:type:: enum nvme_id_ns_dps + This field indicates the Type settings for the end-to-end data protection feature. **Constants** ``NVME_NS_DPS_PI_NONE`` - *undescribed* + Protection information is not enabled ``NVME_NS_DPS_PI_TYPE1`` - *undescribed* + Protection information is enabled, Type 1 ``NVME_NS_DPS_PI_TYPE2`` - *undescribed* + Protection information is enabled, Type 2 ``NVME_NS_DPS_PI_TYPE3`` - *undescribed* + Protection information is enabled, Type 3 ``NVME_NS_DPS_PI_MASK`` - *undescribed* + Mask to get the value of the PI type ``NVME_NS_DPS_PI_FIRST`` - *undescribed* + If set, indicates that the protection information, if + enabled, is transferred as the first eight bytes of + metadata. -.. c:type:: enum +.. c:type:: enum nvme_id_ns_nmic + This field specifies multi-path I/O and namespace sharing capabilities of the namespace. **Constants** ``NVME_NS_NMIC_SHARED`` - *undescribed* + If set, then the namespace may be attached to two or + more controllers in the NVM subsystem concurrently -.. c:type:: enum +.. c:type:: enum nvme_id_ns_rescap + This field indicates the reservation capabilities of the namespace. **Constants** ``NVME_NS_RESCAP_PTPL`` - *undescribed* + If set, indicates that the namespace supports the + Persist Through Power Loss capability. ``NVME_NS_RESCAP_WE`` - *undescribed* + If set, indicates that the namespace supports the + Write Exclusive reservation type. ``NVME_NS_RESCAP_EA`` - *undescribed* + If set, indicates that the namespace supports the + Exclusive Access reservation type. ``NVME_NS_RESCAP_WERO`` - *undescribed* + If set, indicates that the namespace supports the + Write Exclusive - Registrants Only reservation type. ``NVME_NS_RESCAP_EARO`` - *undescribed* + If set, indicates that the namespace supports the + Exclusive Access - Registrants Only reservation type. ``NVME_NS_RESCAP_WEAR`` - *undescribed* + If set, indicates that the namespace supports the + Write Exclusive - All Registrants reservation type. ``NVME_NS_RESCAP_EAAR`` - *undescribed* + If set, indicates that the namespace supports the + Exclusive Access - All Registrants reservation type. ``NVME_NS_RESCAP_IEK_13`` - *undescribed* + If set, indicates that Ignore Existing Key is used + as defined in revision 1.3 or later of this specification. -.. c:type:: enum +.. c:type:: 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. **Constants** ``NVME_NS_FPI_REMAINING`` - *undescribed* + Mask to get the format percent remaining value ``NVME_NS_FPI_SUPPORTED`` - *undescribed* + If set, indicates that the namespace supports the + Format Progress Indicator defined for the field. -.. c:type:: enum +.. c:type:: enum nvme_id_ns_dlfeat + This field indicates information about features that affect deallocating logical blocks for this namespace. **Constants** ``NVME_NS_DLFEAT_RB`` - *undescribed* + Mask to get the value of the read behavior ``NVME_NS_DLFEAT_RB_NR`` - *undescribed* + Read behvaior is not reported ``NVME_NS_DLFEAT_RB_ALL_0S`` - *undescribed* + A deallocated logical block returns all bytes + cleared to 0h. ``NVME_NS_DLFEAT_RB_ALL_FS`` - *undescribed* + A deallocated logical block returns all bytes + set to FFh. ``NVME_NS_DLFEAT_WRITE_ZEROES`` - *undescribed* + If set, indicates that the controller supports + the Deallocate bit in the Write Zeroes command + for this namespace. ``NVME_NS_DLFEAT_CRC_GUARD`` - *undescribed* + If set, indicates that the Guard field for + deallocated logical blocks that contain + protection information is set to the CRC for + the value read from the deallocated logical + block and its metadata -.. c:type:: enum +.. c:type:: enum nvme_id_ns_attr + Specifies attributes of the namespace. **Constants** ``NVME_NS_NSATTR_WRITE_PROTECTED`` - *undescribed* + If set, then the namespace is currently + write protected and all write access to the + namespace shall fail. @@ -7486,29 +8082,46 @@ The namespace identifier if a succecssful or -1 with errno set **Members** +``nidt`` + Namespace Identifier Type, see :c:type:`enum nvme_ns_id_desc_nidt ` +``nidl`` + Namespace Identifier Length contains the length in bytes of the + :c:type:`struct nvme_id_ns `.nid. +``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 :c:type:`struct nvme_id_ns `.nidl. -.. c:type:: enum + +.. c:type:: enum nvme_ns_id_desc_nidt + + Known namespace identifier types + **Constants** ``NVME_NIDT_EUI64`` - *undescribed* + IEEE Extended Unique Identifier, the NID field contains a + copy of the EUI64 field in the struct nvme_id_ns.eui64. ``NVME_NIDT_NGUID`` - *undescribed* + Namespace Globally Unique Identifier, the NID field + contains a copy of the NGUID field in struct nvme_id_ns.nguid. ``NVME_NIDT_UUID`` - *undescribed* + The NID field contains a 128-bit Universally Unique + Identifier (UUID) as specified in RFC 4122. .. c:type:: struct nvme_nvmset_attr + NVM Set Attributes Entry **Definition** @@ -7527,12 +8140,26 @@ The namespace identifier if a succecssful or -1 with errno set **Members** +``id`` + NVM Set Identifier + +``endurance_group_id`` + Endurance Group Identifier + +``random_4k_read_typical`` + 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. + .. c:type:: struct nvme_id_nvmset_list + **nid**; **Definition** @@ -7546,18 +8173,21 @@ The namespace identifier if a succecssful or -1 with errno set **Members** +``ent`` + ; + -.. c:type:: struct nvme_id_ns_granularity_list_entry +.. c:type:: struct nvme_id_ns_granularity_desc **Definition** :: - struct nvme_id_ns_granularity_list_entry { + struct nvme_id_ns_granularity_desc { __le64 namespace_size_granularity; __le64 namespace_capacity_granularity; }; @@ -7579,7 +8209,8 @@ The namespace identifier if a succecssful or -1 with errno set __le32 attributes; __u8 num_descriptors; __u8 rsvd[27]; - struct nvme_id_ns_granularity_list_entry entry[16]; + struct nvme_id_ns_granularity_desc entry[NVME_ID_ND_DESCRIPTOR_MAX]; + __u8 rsvd288[3808]; }; **Members** @@ -7647,6 +8278,7 @@ The namespace identifier if a succecssful or -1 with errno set .. c:type:: struct nvme_ctrl_list + **num**; **Definition** @@ -7740,6 +8372,7 @@ The namespace identifier if a succecssful or -1 with errno set .. c:type:: struct nvme_secondary_ctrl_list + **num**; **Definition** @@ -7755,9 +8388,6 @@ The namespace identifier if a succecssful or -1 with errno set -**NVMe Logs** - - .. c:type:: struct nvme_error_log_page @@ -8537,9 +9167,6 @@ The namespace identifier if a succecssful or -1 with errno set -**NVMe Directives** - - .. c:type:: enum @@ -8604,46 +9231,17 @@ The namespace identifier if a succecssful or -1 with errno set -**NVMe Management Interface** - - - - -.. c:type:: struct nvme_mi_read_nvm_ss_info - - -**Definition** - -:: - - struct nvme_mi_read_nvm_ss_info { - __u8 nump; - __u8 mjr; - __u8 mnr; - __u8 rsvd3[29]; - }; - -**Members** - - - -.. c:type:: struct nvme_mi_port_pcie +.. c:type:: struct nvme_feat_auto_pst **Definition** :: - struct nvme_mi_port_pcie { - __u8 mps; - __u8 sls; - __u8 cls; - __u8 mlw; - __u8 nlw; - __u8 pn; - __u8 rsvd14[18]; + struct nvme_feat_auto_pst { + __le64 apst_entry[32]; }; **Members** @@ -8652,20 +9250,18 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: struct nvme_mi_port_smb +.. c:type:: struct nvme_timestamp + timestamp: **Definition** :: - struct nvme_mi_port_smb { - __u8 vpd_addr; - __u8 mvpd_freq; - __u8 mme_addr; - __u8 mme_freq; - __u8 nvmebm; - __u8 rsvd13[19]; + struct nvme_timestamp { + __u8 timestamp[6]; + __u8 attr; + __u8 rsvd; }; **Members** @@ -8674,86 +9270,67 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: struct nvme_mi_read_port_info +.. c:type:: struct nvme_lba_range_type_entry **Definition** :: - 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; - }; + struct nvme_lba_range_type_entry { + __u8 type; + __u8 attributes; + __u8 rsvd2[14]; + __u64 slba; + __u64 nlb; + __u8 guid[16]; + __u8 rsvd48[16]; }; **Members** -``{unnamed_union}`` - anonymous - - - - - -.. c:type:: struct nvme_mi_read_ctrl_info -**Definition** - -:: - - struct nvme_mi_read_ctrl_info { - __u8 portid; - __u8 rsvd1[4]; - __u8 prii; - __le16 pri; - __le16 vid; - __le16 did; - __le16 ssvid; - __le16 ssid; - __u8 rsvd16[16]; - }; - -**Members** +.. c:type:: enum +**Constants** -.. c:type:: struct nvme_mi_osc +``NVME_LBART_TYPE_GP`` + *undescribed* +``NVME_LBART_TYPE_FS`` + *undescribed* -**Definition** +``NVME_LBART_TYPE_RAID`` + *undescribed* -:: +``NVME_LBART_TYPE_CACHE`` + *undescribed* - struct nvme_mi_osc { - __u8 type; - __u8 opc; - }; +``NVME_LBART_TYPE_SWAP`` + *undescribed* -**Members** +``NVME_LBART_ATTRIB_TEMP`` + *undescribed* +``NVME_LBART_ATTRIB_HIDE`` + *undescribed* -.. c:type:: struct nvme_mi_read_sc_list +.. c:type:: struct nvme_lba_range_type **Definition** :: - struct nvme_mi_read_sc_list { - __le16 numcmd; - struct nvme_mi_osc cmds[]; + struct nvme_lba_range_type { + struct nvme_lba_range_type_entry entry[NVME_FEAT_LBA_RANGE_MAX]; }; **Members** @@ -8762,20 +9339,21 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: struct nvme_mi_nvm_ss_health_status +.. c:type:: struct nvme_plm_config + **ee**; **dtwinrt**; **dtwinwt**; **dtwintt**; **Definition** :: - struct nvme_mi_nvm_ss_health_status { - __u8 nss; - __u8 sw; - __u8 ctemp; - __u8 pdlu; - __le16 ccs; - __u8 rsvd8[2]; + struct nvme_plm_config { + __le16 ee; + __u8 rsvd2[30]; + __le64 dtwinrt; + __le64 dtwinwt; + __le64 dtwintt; + __u8 rsvd56[456]; }; **Members** @@ -8784,65 +9362,16 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: enum - - -**Constants** - -``NVME_MI_CCS_RDY`` - *undescribed* - -``NVME_MI_CSS_CFS`` - *undescribed* - -``NVME_MI_CSS_SHST`` - *undescribed* - -``NVME_MI_CSS_NSSRO`` - *undescribed* - -``NVME_MI_CSS_CECO`` - *undescribed* - -``NVME_MI_CSS_NAC`` - *undescribed* - -``NVME_MI_CSS_FA`` - *undescribed* - -``NVME_MI_CSS_CSTS`` - *undescribed* - -``NVME_MI_CSS_CTEMP`` - *undescribed* - -``NVME_MI_CSS_PDLU`` - *undescribed* - -``NVME_MI_CSS_SPARE`` - *undescribed* - -``NVME_MI_CSS_CCWARN`` - *undescribed* - - - - -.. c:type:: struct nvme_mi_ctrl_heal_status +.. c:type:: struct nvme_feat_host_behavior **Definition** :: - struct nvme_mi_ctrl_heal_status { - __le16 ctlid; - __le16 csts; - __le16 ctemp; - __u8 pdlu; - __u8 spare; - __u8 cwarn; - __u8 rsvd9[7]; + struct nvme_feat_host_behavior { + __u8 acre; + __u8 resv1[511]; }; **Members** @@ -8856,69 +9385,44 @@ The namespace identifier if a succecssful or -1 with errno set **Constants** -``NVME_MI_CSTS_RDY`` - *undescribed* - -``NVME_MI_CSTS_CFS`` +``NVME_ENABLE_ACRE`` *undescribed* -``NVME_MI_CSTS_SHST`` - *undescribed* -``NVME_MI_CSTS_NSSRO`` - *undescribed* -``NVME_MI_CSTS_CECO`` - *undescribed* -``NVME_MI_CSTS_NAC`` - *undescribed* +.. c:type:: struct nvme_dsm_range -``NVME_MI_CSTS_FA`` - *undescribed* -``NVME_MI_CWARN_ST`` - *undescribed* +**Definition** -``NVME_MI_CWARN_TAUT`` - *undescribed* +:: -``NVME_MI_CWARN_RD`` - *undescribed* + struct nvme_dsm_range { + __le32 cattr; + __le32 nlb; + __le64 slba; + }; -``NVME_MI_CWARN_RO`` - *undescribed* +**Members** -``NVME_MI_CWARN_VMBF`` - *undescribed* -.. c:type:: struct nvme_mi_vpd_mra +.. c:type:: struct nvme_registered_ctrl **Definition** :: - 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]; + struct nvme_registered_ctrl { + __le16 cntlid; + __u8 rcsts; + __u8 rsvd3[5]; + __le64 hostid; + __le64 rkey; }; **Members** @@ -8927,23 +9431,20 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: struct nvme_mi_vpd_ppmra +.. c:type:: struct nvme_registered_ctrl_ext **Definition** :: - struct nvme_mi_vpd_ppmra { - __u8 nppmravn; - __u8 pn; - __u8 ppi; - __u8 ls; - __u8 mlw; - __u8 mctp; - __u8 refccap; - __u8 pi; - __u8 rsvd13[3]; + struct nvme_registered_ctrl_ext { + __le16 cntlid; + __u8 rcsts; + __u8 resv3[5]; + __le64 rkey; + __u8 hostid[16]; + __u8 resv32[32]; }; **Members** @@ -8952,67 +9453,78 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: struct nvme_mi_vpd_telem +.. c:type:: struct nvme_reservation_status + { **Definition** :: - struct nvme_mi_vpd_telem { - __u8 type; - __u8 rev; - __u8 len; - __u8 data[0]; + struct nvme_reservation_status { + __le32 gen; + __u8 rtype; + __u8 regctl[2]; + __u8 rsvd7[2]; + __u8 ptpls; + __u8 rsvd10[14]; + union { + struct { + __u8 resv24[40]; + struct nvme_registered_ctrl_ext regctl_eds[0]; + }; + struct nvme_registered_ctrl regctl_ds[0]; + }; }; **Members** +``{unnamed_union}`` + anonymous +``{unnamed_struct}`` + anonymous -.. c:type:: enum - -**Constants** -``NVME_MI_ELEM_EED`` - *undescribed* +.. c:type:: struct nvme_streams_directive_params -``NVME_MI_ELEM_USCE`` - *undescribed* -``NVME_MI_ELEM_ECED`` - *undescribed* +**Definition** -``NVME_MI_ELEM_LED`` - *undescribed* +:: -``NVME_MI_ELEM_SMBMED`` - *undescribed* + struct nvme_streams_directive_params { + __le16 msl; + __le16 nssa; + __le16 nsso; + __u8 nssc; + __u8 rsvd[9]; + __le32 sws; + __le16 sgs; + __le16 nsa; + __le16 nso; + __u8 rsvd2[6]; + }; -``NVME_MI_ELEM_PCIESED`` - *undescribed* +**Members** -``NVME_MI_ELEM_NVMED`` - *undescribed* -.. c:type:: struct nvme_mi_vpd_tra +.. c:type:: struct nvme_streams_directive_status **Definition** :: - struct nvme_mi_vpd_tra { - __u8 vn; - __u8 rsvd6; - __u8 ec; - struct nvme_mi_vpd_telem elems[0]; + struct nvme_streams_directive_status { + __le16 osc; + __le16 sid[]; }; **Members** @@ -9021,160 +9533,222 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: struct nvme_mi_vpd_mr_common +.. c:type:: struct nvme_id_directives **Definition** :: - 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; - }; + struct nvme_id_directives { + __u8 supported[32]; + __u8 enabled[32]; + __u8 rsvd64[4032]; }; **Members** -``{unnamed_union}`` - anonymous +.. c:type:: enum -.. c:type:: struct nvme_mi_vpd_hdr + +**Constants** + +``NVME_ID_DIR_ID_BIT`` + *undescribed* + +``NVME_ID_DIR_SD_BIT`` + *undescribed* + + + + +.. c:type:: struct nvme_host_mem_buf_desc **Definition** :: - struct nvme_mi_vpd_hdr { - __u8 ipmiver; - __u8 iuaoff; - __u8 ciaoff; - __u8 biaoff; - __u8 piaoff; - __u8 mrioff; - __u8 rsvd6; - __u8 chchk; - __u8 vpd[]; + struct nvme_host_mem_buf_desc { + __le64 addr; + __le32 size; + __u32 rsvd; }; **Members** -**NVMe Features** +.. c:type:: enum nvme_ae_type -.. c:type:: struct nvme_feat_auto_pst +**Constants** +``NVME_AER_ERROR`` + *undescribed* -**Definition** +``NVME_AER_SMART`` + *undescribed* -:: +``NVME_AER_NOTICE`` + *undescribed* - struct nvme_feat_auto_pst { - __le64 apst_entry[32]; - }; +``NVME_AER_CSS`` + *undescribed* -**Members** +``NVME_AER_VS`` + *undescribed* +.. c:type:: enum nvme_ae_info_error -.. c:type:: struct nvme_timestamp +**Constants** -**Definition** +``NVME_AER_ERROR_INVALID_DB_REG`` + *undescribed* -:: +``NVME_AER_ERROR_INVALID_DB_VAL`` + *undescribed* - struct nvme_timestamp { - __u8 timestamp[6]; - __u8 attr; - __u8 rsvd; - }; +``NVME_AER_ERROR_DIAG_FAILURE`` + *undescribed* -**Members** +``NVME_AER_ERROR_PERSISTENT_INTERNAL_ERROR`` + *undescribed* + +``NVME_AER_ERROR_TRANSIENT_INTERNAL_ERROR`` + *undescribed* +``NVME_AER_ERROR_FW_IMAGE_LOAD_ERROR`` + *undescribed* -.. c:type:: struct nvme_lba_range_type_entry +.. c:type:: enum nvme_ae_info_smart -**Definition** +**Constants** + +``NVME_AER_SMART_SUBSYSTEM_RELIABILITY`` + *undescribed* + +``NVME_AER_SMART_TEMPERATURE_THRESHOLD`` + *undescribed* + +``NVME_AER_SMART_SPARE_THRESHOLD`` + *undescribed* + + + + +.. c:type:: enum nvme_ae_info_css_nvm + -:: +**Constants** - struct nvme_lba_range_type_entry { - __u8 type; - __u8 attributes; - __u8 rsvd2[14]; - __u64 slba; - __u64 nlb; - __u8 guid[16]; - __u8 rsvd48[16]; - }; +``NVME_AER_CSS_NVM_RESERVATION`` + *undescribed* -**Members** +``NVME_AER_CSS_NVM_SANITIZE_COMPLETED`` + *undescribed* +``NVME_AER_CSS_NVM_UNEXPECTED_SANITIZE_DEALLOC`` + *undescribed* -.. c:type:: enum +.. c:type:: enum nvme_ae_info_notice **Constants** -``NVME_LBART_TYPE_GP`` +``NVME_AER_NOTICE_NS_CHANGED`` *undescribed* -``NVME_LBART_TYPE_FS`` +``NVME_AER_NOTICE_FW_ACT_STARTING`` *undescribed* -``NVME_LBART_TYPE_RAID`` +``NVME_AER_NOTICE_TELEMETRY`` *undescribed* -``NVME_LBART_TYPE_CACHE`` +``NVME_AER_NOTICE_ANA`` *undescribed* -``NVME_LBART_TYPE_SWAP`` +``NVME_AER_NOTICE_PL_EVENT`` *undescribed* -``NVME_LBART_ATTRIB_TEMP`` +``NVME_AER_NOTICE_LBA_STATUS_ALERT`` *undescribed* -``NVME_LBART_ATTRIB_HIDE`` +``NVME_AER_NOTICE_EG_EVENT`` + *undescribed* + +``NVME_AER_NOTICE_DISC_CHANGED`` *undescribed* -.. c:type:: struct nvme_lba_range_type +.. c:type:: enum nvme_subsys_type + + +**Constants** + +``NVME_NQN_DISC`` + Discovery type target subsystem + +``NVME_NQN_NVME`` + NVME type target subsystem + + + +.. c:type:: struct nvmf_disc_log_entry + + Discovery log page entry **Definition** :: - struct nvme_lba_range_type { - struct nvme_lba_range_type_entry entry[NVME_FEAT_LBA_RANGE_MAX]; + struct nvmf_disc_log_entry { + __u8 trtype; + __u8 adrfam; + __u8 subtype; + __u8 treq; + __le16 portid; + __le16 cntlid; + __le16 asqsz; + __u8 resv10[22]; + char trsvcid[NVMF_TRSVCID_SIZE]; + __u8 resv64[192]; + char subnqn[NVMF_NQN_FIELD_LEN]; + char traddr[NVMF_TRADDR_SIZE]; + union tsas { + char common[NVMF_TSAS_SIZE]; + struct rdma { + __u8 qptype; + __u8 prtype; + __u8 cms; + __u8 resv3[5]; + __u16 pkey; + __u8 resv10[246]; + } rdma; + struct tcp { + __u8 sectype; + } tcp; + } tsas; }; **Members** @@ -9183,190 +9757,202 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: struct nvme_plm_config +.. c:type:: enum + Transport Type codes for Discovery Log Page entry TRTYPE field -**Definition** +**Constants** -:: +``NVMF_TRTYPE_UNSPECIFIED`` + Not indicated - struct nvme_plm_config { - __le16 ee; - __u8 rsvd2[30]; - __le64 dtwinrt; - __le64 dtwinwt; - __le64 dtwintt; - __u8 rsvd56[456]; - }; +``NVMF_TRTYPE_RDMA`` + RDMA -**Members** +``NVMF_TRTYPE_FC`` + Fibre Channel +``NVMF_TRTYPE_TCP`` + TCP +``NVMF_TRTYPE_LOOP`` + Reserved for host usage +``NVMF_TRTYPE_MAX`` + *undescribed* -.. c:type:: struct nvme_feat_host_behavior -**Definition** +.. c:type:: enum -:: + Address Family codes for Discovery Log Page entry ADRFAM field - struct nvme_feat_host_behavior { - __u8 acre; - __u8 resv1[511]; - }; +**Constants** -**Members** +``NVMF_ADDR_FAMILY_PCI`` + PCIe + +``NVMF_ADDR_FAMILY_IP4`` + IPv4 + +``NVMF_ADDR_FAMILY_IP6`` + IPv6 + +``NVMF_ADDR_FAMILY_IB`` + InfiniBand +``NVMF_ADDR_FAMILY_FC`` + Fibre Channel .. c:type:: enum + Transport Requirements codes for Discovery Log Page entry TREQ field **Constants** -``NVME_ENABLE_ACRE`` - *undescribed* +``NVMF_TREQ_NOT_SPECIFIED`` + Not specified +``NVMF_TREQ_REQUIRED`` + Required +``NVMF_TREQ_NOT_REQUIRED`` + Not Required +``NVMF_TREQ_DISABLE_SQFLOW`` + SQ flow control disable supported -.. c:type:: struct nvme_dsm_range -**Definition** -:: +.. c:type:: enum - struct nvme_dsm_range { - __le32 cattr; - __le32 nlb; - __le64 slba; - }; + RDMA QP Service Type codes for Discovery Log Page entry TSAS RDMA_QPTYPE field -**Members** +**Constants** +``NVMF_RDMA_QPTYPE_CONNECTED`` + Reliable Connected +``NVMF_RDMA_QPTYPE_DATAGRAM`` + Reliable Datagram -.. c:type:: struct nvme_registered_ctrl +.. c:type:: enum -**Definition** + RDMA Provider Type codes for Discovery Log Page entry TSAS RDMA_PRTYPE field -:: +**Constants** - struct nvme_registered_ctrl { - __le16 cntlid; - __u8 rcsts; - __u8 rsvd3[5]; - __le64 hostid; - __le64 rkey; - }; +``NVMF_RDMA_PRTYPE_NOT_SPECIFIED`` + No Provider Specified -**Members** +``NVMF_RDMA_PRTYPE_IB`` + InfiniBand +``NVMF_RDMA_PRTYPE_ROCE`` + InfiniBand RoCE +``NVMF_RDMA_PRTYPE_ROCEV2`` + InfiniBand RoCEV2 +``NVMF_RDMA_PRTYPE_IWARP`` + iWARP -.. c:type:: struct nvme_registered_ctrl_ext -**Definition** +.. c:type:: enum -:: + RDMA Connection Management Service Type codes for Discovery Log Page entry TSAS RDMA_CMS field - struct nvme_registered_ctrl_ext { - __le16 cntlid; - __u8 rcsts; - __u8 resv3[5]; - __le64 rkey; - __u8 hostid[16]; - __u8 resv32[32]; - }; +**Constants** -**Members** +``NVMF_RDMA_CMS_RDMA_CM`` + Sockets based endpoint addressing +.. c:type:: enum + + +**Constants** + +``NVMF_TCP_SECTYPE_NONE`` + No Security + +``NVMF_TCP_SECTYPE_TLS`` + Transport Layer Security + -.. c:type:: struct nvme_reservation_status + + +.. c:type:: struct nvmf_discovery_log **Definition** :: - struct nvme_reservation_status { - __le32 gen; - __u8 rtype; - __u8 regctl[2]; - __u8 rsvd7[2]; - __u8 ptpls; - __u8 rsvd10[14]; - union { - struct { - __u8 resv24[40]; - struct nvme_registered_ctrl_ext regctl_eds[0]; - }; - struct nvme_registered_ctrl regctl_ds[0]; - }; + struct nvmf_discovery_log { + __le64 genctr; + __le64 numrec; + __le16 recfmt; + __u8 resv14[1006]; + struct nvmf_disc_log_entry entries[0]; }; **Members** -``{unnamed_union}`` - anonymous - -``{unnamed_struct}`` - anonymous - -.. c:type:: struct nvme_streams_directive_params +.. c:type:: struct nvmf_connect_data **Definition** :: - struct nvme_streams_directive_params { - __le16 msl; - __le16 nssa; - __le16 nsso; - __u8 nssc; - __u8 rsvd[9]; - __le32 sws; - __le16 sgs; - __le16 nsa; - __le16 nso; - __u8 rsvd2[6]; + struct nvmf_connect_data { + __u8 hostid[16]; + __le16 cntlid; + char resv4[238]; + char subsysnqn[NVMF_NQN_FIELD_LEN]; + char hostnqn[NVMF_NQN_FIELD_LEN]; + char resv5[256]; }; **Members** +``cntlid`` + **subsysnqn** + **hostnqn** + -.. c:type:: struct nvme_streams_directive_status +.. c:type:: struct nvme_mi_read_nvm_ss_info **Definition** :: - struct nvme_streams_directive_status { - __le16 osc; - __le16 sid[]; + struct nvme_mi_read_nvm_ss_info { + __u8 nump; + __u8 mjr; + __u8 mnr; + __u8 rsvd3[29]; }; **Members** @@ -9375,17 +9961,21 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: struct nvme_id_directives +.. c:type:: struct nvme_mi_port_pcie **Definition** :: - struct nvme_id_directives { - __u8 supported[32]; - __u8 enabled[32]; - __u8 rsvd64[4032]; + struct nvme_mi_port_pcie { + __u8 mps; + __u8 sls; + __u8 cls; + __u8 mlw; + __u8 nlw; + __u8 pn; + __u8 rsvd14[18]; }; **Members** @@ -9394,212 +9984,207 @@ The namespace identifier if a succecssful or -1 with errno set -.. c:type:: enum +.. c:type:: struct nvme_mi_port_smb -**Constants** +**Definition** -``NVME_ID_DIR_ID_BIT`` - *undescribed* +:: -``NVME_ID_DIR_SD_BIT`` - *undescribed* + struct nvme_mi_port_smb { + __u8 vpd_addr; + __u8 mvpd_freq; + __u8 mme_addr; + __u8 mme_freq; + __u8 nvmebm; + __u8 rsvd13[19]; + }; +**Members** -.. c:type:: struct nvme_host_mem_buf_desc + + +.. c:type:: struct nvme_mi_read_port_info **Definition** :: - struct nvme_host_mem_buf_desc { - __le64 addr; - __le32 size; - __u32 rsvd; + 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`` + **mmctptus**; +``{unnamed_union}`` + anonymous -.. c:type:: enum nvme_ae_type -**Constants** +.. c:type:: struct nvme_mi_read_ctrl_info -``NVME_AER_ERROR`` - *undescribed* + **portid**; **prii**; **pri**; **vid**; **did**; **ssvid**; **ssid**; -``NVME_AER_SMART`` - *undescribed* +**Definition** -``NVME_AER_NOTICE`` - *undescribed* +:: -``NVME_AER_CSS`` - *undescribed* + struct nvme_mi_read_ctrl_info { + __u8 portid; + __u8 rsvd1[4]; + __u8 prii; + __le16 pri; + __le16 vid; + __le16 did; + __le16 ssvid; + __le16 ssid; + __u8 rsvd16[16]; + }; -``NVME_AER_VS`` - *undescribed* +**Members** -.. c:type:: enum nvme_ae_info_error +.. c:type:: struct nvme_mi_osc -**Constants** + **type**; **opc**; -``NVME_AER_ERROR_INVALID_DB_REG`` - *undescribed* +**Definition** -``NVME_AER_ERROR_INVALID_DB_VAL`` - *undescribed* +:: -``NVME_AER_ERROR_DIAG_FAILURE`` - *undescribed* + struct nvme_mi_osc { + __u8 type; + __u8 opc; + }; -``NVME_AER_ERROR_PERSISTENT_INTERNAL_ERROR`` - *undescribed* +**Members** -``NVME_AER_ERROR_TRANSIENT_INTERNAL_ERROR`` - *undescribed* -``NVME_AER_ERROR_FW_IMAGE_LOAD_ERROR`` - *undescribed* +.. c:type:: struct nvme_mi_read_sc_list -.. c:type:: enum nvme_ae_info_smart +**Definition** -**Constants** +:: -``NVME_AER_SMART_SUBSYSTEM_RELIABILITY`` - *undescribed* + struct nvme_mi_read_sc_list { + __le16 numcmd; + struct nvme_mi_osc cmds[]; + }; -``NVME_AER_SMART_TEMPERATURE_THRESHOLD`` - *undescribed* +**Members** -``NVME_AER_SMART_SPARE_THRESHOLD`` - *undescribed* -.. c:type:: enum nvme_ae_info_css_nvm +.. c:type:: struct nvme_mi_nvm_ss_health_status -**Constants** +**Definition** -``NVME_AER_CSS_NVM_RESERVATION`` - *undescribed* +:: -``NVME_AER_CSS_NVM_SANITIZE_COMPLETED`` - *undescribed* + struct nvme_mi_nvm_ss_health_status { + __u8 nss; + __u8 sw; + __u8 ctemp; + __u8 pdlu; + __le16 ccs; + __u8 rsvd8[2]; + }; -``NVME_AER_CSS_NVM_UNEXPECTED_SANITIZE_DEALLOC`` - *undescribed* +**Members** -.. c:type:: enum nvme_ae_info_notice + +.. c:type:: enum **Constants** -``NVME_AER_NOTICE_NS_CHANGED`` +``NVME_MI_CCS_RDY`` *undescribed* -``NVME_AER_NOTICE_FW_ACT_STARTING`` +``NVME_MI_CSS_CFS`` *undescribed* -``NVME_AER_NOTICE_TELEMETRY`` +``NVME_MI_CSS_SHST`` *undescribed* -``NVME_AER_NOTICE_ANA`` +``NVME_MI_CSS_NSSRO`` *undescribed* -``NVME_AER_NOTICE_PL_EVENT`` +``NVME_MI_CSS_CECO`` *undescribed* -``NVME_AER_NOTICE_LBA_STATUS_ALERT`` +``NVME_MI_CSS_NAC`` *undescribed* -``NVME_AER_NOTICE_EG_EVENT`` +``NVME_MI_CSS_FA`` *undescribed* -``NVME_AER_NOTICE_DISC_CHANGED`` +``NVME_MI_CSS_CSTS`` *undescribed* +``NVME_MI_CSS_CTEMP`` + *undescribed* +``NVME_MI_CSS_PDLU`` + *undescribed* +``NVME_MI_CSS_SPARE`` + *undescribed* -.. c:type:: enum nvme_subsys_type - - -**Constants** - -``NVME_NQN_DISC`` - Discovery type target subsystem - -``NVME_NQN_NVME`` - NVME type target subsystem +``NVME_MI_CSS_CCWARN`` + *undescribed* -.. c:type:: struct nvmf_disc_log_entry +.. c:type:: struct nvme_mi_ctrl_heal_status **Definition** :: - struct nvmf_disc_log_entry { - __u8 trtype; - __u8 adrfam; - __u8 subtype; - __u8 treq; - __le16 portid; - __le16 cntlid; - __le16 asqsz; - __u8 resv10[22]; - char trsvcid[NVMF_TRSVCID_SIZE]; - __u8 resv64[192]; - char subnqn[NVMF_NQN_FIELD_LEN]; - char traddr[NVMF_TRADDR_SIZE]; - union tsas { - char common[NVMF_TSAS_SIZE]; - struct rdma { - __u8 qptype; - __u8 prtype; - __u8 cms; - __u8 resv3[5]; - __u16 pkey; - __u8 resv10[246]; - } rdma; - struct tcp { - __u8 sectype; - } tcp; - } tsas; + struct nvme_mi_ctrl_heal_status { + __le16 ctlid; + __le16 csts; + __le16 ctemp; + __u8 pdlu; + __u8 spare; + __u8 cwarn; + __u8 rsvd9[7]; }; **Members** -**Description** - - -Discovery log page entry - @@ -9608,194 +10193,219 @@ Discovery log page entry **Constants** -``NVMF_TRTYPE_UNSPECIFIED`` - Not indicated - -``NVMF_TRTYPE_RDMA`` - RDMA - -``NVMF_TRTYPE_FC`` - Fibre Channel - -``NVMF_TRTYPE_TCP`` - TCP - -``NVMF_TRTYPE_LOOP`` - Reserved for host usage - -``NVMF_TRTYPE_MAX`` +``NVME_MI_CSTS_RDY`` *undescribed* -**Description** - -Transport Type codes for Discovery Log Page entry TRTYPE field - - +``NVME_MI_CSTS_CFS`` + *undescribed* +``NVME_MI_CSTS_SHST`` + *undescribed* -.. c:type:: enum +``NVME_MI_CSTS_NSSRO`` + *undescribed* +``NVME_MI_CSTS_CECO`` + *undescribed* -**Constants** +``NVME_MI_CSTS_NAC`` + *undescribed* -``NVMF_ADDR_FAMILY_PCI`` - PCIe +``NVME_MI_CSTS_FA`` + *undescribed* -``NVMF_ADDR_FAMILY_IP4`` - IPv4 +``NVME_MI_CWARN_ST`` + *undescribed* -``NVMF_ADDR_FAMILY_IP6`` - IPv6 +``NVME_MI_CWARN_TAUT`` + *undescribed* -``NVMF_ADDR_FAMILY_IB`` - InfiniBand +``NVME_MI_CWARN_RD`` + *undescribed* -``NVMF_ADDR_FAMILY_FC`` - Fibre Channel +``NVME_MI_CWARN_RO`` + *undescribed* -**Description** +``NVME_MI_CWARN_VMBF`` + *undescribed* -Address Family codes for Discovery Log Page entry ADRFAM field +.. c:type:: struct nvme_mi_vpd_mra -.. c:type:: enum + **nmravn**; **ff**; **i18vpwr**; **m18vpwr**; **i33vpwr**; **m33vpwr**; **m33vapsr**; **i5vapsr**; **m5vapsr**; **i12vapsr**; **m12vapsr**; **mtl**; **tnvmcap**[16]; +**Definition** -**Constants** +:: -``NVMF_TREQ_NOT_SPECIFIED`` - Not specified + 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]; + }; -``NVMF_TREQ_REQUIRED`` - Required +**Members** -``NVMF_TREQ_NOT_REQUIRED`` - Not Required -``NVMF_TREQ_DISABLE_SQFLOW`` - SQ flow control disable supported -**Description** -Transport Requirements codes for Discovery Log Page entry TREQ field +.. c:type:: struct nvme_mi_vpd_ppmra +**Definition** -.. c:type:: enum +:: + struct nvme_mi_vpd_ppmra { + __u8 nppmravn; + __u8 pn; + __u8 ppi; + __u8 ls; + __u8 mlw; + __u8 mctp; + __u8 refccap; + __u8 pi; + __u8 rsvd13[3]; + }; -**Constants** +**Members** -``NVMF_RDMA_QPTYPE_CONNECTED`` - Reliable Connected -``NVMF_RDMA_QPTYPE_DATAGRAM`` - Reliable Datagram -**Description** -RDMA QP Service Type codes for Discovery Log Page entry TSAS -RDMA_QPTYPE field +.. c:type:: struct nvme_mi_vpd_telem +**Definition** -.. c:type:: enum +:: + struct nvme_mi_vpd_telem { + __u8 type; + __u8 rev; + __u8 len; + __u8 data[0]; + }; -**Constants** +**Members** -``NVMF_RDMA_PRTYPE_NOT_SPECIFIED`` - No Provider Specified -``NVMF_RDMA_PRTYPE_IB`` - InfiniBand -``NVMF_RDMA_PRTYPE_ROCE`` - InfiniBand RoCE -``NVMF_RDMA_PRTYPE_ROCEV2`` - InfiniBand RoCEV2 -``NVMF_RDMA_PRTYPE_IWARP`` - iWARP +.. c:type:: enum -**Description** -RDMA Provider Type codes for Discovery Log Page entry TSAS -RDMA_PRTYPE field +**Constants** +``NVME_MI_ELEM_EED`` + *undescribed* +``NVME_MI_ELEM_USCE`` + *undescribed* +``NVME_MI_ELEM_ECED`` + *undescribed* -.. c:type:: enum +``NVME_MI_ELEM_LED`` + *undescribed* +``NVME_MI_ELEM_SMBMED`` + *undescribed* -**Constants** +``NVME_MI_ELEM_PCIESED`` + *undescribed* -``NVMF_RDMA_CMS_RDMA_CM`` - Sockets based endpoint addressing +``NVME_MI_ELEM_NVMED`` + *undescribed* -**Description** -RDMA Connection Management Service Type codes for Discovery Log Page -entry TSAS RDMA_CMS field +.. c:type:: struct nvme_mi_vpd_tra -.. c:type:: enum +**Definition** +:: -**Constants** + struct nvme_mi_vpd_tra { + __u8 vn; + __u8 rsvd6; + __u8 ec; + struct nvme_mi_vpd_telem elems[0]; + }; -``NVMF_TCP_SECTYPE_NONE`` - No Security +**Members** -``NVMF_TCP_SECTYPE_TLS`` - Transport Layer Security -.. c:type:: struct nvmf_discovery_log +.. c:type:: struct nvme_mi_vpd_mr_common + **type**; **rf**; **rlen**; **rchksum**; **hchksum**; **ppmra**; **tmra**; **Definition** :: - struct nvmf_discovery_log { - __le64 genctr; - __le64 numrec; - __le16 recfmt; - __u8 resv14[1006]; - struct nvmf_disc_log_entry entries[0]; + 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** +``{unnamed_union}`` + anonymous -.. c:type:: struct nvmf_connect_data + +.. c:type:: struct nvme_mi_vpd_hdr **Definition** :: - struct nvmf_connect_data { - __u8 hostid[16]; - __le16 cntlid; - char resv4[238]; - char subsysnqn[NVMF_NQN_FIELD_LEN]; - char hostnqn[NVMF_NQN_FIELD_LEN]; - char resv5[256]; + struct nvme_mi_vpd_hdr { + __u8 ipmiver; + __u8 iuaoff; + __u8 ciaoff; + __u8 biaoff; + __u8 piaoff; + __u8 mrioff; + __u8 rsvd6; + __u8 chchk; + __u8 vpd[]; }; **Members** @@ -10146,27 +10756,25 @@ entry TSAS RDMA_CMS field *undescribed* -.. c:function:: __u8 nvme_status_type (__u16 status) +.. c:function:: __u8 nvme_status_to_errno (int status, bool fabrics) - Returns SCT(Status Code Type) in status field of the completion queue entry. + Converts nvme return status to errno **Parameters** -``__u16 status`` - return value from nvme passthrough commands, which is the nvme - status field, located at DW3 in completion queue entry - +``int status`` + Return status from an nvme passthrough commmand -.. c:function:: const char * nvme_status_to_string (int status, bool fabrics) +``bool fabrics`` + true if given status is for fabrics +**Description** -**Parameters** +If status < 0, errno is already set. -``int status`` - *undescribed* +**Return** -``bool fabrics`` - *undescribed* +Appropriate errno for the given nvme status .. c:function:: int nvme_fw_download_seq (int fd, __u32 size, __u32 xfer, __u32 offset, void * buf) @@ -10187,10 +10795,9 @@ entry TSAS RDMA_CMS field *undescribed* ``void * buf`` - *undescribed* -.. c:function:: int nvme_get_telemetry_log (int fd, bool create, bool ctrl, int data_area, void ** buf, __u32 * log_size) +.. c:function:: int nvme_get_ctrl_telemetry (int fd, bool rae, void ** buf, __u32 * log_size) **Parameters** @@ -10198,21 +10805,42 @@ entry TSAS RDMA_CMS field ``int fd`` *undescribed* -``bool create`` +``bool rae`` *undescribed* -``bool ctrl`` +``void ** buf`` *undescribed* -``int data_area`` +``__u32 * log_size`` + + +.. c:function:: int nvme_get_host_telemetry (int fd, void ** buf, __u32 * log_size) + + +**Parameters** + +``int fd`` *undescribed* ``void ** buf`` *undescribed* ``__u32 * log_size`` + + +.. c:function:: int nvme_get_new_host_telemetry (int fd, void ** buf, __u32 * log_size) + + +**Parameters** + +``int fd`` + *undescribed* + +``void ** buf`` *undescribed* +``__u32 * log_size`` + .. c:function:: void nvme_setup_id_ns (struct nvme_id_ns * ns, __u64 nsze, __u64 ncap, __u8 flbas, __u8 dps, __u8 nmic, __u32 anagrpid, __u16 nvmsetid) @@ -10346,14 +10974,19 @@ Calls __nvme_get_log_page() with a default 4k transfer length. .. c:function:: int nvme_get_ana_log_len (int fd, size_t * analen) + Retreive size of the current ANA log **Parameters** ``int fd`` - *undescribed* + File descriptor of nvme device ``size_t * analen`` - *undescribed* + Pointer to where the length will be set on success + +**Return** + +0 on success, -1 otherwise with errno set .. c:function:: int nvme_namespace_attach_ctrls (int fd, __u32 nsid, __u16 num_ctrls, __u16 * ctrlist) @@ -10376,8 +11009,8 @@ Calls __nvme_get_log_page() with a default 4k transfer length. **Return** -The nvme command status if a response was received or -errno - otherwise. +The nvme command status if a response was received or -1 + with errno set otherwise. .. c:function:: int nvme_namespace_detach_ctrls (int fd, __u32 nsid, __u16 num_ctrls, __u16 * ctrlist) @@ -10400,12 +11033,13 @@ The nvme command status if a response was received or -errno **Return** -The nvme command status if a response was received or -errno - otherwise. +The nvme command status if a response was received or -1 + with errno set otherwise. .. c:function:: int nvme_get_feature_length (int fid, __u32 cdw11, __u32 * len) + Retreive the command payload length for a specific feature identifier **Parameters** @@ -10416,22 +11050,30 @@ The nvme command status if a response was received or -errno *undescribed* ``__u32 * len`` - *undescribed* + +**Return** + +0 on success, -1 with errno set otherwise -.. c:function:: int nvme_get_directive_receive_length (__u8 dtype, __u8 doper, __u32 * len) +.. c:function:: int nvme_get_directive_receive_length (enum nvme_directive_dtype dtype, enum nvme_directive_receive_doper doper, __u32 * len) **Parameters** -``__u8 dtype`` - *undescribed* +``enum nvme_directive_dtype dtype`` + Directive type, see :c:type:`enum nvme_directive_dtype ` -``__u8 doper`` - *undescribed* +``enum nvme_directive_receive_doper doper`` + Directive receive operation, see :c:type:`enum nvme_directive_receive_doper ` ``__u32 * len`` - *undescribed* + Address to save the payload length of the directive in bytes on + a successful decode + +**Return** + +0 on success, -1 with errno set to EINVAL. .. c:function:: int nvme_open (const char * name) @@ -10454,3 +11096,21 @@ A file descriptor for the device on a successful open, or -1 with errno set otherwise. +.. c:function:: int nvme_set_attr (const char * dir, const char * attr, const char * value) + + +**Parameters** + +``const char * dir`` + *undescribed* + +``const char * attr`` + *undescribed* + +``const char * value`` + +**Description** + +Return + + diff --git a/doc/man/__nvme_get_log_page.2 b/doc/man/__nvme_get_log_page.2 new file mode 100644 index 00000000..e240ffd6 --- /dev/null +++ b/doc/man/__nvme_get_log_page.2 @@ -0,0 +1,27 @@ +.TH "__nvme_get_log_page" 2 "__nvme_get_log_page" "February 2020" "libnvme Manual" +.SH NAME +__nvme_get_log_page \- +.SH SYNOPSIS +.B "int" __nvme_get_log_page +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u8 " log_id "," +.BI "bool " rae "," +.BI "__u32 " xfer_len "," +.BI "__u32 " data_len "," +.BI "void *" data ");" +.SH ARGUMENTS +.IP "fd" 12 +-- undescribed -- +.IP "nsid" 12 +-- undescribed -- +.IP "log_id" 12 +-- undescribed -- +.IP "rae" 12 +-- undescribed -- +.IP "xfer_len" 12 +Max partial log transfer size to request while splitting +.IP "data_len" 12 +-- undescribed -- +.IP "data" 12 +-- undescribed -- diff --git a/doc/man/enum .2 b/doc/man/enum .2 new file mode 100644 index 00000000..54a840a5 --- /dev/null +++ b/doc/man/enum .2 @@ -0,0 +1,678 @@ +.TH "libnvme" 2 "enum " "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum \- +.SH SYNOPSIS +enum { +.br +.BI " NVME_SCT_GENERIC" +, +.br +.br +.BI " NVME_SCT_CMD_SPECIFIC" +, +.br +.br +.BI " NVME_SCT_MEDIA" +, +.br +.br +.BI " NVME_SCT_PATH" +, +.br +.br +.BI " NVME_SCT_VS" +, +.br +.br +.BI " NVME_SCT_MASK" +, +.br +.br +.BI " NVME_SC_SUCCESS" +, +.br +.br +.BI " NVME_SC_INVALID_OPCODE" +, +.br +.br +.BI " NVME_SC_INVALID_FIELD" +, +.br +.br +.BI " NVME_SC_CMDID_CONFLICT" +, +.br +.br +.BI " NVME_SC_DATA_XFER_ERROR" +, +.br +.br +.BI " NVME_SC_POWER_LOSS" +, +.br +.br +.BI " NVME_SC_INTERNAL" +, +.br +.br +.BI " NVME_SC_ABORT_REQ" +, +.br +.br +.BI " NVME_SC_ABORT_QUEUE" +, +.br +.br +.BI " NVME_SC_FUSED_FAIL" +, +.br +.br +.BI " NVME_SC_FUSED_MISSING" +, +.br +.br +.BI " NVME_SC_INVALID_NS" +, +.br +.br +.BI " NVME_SC_CMD_SEQ_ERROR" +, +.br +.br +.BI " NVME_SC_SGL_INVALID_LAST" +, +.br +.br +.BI " NVME_SC_SGL_INVALID_COUNT" +, +.br +.br +.BI " NVME_SC_SGL_INVALID_DATA" +, +.br +.br +.BI " NVME_SC_SGL_INVALID_METADATA" +, +.br +.br +.BI " NVME_SC_SGL_INVALID_TYPE" +, +.br +.br +.BI " NVME_SC_CMB_INVALID_USE" +, +.br +.br +.BI " NVME_SC_PRP_INVALID_OFFSET" +, +.br +.br +.BI " NVME_SC_AWU_EXCEEDED" +, +.br +.br +.BI " NVME_SC_OP_DENIED" +, +.br +.br +.BI " NVME_SC_SGL_INVALID_OFFSET" +, +.br +.br +.BI " NVME_SC_HOSTID_FORMAT" +, +.br +.br +.BI " NVME_SC_KAT_EXPIRED" +, +.br +.br +.BI " NVME_SC_KAT_INVALID" +, +.br +.br +.BI " NVME_SC_CMD_ABORTED_PREMEPT" +, +.br +.br +.BI " NVME_SC_SANITIZE_FAILED" +, +.br +.br +.BI " NVME_SC_SANITIZE_IN_PROGRESS" +, +.br +.br +.BI " NVME_SC_SGL_INVALID_GRANULARITY" +, +.br +.br +.BI " NVME_SC_CMD_IN_CMBQ_NOT_SUPP" +, +.br +.br +.BI " NVME_SC_NS_WRITE_PROTECTED" +, +.br +.br +.BI " NVME_SC_CMD_INTERRUPTED" +, +.br +.br +.BI " NVME_SC_TRAN_TPORT_ERROR" +, +.br +.br +.BI " NVME_SC_LBA_RANGE" +, +.br +.br +.BI " NVME_SC_CAP_EXCEEDED" +, +.br +.br +.BI " NVME_SC_NS_NOT_READY" +, +.br +.br +.BI " NVME_SC_RESERVATION_CONFLICT" +, +.br +.br +.BI " NVME_SC_FORMAT_IN_PROGRESS" +, +.br +.br +.BI " NVME_SC_CQ_INVALID" +, +.br +.br +.BI " NVME_SC_QID_INVALID" +, +.br +.br +.BI " NVME_SC_QUEUE_SIZE" +, +.br +.br +.BI " NVME_SC_ABORT_LIMIT" +, +.br +.br +.BI " NVME_SC_ABORT_MISSING" +, +.br +.br +.BI " NVME_SC_ASYNC_LIMIT" +, +.br +.br +.BI " NVME_SC_FIRMWARE_SLOT" +, +.br +.br +.BI " NVME_SC_FIRMWARE_IMAGE" +, +.br +.br +.BI " NVME_SC_INVALID_VECTOR" +, +.br +.br +.BI " NVME_SC_INVALID_LOG_PAGE" +, +.br +.br +.BI " NVME_SC_INVALID_FORMAT" +, +.br +.br +.BI " NVME_SC_FW_NEEDS_CONV_RESET" +, +.br +.br +.BI " NVME_SC_INVALID_QUEUE" +, +.br +.br +.BI " NVME_SC_FEATURE_NOT_SAVEABLE" +, +.br +.br +.BI " NVME_SC_FEATURE_NOT_CHANGEABLE" +, +.br +.br +.BI " NVME_SC_FEATURE_NOT_PER_NS" +, +.br +.br +.BI " NVME_SC_FW_NEEDS_SUBSYS_RESET" +, +.br +.br +.BI " NVME_SC_FW_NEEDS_RESET" +, +.br +.br +.BI " NVME_SC_FW_NEEDS_MAX_TIME" +, +.br +.br +.BI " NVME_SC_FW_ACTIVATE_PROHIBITED" +, +.br +.br +.BI " NVME_SC_OVERLAPPING_RANGE" +, +.br +.br +.BI " NVME_SC_NS_INSUFFICIENT_CAP" +, +.br +.br +.BI " NVME_SC_NS_ID_UNAVAILABLE" +, +.br +.br +.BI " NVME_SC_NS_ALREADY_ATTACHED" +, +.br +.br +.BI " NVME_SC_NS_IS_PRIVATE" +, +.br +.br +.BI " NVME_SC_NS_NOT_ATTACHED" +, +.br +.br +.BI " NVME_SC_THIN_PROV_NOT_SUPP" +, +.br +.br +.BI " NVME_SC_CTRL_LIST_INVALID" +, +.br +.br +.BI " NVME_SC_SELF_TEST_IN_PROGRESS" +, +.br +.br +.BI " NVME_SC_BP_WRITE_PROHIBITED" +, +.br +.br +.BI " NVME_SC_INVALID_CTRL_ID" +, +.br +.br +.BI " NVME_SC_INVALID_SEC_CTRL_STATE" +, +.br +.br +.BI " NVME_SC_INVALID_CTRL_RESOURCES" +, +.br +.br +.BI " NVME_SC_INVALID_RESOURCE_ID" +, +.br +.br +.BI " NVME_SC_PMR_SAN_PROHIBITED" +, +.br +.br +.BI " NVME_SC_ANA_GROUP_ID_INVALID" +, +.br +.br +.BI " NVME_SC_ANA_ATTACH_FAILED" +, +.br +.br +.BI " NVME_SC_BAD_ATTRIBUTES" +, +.br +.br +.BI " NVME_SC_INVALID_PI" +, +.br +.br +.BI " NVME_SC_READ_ONLY" +, +.br +.br +.BI " NVME_SC_CONNECT_FORMAT" +, +.br +.br +.BI " NVME_SC_CONNECT_CTRL_BUSY" +, +.br +.br +.BI " NVME_SC_CONNECT_INVALID_PARAM" +, +.br +.br +.BI " NVME_SC_CONNECT_RESTART_DISC" +, +.br +.br +.BI " NVME_SC_CONNECT_INVALID_HOST" +, +.br +.br +.BI " NVME_SC_DISCONNECT_INVALID_QTYPE" +, +.br +.br +.BI " NVME_SC_DISCOVERY_RESTART" +, +.br +.br +.BI " NVME_SC_AUTH_REQUIRED" +, +.br +.br +.BI " NVME_SC_WRITE_FAULT" +, +.br +.br +.BI " NVME_SC_READ_ERROR" +, +.br +.br +.BI " NVME_SC_GUARD_CHECK" +, +.br +.br +.BI " NVME_SC_APPTAG_CHECK" +, +.br +.br +.BI " NVME_SC_REFTAG_CHECK" +, +.br +.br +.BI " NVME_SC_COMPARE_FAILED" +, +.br +.br +.BI " NVME_SC_ACCESS_DENIED" +, +.br +.br +.BI " NVME_SC_UNWRITTEN_BLOCK" +, +.br +.br +.BI " NVME_SC_ANA_INTERNAL_PATH_ERROR" +, +.br +.br +.BI " NVME_SC_ANA_PERSISTENT_LOSS" +, +.br +.br +.BI " NVME_SC_ANA_INACCESSIBLE" +, +.br +.br +.BI " NVME_SC_ANA_TRANSITION" +, +.br +.br +.BI " NVME_SC_CTRL_PATH_ERROR" +, +.br +.br +.BI " NVME_SC_HOST_PATH_ERROR" +, +.br +.br +.BI " NVME_SC_CMD_ABORTED_BY_HOST" +, +.br +.br +.BI " NVME_SC_MASK" +, +.br +.br +.BI " NVME_SC_CRD" +, +.br +.br +.BI " NVME_SC_MORE" +, +.br +.br +.BI " NVME_SC_DNR" + +}; +.SH Constants +.IP "NVME_SCT_GENERIC" 12 +-- undescribed -- +.IP "NVME_SCT_CMD_SPECIFIC" 12 +-- undescribed -- +.IP "NVME_SCT_MEDIA" 12 +-- undescribed -- +.IP "NVME_SCT_PATH" 12 +-- undescribed -- +.IP "NVME_SCT_VS" 12 +-- undescribed -- +.IP "NVME_SCT_MASK" 12 +-- undescribed -- +.IP "NVME_SC_SUCCESS" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_OPCODE" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_FIELD" 12 +-- undescribed -- +.IP "NVME_SC_CMDID_CONFLICT" 12 +-- undescribed -- +.IP "NVME_SC_DATA_XFER_ERROR" 12 +-- undescribed -- +.IP "NVME_SC_POWER_LOSS" 12 +-- undescribed -- +.IP "NVME_SC_INTERNAL" 12 +-- undescribed -- +.IP "NVME_SC_ABORT_REQ" 12 +-- undescribed -- +.IP "NVME_SC_ABORT_QUEUE" 12 +-- undescribed -- +.IP "NVME_SC_FUSED_FAIL" 12 +-- undescribed -- +.IP "NVME_SC_FUSED_MISSING" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_NS" 12 +-- undescribed -- +.IP "NVME_SC_CMD_SEQ_ERROR" 12 +-- undescribed -- +.IP "NVME_SC_SGL_INVALID_LAST" 12 +-- undescribed -- +.IP "NVME_SC_SGL_INVALID_COUNT" 12 +-- undescribed -- +.IP "NVME_SC_SGL_INVALID_DATA" 12 +-- undescribed -- +.IP "NVME_SC_SGL_INVALID_METADATA" 12 +-- undescribed -- +.IP "NVME_SC_SGL_INVALID_TYPE" 12 +-- undescribed -- +.IP "NVME_SC_CMB_INVALID_USE" 12 +-- undescribed -- +.IP "NVME_SC_PRP_INVALID_OFFSET" 12 +-- undescribed -- +.IP "NVME_SC_AWU_EXCEEDED" 12 +-- undescribed -- +.IP "NVME_SC_OP_DENIED" 12 +-- undescribed -- +.IP "NVME_SC_SGL_INVALID_OFFSET" 12 +-- undescribed -- +.IP "NVME_SC_HOSTID_FORMAT" 12 +-- undescribed -- +.IP "NVME_SC_KAT_EXPIRED" 12 +-- undescribed -- +.IP "NVME_SC_KAT_INVALID" 12 +-- undescribed -- +.IP "NVME_SC_CMD_ABORTED_PREMEPT" 12 +-- undescribed -- +.IP "NVME_SC_SANITIZE_FAILED" 12 +-- undescribed -- +.IP "NVME_SC_SANITIZE_IN_PROGRESS" 12 +-- undescribed -- +.IP "NVME_SC_SGL_INVALID_GRANULARITY" 12 +-- undescribed -- +.IP "NVME_SC_CMD_IN_CMBQ_NOT_SUPP" 12 +-- undescribed -- +.IP "NVME_SC_NS_WRITE_PROTECTED" 12 +-- undescribed -- +.IP "NVME_SC_CMD_INTERRUPTED" 12 +-- undescribed -- +.IP "NVME_SC_TRAN_TPORT_ERROR" 12 +-- undescribed -- +.IP "NVME_SC_LBA_RANGE" 12 +-- undescribed -- +.IP "NVME_SC_CAP_EXCEEDED" 12 +-- undescribed -- +.IP "NVME_SC_NS_NOT_READY" 12 +-- undescribed -- +.IP "NVME_SC_RESERVATION_CONFLICT" 12 +-- undescribed -- +.IP "NVME_SC_FORMAT_IN_PROGRESS" 12 +-- undescribed -- +.IP "NVME_SC_CQ_INVALID" 12 +-- undescribed -- +.IP "NVME_SC_QID_INVALID" 12 +-- undescribed -- +.IP "NVME_SC_QUEUE_SIZE" 12 +-- undescribed -- +.IP "NVME_SC_ABORT_LIMIT" 12 +-- undescribed -- +.IP "NVME_SC_ABORT_MISSING" 12 +-- undescribed -- +.IP "NVME_SC_ASYNC_LIMIT" 12 +-- undescribed -- +.IP "NVME_SC_FIRMWARE_SLOT" 12 +-- undescribed -- +.IP "NVME_SC_FIRMWARE_IMAGE" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_VECTOR" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_LOG_PAGE" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_FORMAT" 12 +-- undescribed -- +.IP "NVME_SC_FW_NEEDS_CONV_RESET" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_QUEUE" 12 +-- undescribed -- +.IP "NVME_SC_FEATURE_NOT_SAVEABLE" 12 +-- undescribed -- +.IP "NVME_SC_FEATURE_NOT_CHANGEABLE" 12 +-- undescribed -- +.IP "NVME_SC_FEATURE_NOT_PER_NS" 12 +-- undescribed -- +.IP "NVME_SC_FW_NEEDS_SUBSYS_RESET" 12 +-- undescribed -- +.IP "NVME_SC_FW_NEEDS_RESET" 12 +-- undescribed -- +.IP "NVME_SC_FW_NEEDS_MAX_TIME" 12 +-- undescribed -- +.IP "NVME_SC_FW_ACTIVATE_PROHIBITED" 12 +-- undescribed -- +.IP "NVME_SC_OVERLAPPING_RANGE" 12 +-- undescribed -- +.IP "NVME_SC_NS_INSUFFICIENT_CAP" 12 +-- undescribed -- +.IP "NVME_SC_NS_ID_UNAVAILABLE" 12 +-- undescribed -- +.IP "NVME_SC_NS_ALREADY_ATTACHED" 12 +-- undescribed -- +.IP "NVME_SC_NS_IS_PRIVATE" 12 +-- undescribed -- +.IP "NVME_SC_NS_NOT_ATTACHED" 12 +-- undescribed -- +.IP "NVME_SC_THIN_PROV_NOT_SUPP" 12 +-- undescribed -- +.IP "NVME_SC_CTRL_LIST_INVALID" 12 +-- undescribed -- +.IP "NVME_SC_SELF_TEST_IN_PROGRESS" 12 +-- undescribed -- +.IP "NVME_SC_BP_WRITE_PROHIBITED" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_CTRL_ID" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_SEC_CTRL_STATE" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_CTRL_RESOURCES" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_RESOURCE_ID" 12 +-- undescribed -- +.IP "NVME_SC_PMR_SAN_PROHIBITED" 12 +-- undescribed -- +.IP "NVME_SC_ANA_GROUP_ID_INVALID" 12 +-- undescribed -- +.IP "NVME_SC_ANA_ATTACH_FAILED" 12 +-- undescribed -- +.IP "NVME_SC_BAD_ATTRIBUTES" 12 +-- undescribed -- +.IP "NVME_SC_INVALID_PI" 12 +-- undescribed -- +.IP "NVME_SC_READ_ONLY" 12 +-- undescribed -- +.IP "NVME_SC_CONNECT_FORMAT" 12 +-- undescribed -- +.IP "NVME_SC_CONNECT_CTRL_BUSY" 12 +-- undescribed -- +.IP "NVME_SC_CONNECT_INVALID_PARAM" 12 +-- undescribed -- +.IP "NVME_SC_CONNECT_RESTART_DISC" 12 +-- undescribed -- +.IP "NVME_SC_CONNECT_INVALID_HOST" 12 +-- undescribed -- +.IP "NVME_SC_DISCONNECT_INVALID_QTYPE" 12 +-- undescribed -- +.IP "NVME_SC_DISCOVERY_RESTART" 12 +-- undescribed -- +.IP "NVME_SC_AUTH_REQUIRED" 12 +-- undescribed -- +.IP "NVME_SC_WRITE_FAULT" 12 +-- undescribed -- +.IP "NVME_SC_READ_ERROR" 12 +-- undescribed -- +.IP "NVME_SC_GUARD_CHECK" 12 +-- undescribed -- +.IP "NVME_SC_APPTAG_CHECK" 12 +-- undescribed -- +.IP "NVME_SC_REFTAG_CHECK" 12 +-- undescribed -- +.IP "NVME_SC_COMPARE_FAILED" 12 +-- undescribed -- +.IP "NVME_SC_ACCESS_DENIED" 12 +-- undescribed -- +.IP "NVME_SC_UNWRITTEN_BLOCK" 12 +-- undescribed -- +.IP "NVME_SC_ANA_INTERNAL_PATH_ERROR" 12 +-- undescribed -- +.IP "NVME_SC_ANA_PERSISTENT_LOSS" 12 +-- undescribed -- +.IP "NVME_SC_ANA_INACCESSIBLE" 12 +-- undescribed -- +.IP "NVME_SC_ANA_TRANSITION" 12 +-- undescribed -- +.IP "NVME_SC_CTRL_PATH_ERROR" 12 +-- undescribed -- +.IP "NVME_SC_HOST_PATH_ERROR" 12 +-- undescribed -- +.IP "NVME_SC_CMD_ABORTED_BY_HOST" 12 +-- undescribed -- +.IP "NVME_SC_MASK" 12 +-- undescribed -- +.IP "NVME_SC_CRD" 12 +-- undescribed -- +.IP "NVME_SC_MORE" 12 +-- undescribed -- +.IP "NVME_SC_DNR" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_admin_opcode.2 b/doc/man/enum nvme_admin_opcode.2 new file mode 100644 index 00000000..8b52caae --- /dev/null +++ b/doc/man/enum nvme_admin_opcode.2 @@ -0,0 +1,174 @@ +.TH "libnvme" 2 "enum nvme_admin_opcode" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_admin_opcode \- Known NVMe admin opcodes +.SH SYNOPSIS +enum nvme_admin_opcode { +.br +.BI " nvme_admin_delete_sq" +, +.br +.br +.BI " nvme_admin_create_sq" +, +.br +.br +.BI " nvme_admin_get_log_page" +, +.br +.br +.BI " nvme_admin_delete_cq" +, +.br +.br +.BI " nvme_admin_create_cq" +, +.br +.br +.BI " nvme_admin_identify" +, +.br +.br +.BI " nvme_admin_abort_cmd" +, +.br +.br +.BI " nvme_admin_set_features" +, +.br +.br +.BI " nvme_admin_get_features" +, +.br +.br +.BI " nvme_admin_async_event" +, +.br +.br +.BI " nvme_admin_ns_mgmt" +, +.br +.br +.BI " nvme_admin_fw_commit" +, +.br +.br +.BI " nvme_admin_fw_download" +, +.br +.br +.BI " nvme_admin_dev_self_test" +, +.br +.br +.BI " nvme_admin_ns_attach" +, +.br +.br +.BI " nvme_admin_keep_alive" +, +.br +.br +.BI " nvme_admin_directive_send" +, +.br +.br +.BI " nvme_admin_directive_recv" +, +.br +.br +.BI " nvme_admin_virtual_mgmt" +, +.br +.br +.BI " nvme_admin_nvme_mi_send" +, +.br +.br +.BI " nvme_admin_nvme_mi_recv" +, +.br +.br +.BI " nvme_admin_dbbuf" +, +.br +.br +.BI " nvme_admin_fabrics" +, +.br +.br +.BI " nvme_admin_format_nvm" +, +.br +.br +.BI " nvme_admin_security_send" +, +.br +.br +.BI " nvme_admin_security_recv" +, +.br +.br +.BI " nvme_admin_sanitize_nvm" +, +.br +.br +.BI " nvme_admin_get_lba_status" + +}; +.SH Constants +.IP "nvme_admin_delete_sq" 12 +-- undescribed -- +.IP "nvme_admin_create_sq" 12 +-- undescribed -- +.IP "nvme_admin_get_log_page" 12 +-- undescribed -- +.IP "nvme_admin_delete_cq" 12 +-- undescribed -- +.IP "nvme_admin_create_cq" 12 +-- undescribed -- +.IP "nvme_admin_identify" 12 +-- undescribed -- +.IP "nvme_admin_abort_cmd" 12 +-- undescribed -- +.IP "nvme_admin_set_features" 12 +-- undescribed -- +.IP "nvme_admin_get_features" 12 +-- undescribed -- +.IP "nvme_admin_async_event" 12 +-- undescribed -- +.IP "nvme_admin_ns_mgmt" 12 +-- undescribed -- +.IP "nvme_admin_fw_commit" 12 +-- undescribed -- +.IP "nvme_admin_fw_download" 12 +-- undescribed -- +.IP "nvme_admin_dev_self_test" 12 +-- undescribed -- +.IP "nvme_admin_ns_attach" 12 +-- undescribed -- +.IP "nvme_admin_keep_alive" 12 +-- undescribed -- +.IP "nvme_admin_directive_send" 12 +-- undescribed -- +.IP "nvme_admin_directive_recv" 12 +-- undescribed -- +.IP "nvme_admin_virtual_mgmt" 12 +-- undescribed -- +.IP "nvme_admin_nvme_mi_send" 12 +-- undescribed -- +.IP "nvme_admin_nvme_mi_recv" 12 +-- undescribed -- +.IP "nvme_admin_dbbuf" 12 +-- undescribed -- +.IP "nvme_admin_fabrics" 12 +-- undescribed -- +.IP "nvme_admin_format_nvm" 12 +-- undescribed -- +.IP "nvme_admin_security_send" 12 +-- undescribed -- +.IP "nvme_admin_security_recv" 12 +-- undescribed -- +.IP "nvme_admin_sanitize_nvm" 12 +-- undescribed -- +.IP "nvme_admin_get_lba_status" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_ae_info_css_nvm.2 b/doc/man/enum nvme_ae_info_css_nvm.2 new file mode 100644 index 00000000..5d3fed48 --- /dev/null +++ b/doc/man/enum nvme_ae_info_css_nvm.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_ae_info_css_nvm" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_ae_info_css_nvm \- +.SH SYNOPSIS +enum nvme_ae_info_css_nvm { +.br +.BI " NVME_AER_CSS_NVM_RESERVATION" +, +.br +.br +.BI " NVME_AER_CSS_NVM_SANITIZE_COMPLETED" +, +.br +.br +.BI " NVME_AER_CSS_NVM_UNEXPECTED_SANITIZE_DEALLOC" + +}; +.SH Constants +.IP "NVME_AER_CSS_NVM_RESERVATION" 12 +-- undescribed -- +.IP "NVME_AER_CSS_NVM_SANITIZE_COMPLETED" 12 +-- undescribed -- +.IP "NVME_AER_CSS_NVM_UNEXPECTED_SANITIZE_DEALLOC" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_ae_info_error.2 b/doc/man/enum nvme_ae_info_error.2 new file mode 100644 index 00000000..9087e72c --- /dev/null +++ b/doc/man/enum nvme_ae_info_error.2 @@ -0,0 +1,42 @@ +.TH "libnvme" 2 "enum nvme_ae_info_error" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_ae_info_error \- +.SH SYNOPSIS +enum nvme_ae_info_error { +.br +.BI " NVME_AER_ERROR_INVALID_DB_REG" +, +.br +.br +.BI " NVME_AER_ERROR_INVALID_DB_VAL" +, +.br +.br +.BI " NVME_AER_ERROR_DIAG_FAILURE" +, +.br +.br +.BI " NVME_AER_ERROR_PERSISTENT_INTERNAL_ERROR" +, +.br +.br +.BI " NVME_AER_ERROR_TRANSIENT_INTERNAL_ERROR" +, +.br +.br +.BI " NVME_AER_ERROR_FW_IMAGE_LOAD_ERROR" + +}; +.SH Constants +.IP "NVME_AER_ERROR_INVALID_DB_REG" 12 +-- undescribed -- +.IP "NVME_AER_ERROR_INVALID_DB_VAL" 12 +-- undescribed -- +.IP "NVME_AER_ERROR_DIAG_FAILURE" 12 +-- undescribed -- +.IP "NVME_AER_ERROR_PERSISTENT_INTERNAL_ERROR" 12 +-- undescribed -- +.IP "NVME_AER_ERROR_TRANSIENT_INTERNAL_ERROR" 12 +-- undescribed -- +.IP "NVME_AER_ERROR_FW_IMAGE_LOAD_ERROR" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_ae_info_notice.2 b/doc/man/enum nvme_ae_info_notice.2 new file mode 100644 index 00000000..a49a508d --- /dev/null +++ b/doc/man/enum nvme_ae_info_notice.2 @@ -0,0 +1,54 @@ +.TH "libnvme" 2 "enum nvme_ae_info_notice" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_ae_info_notice \- +.SH SYNOPSIS +enum nvme_ae_info_notice { +.br +.BI " NVME_AER_NOTICE_NS_CHANGED" +, +.br +.br +.BI " NVME_AER_NOTICE_FW_ACT_STARTING" +, +.br +.br +.BI " NVME_AER_NOTICE_TELEMETRY" +, +.br +.br +.BI " NVME_AER_NOTICE_ANA" +, +.br +.br +.BI " NVME_AER_NOTICE_PL_EVENT" +, +.br +.br +.BI " NVME_AER_NOTICE_LBA_STATUS_ALERT" +, +.br +.br +.BI " NVME_AER_NOTICE_EG_EVENT" +, +.br +.br +.BI " NVME_AER_NOTICE_DISC_CHANGED" + +}; +.SH Constants +.IP "NVME_AER_NOTICE_NS_CHANGED" 12 +-- undescribed -- +.IP "NVME_AER_NOTICE_FW_ACT_STARTING" 12 +-- undescribed -- +.IP "NVME_AER_NOTICE_TELEMETRY" 12 +-- undescribed -- +.IP "NVME_AER_NOTICE_ANA" 12 +-- undescribed -- +.IP "NVME_AER_NOTICE_PL_EVENT" 12 +-- undescribed -- +.IP "NVME_AER_NOTICE_LBA_STATUS_ALERT" 12 +-- undescribed -- +.IP "NVME_AER_NOTICE_EG_EVENT" 12 +-- undescribed -- +.IP "NVME_AER_NOTICE_DISC_CHANGED" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_ae_info_smart.2 b/doc/man/enum nvme_ae_info_smart.2 new file mode 100644 index 00000000..6c43a3d2 --- /dev/null +++ b/doc/man/enum nvme_ae_info_smart.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_ae_info_smart" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_ae_info_smart \- +.SH SYNOPSIS +enum nvme_ae_info_smart { +.br +.BI " NVME_AER_SMART_SUBSYSTEM_RELIABILITY" +, +.br +.br +.BI " NVME_AER_SMART_TEMPERATURE_THRESHOLD" +, +.br +.br +.BI " NVME_AER_SMART_SPARE_THRESHOLD" + +}; +.SH Constants +.IP "NVME_AER_SMART_SUBSYSTEM_RELIABILITY" 12 +-- undescribed -- +.IP "NVME_AER_SMART_TEMPERATURE_THRESHOLD" 12 +-- undescribed -- +.IP "NVME_AER_SMART_SPARE_THRESHOLD" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_ae_type.2 b/doc/man/enum nvme_ae_type.2 new file mode 100644 index 00000000..24b8482f --- /dev/null +++ b/doc/man/enum nvme_ae_type.2 @@ -0,0 +1,36 @@ +.TH "libnvme" 2 "enum nvme_ae_type" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_ae_type \- +.SH SYNOPSIS +enum nvme_ae_type { +.br +.BI " NVME_AER_ERROR" +, +.br +.br +.BI " NVME_AER_SMART" +, +.br +.br +.BI " NVME_AER_NOTICE" +, +.br +.br +.BI " NVME_AER_CSS" +, +.br +.br +.BI " NVME_AER_VS" + +}; +.SH Constants +.IP "NVME_AER_ERROR" 12 +-- undescribed -- +.IP "NVME_AER_SMART" 12 +-- undescribed -- +.IP "NVME_AER_NOTICE" 12 +-- undescribed -- +.IP "NVME_AER_CSS" 12 +-- undescribed -- +.IP "NVME_AER_VS" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_cmd_format_mset.2 b/doc/man/enum nvme_cmd_format_mset.2 new file mode 100644 index 00000000..baf172b3 --- /dev/null +++ b/doc/man/enum nvme_cmd_format_mset.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_cmd_format_mset" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_cmd_format_mset \- +.SH SYNOPSIS +enum nvme_cmd_format_mset { +.br +.BI " NVME_FORMAT_MSET_SEPARATE" +, +.br +.br +.BI " NVME_FORMAT_MSET_EXTENEDED" + +}; +.SH Constants +.IP "NVME_FORMAT_MSET_SEPARATE" 12 +-- undescribed -- +.IP "NVME_FORMAT_MSET_EXTENEDED" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_cmd_format_pi.2 b/doc/man/enum nvme_cmd_format_pi.2 new file mode 100644 index 00000000..71be5a6a --- /dev/null +++ b/doc/man/enum nvme_cmd_format_pi.2 @@ -0,0 +1,30 @@ +.TH "libnvme" 2 "enum nvme_cmd_format_pi" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_cmd_format_pi \- +.SH SYNOPSIS +enum nvme_cmd_format_pi { +.br +.BI " NVME_FORMAT_PI_DISABLE" +, +.br +.br +.BI " NVME_FORMAT_PI_TYPE1" +, +.br +.br +.BI " NVME_FORMAT_PI_TYPE2" +, +.br +.br +.BI " NVME_FORMAT_PI_TYPE3" + +}; +.SH Constants +.IP "NVME_FORMAT_PI_DISABLE" 12 +-- undescribed -- +.IP "NVME_FORMAT_PI_TYPE1" 12 +-- undescribed -- +.IP "NVME_FORMAT_PI_TYPE2" 12 +-- undescribed -- +.IP "NVME_FORMAT_PI_TYPE3" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_cmd_format_ses.2 b/doc/man/enum nvme_cmd_format_ses.2 new file mode 100644 index 00000000..9f28db3b --- /dev/null +++ b/doc/man/enum nvme_cmd_format_ses.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_cmd_format_ses" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_cmd_format_ses \- +.SH SYNOPSIS +enum nvme_cmd_format_ses { +.br +.BI " NVME_FORMAT_SES_NONE" +, +.br +.br +.BI " NVME_FORMAT_SES_USER_DATA_ERASE" +, +.br +.br +.BI " NVME_FORMAT_SES_CRYPTO_ERASE" + +}; +.SH Constants +.IP "NVME_FORMAT_SES_NONE" 12 +-- undescribed -- +.IP "NVME_FORMAT_SES_USER_DATA_ERASE" 12 +-- undescribed -- +.IP "NVME_FORMAT_SES_CRYPTO_ERASE" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_cmd_get_log_lid.2 b/doc/man/enum nvme_cmd_get_log_lid.2 new file mode 100644 index 00000000..e2927341 --- /dev/null +++ b/doc/man/enum nvme_cmd_get_log_lid.2 @@ -0,0 +1,114 @@ +.TH "libnvme" 2 "enum nvme_cmd_get_log_lid" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_cmd_get_log_lid \- +.SH SYNOPSIS +enum nvme_cmd_get_log_lid { +.br +.BI " NVME_LOG_LID_ERROR" +, +.br +.br +.BI " NVME_LOG_LID_SMART" +, +.br +.br +.BI " NVME_LOG_LID_FW_SLOT" +, +.br +.br +.BI " NVME_LOG_LID_CHANGED_NS" +, +.br +.br +.BI " NVME_LOG_LID_CMD_EFFECTS" +, +.br +.br +.BI " NVME_LOG_LID_DEVICE_SELF_TEST" +, +.br +.br +.BI " NVME_LOG_LID_TELEMETRY_HOST" +, +.br +.br +.BI " NVME_LOG_LID_TELEMETRY_CTRL" +, +.br +.br +.BI " NVME_LOG_LID_ENDURANCE_GROUP" +, +.br +.br +.BI " NVME_LOG_LID_PREDICTABLE_LAT_NVMSET" +, +.br +.br +.BI " NVME_LOG_LID_PREDICTABLE_LAT_AGG" +, +.br +.br +.BI " NVME_LOG_LID_ANA" +, +.br +.br +.BI " NVME_LOG_LID_PERSISTENT_EVENT" +, +.br +.br +.BI " NVME_LOG_LID_LBA_STATUS" +, +.br +.br +.BI " NVME_LOG_LID_ENDURANCE_GRP_EVT" +, +.br +.br +.BI " NVME_LOG_LID_DISCOVER" +, +.br +.br +.BI " NVME_LOG_LID_RESERVATION" +, +.br +.br +.BI " NVME_LOG_LID_SANITIZE" + +}; +.SH Constants +.IP "NVME_LOG_LID_ERROR" 12 +-- undescribed -- +.IP "NVME_LOG_LID_SMART" 12 +-- undescribed -- +.IP "NVME_LOG_LID_FW_SLOT" 12 +-- undescribed -- +.IP "NVME_LOG_LID_CHANGED_NS" 12 +-- undescribed -- +.IP "NVME_LOG_LID_CMD_EFFECTS" 12 +-- undescribed -- +.IP "NVME_LOG_LID_DEVICE_SELF_TEST" 12 +-- undescribed -- +.IP "NVME_LOG_LID_TELEMETRY_HOST" 12 +-- undescribed -- +.IP "NVME_LOG_LID_TELEMETRY_CTRL" 12 +-- undescribed -- +.IP "NVME_LOG_LID_ENDURANCE_GROUP" 12 +-- undescribed -- +.IP "NVME_LOG_LID_PREDICTABLE_LAT_NVMSET" 12 +-- undescribed -- +.IP "NVME_LOG_LID_PREDICTABLE_LAT_AGG" 12 +-- undescribed -- +.IP "NVME_LOG_LID_ANA" 12 +-- undescribed -- +.IP "NVME_LOG_LID_PERSISTENT_EVENT" 12 +-- undescribed -- +.IP "NVME_LOG_LID_LBA_STATUS" 12 +-- undescribed -- +.IP "NVME_LOG_LID_ENDURANCE_GRP_EVT" 12 +-- undescribed -- +.IP "NVME_LOG_LID_DISCOVER" 12 +-- undescribed -- +.IP "NVME_LOG_LID_RESERVATION" 12 +-- undescribed -- +.IP "NVME_LOG_LID_SANITIZE" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_constants.2 b/doc/man/enum nvme_constants.2 new file mode 100644 index 00000000..9d83563a --- /dev/null +++ b/doc/man/enum nvme_constants.2 @@ -0,0 +1,118 @@ +.TH "libnvme" 2 "enum nvme_constants" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_constants \- A place to stash various constant nvme values +.SH SYNOPSIS +enum nvme_constants { +.br +.BI " NVME_NSID_ALL" +, +.br +.br +.BI " NVME_NSID_NONE" +, +.br +.br +.BI " NVME_UUID_NONE" +, +.br +.br +.BI " NVME_CNTLID_NONE" +, +.br +.br +.BI " NVME_NVMSETID_NONE" +, +.br +.br +.BI " NVME_LOG_LSP_NONE" +, +.br +.br +.BI " NVME_LOG_LSI_NONE" +, +.br +.br +.BI " NVME_IDENTIFY_DATA_SIZE" +, +.br +.br +.BI " NVME_ID_NVMSET_LIST_MAX" +, +.br +.br +.BI " NVME_ID_UUID_LIST_MAX" +, +.br +.br +.BI " NVME_ID_CTRL_LIST_MAX" +, +.br +.br +.BI " NVME_ID_NS_LIST_MAX" +, +.br +.br +.BI " NVME_ID_SECONDARY_CTRL_MAX" +, +.br +.br +.BI " NVME_ID_ND_DESCRIPTOR_MAX" +, +.br +.br +.BI " NVME_FEAT_LBA_RANGE_MAX" +, +.br +.br +.BI " NVME_LOG_ST_MAX_RESULTS" +, +.br +.br +.BI " NVME_DSM_MAX_RANGES" + +}; +.SH Constants +.IP "NVME_NSID_ALL" 12 +A broadcast value that is used to specify all +namespaces +.IP "NVME_NSID_NONE" 12 +The invalid namespace id, for when the nsid +parameter is not used in a command +.IP "NVME_UUID_NONE" 12 +Use to omit the uuid command parameter +.IP "NVME_CNTLID_NONE" 12 +Use to omit the cntlid command parameter +.IP "NVME_NVMSETID_NONE" 12 +Use to omit the nvmsetid command parameter +.IP "NVME_LOG_LSP_NONE" 12 +Use to omit the log lsp command parameter +.IP "NVME_LOG_LSI_NONE" 12 +Use to omit the log lsi command parameter +.IP "NVME_IDENTIFY_DATA_SIZE" 12 +The transfer size for nvme identify commands +.IP "NVME_ID_NVMSET_LIST_MAX" 12 +The largest possible nvmset index in identify +nvmeset +.IP "NVME_ID_UUID_LIST_MAX" 12 +The largest possible uuid index in identify +uuid list +.IP "NVME_ID_CTRL_LIST_MAX" 12 +The largest possible controller index in +identify controller list +.IP "NVME_ID_NS_LIST_MAX" 12 +The largest possible namespace index in +identify namespace list +.IP "NVME_ID_SECONDARY_CTRL_MAX" 12 +The largest possible secondary controller index +in identify secondary controller +.IP "NVME_ID_ND_DESCRIPTOR_MAX" 12 +-- undescribed -- +.IP "NVME_FEAT_LBA_RANGE_MAX" 12 +The largest possible LBA range index in feature +lba range type +.IP "NVME_LOG_ST_MAX_RESULTS" 12 +The largest possible self test result index in the +device self test log +.IP "NVME_DSM_MAX_RANGES" 12 +The largest possible range index in a data-set +management command diff --git a/doc/man/enum nvme_directive_dtype.2 b/doc/man/enum nvme_directive_dtype.2 new file mode 100644 index 00000000..2b50c797 --- /dev/null +++ b/doc/man/enum nvme_directive_dtype.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_directive_dtype" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_directive_dtype \- +.SH SYNOPSIS +enum nvme_directive_dtype { +.br +.BI " NVME_DIRECTIVE_DTYPE_IDENTIFY" +, +.br +.br +.BI " NVME_DIRECTIVE_DTYPE_STREAMS" + +}; +.SH Constants +.IP "NVME_DIRECTIVE_DTYPE_IDENTIFY" 12 +-- undescribed -- +.IP "NVME_DIRECTIVE_DTYPE_STREAMS" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_directive_receive_doper.2 b/doc/man/enum nvme_directive_receive_doper.2 new file mode 100644 index 00000000..29c653b5 --- /dev/null +++ b/doc/man/enum nvme_directive_receive_doper.2 @@ -0,0 +1,30 @@ +.TH "libnvme" 2 "enum nvme_directive_receive_doper" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_directive_receive_doper \- +.SH SYNOPSIS +enum nvme_directive_receive_doper { +.br +.BI " NVME_DIRECTIVE_RECEIVE_IDENTIFY_DOPER_PARAM" +, +.br +.br +.BI " NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_PARAM" +, +.br +.br +.BI " NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_STATUS" +, +.br +.br +.BI " NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_RESOURCE" + +}; +.SH Constants +.IP "NVME_DIRECTIVE_RECEIVE_IDENTIFY_DOPER_PARAM" 12 +-- undescribed -- +.IP "NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_PARAM" 12 +-- undescribed -- +.IP "NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_STATUS" 12 +-- undescribed -- +.IP "NVME_DIRECTIVE_RECEIVE_STREAMS_DOPER_RESOURCE" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_directive_send_doper.2 b/doc/man/enum nvme_directive_send_doper.2 new file mode 100644 index 00000000..0fbdcd29 --- /dev/null +++ b/doc/man/enum nvme_directive_send_doper.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_directive_send_doper" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_directive_send_doper \- +.SH SYNOPSIS +enum nvme_directive_send_doper { +.br +.BI " NVME_DIRECTIVE_SEND_IDENTIFY_DOPER_ENDIR" +, +.br +.br +.BI " NVME_DIRECTIVE_SEND_STREAMS_DOPER_RELEASE_IDENTIFIER" +, +.br +.br +.BI " NVME_DIRECTIVE_SEND_STREAMS_DOPER_RELEASE_RESOURCE" + +}; +.SH Constants +.IP "NVME_DIRECTIVE_SEND_IDENTIFY_DOPER_ENDIR" 12 +-- undescribed -- +.IP "NVME_DIRECTIVE_SEND_STREAMS_DOPER_RELEASE_IDENTIFIER" 12 +-- undescribed -- +.IP "NVME_DIRECTIVE_SEND_STREAMS_DOPER_RELEASE_RESOURCE" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_directive_send_identify_endir.2 b/doc/man/enum nvme_directive_send_identify_endir.2 new file mode 100644 index 00000000..22d4cef6 --- /dev/null +++ b/doc/man/enum nvme_directive_send_identify_endir.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_directive_send_identify_endir" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_directive_send_identify_endir \- +.SH SYNOPSIS +enum nvme_directive_send_identify_endir { +.br +.BI " NVME_DIRECTIVE_SEND_IDENTIFY_ENDIR_DISABLE" +, +.br +.br +.BI " NVME_DIRECTIVE_SEND_IDENTIFY_ENDIR_ENABLE" + +}; +.SH Constants +.IP "NVME_DIRECTIVE_SEND_IDENTIFY_ENDIR_DISABLE" 12 +-- undescribed -- +.IP "NVME_DIRECTIVE_SEND_IDENTIFY_ENDIR_ENABLE" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_dsm_attributes.2 b/doc/man/enum nvme_dsm_attributes.2 new file mode 100644 index 00000000..747db904 --- /dev/null +++ b/doc/man/enum nvme_dsm_attributes.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_dsm_attributes" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_dsm_attributes \- +.SH SYNOPSIS +enum nvme_dsm_attributes { +.br +.BI " NVME_DSMGMT_IDR" +, +.br +.br +.BI " NVME_DSMGMT_IDW" +, +.br +.br +.BI " NVME_DSMGMT_AD" + +}; +.SH Constants +.IP "NVME_DSMGMT_IDR" 12 +-- undescribed -- +.IP "NVME_DSMGMT_IDW" 12 +-- undescribed -- +.IP "NVME_DSMGMT_AD" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_dst_stc.2 b/doc/man/enum nvme_dst_stc.2 new file mode 100644 index 00000000..10580695 --- /dev/null +++ b/doc/man/enum nvme_dst_stc.2 @@ -0,0 +1,30 @@ +.TH "libnvme" 2 "enum nvme_dst_stc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_dst_stc \- +.SH SYNOPSIS +enum nvme_dst_stc { +.br +.BI " NVME_DST_STC_SHORT" +, +.br +.br +.BI " NVME_DST_STC_LONG" +, +.br +.br +.BI " NVME_DST_STC_VS" +, +.br +.br +.BI " NVME_DST_STC_ABORT" + +}; +.SH Constants +.IP "NVME_DST_STC_SHORT" 12 +-- undescribed -- +.IP "NVME_DST_STC_LONG" 12 +-- undescribed -- +.IP "NVME_DST_STC_VS" 12 +-- undescribed -- +.IP "NVME_DST_STC_ABORT" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_eg_critical_warning_flags.2 b/doc/man/enum nvme_eg_critical_warning_flags.2 new file mode 100644 index 00000000..d1ed9686 --- /dev/null +++ b/doc/man/enum nvme_eg_critical_warning_flags.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_eg_critical_warning_flags" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_eg_critical_warning_flags \- +.SH SYNOPSIS +enum nvme_eg_critical_warning_flags { +.br +.BI " NVME_EG_CRITICAL_WARNING_SPARE" +, +.br +.br +.BI " NVME_EG_CRITICAL_WARNING_DEGRADED" +, +.br +.br +.BI " NVME_EG_CRITICAL_WARNING_READ_ONLY" + +}; +.SH Constants +.IP "NVME_EG_CRITICAL_WARNING_SPARE" 12 +-- undescribed -- +.IP "NVME_EG_CRITICAL_WARNING_DEGRADED" 12 +-- undescribed -- +.IP "NVME_EG_CRITICAL_WARNING_READ_ONLY" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_fctype.2 b/doc/man/enum nvme_fctype.2 new file mode 100644 index 00000000..9a7fa6a0 --- /dev/null +++ b/doc/man/enum nvme_fctype.2 @@ -0,0 +1,42 @@ +.TH "libnvme" 2 "enum nvme_fctype" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_fctype \- +.SH SYNOPSIS +enum nvme_fctype { +.br +.BI " nvme_fabrics_type_property_set" +, +.br +.br +.BI " nvme_fabrics_type_connect" +, +.br +.br +.BI " nvme_fabrics_type_property_get" +, +.br +.br +.BI " nvme_fabrics_type_auth_send" +, +.br +.br +.BI " nvme_fabrics_type_auth_receive" +, +.br +.br +.BI " nvme_fabrics_type_disconnect" + +}; +.SH Constants +.IP "nvme_fabrics_type_property_set" 12 +-- undescribed -- +.IP "nvme_fabrics_type_connect" 12 +-- undescribed -- +.IP "nvme_fabrics_type_property_get" 12 +-- undescribed -- +.IP "nvme_fabrics_type_auth_send" 12 +-- undescribed -- +.IP "nvme_fabrics_type_auth_receive" 12 +-- undescribed -- +.IP "nvme_fabrics_type_disconnect" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_feat_nswpcfg_state.2 b/doc/man/enum nvme_feat_nswpcfg_state.2 new file mode 100644 index 00000000..0d996181 --- /dev/null +++ b/doc/man/enum nvme_feat_nswpcfg_state.2 @@ -0,0 +1,30 @@ +.TH "libnvme" 2 "enum nvme_feat_nswpcfg_state" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_feat_nswpcfg_state \- +.SH SYNOPSIS +enum nvme_feat_nswpcfg_state { +.br +.BI " NVME_FEAT_NS_NO_WRITE_PROTECT" +, +.br +.br +.BI " NVME_FEAT_NS_WRITE_PROTECT" +, +.br +.br +.BI " NVME_FEAT_NS_WRITE_PROTECT_PWR_CYCLE" +, +.br +.br +.BI " NVME_FEAT_NS_WRITE_PROTECT_PERMANENT" + +}; +.SH Constants +.IP "NVME_FEAT_NS_NO_WRITE_PROTECT" 12 +-- undescribed -- +.IP "NVME_FEAT_NS_WRITE_PROTECT" 12 +-- undescribed -- +.IP "NVME_FEAT_NS_WRITE_PROTECT_PWR_CYCLE" 12 +-- undescribed -- +.IP "NVME_FEAT_NS_WRITE_PROTECT_PERMANENT" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_feat_plm_window_select.2 b/doc/man/enum nvme_feat_plm_window_select.2 new file mode 100644 index 00000000..cc210c92 --- /dev/null +++ b/doc/man/enum nvme_feat_plm_window_select.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_feat_plm_window_select" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_feat_plm_window_select \- +.SH SYNOPSIS +enum nvme_feat_plm_window_select { +.br +.BI " NVME_FEATURE_PLM_DTWIN" +, +.br +.br +.BI " NVME_FEATURE_PLM_NDWIN" + +}; +.SH Constants +.IP "NVME_FEATURE_PLM_DTWIN" 12 +-- undescribed -- +.IP "NVME_FEATURE_PLM_NDWIN" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_feat_tmpthresh_thsel.2 b/doc/man/enum nvme_feat_tmpthresh_thsel.2 new file mode 100644 index 00000000..305c8a00 --- /dev/null +++ b/doc/man/enum nvme_feat_tmpthresh_thsel.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_feat_tmpthresh_thsel" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_feat_tmpthresh_thsel \- +.SH SYNOPSIS +enum nvme_feat_tmpthresh_thsel { +.br +.BI " NVME_FEATURE_TEMPTHRESH_THSEL_OVER" +, +.br +.br +.BI " NVME_FEATURETEMPTHRESH__THSEL_UNDER" + +}; +.SH Constants +.IP "NVME_FEATURE_TEMPTHRESH_THSEL_OVER" 12 +-- undescribed -- +.IP "NVME_FEATURETEMPTHRESH__THSEL_UNDER" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_features_async_event_config_flags.2 b/doc/man/enum nvme_features_async_event_config_flags.2 new file mode 100644 index 00000000..9f1dd9d0 --- /dev/null +++ b/doc/man/enum nvme_features_async_event_config_flags.2 @@ -0,0 +1,90 @@ +.TH "libnvme" 2 "enum nvme_features_async_event_config_flags" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_features_async_event_config_flags \- +.SH SYNOPSIS +enum nvme_features_async_event_config_flags { +.br +.BI " NVME_FEATURE_AENCFG_SMART_CRIT_SPARE" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_SMART_CRIT_TEMPERATURE" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_SMART_CRIT_DEGRADED" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_SMART_CRIT_READ_ONLY" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_SMART_CRIT_VOLATILE_BACKUP" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_SMART_CRIT_READ_ONLY_PMR" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_NOTICE_NAMESPACE_ATTRIBUTES" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_NOTICE_FIRMWARE_ACTIVATION" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_NOTICE_TELEMETRY_LOG" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_NOTICE_ANA_CHANGE" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_NOTICE_PL_EVENT" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_NOTICE_LBA_STATUS" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_NOTICE_EG_EVENT" +, +.br +.br +.BI " NVME_FEATURE_AENCFG_NOTICE_DISCOVERY_CHANGE" + +}; +.SH Constants +.IP "NVME_FEATURE_AENCFG_SMART_CRIT_SPARE" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_SMART_CRIT_TEMPERATURE" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_SMART_CRIT_DEGRADED" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_SMART_CRIT_READ_ONLY" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_SMART_CRIT_VOLATILE_BACKUP" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_SMART_CRIT_READ_ONLY_PMR" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_NOTICE_NAMESPACE_ATTRIBUTES" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_NOTICE_FIRMWARE_ACTIVATION" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_NOTICE_TELEMETRY_LOG" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_NOTICE_ANA_CHANGE" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_NOTICE_PL_EVENT" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_NOTICE_LBA_STATUS" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_NOTICE_EG_EVENT" 12 +-- undescribed -- +.IP "NVME_FEATURE_AENCFG_NOTICE_DISCOVERY_CHANGE" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_features_id.2 b/doc/man/enum nvme_features_id.2 new file mode 100644 index 00000000..36b33148 --- /dev/null +++ b/doc/man/enum nvme_features_id.2 @@ -0,0 +1,180 @@ +.TH "libnvme" 2 "enum nvme_features_id" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_features_id \- +.SH SYNOPSIS +enum nvme_features_id { +.br +.BI " NVME_FEAT_FID_ARBITRATION" +, +.br +.br +.BI " NVME_FEAT_FID_POWER_MGMT" +, +.br +.br +.BI " NVME_FEAT_FID_LBA_RANGE" +, +.br +.br +.BI " NVME_FEAT_FID_TEMP_THRESH" +, +.br +.br +.BI " NVME_FEAT_FID_ERR_RECOVERY" +, +.br +.br +.BI " NVME_FEAT_FID_VOLATILE_WC" +, +.br +.br +.BI " NVME_FEAT_FID_NUM_QUEUES" +, +.br +.br +.BI " NVME_FEAT_FID_IRQ_COALESCE" +, +.br +.br +.BI " NVME_FEAT_FID_IRQ_CONFIG" +, +.br +.br +.BI " NVME_FEAT_FID_WRITE_ATOMIC" +, +.br +.br +.BI " NVME_FEAT_FID_ASYNC_EVENT" +, +.br +.br +.BI " NVME_FEAT_FID_AUTO_PST" +, +.br +.br +.BI " NVME_FEAT_FID_HOST_MEM_BUF" +, +.br +.br +.BI " NVME_FEAT_FID_TIMESTAMP" +, +.br +.br +.BI " NVME_FEAT_FID_KATO" +, +.br +.br +.BI " NVME_FEAT_FID_HCTM" +, +.br +.br +.BI " NVME_FEAT_FID_NOPSC" +, +.br +.br +.BI " NVME_FEAT_FID_RRL" +, +.br +.br +.BI " NVME_FEAT_FID_PLM_CONFIG" +, +.br +.br +.BI " NVME_FEAT_FID_PLM_WINDOW" +, +.br +.br +.BI " NVME_FEAT_FID_LBA_STS_INTERVAL" +, +.br +.br +.BI " NVME_FEAT_FID_HOST_BEHAVIOR" +, +.br +.br +.BI " NVME_FEAT_FID_SANITIZE" +, +.br +.br +.BI " NVME_FEAT_FID_ENDURANCE_EVT_CFG" +, +.br +.br +.BI " NVME_FEAT_FID_SW_PROGRESS" +, +.br +.br +.BI " NVME_FEAT_FID_HOST_ID" +, +.br +.br +.BI " NVME_FEAT_FID_RESV_MASK" +, +.br +.br +.BI " NVME_FEAT_RESV_PERSIST" +, +.br +.br +.BI " NVME_FEAT_FID_WRITE_PROTECT" + +}; +.SH Constants +.IP "NVME_FEAT_FID_ARBITRATION" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_POWER_MGMT" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_LBA_RANGE" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_TEMP_THRESH" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_ERR_RECOVERY" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_VOLATILE_WC" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_NUM_QUEUES" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_IRQ_COALESCE" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_IRQ_CONFIG" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_WRITE_ATOMIC" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_ASYNC_EVENT" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_AUTO_PST" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_HOST_MEM_BUF" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_TIMESTAMP" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_KATO" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_HCTM" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_NOPSC" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_RRL" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_PLM_CONFIG" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_PLM_WINDOW" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_LBA_STS_INTERVAL" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_HOST_BEHAVIOR" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_SANITIZE" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_ENDURANCE_EVT_CFG" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_SW_PROGRESS" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_HOST_ID" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_RESV_MASK" 12 +-- undescribed -- +.IP "NVME_FEAT_RESV_PERSIST" 12 +-- undescribed -- +.IP "NVME_FEAT_FID_WRITE_PROTECT" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_fw_commit_ca.2 b/doc/man/enum nvme_fw_commit_ca.2 new file mode 100644 index 00000000..46cdd7f4 --- /dev/null +++ b/doc/man/enum nvme_fw_commit_ca.2 @@ -0,0 +1,42 @@ +.TH "libnvme" 2 "enum nvme_fw_commit_ca" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_fw_commit_ca \- +.SH SYNOPSIS +enum nvme_fw_commit_ca { +.br +.BI " NVME_FW_COMMIT_CA_REPLACE" +, +.br +.br +.BI " NVME_FW_COMMIT_CA_REPLACE_AND_ACTIVATE" +, +.br +.br +.BI " NVME_FW_COMMIT_CA_SET_ACTIVE" +, +.br +.br +.BI " NVME_FW_COMMIT_CA_REPLACE_AND_ACTIVATE_IMMEDIATE" +, +.br +.br +.BI " NVME_FW_COMMIT_CA_REPLACE_BOOT_PARTITION" +, +.br +.br +.BI " NVME_FW_COMMIT_CA_ACTIVATE_BOOT_PARTITION" + +}; +.SH Constants +.IP "NVME_FW_COMMIT_CA_REPLACE" 12 +-- undescribed -- +.IP "NVME_FW_COMMIT_CA_REPLACE_AND_ACTIVATE" 12 +-- undescribed -- +.IP "NVME_FW_COMMIT_CA_SET_ACTIVE" 12 +-- undescribed -- +.IP "NVME_FW_COMMIT_CA_REPLACE_AND_ACTIVATE_IMMEDIATE" 12 +-- undescribed -- +.IP "NVME_FW_COMMIT_CA_REPLACE_BOOT_PARTITION" 12 +-- undescribed -- +.IP "NVME_FW_COMMIT_CA_ACTIVATE_BOOT_PARTITION" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_get_features_sel.2 b/doc/man/enum nvme_get_features_sel.2 new file mode 100644 index 00000000..99b64968 --- /dev/null +++ b/doc/man/enum nvme_get_features_sel.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_get_features_sel" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_get_features_sel \- +.SH SYNOPSIS +enum nvme_get_features_sel { +.br +.BI " NVME_GET_FEATURES_SEL_CURRENT" +, +.br +.br +.BI " NVME_GET_FEATURES_SEL_DEFAULT" +, +.br +.br +.BI " NVME_GET_FEATURES_SEL_SAVED" + +}; +.SH Constants +.IP "NVME_GET_FEATURES_SEL_CURRENT" 12 +-- undescribed -- +.IP "NVME_GET_FEATURES_SEL_DEFAULT" 12 +-- undescribed -- +.IP "NVME_GET_FEATURES_SEL_SAVED" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_id_ctrl_anacap.2 b/doc/man/enum nvme_id_ctrl_anacap.2 new file mode 100644 index 00000000..8ff1515f --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_anacap.2 @@ -0,0 +1,59 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_anacap" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_anacap \- This field indicates the capabilities associated with Asymmetric Namespace Access Reporting. +.SH SYNOPSIS +enum nvme_id_ctrl_anacap { +.br +.BI " NVME_CTRL_ANACAP_OPT" +, +.br +.br +.BI " NVME_CTRL_ANACAP_NON_OPT" +, +.br +.br +.BI " NVME_CTRL_ANACAP_INACCESSIBLE" +, +.br +.br +.BI " NVME_CTRL_ANACAP_PERSISTENT_LOSS" +, +.br +.br +.BI " NVME_CTRL_ANACAP_CHANGE" +, +.br +.br +.BI " NVME_CTRL_ANACAP_GRPID_NO_CHG" +, +.br +.br +.BI " NVME_CTRL_ANACAP_GRPID_MGMT" + +}; +.SH Constants +.IP "NVME_CTRL_ANACAP_OPT" 12 +If set, then the controller is able to +report ANA Optimized state. +.IP "NVME_CTRL_ANACAP_NON_OPT" 12 +If set, then the controller is able to +report ANA Non-Optimized state. +.IP "NVME_CTRL_ANACAP_INACCESSIBLE" 12 +If set, then the controller is able to +report ANA Inaccessible state. +.IP "NVME_CTRL_ANACAP_PERSISTENT_LOSS" 12 +If set, then the controller is able to +report ANA Persistent Loss state. +.IP "NVME_CTRL_ANACAP_CHANGE" 12 +If set, then the controller is able to +report ANA Change state. +.IP "NVME_CTRL_ANACAP_GRPID_NO_CHG" 12 +If set, then the ANAGRPID field in the +Identify Namespace data structure +(\fIstruct nvme_id_ns\fP.anagrpid), does not +change while the namespace is attached to +any controller. +.IP "NVME_CTRL_ANACAP_GRPID_MGMT" 12 +If set, then the controller supports a +non-zero value in the ANAGRPID field of +the Namespace Management command. diff --git a/doc/man/enum nvme_id_ctrl_apsta.2 b/doc/man/enum nvme_id_ctrl_apsta.2 new file mode 100644 index 00000000..a446ecd3 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_apsta.2 @@ -0,0 +1,13 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_apsta" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_apsta \- Flags indicating the attributes of the autonomous power state transition feature. +.SH SYNOPSIS +enum nvme_id_ctrl_apsta { +.br +.BI " NVME_CTRL_APSTA_APST" + +}; +.SH Constants +.IP "NVME_CTRL_APSTA_APST" 12 +If set, then the controller supports autonomous power +state transitions. diff --git a/doc/man/enum nvme_id_ctrl_avscc.2 b/doc/man/enum nvme_id_ctrl_avscc.2 new file mode 100644 index 00000000..dce414b8 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_avscc.2 @@ -0,0 +1,14 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_avscc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_avscc \- Flags indicating the configuration settings for Admin Vendor Specific command handling. +.SH SYNOPSIS +enum nvme_id_ctrl_avscc { +.br +.BI " NVME_CTRL_AVSCC_AVS" + +}; +.SH Constants +.IP "NVME_CTRL_AVSCC_AVS" 12 +If set, all Admin Vendor Specific Commands use the +optional vendor specific command format with NDT and +NDM fields. diff --git a/doc/man/enum nvme_id_ctrl_cmic.2 b/doc/man/enum nvme_id_ctrl_cmic.2 new file mode 100644 index 00000000..76a22eb8 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_cmic.2 @@ -0,0 +1,30 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_cmic" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_cmic \- +.SH SYNOPSIS +enum nvme_id_ctrl_cmic { +.br +.BI " NVME_CTRL_CMIC_MULTI_PORT" +, +.br +.br +.BI " NVME_CTRL_CMIC_MULTI_CTRL" +, +.br +.br +.BI " NVME_CTRL_CMIC_MULTI_SRIOV" +, +.br +.br +.BI " NVME_CTRL_CMIC_MULTI_ANA_REPORTING" + +}; +.SH Constants +.IP "NVME_CTRL_CMIC_MULTI_PORT" 12 +-- undescribed -- +.IP "NVME_CTRL_CMIC_MULTI_CTRL" 12 +-- undescribed -- +.IP "NVME_CTRL_CMIC_MULTI_SRIOV" 12 +-- undescribed -- +.IP "NVME_CTRL_CMIC_MULTI_ANA_REPORTING" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_id_ctrl_cntrltype.2 b/doc/man/enum nvme_id_ctrl_cntrltype.2 new file mode 100644 index 00000000..34f7d1de --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_cntrltype.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_cntrltype" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_cntrltype \- +.SH SYNOPSIS +enum nvme_id_ctrl_cntrltype { +.br +.BI " NVME_CTRL_CNTRLTYPE_IO" +, +.br +.br +.BI " NVME_CTRL_CNTRLTYPE_DISCOVERY" +, +.br +.br +.BI " NVME_CTRL_CNTRLTYPE_ADMIN" + +}; +.SH Constants +.IP "NVME_CTRL_CNTRLTYPE_IO" 12 +-- undescribed -- +.IP "NVME_CTRL_CNTRLTYPE_DISCOVERY" 12 +-- undescribed -- +.IP "NVME_CTRL_CNTRLTYPE_ADMIN" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_id_ctrl_ctratt.2 b/doc/man/enum nvme_id_ctrl_ctratt.2 new file mode 100644 index 00000000..76fde98d --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_ctratt.2 @@ -0,0 +1,66 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_ctratt" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_ctratt \- +.SH SYNOPSIS +enum nvme_id_ctrl_ctratt { +.br +.BI " NVME_CTRL_CTRATT_128_ID" +, +.br +.br +.BI " NVME_CTRL_CTRATT_NON_OP_PSP" +, +.br +.br +.BI " NVME_CTRL_CTRATT_NVM_SETS" +, +.br +.br +.BI " NVME_CTRL_CTRATT_READ_RECV_LVLS" +, +.br +.br +.BI " NVME_CTRL_CTRATT_ENDURANCE_GROUPS" +, +.br +.br +.BI " NVME_CTRL_CTRATT_PREDICTABLE_LAT" +, +.br +.br +.BI " NVME_CTRL_CTRATT_TBKAS" +, +.br +.br +.BI " NVME_CTRL_CTRATT_NAMESPACE_GRANULARITY" +, +.br +.br +.BI " NVME_CTRL_CTRATT_SQ_ASSOCIATIONS" +, +.br +.br +.BI " NVME_CTRL_CTRATT_UUID_LIST" + +}; +.SH Constants +.IP "NVME_CTRL_CTRATT_128_ID" 12 +-- undescribed -- +.IP "NVME_CTRL_CTRATT_NON_OP_PSP" 12 +-- undescribed -- +.IP "NVME_CTRL_CTRATT_NVM_SETS" 12 +-- undescribed -- +.IP "NVME_CTRL_CTRATT_READ_RECV_LVLS" 12 +-- undescribed -- +.IP "NVME_CTRL_CTRATT_ENDURANCE_GROUPS" 12 +-- undescribed -- +.IP "NVME_CTRL_CTRATT_PREDICTABLE_LAT" 12 +-- undescribed -- +.IP "NVME_CTRL_CTRATT_TBKAS" 12 +-- undescribed -- +.IP "NVME_CTRL_CTRATT_NAMESPACE_GRANULARITY" 12 +-- undescribed -- +.IP "NVME_CTRL_CTRATT_SQ_ASSOCIATIONS" 12 +-- undescribed -- +.IP "NVME_CTRL_CTRATT_UUID_LIST" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_id_ctrl_dsto.2 b/doc/man/enum nvme_id_ctrl_dsto.2 new file mode 100644 index 00000000..7311a190 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_dsto.2 @@ -0,0 +1,13 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_dsto" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_dsto \- Flags indicating the optional Device Self-test command or operation behaviors supported by the controller or NVM subsystem. +.SH SYNOPSIS +enum nvme_id_ctrl_dsto { +.br +.BI " NVME_CTRL_DSTO_ONE_DST" + +}; +.SH Constants +.IP "NVME_CTRL_DSTO_ONE_DST" 12 +If set, then the NVM subsystem supports only one +device self-test operation in progress at a time. diff --git a/doc/man/enum nvme_id_ctrl_fcatt.2 b/doc/man/enum nvme_id_ctrl_fcatt.2 new file mode 100644 index 00000000..c11ab21f --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_fcatt.2 @@ -0,0 +1,14 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_fcatt" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_fcatt \- This field indicates attributes of the controller that are specific to NVMe over Fabrics. +.SH SYNOPSIS +enum nvme_id_ctrl_fcatt { +.br +.BI " NVME_CTRL_FCATT_DYNAMIC" + +}; +.SH Constants +.IP "NVME_CTRL_FCATT_DYNAMIC" 12 +If cleared, then the NVM subsystem uses a dynamic +controller model. If set, then the NVM subsystem +uses a static controller model. diff --git a/doc/man/enum nvme_id_ctrl_fna.2 b/doc/man/enum nvme_id_ctrl_fna.2 new file mode 100644 index 00000000..cb0c0a98 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_fna.2 @@ -0,0 +1,39 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_fna" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_fna \- This field indicates attributes for the Format NVM command. +.SH SYNOPSIS +enum nvme_id_ctrl_fna { +.br +.BI " NVME_CTRL_FNA_FMT_ALL_NAMESPACES" +, +.br +.br +.BI " NVME_CTRL_FNA_SEC_ALL_NAMESPACES" +, +.br +.br +.BI " NVME_CTRL_FNA_CRYPTO_ERASE" + +}; +.SH Constants +.IP "NVME_CTRL_FNA_FMT_ALL_NAMESPACES" 12 +If set, then all namespaces in an NVM +subsystem shall be configured with the +same attributes and a format (excluding +secure erase) of any namespace results in +a format of all namespaces in an NVM +subsystem. If cleared, then the +controller supports format on a per +namespace basis. +.IP "NVME_CTRL_FNA_SEC_ALL_NAMESPACES" 12 +If set, then any secure erase performed +as part of a format operation results in +a secure erase of all namespaces in the +NVM subsystem. If cleared, then any +secure erase performed as part of a +format results in a secure erase of the +particular namespace specified. +.IP "NVME_CTRL_FNA_CRYPTO_ERASE" 12 +If set, then cryptographic erase is +supported. If cleared, then cryptographic +erase is not supported. diff --git a/doc/man/enum nvme_id_ctrl_frmw.2 b/doc/man/enum nvme_id_ctrl_frmw.2 new file mode 100644 index 00000000..40611e65 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_frmw.2 @@ -0,0 +1,26 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_frmw" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_frmw \- Flags and values indicates capabilities regarding firmware updates from &struct nvme_id_ctrl.frmw. +.SH SYNOPSIS +enum nvme_id_ctrl_frmw { +.br +.BI " NVME_CTRL_FRMW_1ST_RO" +, +.br +.br +.BI " NVME_CTRL_FRMW_NR_SLOTS" +, +.br +.br +.BI " NVME_CTRL_FRMW_FW_ACT_NO_RESET" + +}; +.SH Constants +.IP "NVME_CTRL_FRMW_1ST_RO" 12 +If set, the first firmware slot is readonly +.IP "NVME_CTRL_FRMW_NR_SLOTS" 12 +Mask to get the value of the number of +firmware slots that the controller supports. +.IP "NVME_CTRL_FRMW_FW_ACT_NO_RESET" 12 +If set, the controller supports firmware +activation without a reset. diff --git a/doc/man/enum nvme_id_ctrl_fuses.2 b/doc/man/enum nvme_id_ctrl_fuses.2 new file mode 100644 index 00000000..dbdaddf5 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_fuses.2 @@ -0,0 +1,13 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_fuses" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_fuses \- This field indicates the fused operations that the controller supports. +.SH SYNOPSIS +enum nvme_id_ctrl_fuses { +.br +.BI " NVME_CTRL_FUSES_COMPARE_AND_WRITE" + +}; +.SH Constants +.IP "NVME_CTRL_FUSES_COMPARE_AND_WRITE" 12 +If set, then the controller supports the +Compare and Write fused operation. diff --git a/doc/man/enum nvme_id_ctrl_hctm.2 b/doc/man/enum nvme_id_ctrl_hctm.2 new file mode 100644 index 00000000..0e2d3e6d --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_hctm.2 @@ -0,0 +1,15 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_hctm" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_hctm \- Flags indicate the attributes of the host controlled thermal management feature +.SH SYNOPSIS +enum nvme_id_ctrl_hctm { +.br +.BI " NVME_CTRL_HCTMA_HCTM" + +}; +.SH Constants +.IP "NVME_CTRL_HCTMA_HCTM" 12 +then the controller supports host controlled thermal +management, and the Set Features command and Get +Features command with the Feature Identifier field +set to NVME_FEAT_FID_HCTM. diff --git a/doc/man/enum nvme_id_ctrl_lpa.2 b/doc/man/enum nvme_id_ctrl_lpa.2 new file mode 100644 index 00000000..ada9b2b1 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_lpa.2 @@ -0,0 +1,36 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_lpa" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_lpa \- Flags indicating optional attributes for log pages that are accessed via the Get Log Page command. +.SH SYNOPSIS +enum nvme_id_ctrl_lpa { +.br +.BI " NVME_CTRL_LPA_SMART_PER_NS" +, +.br +.br +.BI " NVME_CTRL_LPA_CMD_EFFECTS" +, +.br +.br +.BI " NVME_CTRL_LPA_EXTENDED" +, +.br +.br +.BI " NVME_CTRL_LPA_TELEMETRY" +, +.br +.br +.BI " NVME_CTRL_LPA_PERSETENT_EVENT" + +}; +.SH Constants +.IP "NVME_CTRL_LPA_SMART_PER_NS" 12 +-- undescribed -- +.IP "NVME_CTRL_LPA_CMD_EFFECTS" 12 +-- undescribed -- +.IP "NVME_CTRL_LPA_EXTENDED" 12 +-- undescribed -- +.IP "NVME_CTRL_LPA_TELEMETRY" 12 +-- undescribed -- +.IP "NVME_CTRL_LPA_PERSETENT_EVENT" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_id_ctrl_mec.2 b/doc/man/enum nvme_id_ctrl_mec.2 new file mode 100644 index 00000000..d530757f --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_mec.2 @@ -0,0 +1,20 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_mec" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_mec \- Flags indicatings the capabilities of the Management Endpoint in the Controller, &struct nvme_id_ctrl.mec. +.SH SYNOPSIS +enum nvme_id_ctrl_mec { +.br +.BI " NVME_CTRL_MEC_SMBUSME" +, +.br +.br +.BI " NVME_CTRL_MEC_PCIEME" + +}; +.SH Constants +.IP "NVME_CTRL_MEC_SMBUSME" 12 +If set, then the NVM Subsystem contains a Management +Endpoint on an SMBus/I2C port. +.IP "NVME_CTRL_MEC_PCIEME" 12 +If set, then the NVM Subsystem contains a Management +Endpoint on a PCIe port. diff --git a/doc/man/enum nvme_id_ctrl_nvmsr.2 b/doc/man/enum nvme_id_ctrl_nvmsr.2 new file mode 100644 index 00000000..b8e1a216 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_nvmsr.2 @@ -0,0 +1,22 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_nvmsr" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_nvmsr \- This field reports information associated with the NVM Subsystem, see &struct nvme_id_ctrl.nvmsr. +.SH SYNOPSIS +enum nvme_id_ctrl_nvmsr { +.br +.BI " NVME_CTRL_NVMSR_NVMESD" +, +.br +.br +.BI " NVME_CTRL_NVMSR_NVMEE" + +}; +.SH Constants +.IP "NVME_CTRL_NVMSR_NVMESD" 12 +If set, then the NVM Subsystem is part of an NVMe +Storage Device; if cleared, then the NVM Subsystem +is not part of an NVMe Storage Device. +.IP "NVME_CTRL_NVMSR_NVMEE" 12 +If set’, then the NVM Subsystem is part of an NVMe +Enclosure; if cleared, then the NVM Subsystem is +not part of an NVMe Enclosure. diff --git a/doc/man/enum nvme_id_ctrl_nvscc.2 b/doc/man/enum nvme_id_ctrl_nvscc.2 new file mode 100644 index 00000000..2dc529b0 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_nvscc.2 @@ -0,0 +1,13 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_nvscc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_nvscc \- This field indicates the configuration settings for NVM Vendor Specific command handling. +.SH SYNOPSIS +enum nvme_id_ctrl_nvscc { +.br +.BI " NVME_CTRL_NVSCC_FMT" + +}; +.SH Constants +.IP "NVME_CTRL_NVSCC_FMT" 12 +If set, all NVM Vendor Specific Commands use the +format format with NDT and NDM fields. diff --git a/doc/man/enum nvme_id_ctrl_nwpc.2 b/doc/man/enum nvme_id_ctrl_nwpc.2 new file mode 100644 index 00000000..d7a82c55 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_nwpc.2 @@ -0,0 +1,35 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_nwpc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_nwpc \- This field indicates the optional namespace write protection capabilities supported by the controller. +.SH SYNOPSIS +enum nvme_id_ctrl_nwpc { +.br +.BI " NVME_CTRL_NWPC_WRITE_PROTECT" +, +.br +.br +.BI " NVME_CTRL_NWPC_WRITE_PROTECT_POWER_CYCLE" +, +.br +.br +.BI " NVME_CTRL_NWPC_WRITE_PROTECT_PERMANENT" + +}; +.SH Constants +.IP "NVME_CTRL_NWPC_WRITE_PROTECT" 12 +If set, then the controller shall +support the No Write Protect and +Write Protect namespace write +protection states and may support +the Write Protect Until Power +Cycle state and Permanent Write +Protect namespace write +protection states. +.IP "NVME_CTRL_NWPC_WRITE_PROTECT_POWER_CYCLE" 12 +If set, then the controller +supports the Write Protect Until +Power Cycle state. +.IP "NVME_CTRL_NWPC_WRITE_PROTECT_PERMANENT" 12 +If set, then the controller +supports the Permanent Write +Protect state. diff --git a/doc/man/enum nvme_id_ctrl_oacs.2 b/doc/man/enum nvme_id_ctrl_oacs.2 new file mode 100644 index 00000000..d70bb240 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_oacs.2 @@ -0,0 +1,77 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_oacs" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_oacs \- Flags indicating the optional Admin commands and features supported by the controller, see &struct nvme_id_ctrl.oacs. +.SH SYNOPSIS +enum nvme_id_ctrl_oacs { +.br +.BI " NVME_CTRL_OACS_SECURITY" +, +.br +.br +.BI " NVME_CTRL_OACS_FORMAT" +, +.br +.br +.BI " NVME_CTRL_OACS_FW" +, +.br +.br +.BI " NVME_CTRL_OACS_NS_MGMT" +, +.br +.br +.BI " NVME_CTRL_OACS_SELF_TEST" +, +.br +.br +.BI " NVME_CTRL_OACS_DIRECTIVES" +, +.br +.br +.BI " NVME_CTRL_OACS_NVME_MI" +, +.br +.br +.BI " NVME_CTRL_OACS_VIRT_MGMT" +, +.br +.br +.BI " NVME_CTRL_OACS_DBBUF_CFG" +, +.br +.br +.BI " NVME_CTRL_OACS_LBA_STATUS" + +}; +.SH Constants +.IP "NVME_CTRL_OACS_SECURITY" 12 +If set, then the controller supports the +Security Send and Security Receive commands. +.IP "NVME_CTRL_OACS_FORMAT" 12 +If set then the controller supports the Format +NVM command. +.IP "NVME_CTRL_OACS_FW" 12 +If set, then the controller supports the +Firmware Commit and Firmware Image Download commands. +.IP "NVME_CTRL_OACS_NS_MGMT" 12 +If set, then the controller supports the +Namespace Management capability +.IP "NVME_CTRL_OACS_SELF_TEST" 12 +If set, then the controller supports the Device +Self-test command. +.IP "NVME_CTRL_OACS_DIRECTIVES" 12 +If set, then the controller supports Directives +and the Directive Send and Directive Receive +commands. +.IP "NVME_CTRL_OACS_NVME_MI" 12 +If set, then the controller supports the NVMe-MI +Send and NVMe-MI Receive commands. +.IP "NVME_CTRL_OACS_VIRT_MGMT" 12 +If set, then the controller supports the +Virtualization Management command. +.IP "NVME_CTRL_OACS_DBBUF_CFG" 12 +If set, then the controller supports the +Doorbell Buffer Config command. +.IP "NVME_CTRL_OACS_LBA_STATUS" 12 +If set, then the controller supports the Get LBA +Status capability. diff --git a/doc/man/enum nvme_id_ctrl_oaes.2 b/doc/man/enum nvme_id_ctrl_oaes.2 new file mode 100644 index 00000000..82810cbd --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_oaes.2 @@ -0,0 +1,42 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_oaes" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_oaes \- The typical latency in microseconds to enter Runtime D3 +.SH SYNOPSIS +enum nvme_id_ctrl_oaes { +.br +.BI " NVME_CTRL_OAES_NA" +, +.br +.br +.BI " NVME_CTRL_OAES_FA" +, +.br +.br +.BI " NVME_CTRL_OAES_ANA" +, +.br +.br +.BI " NVME_CTRL_OAES_PLEA" +, +.br +.br +.BI " NVME_CTRL_OAES_LBAS" +, +.br +.br +.BI " NVME_CTRL_OAES_EGE" + +}; +.SH Constants +.IP "NVME_CTRL_OAES_NA" 12 +-- undescribed -- +.IP "NVME_CTRL_OAES_FA" 12 +-- undescribed -- +.IP "NVME_CTRL_OAES_ANA" 12 +-- undescribed -- +.IP "NVME_CTRL_OAES_PLEA" 12 +-- undescribed -- +.IP "NVME_CTRL_OAES_LBAS" 12 +: +.IP "NVME_CTRL_OAES_EGE" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_id_ctrl_ofcs.2 b/doc/man/enum nvme_id_ctrl_ofcs.2 new file mode 100644 index 00000000..a594dd2d --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_ofcs.2 @@ -0,0 +1,14 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_ofcs" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_ofcs \- Indicate whether the controller supports optional fabric commands. +.SH SYNOPSIS +enum nvme_id_ctrl_ofcs { +.br +.BI " NVME_CTRL_OFCS_DISCONNECT" + +}; +.SH Constants +.IP "NVME_CTRL_OFCS_DISCONNECT" 12 +If set, then the controller supports the +Disconnect command and deletion of individual +I/O Queues. diff --git a/doc/man/enum nvme_id_ctrl_oncs.2 b/doc/man/enum nvme_id_ctrl_oncs.2 new file mode 100644 index 00000000..ae82bb75 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_oncs.2 @@ -0,0 +1,65 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_oncs" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_oncs \- This field indicates the optional NVM commands and features supported by the controller. +.SH SYNOPSIS +enum nvme_id_ctrl_oncs { +.br +.BI " NVME_CTRL_ONCS_COMPARE" +, +.br +.br +.BI " NVME_CTRL_ONCS_WRITE_UNCORRECTABLE" +, +.br +.br +.BI " NVME_CTRL_ONCS_DSM" +, +.br +.br +.BI " NVME_CTRL_ONCS_WRITE_ZEROES" +, +.br +.br +.BI " NVME_CTRL_ONCS_SAVE_FEATURES" +, +.br +.br +.BI " NVME_CTRL_ONCS_RESERVATIONS" +, +.br +.br +.BI " NVME_CTRL_ONCS_TIMESTAMP" +, +.br +.br +.BI " NVME_CTRL_ONCS_VERIFY" + +}; +.SH Constants +.IP "NVME_CTRL_ONCS_COMPARE" 12 +If set, then the controller supports +the Compare command. +.IP "NVME_CTRL_ONCS_WRITE_UNCORRECTABLE" 12 +If set, then the controller supports +the Write Uncorrectable command. +.IP "NVME_CTRL_ONCS_DSM" 12 +If set, then the controller supports +the Dataset Management command. +.IP "NVME_CTRL_ONCS_WRITE_ZEROES" 12 +If set, then the controller supports +the Write Zeroes command. +.IP "NVME_CTRL_ONCS_SAVE_FEATURES" 12 +If set, then the controller supports +the Save field set to a non-zero value +in the Set Features command and the +Select field set to a non-zero value in +the Get Features command. +.IP "NVME_CTRL_ONCS_RESERVATIONS" 12 +If set, then the controller supports +reservations. +.IP "NVME_CTRL_ONCS_TIMESTAMP" 12 +If set, then the controller supports +the Timestamp feature. +.IP "NVME_CTRL_ONCS_VERIFY" 12 +If set, then the controller supports +the Verify command. diff --git a/doc/man/enum nvme_id_ctrl_rpmbs.2 b/doc/man/enum nvme_id_ctrl_rpmbs.2 new file mode 100644 index 00000000..36a1d3e1 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_rpmbs.2 @@ -0,0 +1,30 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_rpmbs" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_rpmbs \- This field indicates if the controller supports one or more Replay Protected Memory Blocks, from &struct nvme_id_ctrl.rpmbs. +.SH SYNOPSIS +enum nvme_id_ctrl_rpmbs { +.br +.BI " NVME_CTRL_RPMBS_NR_UNITS" +, +.br +.br +.BI " NVME_CTRL_RPMBS_AUTH_METHOD" +, +.br +.br +.BI " NVME_CTRL_RPMBS_TOTAL_SIZE" +, +.br +.br +.BI " NVME_CTRL_RPMBS_ACCESS_SIZE" + +}; +.SH Constants +.IP "NVME_CTRL_RPMBS_NR_UNITS" 12 +Mask to get the value of the Number of RPMB Units +.IP "NVME_CTRL_RPMBS_AUTH_METHOD" 12 +Mask to get the value of the Authentication Method +.IP "NVME_CTRL_RPMBS_TOTAL_SIZE" 12 +Mask to get the value of Total Size +.IP "NVME_CTRL_RPMBS_ACCESS_SIZE" 12 +Mask to get the value of Access Size diff --git a/doc/man/enum nvme_id_ctrl_sanicap.2 b/doc/man/enum nvme_id_ctrl_sanicap.2 new file mode 100644 index 00000000..e0b518cd --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_sanicap.2 @@ -0,0 +1,44 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_sanicap" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_sanicap \- Indicates attributes for sanitize operations. +.SH SYNOPSIS +enum nvme_id_ctrl_sanicap { +.br +.BI " NVME_CTRL_SANICAP_CES" +, +.br +.br +.BI " NVME_CTRL_SANICAP_BES" +, +.br +.br +.BI " NVME_CTRL_SANICAP_OWS" +, +.br +.br +.BI " NVME_CTRL_SANICAP_NDI" +, +.br +.br +.BI " NVME_CTRL_SANICAP_NODMMAS" + +}; +.SH Constants +.IP "NVME_CTRL_SANICAP_CES" 12 +Crypto Erase Support. If set, then the +controller supports the Crypto Erase sanitize operation. +.IP "NVME_CTRL_SANICAP_BES" 12 +Block Erase Support. If set, then the controller +supports the Block Erase sanitize operation. +.IP "NVME_CTRL_SANICAP_OWS" 12 +Overwrite Support. If set, then the controller +supports the Overwrite sanitize operation. +.IP "NVME_CTRL_SANICAP_NDI" 12 +No-Deallocate Inhibited. If set and the No- +Deallocate Response Mode bit is set, then the +controller deallocates after the sanitize +operation even if the No-Deallocate After +Sanitize bit is set in a Sanitize command. +.IP "NVME_CTRL_SANICAP_NODMMAS" 12 +No-Deallocate Modifies Media After Sanitize, +mask to extract value. diff --git a/doc/man/enum nvme_id_ctrl_sgls.2 b/doc/man/enum nvme_id_ctrl_sgls.2 new file mode 100644 index 00000000..4e860510 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_sgls.2 @@ -0,0 +1,54 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_sgls" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_sgls \- This field indicates if SGLs are supported for the NVM Command Set and the particular SGL types supported. +.SH SYNOPSIS +enum nvme_id_ctrl_sgls { +.br +.BI " NVME_CTRL_SGLS_SUPPORTED" +, +.br +.br +.BI " NVME_CTRL_SGLS_KEYED" +, +.br +.br +.BI " NVME_CTRL_SGLS_BIT_BUCKET" +, +.br +.br +.BI " NVME_CTRL_SGLS_MPTR_BYTE_ALIGNED" +, +.br +.br +.BI " NVME_CTRL_SGLS_OVERSIZE" +, +.br +.br +.BI " NVME_CTRL_SGLS_MPTR_SGL" +, +.br +.br +.BI " NVME_CTRL_SGLS_OFFSET" +, +.br +.br +.BI " NVME_CTRL_SGLS_TPORT" + +}; +.SH Constants +.IP "NVME_CTRL_SGLS_SUPPORTED" 12 +-- undescribed -- +.IP "NVME_CTRL_SGLS_KEYED" 12 +-- undescribed -- +.IP "NVME_CTRL_SGLS_BIT_BUCKET" 12 +-- undescribed -- +.IP "NVME_CTRL_SGLS_MPTR_BYTE_ALIGNED" 12 +-- undescribed -- +.IP "NVME_CTRL_SGLS_OVERSIZE" 12 +-- undescribed -- +.IP "NVME_CTRL_SGLS_MPTR_SGL" 12 +-- undescribed -- +.IP "NVME_CTRL_SGLS_OFFSET" 12 +-- undescribed -- +.IP "NVME_CTRL_SGLS_TPORT" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_id_ctrl_sqes.2 b/doc/man/enum nvme_id_ctrl_sqes.2 new file mode 100644 index 00000000..c5b25ca6 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_sqes.2 @@ -0,0 +1,20 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_sqes" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_sqes \- Defines the required and maximum Submission Queue entry size when using the NVM Command Set. +.SH SYNOPSIS +enum nvme_id_ctrl_sqes { +.br +.BI " NVME_CTRL_SQES_MIN" +, +.br +.br +.BI " NVME_CTRL_SQES_MAX" + +}; +.SH Constants +.IP "NVME_CTRL_SQES_MIN" 12 +Mask to get the value of the required Submission Queue +Entry size when using the NVM Command Set. +.IP "NVME_CTRL_SQES_MAX" 12 +Mask to get the value of the maximum Submission Queue +entry size when using the NVM Command Set. diff --git a/doc/man/enum nvme_id_ctrl_vwc.2 b/doc/man/enum nvme_id_ctrl_vwc.2 new file mode 100644 index 00000000..d2b6ac95 --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_vwc.2 @@ -0,0 +1,22 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_vwc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_vwc \- +.SH SYNOPSIS +enum nvme_id_ctrl_vwc { +.br +.BI " NVME_CTRL_VWC_PRESENT" +, +.br +.br +.BI " NVME_CTRL_VWC_FLUSH" + +}; +.SH Constants +.IP "NVME_CTRL_VWC_PRESENT" 12 +If set, indicates a volatile write cache is present. +If a volatile write cache is present, then the host +controls whether the volatile write cache is enabled +with a Set Features command specifying the value +NVME_FEAT_FID_VOLATILE_WC. +.IP "NVME_CTRL_VWC_FLUSH" 12 +Mask to get the value of the flush command behavior. diff --git a/doc/man/enum nvme_id_ctrl_vwci.2 b/doc/man/enum nvme_id_ctrl_vwci.2 new file mode 100644 index 00000000..0dbfef4d --- /dev/null +++ b/doc/man/enum nvme_id_ctrl_vwci.2 @@ -0,0 +1,28 @@ +.TH "libnvme" 2 "enum nvme_id_ctrl_vwci" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ctrl_vwci \- This field indicates information about remaining number of times that VPD contents are able to be updated using the VPD Write command, see &struct nvme_id_ctrl.vwci. +.SH SYNOPSIS +enum nvme_id_ctrl_vwci { +.br +.BI " NVME_CTRL_VWCI_VWCR" +, +.br +.br +.BI " NVME_CTRL_VWCI_VWCRV" + +}; +.SH Constants +.IP "NVME_CTRL_VWCI_VWCR" 12 +Mask to get value of VPD Write Cycles Remaining. If +the VPD Write Cycle Remaining Valid bit is set, then +this field contains a value indicating the remaining +number of times that VPD contents are able to be +updated using the VPD Write command. If this field is +set to 7Fh, then the remaining number of times that +VPD contents are able to be updated using the VPD +Write command is greater than or equal to 7Fh. +.IP "NVME_CTRL_VWCI_VWCRV" 12 +VPD Write Cycle Remaining Valid. If this bit is set, +then the VPD Write Cycle Remaining field is valid. If +this bit is cleared, then the VPD Write Cycles +Remaining field is invalid and cleared to 0h. diff --git a/doc/man/enum nvme_id_ns_attr.2 b/doc/man/enum nvme_id_ns_attr.2 new file mode 100644 index 00000000..ec634175 --- /dev/null +++ b/doc/man/enum nvme_id_ns_attr.2 @@ -0,0 +1,14 @@ +.TH "libnvme" 2 "enum nvme_id_ns_attr" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ns_attr \- Specifies attributes of the namespace. +.SH SYNOPSIS +enum nvme_id_ns_attr { +.br +.BI " NVME_NS_NSATTR_WRITE_PROTECTED" + +}; +.SH Constants +.IP "NVME_NS_NSATTR_WRITE_PROTECTED" 12 +If set, then the namespace is currently +write protected and all write access to the +namespace shall fail. diff --git a/doc/man/enum nvme_id_ns_dlfeat.2 b/doc/man/enum nvme_id_ns_dlfeat.2 new file mode 100644 index 00000000..b55d45c4 --- /dev/null +++ b/doc/man/enum nvme_id_ns_dlfeat.2 @@ -0,0 +1,50 @@ +.TH "libnvme" 2 "enum nvme_id_ns_dlfeat" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ns_dlfeat \- This field indicates information about features that affect deallocating logical blocks for this namespace. +.SH SYNOPSIS +enum nvme_id_ns_dlfeat { +.br +.BI " NVME_NS_DLFEAT_RB" +, +.br +.br +.BI " NVME_NS_DLFEAT_RB_NR" +, +.br +.br +.BI " NVME_NS_DLFEAT_RB_ALL_0S" +, +.br +.br +.BI " NVME_NS_DLFEAT_RB_ALL_FS" +, +.br +.br +.BI " NVME_NS_DLFEAT_WRITE_ZEROES" +, +.br +.br +.BI " NVME_NS_DLFEAT_CRC_GUARD" + +}; +.SH Constants +.IP "NVME_NS_DLFEAT_RB" 12 +Mask to get the value of the read behavior +.IP "NVME_NS_DLFEAT_RB_NR" 12 +Read behvaior is not reported +.IP "NVME_NS_DLFEAT_RB_ALL_0S" 12 +A deallocated logical block returns all bytes +cleared to 0h. +.IP "NVME_NS_DLFEAT_RB_ALL_FS" 12 +A deallocated logical block returns all bytes +set to FFh. +.IP "NVME_NS_DLFEAT_WRITE_ZEROES" 12 +If set, indicates that the controller supports +the Deallocate bit in the Write Zeroes command +for this namespace. +.IP "NVME_NS_DLFEAT_CRC_GUARD" 12 +If set, indicates that the Guard field for +deallocated logical blocks that contain +protection information is set to the CRC for +the value read from the deallocated logical +block and its metadata diff --git a/doc/man/enum nvme_id_ns_dpc.2 b/doc/man/enum nvme_id_ns_dpc.2 new file mode 100644 index 00000000..358b8b15 --- /dev/null +++ b/doc/man/enum nvme_id_ns_dpc.2 @@ -0,0 +1,43 @@ +.TH "libnvme" 2 "enum nvme_id_ns_dpc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ns_dpc \- This field indicates the capabilities for the end-to-end data protection feature. +.SH SYNOPSIS +enum nvme_id_ns_dpc { +.br +.BI " NVME_NS_DPC_PI_TYPE1" +, +.br +.br +.BI " NVME_NS_DPC_PI_TYPE2" +, +.br +.br +.BI " NVME_NS_DPC_PI_TYPE3" +, +.br +.br +.BI " NVME_NS_DPC_PI_FIRST" +, +.br +.br +.BI " NVME_NS_DPC_PI_LAST" + +}; +.SH Constants +.IP "NVME_NS_DPC_PI_TYPE1" 12 +If set, indicates that the namespace supports +Protection Information Type 1. +.IP "NVME_NS_DPC_PI_TYPE2" 12 +If set, indicates that the namespace supports +Protection Information Type 2. +.IP "NVME_NS_DPC_PI_TYPE3" 12 +If set, indicates that the namespace supports +Protection Information Type 3. +.IP "NVME_NS_DPC_PI_FIRST" 12 +If set, indicates that the namespace supports +protection information transferred as the first eight +bytes of metadata. +.IP "NVME_NS_DPC_PI_LAST" 12 +If set, indicates that the namespace supports +protection information transferred as the last eight +bytes of metadata. diff --git a/doc/man/enum nvme_id_ns_dps.2 b/doc/man/enum nvme_id_ns_dps.2 new file mode 100644 index 00000000..93d51bb4 --- /dev/null +++ b/doc/man/enum nvme_id_ns_dps.2 @@ -0,0 +1,44 @@ +.TH "libnvme" 2 "enum nvme_id_ns_dps" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ns_dps \- This field indicates the Type settings for the end-to-end data protection feature. +.SH SYNOPSIS +enum nvme_id_ns_dps { +.br +.BI " NVME_NS_DPS_PI_NONE" +, +.br +.br +.BI " NVME_NS_DPS_PI_TYPE1" +, +.br +.br +.BI " NVME_NS_DPS_PI_TYPE2" +, +.br +.br +.BI " NVME_NS_DPS_PI_TYPE3" +, +.br +.br +.BI " NVME_NS_DPS_PI_MASK" +, +.br +.br +.BI " NVME_NS_DPS_PI_FIRST" + +}; +.SH Constants +.IP "NVME_NS_DPS_PI_NONE" 12 +Protection information is not enabled +.IP "NVME_NS_DPS_PI_TYPE1" 12 +Protection information is enabled, Type 1 +.IP "NVME_NS_DPS_PI_TYPE2" 12 +Protection information is enabled, Type 2 +.IP "NVME_NS_DPS_PI_TYPE3" 12 +Protection information is enabled, Type 3 +.IP "NVME_NS_DPS_PI_MASK" 12 +Mask to get the value of the PI type +.IP "NVME_NS_DPS_PI_FIRST" 12 +If set, indicates that the protection information, if +enabled, is transferred as the first eight bytes of +metadata. diff --git a/doc/man/enum nvme_id_ns_flbas.2 b/doc/man/enum nvme_id_ns_flbas.2 new file mode 100644 index 00000000..080d2ee2 --- /dev/null +++ b/doc/man/enum nvme_id_ns_flbas.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_id_ns_flbas" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ns_flbas \- This field indicates the LBA data size & metadata size combination that the namespace has been formatted with +.SH SYNOPSIS +enum nvme_id_ns_flbas { +.br +.BI " NVME_NS_FLBAS_LBA_MASK" +, +.br +.br +.BI " NVME_NS_FLBAS_META_EXT" + +}; +.SH Constants +.IP "NVME_NS_FLBAS_LBA_MASK" 12 +Mask to get the index of one of the 16 supported +LBA Formats indicated in \fIstruct nvme_id_ns\fP.lbaf. +.IP "NVME_NS_FLBAS_META_EXT" 12 +Applicable only if format contains metadata. If +this bit is set, indicates that the metadata is +transferred at the end of the data LBA, creating an +extended data LBA. If cleared, indicates that all +of the metadata for a command is transferred as a +separate contiguous buffer of data. diff --git a/doc/man/enum nvme_id_ns_mc.2 b/doc/man/enum nvme_id_ns_mc.2 new file mode 100644 index 00000000..801f280c --- /dev/null +++ b/doc/man/enum nvme_id_ns_mc.2 @@ -0,0 +1,21 @@ +.TH "libnvme" 2 "enum nvme_id_ns_mc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ns_mc \- This field indicates the capabilities for metadata. +.SH SYNOPSIS +enum nvme_id_ns_mc { +.br +.BI " NVME_NS_MC_EXTENDED" +, +.br +.br +.BI " NVME_NS_MC_SEPARATE" + +}; +.SH Constants +.IP "NVME_NS_MC_EXTENDED" 12 +If set, indicates the namespace supports the metadata +being transferred as part of a separate buffer that is +specified in the Metadata Pointer. +.IP "NVME_NS_MC_SEPARATE" 12 +If set, indicates that the namespace supports the +metadata being transferred as part of an extended data LBA. diff --git a/doc/man/enum nvme_id_ns_nmic.2 b/doc/man/enum nvme_id_ns_nmic.2 new file mode 100644 index 00000000..030e3af0 --- /dev/null +++ b/doc/man/enum nvme_id_ns_nmic.2 @@ -0,0 +1,13 @@ +.TH "libnvme" 2 "enum nvme_id_ns_nmic" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ns_nmic \- This field specifies multi-path I/O and namespace sharing capabilities of the namespace. +.SH SYNOPSIS +enum nvme_id_ns_nmic { +.br +.BI " NVME_NS_NMIC_SHARED" + +}; +.SH Constants +.IP "NVME_NS_NMIC_SHARED" 12 +If set, then the namespace may be attached to two or +more controllers in the NVM subsystem concurrently diff --git a/doc/man/enum nvme_id_ns_rescap.2 b/doc/man/enum nvme_id_ns_rescap.2 new file mode 100644 index 00000000..162cef47 --- /dev/null +++ b/doc/man/enum nvme_id_ns_rescap.2 @@ -0,0 +1,62 @@ +.TH "libnvme" 2 "enum nvme_id_ns_rescap" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_ns_rescap \- This field indicates the reservation capabilities of the namespace. +.SH SYNOPSIS +enum nvme_id_ns_rescap { +.br +.BI " NVME_NS_RESCAP_PTPL" +, +.br +.br +.BI " NVME_NS_RESCAP_WE" +, +.br +.br +.BI " NVME_NS_RESCAP_EA" +, +.br +.br +.BI " NVME_NS_RESCAP_WERO" +, +.br +.br +.BI " NVME_NS_RESCAP_EARO" +, +.br +.br +.BI " NVME_NS_RESCAP_WEAR" +, +.br +.br +.BI " NVME_NS_RESCAP_EAAR" +, +.br +.br +.BI " NVME_NS_RESCAP_IEK_13" + +}; +.SH Constants +.IP "NVME_NS_RESCAP_PTPL" 12 +If set, indicates that the namespace supports the +Persist Through Power Loss capability. +.IP "NVME_NS_RESCAP_WE" 12 +If set, indicates that the namespace supports the +Write Exclusive reservation type. +.IP "NVME_NS_RESCAP_EA" 12 +If set, indicates that the namespace supports the +Exclusive Access reservation type. +.IP "NVME_NS_RESCAP_WERO" 12 +If set, indicates that the namespace supports the +Write Exclusive - Registrants Only reservation type. +.IP "NVME_NS_RESCAP_EARO" 12 +If set, indicates that the namespace supports the +Exclusive Access - Registrants Only reservation type. +.IP "NVME_NS_RESCAP_WEAR" 12 +If set, indicates that the namespace supports the +Write Exclusive - All Registrants reservation type. +.IP "NVME_NS_RESCAP_EAAR" 12 +If set, indicates that the namespace supports the +Exclusive Access - All Registrants reservation type. +.IP "NVME_NS_RESCAP_IEK_13" 12 +If set, indicates that Ignore Existing Key is used +as defined in revision 1.3 or later of this specification. diff --git a/doc/man/enum nvme_id_nsfeat.2 b/doc/man/enum nvme_id_nsfeat.2 new file mode 100644 index 00000000..f97d6901 --- /dev/null +++ b/doc/man/enum nvme_id_nsfeat.2 @@ -0,0 +1,51 @@ +.TH "libnvme" 2 "enum nvme_id_nsfeat" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_id_nsfeat \- This field defines features of the namespace. +.SH SYNOPSIS +enum nvme_id_nsfeat { +.br +.BI " NVME_NS_FEAT_THIN" +, +.br +.br +.BI " NVME_NS_FEAT_NATOMIC" +, +.br +.br +.BI " NVME_NS_FEAT_DULBE" +, +.br +.br +.BI " NVME_NS_FEAT_ID_REUSE" +, +.br +.br +.BI " NVME_NS_FEAT_IO_OPT" + +}; +.SH Constants +.IP "NVME_NS_FEAT_THIN" 12 +If set, indicates that the namespace supports thin +provisioning. Specifically, the Namespace Capacity +reported may be less than the Namespace Size. +.IP "NVME_NS_FEAT_NATOMIC" 12 +If set, indicates that the fields NAWUN, NAWUPF, and +NACWU are defined for this namespace and should be +used by the host for this namespace instead of the +AWUN, AWUPF, and ACWU fields in the Identify +Controller data structure. +.IP "NVME_NS_FEAT_DULBE" 12 +If set, indicates that the controller supports the +Deallocated or Unwritten Logical Block error for +this namespace. \fINVME_NS_FEAT_ID_REUSE\fP: If set, +indicates that the value in the NGUID field for this +namespace, if non- zero, is never reused by the +controller and that the value in the EUI64 field for +this namespace, if non-zero, is never reused by the +controller. +.IP "NVME_NS_FEAT_ID_REUSE" 12 +-- undescribed -- +.IP "NVME_NS_FEAT_IO_OPT" 12 +If set, indicates that the fields NPWG, NPWA, NPDG, +NPDA, and NOWS are defined for this namespace and +should be used by the host for I/O optimization diff --git a/doc/man/enum nvme_identify_cns.2 b/doc/man/enum nvme_identify_cns.2 new file mode 100644 index 00000000..9588548d --- /dev/null +++ b/doc/man/enum nvme_identify_cns.2 @@ -0,0 +1,84 @@ +.TH "libnvme" 2 "enum nvme_identify_cns" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_identify_cns \- +.SH SYNOPSIS +enum nvme_identify_cns { +.br +.BI " NVME_IDENTIFY_CNS_NS" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_CTRL" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_NS_ACTIVE_LIST" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_NS_DESC_LIST" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_NVMSET_LIST" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_ALLOCATED_NS_LIST" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_ALLOCATED_NS" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_NS_CTRL_LIST" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_CTRL_LIST" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_PRIMARY_CTRL_CAP" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_SECONDARY_CTRL_LIST" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_NS_GRANULARITY" +, +.br +.br +.BI " NVME_IDENTIFY_CNS_UUID_LIST" + +}; +.SH Constants +.IP "NVME_IDENTIFY_CNS_NS" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_CTRL" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_NS_ACTIVE_LIST" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_NS_DESC_LIST" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_NVMSET_LIST" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_ALLOCATED_NS_LIST" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_ALLOCATED_NS" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_NS_CTRL_LIST" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_CTRL_LIST" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_PRIMARY_CTRL_CAP" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_SECONDARY_CTRL_LIST" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_NS_GRANULARITY" 12 +-- undescribed -- +.IP "NVME_IDENTIFY_CNS_UUID_LIST" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_io_control_flags.2 b/doc/man/enum nvme_io_control_flags.2 new file mode 100644 index 00000000..8390b059 --- /dev/null +++ b/doc/man/enum nvme_io_control_flags.2 @@ -0,0 +1,54 @@ +.TH "libnvme" 2 "enum nvme_io_control_flags" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_io_control_flags \- +.SH SYNOPSIS +enum nvme_io_control_flags { +.br +.BI " NVME_IO_DTYPE_STREAMS" +, +.br +.br +.BI " NVME_IO_DEAC" +, +.br +.br +.BI " NVME_IO_PRINFO_PRCHK_REF" +, +.br +.br +.BI " NVME_IO_PRINFO_PRCHK_APP" +, +.br +.br +.BI " NVME_IO_PRINFO_PRCHK_GUARD" +, +.br +.br +.BI " NVME_IO_PRINFO_PRACT" +, +.br +.br +.BI " NVME_IO_FUA" +, +.br +.br +.BI " NVME_IO_LR" + +}; +.SH Constants +.IP "NVME_IO_DTYPE_STREAMS" 12 +-- undescribed -- +.IP "NVME_IO_DEAC" 12 +-- undescribed -- +.IP "NVME_IO_PRINFO_PRCHK_REF" 12 +-- undescribed -- +.IP "NVME_IO_PRINFO_PRCHK_APP" 12 +-- undescribed -- +.IP "NVME_IO_PRINFO_PRCHK_GUARD" 12 +-- undescribed -- +.IP "NVME_IO_PRINFO_PRACT" 12 +-- undescribed -- +.IP "NVME_IO_FUA" 12 +-- undescribed -- +.IP "NVME_IO_LR" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_io_dsm_flags.2 b/doc/man/enum nvme_io_dsm_flags.2 new file mode 100644 index 00000000..76e5f210 --- /dev/null +++ b/doc/man/enum nvme_io_dsm_flags.2 @@ -0,0 +1,96 @@ +.TH "libnvme" 2 "enum nvme_io_dsm_flags" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_io_dsm_flags \- +.SH SYNOPSIS +enum nvme_io_dsm_flags { +.br +.BI " NVME_IO_DSM_FREQ_UNSPEC" +, +.br +.br +.BI " NVME_IO_DSM_FREQ_TYPICAL" +, +.br +.br +.BI " NVME_IO_DSM_FREQ_RARE" +, +.br +.br +.BI " NVME_IO_DSM_FREQ_READS" +, +.br +.br +.BI " NVME_IO_DSM_FREQ_WRITES" +, +.br +.br +.BI " NVME_IO_DSM_FREQ_RW" +, +.br +.br +.BI " NVME_IO_DSM_FREQ_ONCE" +, +.br +.br +.BI " NVME_IO_DSM_FREQ_PREFETCH" +, +.br +.br +.BI " NVME_IO_DSM_FREQ_TEMP" +, +.br +.br +.BI " NVME_IO_DSM_LATENCY_NONE" +, +.br +.br +.BI " NVME_IO_DSM_LATENCY_IDLE" +, +.br +.br +.BI " NVME_IO_DSM_LATENCY_NORM" +, +.br +.br +.BI " NVME_IO_DSM_LATENCY_LOW" +, +.br +.br +.BI " NVME_IO_DSM_SEQ_REQ" +, +.br +.br +.BI " NVME_IO_DSM_COMPRESSED" + +}; +.SH Constants +.IP "NVME_IO_DSM_FREQ_UNSPEC" 12 +-- undescribed -- +.IP "NVME_IO_DSM_FREQ_TYPICAL" 12 +-- undescribed -- +.IP "NVME_IO_DSM_FREQ_RARE" 12 +-- undescribed -- +.IP "NVME_IO_DSM_FREQ_READS" 12 +-- undescribed -- +.IP "NVME_IO_DSM_FREQ_WRITES" 12 +-- undescribed -- +.IP "NVME_IO_DSM_FREQ_RW" 12 +-- undescribed -- +.IP "NVME_IO_DSM_FREQ_ONCE" 12 +-- undescribed -- +.IP "NVME_IO_DSM_FREQ_PREFETCH" 12 +-- undescribed -- +.IP "NVME_IO_DSM_FREQ_TEMP" 12 +-- undescribed -- +.IP "NVME_IO_DSM_LATENCY_NONE" 12 +-- undescribed -- +.IP "NVME_IO_DSM_LATENCY_IDLE" 12 +-- undescribed -- +.IP "NVME_IO_DSM_LATENCY_NORM" 12 +-- undescribed -- +.IP "NVME_IO_DSM_LATENCY_LOW" 12 +-- undescribed -- +.IP "NVME_IO_DSM_SEQ_REQ" 12 +-- undescribed -- +.IP "NVME_IO_DSM_COMPRESSED" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_io_opcode.2 b/doc/man/enum nvme_io_opcode.2 new file mode 100644 index 00000000..64ee88e6 --- /dev/null +++ b/doc/man/enum nvme_io_opcode.2 @@ -0,0 +1,78 @@ +.TH "libnvme" 2 "enum nvme_io_opcode" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_io_opcode \- +.SH SYNOPSIS +enum nvme_io_opcode { +.br +.BI " nvme_cmd_flush" +, +.br +.br +.BI " nvme_cmd_write" +, +.br +.br +.BI " nvme_cmd_read" +, +.br +.br +.BI " nvme_cmd_write_uncor" +, +.br +.br +.BI " nvme_cmd_compare" +, +.br +.br +.BI " nvme_cmd_write_zeroes" +, +.br +.br +.BI " nvme_cmd_dsm" +, +.br +.br +.BI " nvme_cmd_verify" +, +.br +.br +.BI " nvme_cmd_resv_register" +, +.br +.br +.BI " nvme_cmd_resv_report" +, +.br +.br +.BI " nvme_cmd_resv_acquire" +, +.br +.br +.BI " nvme_cmd_resv_release" + +}; +.SH Constants +.IP "nvme_cmd_flush" 12 +-- undescribed -- +.IP "nvme_cmd_write" 12 +-- undescribed -- +.IP "nvme_cmd_read" 12 +-- undescribed -- +.IP "nvme_cmd_write_uncor" 12 +-- undescribed -- +.IP "nvme_cmd_compare" 12 +-- undescribed -- +.IP "nvme_cmd_write_zeroes" 12 +-- undescribed -- +.IP "nvme_cmd_dsm" 12 +-- undescribed -- +.IP "nvme_cmd_verify" 12 +-- undescribed -- +.IP "nvme_cmd_resv_register" 12 +-- undescribed -- +.IP "nvme_cmd_resv_report" 12 +-- undescribed -- +.IP "nvme_cmd_resv_acquire" 12 +-- undescribed -- +.IP "nvme_cmd_resv_release" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_lba_status_atype.2 b/doc/man/enum nvme_lba_status_atype.2 new file mode 100644 index 00000000..511fc5cc --- /dev/null +++ b/doc/man/enum nvme_lba_status_atype.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_lba_status_atype" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_lba_status_atype \- +.SH SYNOPSIS +enum nvme_lba_status_atype { +.br +.BI " NVME_LBA_STATUS_ATYPE_SCAN_UNTRACKED" +, +.br +.br +.BI " NVME_LBA_STATUS_ATYPE_SCAN_TRACKED" + +}; +.SH Constants +.IP "NVME_LBA_STATUS_ATYPE_SCAN_UNTRACKED" 12 +-- undescribed -- +.IP "NVME_LBA_STATUS_ATYPE_SCAN_TRACKED" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_lbaf_rp.2 b/doc/man/enum nvme_lbaf_rp.2 new file mode 100644 index 00000000..537e7444 --- /dev/null +++ b/doc/man/enum nvme_lbaf_rp.2 @@ -0,0 +1,37 @@ +.TH "libnvme" 2 "enum nvme_lbaf_rp" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_lbaf_rp \- This field indicates the relative performance of the LBA format indicated relative to other LBA formats supported by the controller. +.SH SYNOPSIS +enum nvme_lbaf_rp { +.br +.BI " NVME_LBAF_RP_BEST" +, +.br +.br +.BI " NVME_LBAF_RP_BETTER" +, +.br +.br +.BI " NVME_LBAF_RP_GOOD" +, +.br +.br +.BI " NVME_LBAF_RP_DEGRADED" +, +.br +.br +.BI " NVME_LBAF_RP_MASK" + +}; +.SH Constants +.IP "NVME_LBAF_RP_BEST" 12 +Best performance +.IP "NVME_LBAF_RP_BETTER" 12 +Better performance +.IP "NVME_LBAF_RP_GOOD" 12 +Good performance +.IP "NVME_LBAF_RP_DEGRADED" 12 +Degraded performance +.IP "NVME_LBAF_RP_MASK" 12 +Mask to get the relative performance value from the +field diff --git a/doc/man/enum nvme_nd_ns_fpi.2 b/doc/man/enum nvme_nd_ns_fpi.2 new file mode 100644 index 00000000..23460f7d --- /dev/null +++ b/doc/man/enum nvme_nd_ns_fpi.2 @@ -0,0 +1,19 @@ +.TH "libnvme" 2 "enum nvme_nd_ns_fpi" "February 2020" "LIBNVME API Manual" LINUX +.SH 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. +.SH SYNOPSIS +enum nvme_nd_ns_fpi { +.br +.BI " NVME_NS_FPI_REMAINING" +, +.br +.br +.BI " NVME_NS_FPI_SUPPORTED" + +}; +.SH Constants +.IP "NVME_NS_FPI_REMAINING" 12 +Mask to get the format percent remaining value +.IP "NVME_NS_FPI_SUPPORTED" 12 +If set, indicates that the namespace supports the +Format Progress Indicator defined for the field. diff --git a/doc/man/enum nvme_ns_attach_sel.2 b/doc/man/enum nvme_ns_attach_sel.2 new file mode 100644 index 00000000..7d3c0dcf --- /dev/null +++ b/doc/man/enum nvme_ns_attach_sel.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_ns_attach_sel" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_ns_attach_sel \- NVME_NS_ATTACH_SEL_CTRL_ATTACH: NVME_NP_ATTACH_SEL_CTRL_DEATTACH: +.SH SYNOPSIS +enum nvme_ns_attach_sel { +.br +.BI " NVME_NS_ATTACH_SEL_CTRL_ATTACH" +, +.br +.br +.BI " NVME_NS_ATTACH_SEL_CTRL_DEATTACH" + +}; +.SH Constants +.IP "NVME_NS_ATTACH_SEL_CTRL_ATTACH" 12 +-- undescribed -- +.IP "NVME_NS_ATTACH_SEL_CTRL_DEATTACH" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_ns_id_desc_nidt.2 b/doc/man/enum nvme_ns_id_desc_nidt.2 new file mode 100644 index 00000000..6e028e16 --- /dev/null +++ b/doc/man/enum nvme_ns_id_desc_nidt.2 @@ -0,0 +1,27 @@ +.TH "libnvme" 2 "enum nvme_ns_id_desc_nidt" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_ns_id_desc_nidt \- Known namespace identifier types +.SH SYNOPSIS +enum nvme_ns_id_desc_nidt { +.br +.BI " NVME_NIDT_EUI64" +, +.br +.br +.BI " NVME_NIDT_NGUID" +, +.br +.br +.BI " NVME_NIDT_UUID" + +}; +.SH Constants +.IP "NVME_NIDT_EUI64" 12 +IEEE Extended Unique Identifier, the NID field contains a +copy of the EUI64 field in the struct nvme_id_ns.eui64. +.IP "NVME_NIDT_NGUID" 12 +Namespace Globally Unique Identifier, the NID field +contains a copy of the NGUID field in struct nvme_id_ns.nguid. +.IP "NVME_NIDT_UUID" 12 +The NID field contains a 128-bit Universally Unique +Identifier (UUID) as specified in RFC 4122. diff --git a/doc/man/enum nvme_ns_mgmt_sel.2 b/doc/man/enum nvme_ns_mgmt_sel.2 new file mode 100644 index 00000000..4132c895 --- /dev/null +++ b/doc/man/enum nvme_ns_mgmt_sel.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_ns_mgmt_sel" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_ns_mgmt_sel \- +.SH SYNOPSIS +enum nvme_ns_mgmt_sel { +.br +.BI " NVME_NS_MGMT_SEL_CREATE" +, +.br +.br +.BI " NVME_NS_MGMT_SEL_DELETE" + +}; +.SH Constants +.IP "NVME_NS_MGMT_SEL_CREATE" 12 +-- undescribed -- +.IP "NVME_NS_MGMT_SEL_DELETE" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_psd_flags.2 b/doc/man/enum nvme_psd_flags.2 new file mode 100644 index 00000000..1b4e7435 --- /dev/null +++ b/doc/man/enum nvme_psd_flags.2 @@ -0,0 +1,26 @@ +.TH "libnvme" 2 "enum nvme_psd_flags" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_psd_flags \- Possible flag values in nvme power state descriptor +.SH SYNOPSIS +enum nvme_psd_flags { +.br +.BI " NVME_PSD_FLAGS_MXPS" +, +.br +.br +.BI " NVME_PSD_FLAGS_NOPS" + +}; +.SH Constants +.IP "NVME_PSD_FLAGS_MXPS" 12 +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. +.IP "NVME_PSD_FLAGS_NOPS" 12 +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. diff --git a/doc/man/enum nvme_psd_ps.2 b/doc/man/enum nvme_psd_ps.2 new file mode 100644 index 00000000..76499227 --- /dev/null +++ b/doc/man/enum nvme_psd_ps.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_psd_ps" "February 2020" "LIBNVME API Manual" LINUX +.SH 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. NVME_PSD_IPS_100_MICRO_WATT: 0.0001 watt scale NVME_PSD_IPS_10_MILLI_WATT: 0.01 watt scale +.SH SYNOPSIS +enum nvme_psd_ps { +.br +.BI " NVME_PSD_PS_100_MICRO_WATT" +, +.br +.br +.BI " NVME_PSD_PS_10_MILLI_WATT" + +}; +.SH Constants +.IP "NVME_PSD_PS_100_MICRO_WATT" 12 +-- undescribed -- +.IP "NVME_PSD_PS_10_MILLI_WATT" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_psd_workload.2 b/doc/man/enum nvme_psd_workload.2 new file mode 100644 index 00000000..b370397f --- /dev/null +++ b/doc/man/enum nvme_psd_workload.2 @@ -0,0 +1,29 @@ +.TH "libnvme" 2 "enum nvme_psd_workload" "February 2020" "LIBNVME API Manual" LINUX +.SH 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. +.SH SYNOPSIS +enum nvme_psd_workload { +.br +.BI " NVME_PSD_WORKLOAD_1" +, +.br +.br +.BI " NVME_PSD_WORKLOAD_2" + +}; +.SH Constants +.IP "NVME_PSD_WORKLOAD_1" 12 +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. +.IP "NVME_PSD_WORKLOAD_2" 12 +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. diff --git a/doc/man/enum nvme_registers.2 b/doc/man/enum nvme_registers.2 new file mode 100644 index 00000000..8fb1776a --- /dev/null +++ b/doc/man/enum nvme_registers.2 @@ -0,0 +1,150 @@ +.TH "libnvme" 2 "enum nvme_registers" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_registers \- The nvme controller registers for all transports. This is the layout of BAR0/1 for PCIe, and properties for fabrics. +.SH SYNOPSIS +enum nvme_registers { +.br +.BI " NVME_REG_CAP" +, +.br +.br +.BI " NVME_REG_VS" +, +.br +.br +.BI " NVME_REG_INTMS" +, +.br +.br +.BI " NVME_REG_INTMC" +, +.br +.br +.BI " NVME_REG_CC" +, +.br +.br +.BI " NVME_REG_CSTS" +, +.br +.br +.BI " NVME_REG_NSSR" +, +.br +.br +.BI " NVME_REG_AQA" +, +.br +.br +.BI " NVME_REG_ASQ" +, +.br +.br +.BI " NVME_REG_ACQ" +, +.br +.br +.BI " NVME_REG_CMBLOC" +, +.br +.br +.BI " NVME_REG_CMBSZ" +, +.br +.br +.BI " NVME_REG_BPINFO" +, +.br +.br +.BI " NVME_REG_BPRSEL" +, +.br +.br +.BI " NVME_REG_BPMBL" +, +.br +.br +.BI " NVME_REG_CMBMSC" +, +.br +.br +.BI " NVME_REG_CMBSTS" +, +.br +.br +.BI " NVME_REG_PMRCAP" +, +.br +.br +.BI " NVME_REG_PMRCTL" +, +.br +.br +.BI " NVME_REG_PMRSTS" +, +.br +.br +.BI " NVME_REG_PMREBS" +, +.br +.br +.BI " NVME_REG_PMRSWTP" +, +.br +.br +.BI " NVME_REG_PMRMSC" +, +.br +.br +.BI " NVME_REG_DBS" + +}; +.SH Constants +.IP "NVME_REG_CAP" 12 +Controller Capabilities +.IP "NVME_REG_VS" 12 +Version +.IP "NVME_REG_INTMS" 12 +Interrupt Mask Set +.IP "NVME_REG_INTMC" 12 +Interrupt Mask Clear +.IP "NVME_REG_CC" 12 +Controller Configuration +.IP "NVME_REG_CSTS" 12 +Controller Status +.IP "NVME_REG_NSSR" 12 +NVM Subsystem Reset +.IP "NVME_REG_AQA" 12 +Admin Queue Attributes +.IP "NVME_REG_ASQ" 12 +Admin SQ Base Address +.IP "NVME_REG_ACQ" 12 +Admin CQ Base Address +.IP "NVME_REG_CMBLOC" 12 +Controller Memory Buffer Location +.IP "NVME_REG_CMBSZ" 12 +Controller Memory Buffer Size +.IP "NVME_REG_BPINFO" 12 +Boot Partition Information +.IP "NVME_REG_BPRSEL" 12 +Boot Partition Read Select +.IP "NVME_REG_BPMBL" 12 +Boot Partition Memory Buffer Location +.IP "NVME_REG_CMBMSC" 12 +Controller Memory Buffer Memory Space Control +.IP "NVME_REG_CMBSTS" 12 +Controller Memory Buffer Status +.IP "NVME_REG_PMRCAP" 12 +Persistent Memory Capabilities +.IP "NVME_REG_PMRCTL" 12 +Persistent Memory Region Control +.IP "NVME_REG_PMRSTS" 12 +Persistent Memory Region Status +.IP "NVME_REG_PMREBS" 12 +Persistent Memory Region Elasticity Buffer Size +.IP "NVME_REG_PMRSWTP" 12 +Memory Region Sustained Write Throughput +.IP "NVME_REG_PMRMSC" 12 +Persistent Memory Region Controller Memory Space Control +.IP "NVME_REG_DBS" 12 +SQ 0 Tail Doorbell diff --git a/doc/man/enum nvme_reservation_cptpl.2 b/doc/man/enum nvme_reservation_cptpl.2 new file mode 100644 index 00000000..7033a176 --- /dev/null +++ b/doc/man/enum nvme_reservation_cptpl.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_reservation_cptpl" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_reservation_cptpl \- +.SH SYNOPSIS +enum nvme_reservation_cptpl { +.br +.BI " NVME_RESERVATION_CPTPL_NO_CHANGE" +, +.br +.br +.BI " NVME_RESERVATION_CPTPL_CLEAR" +, +.br +.br +.BI " NVME_RESERVATION_CPTPL_PERSIST" + +}; +.SH Constants +.IP "NVME_RESERVATION_CPTPL_NO_CHANGE" 12 +-- undescribed -- +.IP "NVME_RESERVATION_CPTPL_CLEAR" 12 +-- undescribed -- +.IP "NVME_RESERVATION_CPTPL_PERSIST" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_reservation_racqa.2 b/doc/man/enum nvme_reservation_racqa.2 new file mode 100644 index 00000000..89168c2f --- /dev/null +++ b/doc/man/enum nvme_reservation_racqa.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_reservation_racqa" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_reservation_racqa \- +.SH SYNOPSIS +enum nvme_reservation_racqa { +.br +.BI " NVME_RESERVATION_RACQA_ACQUIRE" +, +.br +.br +.BI " NVME_RESERVATION_RACQA_PREEMPT" +, +.br +.br +.BI " NVME_RESERVATION_RACQA_PREEMPT_AND_ABORT" + +}; +.SH Constants +.IP "NVME_RESERVATION_RACQA_ACQUIRE" 12 +-- undescribed -- +.IP "NVME_RESERVATION_RACQA_PREEMPT" 12 +-- undescribed -- +.IP "NVME_RESERVATION_RACQA_PREEMPT_AND_ABORT" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_reservation_rrega.2 b/doc/man/enum nvme_reservation_rrega.2 new file mode 100644 index 00000000..155f305f --- /dev/null +++ b/doc/man/enum nvme_reservation_rrega.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 2 "enum nvme_reservation_rrega" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_reservation_rrega \- +.SH SYNOPSIS +enum nvme_reservation_rrega { +.br +.BI " NVME_RESERVATION_RREGA_REGISTER_KEY" +, +.br +.br +.BI " NVME_RESERVATION_RREGA_UNREGISTER_KEY" +, +.br +.br +.BI " NVME_RESERVATION_RREGA_REPLACE_KEY" + +}; +.SH Constants +.IP "NVME_RESERVATION_RREGA_REGISTER_KEY" 12 +-- undescribed -- +.IP "NVME_RESERVATION_RREGA_UNREGISTER_KEY" 12 +-- undescribed -- +.IP "NVME_RESERVATION_RREGA_REPLACE_KEY" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_reservation_rrela.2 b/doc/man/enum nvme_reservation_rrela.2 new file mode 100644 index 00000000..c8a9d266 --- /dev/null +++ b/doc/man/enum nvme_reservation_rrela.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_reservation_rrela" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_reservation_rrela \- +.SH SYNOPSIS +enum nvme_reservation_rrela { +.br +.BI " NVME_RESERVATION_RRELA_RELEASE" +, +.br +.br +.BI " NVME_RESERVATION_RRELA_CLEAR" + +}; +.SH Constants +.IP "NVME_RESERVATION_RRELA_RELEASE" 12 +-- undescribed -- +.IP "NVME_RESERVATION_RRELA_CLEAR" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_reservation_rtype.2 b/doc/man/enum nvme_reservation_rtype.2 new file mode 100644 index 00000000..079b3c52 --- /dev/null +++ b/doc/man/enum nvme_reservation_rtype.2 @@ -0,0 +1,42 @@ +.TH "libnvme" 2 "enum nvme_reservation_rtype" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_reservation_rtype \- +.SH SYNOPSIS +enum nvme_reservation_rtype { +.br +.BI " NVME_RESERVATION_RTYPE_WE" +, +.br +.br +.BI " NVME_RESERVATION_RTYPE_EA" +, +.br +.br +.BI " NVME_RESERVATION_RTYPE_WERO" +, +.br +.br +.BI " NVME_RESERVATION_RTYPE_EARO" +, +.br +.br +.BI " NVME_RESERVATION_RTYPE_WEAR" +, +.br +.br +.BI " NVME_RESERVATION_RTYPE_EAAR" + +}; +.SH Constants +.IP "NVME_RESERVATION_RTYPE_WE" 12 +-- undescribed -- +.IP "NVME_RESERVATION_RTYPE_EA" 12 +-- undescribed -- +.IP "NVME_RESERVATION_RTYPE_WERO" 12 +-- undescribed -- +.IP "NVME_RESERVATION_RTYPE_EARO" 12 +-- undescribed -- +.IP "NVME_RESERVATION_RTYPE_WEAR" 12 +-- undescribed -- +.IP "NVME_RESERVATION_RTYPE_EAAR" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_sanitize_sanact.2 b/doc/man/enum nvme_sanitize_sanact.2 new file mode 100644 index 00000000..36ebbadb --- /dev/null +++ b/doc/man/enum nvme_sanitize_sanact.2 @@ -0,0 +1,30 @@ +.TH "libnvme" 2 "enum nvme_sanitize_sanact" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_sanitize_sanact \- +.SH SYNOPSIS +enum nvme_sanitize_sanact { +.br +.BI " NVME_SANITIZE_SANACT_EXIT_FAILURE" +, +.br +.br +.BI " NVME_SANITIZE_SANACT_START_BLOCK_ERASE" +, +.br +.br +.BI " NVME_SANITIZE_SANACT_START_OVERWRITE" +, +.br +.br +.BI " NVME_SANITIZE_SANACT_START_CRYPTO_ERASE" + +}; +.SH Constants +.IP "NVME_SANITIZE_SANACT_EXIT_FAILURE" 12 +-- undescribed -- +.IP "NVME_SANITIZE_SANACT_START_BLOCK_ERASE" 12 +-- undescribed -- +.IP "NVME_SANITIZE_SANACT_START_OVERWRITE" 12 +-- undescribed -- +.IP "NVME_SANITIZE_SANACT_START_CRYPTO_ERASE" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_subsys_type.2 b/doc/man/enum nvme_subsys_type.2 new file mode 100644 index 00000000..17e11b82 --- /dev/null +++ b/doc/man/enum nvme_subsys_type.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_subsys_type" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_subsys_type \- +.SH SYNOPSIS +enum nvme_subsys_type { +.br +.BI " NVME_NQN_DISC" +, +.br +.br +.BI " NVME_NQN_NVME" + +}; +.SH Constants +.IP "NVME_NQN_DISC" 12 +Discovery type target subsystem +.IP "NVME_NQN_NVME" 12 +NVME type target subsystem diff --git a/doc/man/enum nvme_virt_mgmt_act.2 b/doc/man/enum nvme_virt_mgmt_act.2 new file mode 100644 index 00000000..0151350e --- /dev/null +++ b/doc/man/enum nvme_virt_mgmt_act.2 @@ -0,0 +1,30 @@ +.TH "libnvme" 2 "enum nvme_virt_mgmt_act" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_virt_mgmt_act \- +.SH SYNOPSIS +enum nvme_virt_mgmt_act { +.br +.BI " NVME_VIRT_MGMT_ACT_PRIM_CTRL_FLEX_ALLOC" +, +.br +.br +.BI " NVME_VIRT_MGMT_ACT_OFFLINE_SEC_CTRL" +, +.br +.br +.BI " NVME_VIRT_MGMT_ACT_ASSIGN_SEC_CTRL" +, +.br +.br +.BI " NVME_VIRT_MGMT_ACT_ONLINE_SEC_CTRL" + +}; +.SH Constants +.IP "NVME_VIRT_MGMT_ACT_PRIM_CTRL_FLEX_ALLOC" 12 +-- undescribed -- +.IP "NVME_VIRT_MGMT_ACT_OFFLINE_SEC_CTRL" 12 +-- undescribed -- +.IP "NVME_VIRT_MGMT_ACT_ASSIGN_SEC_CTRL" 12 +-- undescribed -- +.IP "NVME_VIRT_MGMT_ACT_ONLINE_SEC_CTRL" 12 +-- undescribed -- diff --git a/doc/man/enum nvme_virt_mgmt_rt.2 b/doc/man/enum nvme_virt_mgmt_rt.2 new file mode 100644 index 00000000..eaaff80a --- /dev/null +++ b/doc/man/enum nvme_virt_mgmt_rt.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 2 "enum nvme_virt_mgmt_rt" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +enum nvme_virt_mgmt_rt \- +.SH SYNOPSIS +enum nvme_virt_mgmt_rt { +.br +.BI " NVME_VIRT_MGMT_RT_VQ_RESOURCE" +, +.br +.br +.BI " NVME_VIRT_MGMT_RT_VI_RESOURCE" + +}; +.SH Constants +.IP "NVME_VIRT_MGMT_RT_VQ_RESOURCE" 12 +-- undescribed -- +.IP "NVME_VIRT_MGMT_RT_VI_RESOURCE" 12 +-- undescribed -- diff --git a/doc/man/is_64bit_reg.2 b/doc/man/is_64bit_reg.2 new file mode 100644 index 00000000..62331f8b --- /dev/null +++ b/doc/man/is_64bit_reg.2 @@ -0,0 +1,16 @@ +.TH "is_64bit_reg" 2 "is_64bit_reg" "February 2020" "libnvme Manual" +.SH NAME +is_64bit_reg \- Checks if offset of the controller register is 64bit or not. +.SH SYNOPSIS +.B "bool" is_64bit_reg +.BI "(__u32 " offset ");" +.SH ARGUMENTS +.IP "offset" 12 +Offset of controller register field in bytes +.SH "DESCRIPTION" +This function does not care about transport so that the offset is not going +to be checked inside of this function for the unsupported fields in a +specific transport. For example, BPMBL(Boot Partition Memory Buffer +Location) register is not supported by fabrics, but it can be chcked here. + +Returns true if given offset is 64bit register, otherwise it returns false. diff --git a/doc/man/libnvme.2 b/doc/man/libnvme.2 new file mode 100644 index 00000000..b214923f --- /dev/null +++ b/doc/man/libnvme.2 @@ -0,0 +1,2 @@ +.TH "libnvme" 2 "libnvme" "February 2020" "LIBNVME API Manual" LINUX +.SH "NVMe IO command" diff --git a/doc/man/nvme_admin_passthru.2 b/doc/man/nvme_admin_passthru.2 new file mode 100644 index 00000000..a4f83cd9 --- /dev/null +++ b/doc/man/nvme_admin_passthru.2 @@ -0,0 +1,71 @@ +.TH "nvme_admin_passthru" 2 "nvme_admin_passthru" "February 2020" "libnvme Manual" +.SH NAME +nvme_admin_passthru \- Submit an nvme passthrough command +.SH SYNOPSIS +.B "int" nvme_admin_passthru +.BI "(int " fd "," +.BI "__u8 " opcode "," +.BI "__u8 " flags "," +.BI "__u16 " rsvd "," +.BI "__u32 " nsid "," +.BI "__u32 " cdw2 "," +.BI "__u32 " cdw3 "," +.BI "__u32 " cdw10 "," +.BI "__u32 " cdw11 "," +.BI "__u32 " cdw12 "," +.BI "__u32 " cdw13 "," +.BI "__u32 " cdw14 "," +.BI "__u32 " cdw15 "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 " metadata_len "," +.BI "void *" metadata "," +.BI "__u32 " timeout_ms "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "opcode" 12 +The nvme io command to send +.IP "flags" 12 +NVMe command flags (not used) +.IP "rsvd" 12 +Reserevd for future use +.IP "nsid" 12 +Namespace identifier +.IP "cdw2" 12 +Command dword 2 +.IP "cdw3" 12 +Command dword 3 +.IP "cdw10" 12 +Command dword 10 +.IP "cdw11" 12 +Command dword 11 +.IP "cdw12" 12 +Command dword 12 +.IP "cdw13" 12 +Command dword 13 +.IP "cdw14" 12 +Command dword 14 +.IP "cdw15" 12 +Command dword 15 +.IP "data_len" 12 +Length of the data transfered in this command in bytes +.IP "data" 12 +Pointer to user address of the data buffer +.IP "metadata_len" 12 +Length of metadata transfered in this command +.IP "metadata" 12 +Pointer to user address of the metadata buffer +.IP "timeout_ms" 12 +How long the kernel waits for the command to complete +.IP "result" 12 +Optional field to return the result from the CQE dword 0 +.SH "DESCRIPTION" +Parameterized form of \fBnvme_submit_admin_passthru\fP. This sets up and +submits a \fIstruct nvme_passthru_cmd\fP. + +Known values for \fIopcode\fP are defined in \fIenum nvme_admin_opcode\fP. +.SH "RETURN" +The nvme command status if a response was received or -1 +with errno set otherwise. diff --git a/doc/man/nvme_admin_passthru64.2 b/doc/man/nvme_admin_passthru64.2 new file mode 100644 index 00000000..46b10f7e --- /dev/null +++ b/doc/man/nvme_admin_passthru64.2 @@ -0,0 +1,71 @@ +.TH "nvme_admin_passthru64" 2 "nvme_admin_passthru64" "February 2020" "libnvme Manual" +.SH NAME +nvme_admin_passthru64 \- Submit an nvme passthrough command +.SH SYNOPSIS +.B "int" nvme_admin_passthru64 +.BI "(int " fd "," +.BI "__u8 " opcode "," +.BI "__u8 " flags "," +.BI "__u16 " rsvd "," +.BI "__u32 " nsid "," +.BI "__u32 " cdw2 "," +.BI "__u32 " cdw3 "," +.BI "__u32 " cdw10 "," +.BI "__u32 " cdw11 "," +.BI "__u32 " cdw12 "," +.BI "__u32 " cdw13 "," +.BI "__u32 " cdw14 "," +.BI "__u32 " cdw15 "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 " metadata_len "," +.BI "void *" metadata "," +.BI "__u32 " timeout_ms "," +.BI "__u64 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "opcode" 12 +The nvme io command to send +.IP "flags" 12 +NVMe command flags (not used) +.IP "rsvd" 12 +Reserevd for future use +.IP "nsid" 12 +Namespace identifier +.IP "cdw2" 12 +Command dword 2 +.IP "cdw3" 12 +Command dword 3 +.IP "cdw10" 12 +Command dword 10 +.IP "cdw11" 12 +Command dword 11 +.IP "cdw12" 12 +Command dword 12 +.IP "cdw13" 12 +Command dword 13 +.IP "cdw14" 12 +Command dword 14 +.IP "cdw15" 12 +Command dword 15 +.IP "data_len" 12 +Length of the data transfered in this command in bytes +.IP "data" 12 +Pointer to user address of the data buffer +.IP "metadata_len" 12 +Length of metadata transfered in this command +.IP "metadata" 12 +Pointer to user address of the metadata buffer +.IP "timeout_ms" 12 +How long the kernel waits for the command to complete +.IP "result" 12 +Optional field to return the result from the CQE dword 0 +.SH "DESCRIPTION" +Parameterized form of \fBnvme_submit_admin_passthru64\fP. This sets up and +submits a \fIstruct nvme_passthru_cmd64\fP. + +Known values for \fIopcode\fP are defined in \fIenum nvme_admin_opcode\fP. +.SH "RETURN" +The nvme command status if a response was received or -1 +with errno set otherwise. diff --git a/doc/man/nvme_compare.2 b/doc/man/nvme_compare.2 new file mode 100644 index 00000000..fc93bd87 --- /dev/null +++ b/doc/man/nvme_compare.2 @@ -0,0 +1,52 @@ +.TH "nvme_compare" 2 "nvme_compare" "February 2020" "libnvme Manual" +.SH NAME +nvme_compare \- Submit an nvme user compare command +.SH SYNOPSIS +.B "int" nvme_compare +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u64 " slba "," +.BI "__u16 " nlb "," +.BI "__u16 " control "," +.BI "__u32 " reftag "," +.BI "__u16 " apptag "," +.BI "__u16 " appmask "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 " metadata_len "," +.BI "void *" metadata ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "slba" 12 +Starting logical block +.IP "nlb" 12 +-- undescribed -- +.IP "control" 12 +Command control flags, see \fIenum nvme_io_control_flags\fP. +.IP "reftag" 12 +This field specifies the Initial Logical Block Reference Tag +expected value. Used only if the namespace is formatted to use +end-to-end protection information. +.IP "apptag" 12 +This field specifies the Application Tag Mask expected value. +Used only if the namespace is formatted to use end-to-end +protection information. +.IP "appmask" 12 +This field specifies the Application Tag expected value. Used +only if the namespace is formatted to use end-to-end protection +information. +.IP "data_len" 12 +Length of user buffer, \fIdata\fP, in bytes +.IP "data" 12 +Pointer to user address of the data buffer +metadata_len:Length of user buffer, \fImetadata\fP, in bytes +.IP "metadata_len" 12 +-- undescribed -- +.IP "metadata" 12 +Pointer to user address of the metadata buffer +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_ctrl_disconnect.2 b/doc/man/nvme_ctrl_disconnect.2 new file mode 100644 index 00000000..9ad29a68 --- /dev/null +++ b/doc/man/nvme_ctrl_disconnect.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_disconnect" 2 "nvme_ctrl_disconnect" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_disconnect \- +.SH SYNOPSIS +.B "int" nvme_ctrl_disconnect +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_first_ns.2 b/doc/man/nvme_ctrl_first_ns.2 new file mode 100644 index 00000000..c73e5413 --- /dev/null +++ b/doc/man/nvme_ctrl_first_ns.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_first_ns" 2 "nvme_ctrl_first_ns" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_first_ns \- +.SH SYNOPSIS +.B "nvme_ns_t" nvme_ctrl_first_ns +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_first_path.2 b/doc/man/nvme_ctrl_first_path.2 new file mode 100644 index 00000000..74f95c02 --- /dev/null +++ b/doc/man/nvme_ctrl_first_path.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_first_path" 2 "nvme_ctrl_first_path" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_first_path \- +.SH SYNOPSIS +.B "nvme_path_t" nvme_ctrl_first_path +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_for_each_ns.2 b/doc/man/nvme_ctrl_for_each_ns.2 new file mode 100644 index 00000000..d0abb504 --- /dev/null +++ b/doc/man/nvme_ctrl_for_each_ns.2 @@ -0,0 +1,12 @@ +.TH "nvme_ctrl_for_each_ns" 2 "nvme_ctrl_for_each_ns" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_for_each_ns \- +.SH SYNOPSIS +.B "nvme_ctrl_for_each_ns +.BI "(" c "," +.BI "" n ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- +.IP "n" 12 +-- undescribed -- diff --git a/doc/man/nvme_ctrl_for_each_ns_safe.2 b/doc/man/nvme_ctrl_for_each_ns_safe.2 new file mode 100644 index 00000000..e5697bfa --- /dev/null +++ b/doc/man/nvme_ctrl_for_each_ns_safe.2 @@ -0,0 +1,15 @@ +.TH "nvme_ctrl_for_each_ns_safe" 2 "nvme_ctrl_for_each_ns_safe" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_for_each_ns_safe \- +.SH SYNOPSIS +.B "nvme_ctrl_for_each_ns_safe +.BI "(" c "," +.BI "" n "," +.BI "" _n ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- +.IP "n" 12 +-- undescribed -- +.IP "_n" 12 +-- undescribed -- diff --git a/doc/man/nvme_ctrl_for_each_path.2 b/doc/man/nvme_ctrl_for_each_path.2 new file mode 100644 index 00000000..c4b20218 --- /dev/null +++ b/doc/man/nvme_ctrl_for_each_path.2 @@ -0,0 +1,12 @@ +.TH "nvme_ctrl_for_each_path" 2 "nvme_ctrl_for_each_path" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_for_each_path \- +.SH SYNOPSIS +.B "nvme_ctrl_for_each_path +.BI "(" c "," +.BI "" p ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- +.IP "p" 12 +-- undescribed -- diff --git a/doc/man/nvme_ctrl_for_each_path_safe.2 b/doc/man/nvme_ctrl_for_each_path_safe.2 new file mode 100644 index 00000000..1cbe96e9 --- /dev/null +++ b/doc/man/nvme_ctrl_for_each_path_safe.2 @@ -0,0 +1,15 @@ +.TH "nvme_ctrl_for_each_path_safe" 2 "nvme_ctrl_for_each_path_safe" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_for_each_path_safe \- +.SH SYNOPSIS +.B "nvme_ctrl_for_each_path_safe +.BI "(" c "," +.BI "" p "," +.BI "" _p ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- +.IP "p" 12 +-- undescribed -- +.IP "_p" 12 +-- undescribed -- diff --git a/doc/man/nvme_ctrl_get_address.2 b/doc/man/nvme_ctrl_get_address.2 new file mode 100644 index 00000000..e3b49904 --- /dev/null +++ b/doc/man/nvme_ctrl_get_address.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_address" 2 "nvme_ctrl_get_address" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_address \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_address +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_fd.2 b/doc/man/nvme_ctrl_get_fd.2 new file mode 100644 index 00000000..f268f64f --- /dev/null +++ b/doc/man/nvme_ctrl_get_fd.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_fd" 2 "nvme_ctrl_get_fd" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_fd \- +.SH SYNOPSIS +.B "int" nvme_ctrl_get_fd +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_firmware.2 b/doc/man/nvme_ctrl_get_firmware.2 new file mode 100644 index 00000000..18ac42a6 --- /dev/null +++ b/doc/man/nvme_ctrl_get_firmware.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_firmware" 2 "nvme_ctrl_get_firmware" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_firmware \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_firmware +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_model.2 b/doc/man/nvme_ctrl_get_model.2 new file mode 100644 index 00000000..8b1013e1 --- /dev/null +++ b/doc/man/nvme_ctrl_get_model.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_model" 2 "nvme_ctrl_get_model" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_model \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_model +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_name.2 b/doc/man/nvme_ctrl_get_name.2 new file mode 100644 index 00000000..e0b73933 --- /dev/null +++ b/doc/man/nvme_ctrl_get_name.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_name" 2 "nvme_ctrl_get_name" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_name \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_name +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_nqn.2 b/doc/man/nvme_ctrl_get_nqn.2 new file mode 100644 index 00000000..47180ac2 --- /dev/null +++ b/doc/man/nvme_ctrl_get_nqn.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_nqn" 2 "nvme_ctrl_get_nqn" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_nqn \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_nqn +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_numa_node.2 b/doc/man/nvme_ctrl_get_numa_node.2 new file mode 100644 index 00000000..93a856d9 --- /dev/null +++ b/doc/man/nvme_ctrl_get_numa_node.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_numa_node" 2 "nvme_ctrl_get_numa_node" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_numa_node \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_numa_node +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_queue_count.2 b/doc/man/nvme_ctrl_get_queue_count.2 new file mode 100644 index 00000000..63bfa969 --- /dev/null +++ b/doc/man/nvme_ctrl_get_queue_count.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_queue_count" 2 "nvme_ctrl_get_queue_count" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_queue_count \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_queue_count +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_serial.2 b/doc/man/nvme_ctrl_get_serial.2 new file mode 100644 index 00000000..7e417e70 --- /dev/null +++ b/doc/man/nvme_ctrl_get_serial.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_serial" 2 "nvme_ctrl_get_serial" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_serial \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_serial +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_sqsize.2 b/doc/man/nvme_ctrl_get_sqsize.2 new file mode 100644 index 00000000..938eaee8 --- /dev/null +++ b/doc/man/nvme_ctrl_get_sqsize.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_sqsize" 2 "nvme_ctrl_get_sqsize" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_sqsize \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_sqsize +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_state.2 b/doc/man/nvme_ctrl_get_state.2 new file mode 100644 index 00000000..8bfa163c --- /dev/null +++ b/doc/man/nvme_ctrl_get_state.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_state" 2 "nvme_ctrl_get_state" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_state \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_state +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_subsysnqn.2 b/doc/man/nvme_ctrl_get_subsysnqn.2 new file mode 100644 index 00000000..a4505a11 --- /dev/null +++ b/doc/man/nvme_ctrl_get_subsysnqn.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_subsysnqn" 2 "nvme_ctrl_get_subsysnqn" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_subsysnqn \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_subsysnqn +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_subsystem.2 b/doc/man/nvme_ctrl_get_subsystem.2 new file mode 100644 index 00000000..812eb9b7 --- /dev/null +++ b/doc/man/nvme_ctrl_get_subsystem.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_subsystem" 2 "nvme_ctrl_get_subsystem" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_subsystem \- +.SH SYNOPSIS +.B "nvme_subsystem_t" nvme_ctrl_get_subsystem +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_sysfs_dir.2 b/doc/man/nvme_ctrl_get_sysfs_dir.2 new file mode 100644 index 00000000..7de493fc --- /dev/null +++ b/doc/man/nvme_ctrl_get_sysfs_dir.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_sysfs_dir" 2 "nvme_ctrl_get_sysfs_dir" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_sysfs_dir \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_sysfs_dir +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_get_transport.2 b/doc/man/nvme_ctrl_get_transport.2 new file mode 100644 index 00000000..8e9d2e5d --- /dev/null +++ b/doc/man/nvme_ctrl_get_transport.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrl_get_transport" 2 "nvme_ctrl_get_transport" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_get_transport \- +.SH SYNOPSIS +.B "const char *" nvme_ctrl_get_transport +.BI "(nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "c" 12 diff --git a/doc/man/nvme_ctrl_identify.2 b/doc/man/nvme_ctrl_identify.2 new file mode 100644 index 00000000..c29769a4 --- /dev/null +++ b/doc/man/nvme_ctrl_identify.2 @@ -0,0 +1,11 @@ +.TH "nvme_ctrl_identify" 2 "nvme_ctrl_identify" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_identify \- +.SH SYNOPSIS +.B "int" nvme_ctrl_identify +.BI "(nvme_ctrl_t " c "," +.BI "struct nvme_id_ctrl *" id ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- +.IP "id" 12 diff --git a/doc/man/nvme_ctrl_next_ns.2 b/doc/man/nvme_ctrl_next_ns.2 new file mode 100644 index 00000000..36b7863c --- /dev/null +++ b/doc/man/nvme_ctrl_next_ns.2 @@ -0,0 +1,11 @@ +.TH "nvme_ctrl_next_ns" 2 "nvme_ctrl_next_ns" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_next_ns \- +.SH SYNOPSIS +.B "nvme_ns_t" nvme_ctrl_next_ns +.BI "(nvme_ctrl_t " c "," +.BI "nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- +.IP "n" 12 diff --git a/doc/man/nvme_ctrl_next_path.2 b/doc/man/nvme_ctrl_next_path.2 new file mode 100644 index 00000000..bd205ad2 --- /dev/null +++ b/doc/man/nvme_ctrl_next_path.2 @@ -0,0 +1,11 @@ +.TH "nvme_ctrl_next_path" 2 "nvme_ctrl_next_path" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_next_path \- +.SH SYNOPSIS +.B "nvme_path_t" nvme_ctrl_next_path +.BI "(nvme_ctrl_t " c "," +.BI "nvme_path_t " p ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- +.IP "p" 12 diff --git a/doc/man/nvme_ctrl_reset.2 b/doc/man/nvme_ctrl_reset.2 new file mode 100644 index 00000000..9ff7841e --- /dev/null +++ b/doc/man/nvme_ctrl_reset.2 @@ -0,0 +1,13 @@ +.TH "nvme_ctrl_reset" 2 "nvme_ctrl_reset" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrl_reset \- Initiate a controller reset +.SH SYNOPSIS +.B "int" nvme_ctrl_reset +.BI "(int " fd ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.SH "DESCRIPTION" +This should only be sent to controller handles, not to namespaces. +.SH "RETURN" +Zero if a reset was initiated or -1 with errno set otherwise. diff --git a/doc/man/nvme_ctrls_filter.2 b/doc/man/nvme_ctrls_filter.2 new file mode 100644 index 00000000..c3695924 --- /dev/null +++ b/doc/man/nvme_ctrls_filter.2 @@ -0,0 +1,8 @@ +.TH "nvme_ctrls_filter" 2 "nvme_ctrls_filter" "February 2020" "libnvme Manual" +.SH NAME +nvme_ctrls_filter \- +.SH SYNOPSIS +.B "int" nvme_ctrls_filter +.BI "(const struct dirent *" d ");" +.SH ARGUMENTS +.IP "d" 12 diff --git a/doc/man/nvme_dev_self_test.2 b/doc/man/nvme_dev_self_test.2 new file mode 100644 index 00000000..09aa25c5 --- /dev/null +++ b/doc/man/nvme_dev_self_test.2 @@ -0,0 +1,29 @@ +.TH "nvme_dev_self_test" 2 "nvme_dev_self_test" "February 2020" "libnvme Manual" +.SH NAME +nvme_dev_self_test \- Start or abort a self test +.SH SYNOPSIS +.B "int" nvme_dev_self_test +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "enum nvme_dst_stc " stc ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID to test +.IP "stc" 12 +Self test code, see \fIenum nvme_dst_stc\fP +.SH "DESCRIPTION" +The Device Self-test command is used to start a device self-test operation +or abort a device self-test operation. A device self-test operation is a +diagnostic testing sequence that tests the integrity and functionality of +the controller and may include testing of the media associated with +namespaces. The controller may return a response to this command immediately +while running the self-test in the background. + +Set the 'nsid' field to 0 to not include namepsaces in the test. Set to +0xffffffff to test all namespaces. All other values tests a specific +namespace, if present. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_directive_recv.2 b/doc/man/nvme_directive_recv.2 new file mode 100644 index 00000000..208a9fc6 --- /dev/null +++ b/doc/man/nvme_directive_recv.2 @@ -0,0 +1,36 @@ +.TH "nvme_directive_recv" 2 "nvme_directive_recv" "February 2020" "libnvme Manual" +.SH NAME +nvme_directive_recv \- Receive directive specific data +.SH SYNOPSIS +.B "int" nvme_directive_recv +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u16 " dspec "," +.BI "enum nvme_directive_receive_doper " doper "," +.BI "enum nvme_directive_dtype " dtype "," +.BI "__u32 " cdw12 "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID, if applicable +.IP "dspec" 12 +Directive specific field +.IP "doper" 12 +Directive receive operation, see \fIenum nvme_directive_receive_doper\fP +.IP "dtype" 12 +Directive type, see \fIenum nvme_directive_dtype\fP +.IP "cdw12" 12 +-- undescribed -- +.IP "data_len" 12 +Length of data payload +.IP "data" 12 +Usespace address of data payload in bytes +.IP "result" 12 +If successful, the CQE dword0 value +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_directive_recv_identify_parameters.2 b/doc/man/nvme_directive_recv_identify_parameters.2 new file mode 100644 index 00000000..5553410e --- /dev/null +++ b/doc/man/nvme_directive_recv_identify_parameters.2 @@ -0,0 +1,18 @@ +.TH "nvme_directive_recv_identify_parameters" 2 "nvme_directive_recv_identify_parameters" "February 2020" "libnvme Manual" +.SH NAME +nvme_directive_recv_identify_parameters \- +.SH SYNOPSIS +.B "int" nvme_directive_recv_identify_parameters +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "struct nvme_id_directives *" id ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "id" 12 +-- undescribed -- +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_directive_recv_stream_allocate.2 b/doc/man/nvme_directive_recv_stream_allocate.2 new file mode 100644 index 00000000..c813c78d --- /dev/null +++ b/doc/man/nvme_directive_recv_stream_allocate.2 @@ -0,0 +1,21 @@ +.TH "nvme_directive_recv_stream_allocate" 2 "nvme_directive_recv_stream_allocate" "February 2020" "libnvme Manual" +.SH NAME +nvme_directive_recv_stream_allocate \- +.SH SYNOPSIS +.B "int" nvme_directive_recv_stream_allocate +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u16 " nsr "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "nsr" 12 +-- undescribed -- +.IP "result" 12 +-- undescribed -- +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_directive_recv_stream_parameters.2 b/doc/man/nvme_directive_recv_stream_parameters.2 new file mode 100644 index 00000000..2fbb5b2d --- /dev/null +++ b/doc/man/nvme_directive_recv_stream_parameters.2 @@ -0,0 +1,18 @@ +.TH "nvme_directive_recv_stream_parameters" 2 "nvme_directive_recv_stream_parameters" "February 2020" "libnvme Manual" +.SH NAME +nvme_directive_recv_stream_parameters \- +.SH SYNOPSIS +.B "int" nvme_directive_recv_stream_parameters +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "struct nvme_streams_directive_params *" parms ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "parms" 12 +-- undescribed -- +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_directive_recv_stream_status.2 b/doc/man/nvme_directive_recv_stream_status.2 new file mode 100644 index 00000000..027a029e --- /dev/null +++ b/doc/man/nvme_directive_recv_stream_status.2 @@ -0,0 +1,21 @@ +.TH "nvme_directive_recv_stream_status" 2 "nvme_directive_recv_stream_status" "February 2020" "libnvme Manual" +.SH NAME +nvme_directive_recv_stream_status \- +.SH SYNOPSIS +.B "int" nvme_directive_recv_stream_status +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "unsigned " nr_entries "," +.BI "struct nvme_streams_directive_status *" id ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "nr_entries" 12 +-- undescribed -- +.IP "id" 12 +-- undescribed -- +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_directive_send.2 b/doc/man/nvme_directive_send.2 new file mode 100644 index 00000000..8847383a --- /dev/null +++ b/doc/man/nvme_directive_send.2 @@ -0,0 +1,42 @@ +.TH "nvme_directive_send" 2 "nvme_directive_send" "February 2020" "libnvme Manual" +.SH NAME +nvme_directive_send \- Send directive command +.SH SYNOPSIS +.B "int" nvme_directive_send +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u16 " dspec "," +.BI "enum nvme_directive_send_doper " doper "," +.BI "enum nvme_directive_dtype " dtype "," +.BI "__u32 " cdw12 "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID, if applicable +.IP "dspec" 12 +Directive specific field +.IP "doper" 12 +Directive send operation, see \fIenum nvme_directive_send_doper\fP +.IP "dtype" 12 +Directive type, see \fIenum nvme_directive_dtype\fP +.IP "cdw12" 12 +-- undescribed -- +.IP "data_len" 12 +Length of data payload in bytes +.IP "data" 12 +Usespace address of data payload +.IP "result" 12 +If successful, the CQE dword0 value +.SH "DESCRIPTION" +Directives is a mechanism to enable host and NVM subsystem or controller +information exchange. The Directive Send command is used to transfer data +related to a specific Directive Type from the host to the controller. + +See the NVMe specification for more information. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_directive_send_id_endir.2 b/doc/man/nvme_directive_send_id_endir.2 new file mode 100644 index 00000000..76d3bcb7 --- /dev/null +++ b/doc/man/nvme_directive_send_id_endir.2 @@ -0,0 +1,24 @@ +.TH "nvme_directive_send_id_endir" 2 "nvme_directive_send_id_endir" "February 2020" "libnvme Manual" +.SH NAME +nvme_directive_send_id_endir \- +.SH SYNOPSIS +.B "int" nvme_directive_send_id_endir +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "bool " endir "," +.BI "enum nvme_directive_dtype " dtype "," +.BI "struct nvme_id_directives *" id ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "endir" 12 +-- undescribed -- +.IP "dtype" 12 +-- undescribed -- +.IP "id" 12 +-- undescribed -- +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_directive_send_stream_release_identifier.2 b/doc/man/nvme_directive_send_stream_release_identifier.2 new file mode 100644 index 00000000..bad7cc37 --- /dev/null +++ b/doc/man/nvme_directive_send_stream_release_identifier.2 @@ -0,0 +1,18 @@ +.TH "nvme_directive_send_stream_release_identifier" 2 "nvme_directive_send_stream_release_identifier" "February 2020" "libnvme Manual" +.SH NAME +nvme_directive_send_stream_release_identifier \- +.SH SYNOPSIS +.B "int" nvme_directive_send_stream_release_identifier +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u16 " stream_id ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "stream_id" 12 +-- undescribed -- +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_directive_send_stream_release_resource.2 b/doc/man/nvme_directive_send_stream_release_resource.2 new file mode 100644 index 00000000..e1852a39 --- /dev/null +++ b/doc/man/nvme_directive_send_stream_release_resource.2 @@ -0,0 +1,15 @@ +.TH "nvme_directive_send_stream_release_resource" 2 "nvme_directive_send_stream_release_resource" "February 2020" "libnvme Manual" +.SH NAME +nvme_directive_send_stream_release_resource \- +.SH SYNOPSIS +.B "int" nvme_directive_send_stream_release_resource +.BI "(int " fd "," +.BI "__u32 " nsid ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_dsm.2 b/doc/man/nvme_dsm.2 new file mode 100644 index 00000000..7b2e7f19 --- /dev/null +++ b/doc/man/nvme_dsm.2 @@ -0,0 +1,31 @@ +.TH "nvme_dsm" 2 "nvme_dsm" "February 2020" "libnvme Manual" +.SH NAME +nvme_dsm \- Send an nvme data set management command +.SH SYNOPSIS +.B "int" nvme_dsm +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u32 " attrs "," +.BI "__u16 " nr_ranges "," +.BI "struct nvme_dsm_range *" dsm ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace identifier +.IP "attrs" 12 +DSM attributes, see \fIenum nvme_dsm_attributes\fP +\fInr_ranges\fP: Number of block ranges in the data set management attributes +.IP "nr_ranges" 12 +-- undescribed -- +.IP "dsm" 12 +The data set management attributes +.SH "DESCRIPTION" +The Dataset Management command is used by the host to indicate attributes +for ranges of logical blocks. This includes attributes like frequency that +data is read or written, access size, and other information that may be used +to optimize performance and reliability, and may be used to +deallocate/unmap/trim those logical blocks. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_first_subsystem.2 b/doc/man/nvme_first_subsystem.2 new file mode 100644 index 00000000..bcc1bc58 --- /dev/null +++ b/doc/man/nvme_first_subsystem.2 @@ -0,0 +1,8 @@ +.TH "nvme_first_subsystem" 2 "nvme_first_subsystem" "February 2020" "libnvme Manual" +.SH NAME +nvme_first_subsystem \- +.SH SYNOPSIS +.B "nvme_subsystem_t" nvme_first_subsystem +.BI "(nvme_root_t " r ");" +.SH ARGUMENTS +.IP "r" 12 diff --git a/doc/man/nvme_flush.2 b/doc/man/nvme_flush.2 new file mode 100644 index 00000000..090cf19d --- /dev/null +++ b/doc/man/nvme_flush.2 @@ -0,0 +1,18 @@ +.TH "nvme_flush" 2 "nvme_flush" "February 2020" "libnvme Manual" +.SH NAME +nvme_flush \- Send an nvme flush command +.SH SYNOPSIS +.B "int" nvme_flush +.BI "(int " fd "," +.BI "__u32 " nsid ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace identifier +.SH "DESCRIPTION" +The Flush command is used to request that the contents of volatile write +cache be made non-volatile. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_for_each_subsystem.2 b/doc/man/nvme_for_each_subsystem.2 new file mode 100644 index 00000000..2cfeca5c --- /dev/null +++ b/doc/man/nvme_for_each_subsystem.2 @@ -0,0 +1,12 @@ +.TH "nvme_for_each_subsystem" 2 "nvme_for_each_subsystem" "February 2020" "libnvme Manual" +.SH NAME +nvme_for_each_subsystem \- +.SH SYNOPSIS +.B "nvme_for_each_subsystem +.BI "(" r "," +.BI "" s ");" +.SH ARGUMENTS +.IP "r" 12 +-- undescribed -- +.IP "s" 12 +-- undescribed -- diff --git a/doc/man/nvme_for_each_subsystem_safe.2 b/doc/man/nvme_for_each_subsystem_safe.2 new file mode 100644 index 00000000..5604544a --- /dev/null +++ b/doc/man/nvme_for_each_subsystem_safe.2 @@ -0,0 +1,15 @@ +.TH "nvme_for_each_subsystem_safe" 2 "nvme_for_each_subsystem_safe" "February 2020" "libnvme Manual" +.SH NAME +nvme_for_each_subsystem_safe \- +.SH SYNOPSIS +.B "nvme_for_each_subsystem_safe +.BI "(" r "," +.BI "" s "," +.BI "" _s ");" +.SH ARGUMENTS +.IP "r" 12 +-- undescribed -- +.IP "s" 12 +-- undescribed -- +.IP "_s" 12 +-- undescribed -- diff --git a/doc/man/nvme_format_nvm.2 b/doc/man/nvme_format_nvm.2 new file mode 100644 index 00000000..87023b36 --- /dev/null +++ b/doc/man/nvme_format_nvm.2 @@ -0,0 +1,39 @@ +.TH "nvme_format_nvm" 2 "nvme_format_nvm" "February 2020" "libnvme Manual" +.SH NAME +nvme_format_nvm \- Format nvme namespace(s) +.SH SYNOPSIS +.B "int" nvme_format_nvm +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u8 " lbaf "," +.BI "enum nvme_cmd_format_mset " mset "," +.BI "enum nvme_cmd_format_pi " pi "," +.BI "enum nvme_cmd_format_pil " pil "," +.BI "enum nvme_cmd_format_ses " ses "," +.BI "__u32 " timeout ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID to format +.IP "lbaf" 12 +Logical block address format +.IP "mset" 12 +Metadata settings (extended or separated), true if extended +.IP "pi" 12 +Protection information type +.IP "pil" 12 +Protection information location (beginning or end), true if end +.IP "ses" 12 +Secure erase settings +.IP "timeout" 12 +Set to override default timeout to this value in milliseconds; +useful for long running formats. 0 will use system default. +.SH "DESCRIPTION" +The Format NVM command is used to low level format the NVM media. This +command is used by the host to change the LBA data size and/or metadata +size. A low level format may destroy all data and metadata associated with +all namespaces or only the specific namespace associated with the command +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_free_ctrl.2 b/doc/man/nvme_free_ctrl.2 new file mode 100644 index 00000000..78d9f928 --- /dev/null +++ b/doc/man/nvme_free_ctrl.2 @@ -0,0 +1,9 @@ +.TH "nvme_free_ctrl" 2 "nvme_free_ctrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_free_ctrl \- +.SH SYNOPSIS +.B "void" nvme_free_ctrl +.BI "(struct nvme_ctrl *" c ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- diff --git a/doc/man/nvme_free_tree.2 b/doc/man/nvme_free_tree.2 new file mode 100644 index 00000000..ef1138ef --- /dev/null +++ b/doc/man/nvme_free_tree.2 @@ -0,0 +1,9 @@ +.TH "nvme_free_tree" 2 "nvme_free_tree" "February 2020" "libnvme Manual" +.SH NAME +nvme_free_tree \- +.SH SYNOPSIS +.B "void" nvme_free_tree +.BI "(nvme_root_t " r ");" +.SH ARGUMENTS +.IP "r" 12 +-- undescribed -- diff --git a/doc/man/nvme_fw_commit.2 b/doc/man/nvme_fw_commit.2 new file mode 100644 index 00000000..093e9728 --- /dev/null +++ b/doc/man/nvme_fw_commit.2 @@ -0,0 +1,25 @@ +.TH "nvme_fw_commit" 2 "nvme_fw_commit" "February 2020" "libnvme Manual" +.SH NAME +nvme_fw_commit \- Commit firmware using the specified action +.SH SYNOPSIS +.B "int" nvme_fw_commit +.BI "(int " fd "," +.BI "__u8 " slot "," +.BI "enum nvme_fw_commit_ca " action "," +.BI "bool " bpid ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "slot" 12 +Firmware slot to commit the downloaded image +.IP "action" 12 +Action to use for the firmware image, see \fIenum nvme_fw_commit_ca\fP +.IP "bpid" 12 +Set to true to select the boot partition id +.SH "DESCRIPTION" +The Firmware Commit command is used to modify the firmware image or Boot +Partitions. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. The command status response may specify additional +reset actions required to complete the commit process. diff --git a/doc/man/nvme_fw_download.2 b/doc/man/nvme_fw_download.2 new file mode 100644 index 00000000..be478dac --- /dev/null +++ b/doc/man/nvme_fw_download.2 @@ -0,0 +1,34 @@ +.TH "nvme_fw_download" 2 "nvme_fw_download" "February 2020" "libnvme Manual" +.SH NAME +nvme_fw_download \- Download part or all of a firmware image to the controller +.SH SYNOPSIS +.B "int" nvme_fw_download +.BI "(int " fd "," +.BI "__u32 " offset "," +.BI "__u32 " data_len "," +.BI "void *" data ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "offset" 12 +Offset in the firmware data +.IP "data_len" 12 +Length of data in this command in bytes +.IP "data" 12 +Userspace address of the firmware data +.SH "DESCRIPTION" +The Firmware Image Download command is used to download all or a portion of +an image for a future update to the controller. The Firmware Image Download +command downloads a new image (in whole or in part) to the controller. + +The image may be constructed of multiple pieces that are individually +downloaded with separate Firmware Image Download commands. Each Firmware +Image Download command includes a Dword Offset and Number of Dwords that +specify a dword range. + +The new firmware image is not activated as part of the Firmware Image +Download command. Use the \fBnvme_fw_commit\fP to activate a newly downloaded +image. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_fw_download_seq.2 b/doc/man/nvme_fw_download_seq.2 new file mode 100644 index 00000000..fcba60af --- /dev/null +++ b/doc/man/nvme_fw_download_seq.2 @@ -0,0 +1,20 @@ +.TH "nvme_fw_download_seq" 2 "nvme_fw_download_seq" "February 2020" "libnvme Manual" +.SH NAME +nvme_fw_download_seq \- +.SH SYNOPSIS +.B "int" nvme_fw_download_seq +.BI "(int " fd "," +.BI "__u32 " size "," +.BI "__u32 " xfer "," +.BI "__u32 " offset "," +.BI "void *" buf ");" +.SH ARGUMENTS +.IP "fd" 12 +-- undescribed -- +.IP "size" 12 +-- undescribed -- +.IP "xfer" 12 +-- undescribed -- +.IP "offset" 12 +-- undescribed -- +.IP "buf" 12 diff --git a/doc/man/nvme_get_ana_log_len.2 b/doc/man/nvme_get_ana_log_len.2 new file mode 100644 index 00000000..08d7b422 --- /dev/null +++ b/doc/man/nvme_get_ana_log_len.2 @@ -0,0 +1,14 @@ +.TH "nvme_get_ana_log_len" 2 "nvme_get_ana_log_len" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_ana_log_len \- Retreive size of the current ANA log +.SH SYNOPSIS +.B "int" nvme_get_ana_log_len +.BI "(int " fd "," +.BI "size_t *" analen ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "analen" 12 +Pointer to where the length will be set on success +.SH "RETURN" +0 on success, -1 otherwise with errno set diff --git a/doc/man/nvme_get_ctrl_attr.2 b/doc/man/nvme_get_ctrl_attr.2 new file mode 100644 index 00000000..eecaa87a --- /dev/null +++ b/doc/man/nvme_get_ctrl_attr.2 @@ -0,0 +1,11 @@ +.TH "nvme_get_ctrl_attr" 2 "nvme_get_ctrl_attr" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_ctrl_attr \- +.SH SYNOPSIS +.B "char *" nvme_get_ctrl_attr +.BI "(nvme_ctrl_t " c "," +.BI "const char *" attr ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- +.IP "attr" 12 diff --git a/doc/man/nvme_get_ctrl_telemetry.2 b/doc/man/nvme_get_ctrl_telemetry.2 new file mode 100644 index 00000000..6fb9dde6 --- /dev/null +++ b/doc/man/nvme_get_ctrl_telemetry.2 @@ -0,0 +1,17 @@ +.TH "nvme_get_ctrl_telemetry" 2 "nvme_get_ctrl_telemetry" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_ctrl_telemetry \- +.SH SYNOPSIS +.B "int" nvme_get_ctrl_telemetry +.BI "(int " fd "," +.BI "bool " rae "," +.BI "void **" buf "," +.BI "__u32 *" log_size ");" +.SH ARGUMENTS +.IP "fd" 12 +-- undescribed -- +.IP "rae" 12 +-- undescribed -- +.IP "buf" 12 +-- undescribed -- +.IP "log_size" 12 diff --git a/doc/man/nvme_get_directive_receive_length.2 b/doc/man/nvme_get_directive_receive_length.2 new file mode 100644 index 00000000..c5b6e2b4 --- /dev/null +++ b/doc/man/nvme_get_directive_receive_length.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_directive_receive_length" 2 "nvme_get_directive_receive_length" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_directive_receive_length \- +.SH SYNOPSIS +.B "int" nvme_get_directive_receive_length +.BI "(enum nvme_directive_dtype " dtype "," +.BI "enum nvme_directive_receive_doper " doper "," +.BI "__u32 *" len ");" +.SH ARGUMENTS +.IP "dtype" 12 +Directive type, see \fIenum nvme_directive_dtype\fP +.IP "doper" 12 +Directive receive operation, see \fIenum nvme_directive_receive_doper\fP +.IP "len" 12 +Address to save the payload length of the directive in bytes on +a successful decode +.SH "RETURN" +0 on success, -1 with errno set to EINVAL. diff --git a/doc/man/nvme_get_feature_length.2 b/doc/man/nvme_get_feature_length.2 new file mode 100644 index 00000000..0456c360 --- /dev/null +++ b/doc/man/nvme_get_feature_length.2 @@ -0,0 +1,16 @@ +.TH "nvme_get_feature_length" 2 "nvme_get_feature_length" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_feature_length \- Retreive the command payload length for a specific feature identifier +.SH SYNOPSIS +.B "int" nvme_get_feature_length +.BI "(int " fid "," +.BI "__u32 " cdw11 "," +.BI "__u32 *" len ");" +.SH ARGUMENTS +.IP "fid" 12 +-- undescribed -- +.IP "cdw11" 12 +-- undescribed -- +.IP "len" 12 +.SH "RETURN" +0 on success, -1 with errno set otherwise diff --git a/doc/man/nvme_get_features.2 b/doc/man/nvme_get_features.2 new file mode 100644 index 00000000..76ff35c1 --- /dev/null +++ b/doc/man/nvme_get_features.2 @@ -0,0 +1,36 @@ +.TH "nvme_get_features" 2 "nvme_get_features" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features \- Retrieve a feature attribute +.SH SYNOPSIS +.B "int" nvme_get_features +.BI "(int " fd "," +.BI "enum nvme_features_id " fid "," +.BI "__u32 " nsid "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 " cdw11 "," +.BI "__u8 " uuidx "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "fid" 12 +Feature identifier +.IP "nsid" 12 +Namespace ID, if applicable +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "cdw11" 12 +Feature specific command dword11 field +.IP "uuidx" 12 +UUID Index for differentiating vendor specific encoding +.IP "data_len" 12 +Length of feature data, if applicable, in bytes +.IP "data" 12 +User address of feature data, if applicable +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_arbitration.2 b/doc/man/nvme_get_features_arbitration.2 new file mode 100644 index 00000000..b81cb905 --- /dev/null +++ b/doc/man/nvme_get_features_arbitration.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_arbitration" 2 "nvme_get_features_arbitration" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_arbitration \- +.SH SYNOPSIS +.B "int" nvme_get_features_arbitration +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_async_event.2 b/doc/man/nvme_get_features_async_event.2 new file mode 100644 index 00000000..2ff8ef89 --- /dev/null +++ b/doc/man/nvme_get_features_async_event.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_async_event" 2 "nvme_get_features_async_event" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_async_event \- +.SH SYNOPSIS +.B "int" nvme_get_features_async_event +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_auto_pst.2 b/doc/man/nvme_get_features_auto_pst.2 new file mode 100644 index 00000000..63822dc3 --- /dev/null +++ b/doc/man/nvme_get_features_auto_pst.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_features_auto_pst" 2 "nvme_get_features_auto_pst" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_auto_pst \- +.SH SYNOPSIS +.B "int" nvme_get_features_auto_pst +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "struct nvme_feat_auto_pst *" apst "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "apst" 12 +-- undescribed -- +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_endurance_event_cfg.2 b/doc/man/nvme_get_features_endurance_event_cfg.2 new file mode 100644 index 00000000..531a3bf8 --- /dev/null +++ b/doc/man/nvme_get_features_endurance_event_cfg.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_features_endurance_event_cfg" 2 "nvme_get_features_endurance_event_cfg" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_endurance_event_cfg \- +.SH SYNOPSIS +.B "int" nvme_get_features_endurance_event_cfg +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u16 " endgid "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "endgid" 12 +-- undescribed -- +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_err_recovery.2 b/doc/man/nvme_get_features_err_recovery.2 new file mode 100644 index 00000000..7f847ba0 --- /dev/null +++ b/doc/man/nvme_get_features_err_recovery.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_err_recovery" 2 "nvme_get_features_err_recovery" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_err_recovery \- +.SH SYNOPSIS +.B "int" nvme_get_features_err_recovery +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_hctm.2 b/doc/man/nvme_get_features_hctm.2 new file mode 100644 index 00000000..0ce7465e --- /dev/null +++ b/doc/man/nvme_get_features_hctm.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_hctm" 2 "nvme_get_features_hctm" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_hctm \- +.SH SYNOPSIS +.B "int" nvme_get_features_hctm +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_host_behavior.2 b/doc/man/nvme_get_features_host_behavior.2 new file mode 100644 index 00000000..23cfe988 --- /dev/null +++ b/doc/man/nvme_get_features_host_behavior.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_features_host_behavior" 2 "nvme_get_features_host_behavior" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_host_behavior \- +.SH SYNOPSIS +.B "int" nvme_get_features_host_behavior +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "struct nvme_feat_host_behavior *" data "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "data" 12 +-- undescribed -- +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_host_id.2 b/doc/man/nvme_get_features_host_id.2 new file mode 100644 index 00000000..152e9482 --- /dev/null +++ b/doc/man/nvme_get_features_host_id.2 @@ -0,0 +1,24 @@ +.TH "nvme_get_features_host_id" 2 "nvme_get_features_host_id" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_host_id \- +.SH SYNOPSIS +.B "int" nvme_get_features_host_id +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "bool " exhid "," +.BI "__u32 " len "," +.BI "__u8 *" hostid ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "exhid" 12 +-- undescribed -- +.IP "len" 12 +-- undescribed -- +.IP "hostid" 12 +-- undescribed -- +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_host_mem_buf.2 b/doc/man/nvme_get_features_host_mem_buf.2 new file mode 100644 index 00000000..28393b0c --- /dev/null +++ b/doc/man/nvme_get_features_host_mem_buf.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_host_mem_buf" 2 "nvme_get_features_host_mem_buf" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_host_mem_buf \- +.SH SYNOPSIS +.B "int" nvme_get_features_host_mem_buf +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_irq_coalesce.2 b/doc/man/nvme_get_features_irq_coalesce.2 new file mode 100644 index 00000000..1e5f7c18 --- /dev/null +++ b/doc/man/nvme_get_features_irq_coalesce.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_irq_coalesce" 2 "nvme_get_features_irq_coalesce" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_irq_coalesce \- +.SH SYNOPSIS +.B "int" nvme_get_features_irq_coalesce +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_irq_config.2 b/doc/man/nvme_get_features_irq_config.2 new file mode 100644 index 00000000..1c353e88 --- /dev/null +++ b/doc/man/nvme_get_features_irq_config.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_features_irq_config" 2 "nvme_get_features_irq_config" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_irq_config \- +.SH SYNOPSIS +.B "int" nvme_get_features_irq_config +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u16 " iv "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "iv" 12 +-- undescribed -- +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_kato.2 b/doc/man/nvme_get_features_kato.2 new file mode 100644 index 00000000..3e060222 --- /dev/null +++ b/doc/man/nvme_get_features_kato.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_kato" 2 "nvme_get_features_kato" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_kato \- +.SH SYNOPSIS +.B "int" nvme_get_features_kato +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_lba_range.2 b/doc/man/nvme_get_features_lba_range.2 new file mode 100644 index 00000000..01969af9 --- /dev/null +++ b/doc/man/nvme_get_features_lba_range.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_features_lba_range" 2 "nvme_get_features_lba_range" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_lba_range \- +.SH SYNOPSIS +.B "int" nvme_get_features_lba_range +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "struct nvme_lba_range_type *" data "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "data" 12 +-- undescribed -- +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_lba_sts_interval.2 b/doc/man/nvme_get_features_lba_sts_interval.2 new file mode 100644 index 00000000..15ae7d86 --- /dev/null +++ b/doc/man/nvme_get_features_lba_sts_interval.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_lba_sts_interval" 2 "nvme_get_features_lba_sts_interval" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_lba_sts_interval \- +.SH SYNOPSIS +.B "int" nvme_get_features_lba_sts_interval +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_nopsc.2 b/doc/man/nvme_get_features_nopsc.2 new file mode 100644 index 00000000..d702cd35 --- /dev/null +++ b/doc/man/nvme_get_features_nopsc.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_nopsc" 2 "nvme_get_features_nopsc" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_nopsc \- +.SH SYNOPSIS +.B "int" nvme_get_features_nopsc +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_num_queues.2 b/doc/man/nvme_get_features_num_queues.2 new file mode 100644 index 00000000..ffc529c7 --- /dev/null +++ b/doc/man/nvme_get_features_num_queues.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_num_queues" 2 "nvme_get_features_num_queues" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_num_queues \- +.SH SYNOPSIS +.B "int" nvme_get_features_num_queues +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_plm_config.2 b/doc/man/nvme_get_features_plm_config.2 new file mode 100644 index 00000000..e694343d --- /dev/null +++ b/doc/man/nvme_get_features_plm_config.2 @@ -0,0 +1,24 @@ +.TH "nvme_get_features_plm_config" 2 "nvme_get_features_plm_config" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_plm_config \- +.SH SYNOPSIS +.B "int" nvme_get_features_plm_config +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u16 " nvmsetid "," +.BI "struct nvme_plm_config *" data "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "nvmsetid" 12 +-- undescribed -- +.IP "data" 12 +-- undescribed -- +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_plm_window.2 b/doc/man/nvme_get_features_plm_window.2 new file mode 100644 index 00000000..3745d206 --- /dev/null +++ b/doc/man/nvme_get_features_plm_window.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_features_plm_window" 2 "nvme_get_features_plm_window" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_plm_window \- +.SH SYNOPSIS +.B "int" nvme_get_features_plm_window +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u16 " nvmsetid "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "nvmsetid" 12 +-- undescribed -- +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_power_mgmt.2 b/doc/man/nvme_get_features_power_mgmt.2 new file mode 100644 index 00000000..afb40d6f --- /dev/null +++ b/doc/man/nvme_get_features_power_mgmt.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_power_mgmt" 2 "nvme_get_features_power_mgmt" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_power_mgmt \- +.SH SYNOPSIS +.B "int" nvme_get_features_power_mgmt +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_resv_mask.2 b/doc/man/nvme_get_features_resv_mask.2 new file mode 100644 index 00000000..847951c7 --- /dev/null +++ b/doc/man/nvme_get_features_resv_mask.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_resv_mask" 2 "nvme_get_features_resv_mask" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_resv_mask \- +.SH SYNOPSIS +.B "int" nvme_get_features_resv_mask +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_resv_persist.2 b/doc/man/nvme_get_features_resv_persist.2 new file mode 100644 index 00000000..a199048c --- /dev/null +++ b/doc/man/nvme_get_features_resv_persist.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_resv_persist" 2 "nvme_get_features_resv_persist" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_resv_persist \- +.SH SYNOPSIS +.B "int" nvme_get_features_resv_persist +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_rrl.2 b/doc/man/nvme_get_features_rrl.2 new file mode 100644 index 00000000..84585fa9 --- /dev/null +++ b/doc/man/nvme_get_features_rrl.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_rrl" 2 "nvme_get_features_rrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_rrl \- +.SH SYNOPSIS +.B "int" nvme_get_features_rrl +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_sanitize.2 b/doc/man/nvme_get_features_sanitize.2 new file mode 100644 index 00000000..36fee6ac --- /dev/null +++ b/doc/man/nvme_get_features_sanitize.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_sanitize" 2 "nvme_get_features_sanitize" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_sanitize \- +.SH SYNOPSIS +.B "int" nvme_get_features_sanitize +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_sw_progress.2 b/doc/man/nvme_get_features_sw_progress.2 new file mode 100644 index 00000000..51357cf3 --- /dev/null +++ b/doc/man/nvme_get_features_sw_progress.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_sw_progress" 2 "nvme_get_features_sw_progress" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_sw_progress \- +.SH SYNOPSIS +.B "int" nvme_get_features_sw_progress +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_temp_thresh.2 b/doc/man/nvme_get_features_temp_thresh.2 new file mode 100644 index 00000000..61b845ba --- /dev/null +++ b/doc/man/nvme_get_features_temp_thresh.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_temp_thresh" 2 "nvme_get_features_temp_thresh" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_temp_thresh \- +.SH SYNOPSIS +.B "int" nvme_get_features_temp_thresh +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_timestamp.2 b/doc/man/nvme_get_features_timestamp.2 new file mode 100644 index 00000000..c541f842 --- /dev/null +++ b/doc/man/nvme_get_features_timestamp.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_timestamp" 2 "nvme_get_features_timestamp" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_timestamp \- +.SH SYNOPSIS +.B "int" nvme_get_features_timestamp +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "struct nvme_timestamp *" ts ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "ts" 12 +-- undescribed -- +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_volatile_wc.2 b/doc/man/nvme_get_features_volatile_wc.2 new file mode 100644 index 00000000..fde62d8d --- /dev/null +++ b/doc/man/nvme_get_features_volatile_wc.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_volatile_wc" 2 "nvme_get_features_volatile_wc" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_volatile_wc \- +.SH SYNOPSIS +.B "int" nvme_get_features_volatile_wc +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_write_atomic.2 b/doc/man/nvme_get_features_write_atomic.2 new file mode 100644 index 00000000..fcfc260d --- /dev/null +++ b/doc/man/nvme_get_features_write_atomic.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_features_write_atomic" 2 "nvme_get_features_write_atomic" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_write_atomic \- +.SH SYNOPSIS +.B "int" nvme_get_features_write_atomic +.BI "(int " fd "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_features_write_protect.2 b/doc/man/nvme_get_features_write_protect.2 new file mode 100644 index 00000000..dd4ecfca --- /dev/null +++ b/doc/man/nvme_get_features_write_protect.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_features_write_protect" 2 "nvme_get_features_write_protect" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_features_write_protect \- +.SH SYNOPSIS +.B "int" nvme_get_features_write_protect +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "enum nvme_get_features_sel " sel "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "sel" 12 +Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_host_telemetry.2 b/doc/man/nvme_get_host_telemetry.2 new file mode 100644 index 00000000..d1d1c232 --- /dev/null +++ b/doc/man/nvme_get_host_telemetry.2 @@ -0,0 +1,14 @@ +.TH "nvme_get_host_telemetry" 2 "nvme_get_host_telemetry" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_host_telemetry \- +.SH SYNOPSIS +.B "int" nvme_get_host_telemetry +.BI "(int " fd "," +.BI "void **" buf "," +.BI "__u32 *" log_size ");" +.SH ARGUMENTS +.IP "fd" 12 +-- undescribed -- +.IP "buf" 12 +-- undescribed -- +.IP "log_size" 12 diff --git a/doc/man/nvme_get_lba_status.2 b/doc/man/nvme_get_lba_status.2 new file mode 100644 index 00000000..ad406f74 --- /dev/null +++ b/doc/man/nvme_get_lba_status.2 @@ -0,0 +1,34 @@ +.TH "nvme_get_lba_status" 2 "nvme_get_lba_status" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_lba_status \- Retrieve information on possibly unrecoverable LBAs +.SH SYNOPSIS +.B "int" nvme_get_lba_status +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u64 " slba "," +.BI "__u32 " mndw "," +.BI "__u16 " rl "," +.BI "enum nvme_lba_status_atype " atype "," +.BI "struct nvme_lba_status *" lbas ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID to retrieve LBA status +.IP "slba" 12 +Starting logical block address to check statuses +.IP "mndw" 12 +Maximum number of dwords to return +.IP "rl" 12 +Range length from slba to perform the action +.IP "atype" 12 +Action type mechanism to determine LBA status desctriptors to +return, see \fIenum nvme_lba_status_atype\fP +.IP "lbas" 12 +Data payload to return status descriptors +.SH "DESCRIPTION" +The Get LBA Status command requests information about Potentially +Unrecoverable LBAs. Refer to the specification for action type descriptions. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log.2 b/doc/man/nvme_get_log.2 new file mode 100644 index 00000000..2f7fd0f6 --- /dev/null +++ b/doc/man/nvme_get_log.2 @@ -0,0 +1,39 @@ +.TH "nvme_get_log" 2 "nvme_get_log" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log \- NVMe Admin Get Log command +.SH SYNOPSIS +.B "int" nvme_get_log +.BI "(int " fd "," +.BI "enum nvme_cmd_get_log_lid " lid "," +.BI "__u32 " nsid "," +.BI "__u64 " lpo "," +.BI "__u8 " lsp "," +.BI "__u16 " lsi "," +.BI "bool " rae "," +.BI "__u8 " uuidx "," +.BI "__u32 " len "," +.BI "void *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "lid" 12 +Log page identifier, see \fIenum nvme_cmd_get_log_lid\fP for known values +.IP "nsid" 12 +Namespace identifier, if applicable +.IP "lpo" 12 +Log page offset for partial log transfers +.IP "lsp" 12 +Log specific field +.IP "lsi" 12 +Endurance group information +.IP "rae" 12 +Retain asynchronous events +.IP "uuidx" 12 +UUID selection, if supported +.IP "len" 12 +Length of provided user buffer to hold the log data in bytes +.IP "log" 12 +User space destination address to transfer the data +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_ana.2 b/doc/man/nvme_get_log_ana.2 new file mode 100644 index 00000000..af9fe716 --- /dev/null +++ b/doc/man/nvme_get_log_ana.2 @@ -0,0 +1,33 @@ +.TH "nvme_get_log_ana" 2 "nvme_get_log_ana" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_ana \- +.SH SYNOPSIS +.B "int" nvme_get_log_ana +.BI "(int " fd "," +.BI "enum nvme_log_ana_lsp " lsp "," +.BI "bool " rae "," +.BI "__u64 " offset "," +.BI "__u32 " len "," +.BI "void *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "lsp" 12 +Log specific, see \fIenum nvme_get_log_ana_lsp\fP +.IP "rae" 12 +Retain asynchronous events +.IP "offset" 12 +-- undescribed -- +.IP "len" 12 +The allocated length of the log page +.IP "log" 12 +User address to store the ana log +.SH "DESCRIPTION" +This log consists of a header describing the log and descriptors containing +the asymmetric namespace access information for ANA Groups that contain +namespaces that are attached to the controller processing the command. + +See \fIstruct nvme_ana_rsp_hdr\fP for the defintion of the returned structure. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_ana_groups.2 b/doc/man/nvme_get_log_ana_groups.2 new file mode 100644 index 00000000..228f6546 --- /dev/null +++ b/doc/man/nvme_get_log_ana_groups.2 @@ -0,0 +1,20 @@ +.TH "nvme_get_log_ana_groups" 2 "nvme_get_log_ana_groups" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_ana_groups \- +.SH SYNOPSIS +.B "int" nvme_get_log_ana_groups +.BI "(int " fd "," +.BI "bool " rae "," +.BI "__u32 " len "," +.BI "struct nvme_ana_group_desc *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "rae" 12 +Retain asynchronous events +.IP "len" 12 +-- undescribed -- +.IP "log" 12 +-- undescribed -- +.SH "DESCRIPTION" +See \fIstruct nvme_ana_group_desc\fP for the defintion of the returned structure. diff --git a/doc/man/nvme_get_log_changed_ns_list.2 b/doc/man/nvme_get_log_changed_ns_list.2 new file mode 100644 index 00000000..882541b9 --- /dev/null +++ b/doc/man/nvme_get_log_changed_ns_list.2 @@ -0,0 +1,22 @@ +.TH "nvme_get_log_changed_ns_list" 2 "nvme_get_log_changed_ns_list" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_changed_ns_list \- Retrieve namespace changed list +.SH SYNOPSIS +.B "int" nvme_get_log_changed_ns_list +.BI "(int " fd "," +.BI "bool " rae "," +.BI "struct nvme_ns_list *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "rae" 12 +Retain asynchronous events +.IP "log" 12 +-- undescribed -- +.SH "DESCRIPTION" +This log page is used to describe namespaces attached to this controller +that have changed since the last time the namespace was identified, been +added, or deleted. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_cmd_effects.2 b/doc/man/nvme_get_log_cmd_effects.2 new file mode 100644 index 00000000..cedf2536 --- /dev/null +++ b/doc/man/nvme_get_log_cmd_effects.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_log_cmd_effects" 2 "nvme_get_log_cmd_effects" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_cmd_effects \- Retrieve nvme command effects log +.SH SYNOPSIS +.B "int" nvme_get_log_cmd_effects +.BI "(int " fd "," +.BI "struct nvme_cmd_effects_log *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "log" 12 +-- undescribed -- +.SH "DESCRIPTION" +This log page is used to describe the commands that the controller supports +and the effects of those commands on the state of the NVM subsystem. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_create_telemetry_host.2 b/doc/man/nvme_get_log_create_telemetry_host.2 new file mode 100644 index 00000000..929d957a --- /dev/null +++ b/doc/man/nvme_get_log_create_telemetry_host.2 @@ -0,0 +1,12 @@ +.TH "nvme_get_log_create_telemetry_host" 2 "nvme_get_log_create_telemetry_host" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_create_telemetry_host \- +.SH SYNOPSIS +.B "int" nvme_get_log_create_telemetry_host +.BI "(int " fd "," +.BI "struct nvme_telemetry_log *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +-- undescribed -- +.IP "log" 12 +-- undescribed -- diff --git a/doc/man/nvme_get_log_device_self_test.2 b/doc/man/nvme_get_log_device_self_test.2 new file mode 100644 index 00000000..bc236b5d --- /dev/null +++ b/doc/man/nvme_get_log_device_self_test.2 @@ -0,0 +1,19 @@ +.TH "nvme_get_log_device_self_test" 2 "nvme_get_log_device_self_test" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_device_self_test \- Retrieve the device self test log +.SH SYNOPSIS +.B "int" nvme_get_log_device_self_test +.BI "(int " fd "," +.BI "struct nvme_self_test_log *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "log" 12 +Userspace address of the log payload +.SH "DESCRIPTION" +The log page is used to indicate the status of an in progress self test and +the percent complete of that operation, and the results of the previous 20 +self-test operations. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_discovery.2 b/doc/man/nvme_get_log_discovery.2 new file mode 100644 index 00000000..7eae9237 --- /dev/null +++ b/doc/man/nvme_get_log_discovery.2 @@ -0,0 +1,27 @@ +.TH "nvme_get_log_discovery" 2 "nvme_get_log_discovery" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_discovery \- +.SH SYNOPSIS +.B "int" nvme_get_log_discovery +.BI "(int " fd "," +.BI "bool " rae "," +.BI "__u32 " offset "," +.BI "__u32 " len "," +.BI "void *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "rae" 12 +Retain asynchronous events +.IP "offset" 12 +Offset of this log to retrieve +.IP "len" 12 +The allocated size for this portion of the log +.IP "log" 12 +User address to store the discovery log +.SH "DESCRIPTION" +Supported only by fabrics discovery controllers, returning discovery +records. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_endurance_group.2 b/doc/man/nvme_get_log_endurance_group.2 new file mode 100644 index 00000000..a8516a62 --- /dev/null +++ b/doc/man/nvme_get_log_endurance_group.2 @@ -0,0 +1,25 @@ +.TH "nvme_get_log_endurance_group" 2 "nvme_get_log_endurance_group" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_endurance_group \- +.SH SYNOPSIS +.B "int" nvme_get_log_endurance_group +.BI "(int " fd "," +.BI "__u16 " endgid "," +.BI "struct nvme_endurance_group_log *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "endgid" 12 +Starting group identifier to return in the list +.IP "log" 12 +User address to store the endurance log +.SH "DESCRIPTION" +This log page indicates if an Endurance Group Event has occurred for a +particular Endurance Group. If an Endurance Group Event has occurred, the +details of the particular event are included in the Endurance Group +Information log page for that Endurance Group. An asynchronous event is +generated when an entry for an Endurance Group is newly added to this log +page. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_endurance_grp_evt.2 b/doc/man/nvme_get_log_endurance_grp_evt.2 new file mode 100644 index 00000000..66bfe7fe --- /dev/null +++ b/doc/man/nvme_get_log_endurance_grp_evt.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_log_endurance_grp_evt" 2 "nvme_get_log_endurance_grp_evt" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_endurance_grp_evt \- +.SH SYNOPSIS +.B "int" nvme_get_log_endurance_grp_evt +.BI "(int " fd "," +.BI "bool " rae "," +.BI "__u32 " offset "," +.BI "__u32 " len "," +.BI "void *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "rae" 12 +Retain asynchronous events +.IP "offset" 12 +-- undescribed -- +.IP "len" 12 +-- undescribed -- +.IP "log" 12 +-- undescribed -- diff --git a/doc/man/nvme_get_log_error.2 b/doc/man/nvme_get_log_error.2 new file mode 100644 index 00000000..3ae17f1d --- /dev/null +++ b/doc/man/nvme_get_log_error.2 @@ -0,0 +1,25 @@ +.TH "nvme_get_log_error" 2 "nvme_get_log_error" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_error \- Retrieve nvme error log +.SH SYNOPSIS +.B "int" nvme_get_log_error +.BI "(int " fd "," +.BI "unsigned " nr_entries "," +.BI "bool " rae "," +.BI "struct nvme_error_log_page *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nr_entries" 12 +-- undescribed -- +.IP "rae" 12 +Retain asynchronous events +.IP "log" 12 +-- undescribed -- +.SH "DESCRIPTION" +This log page is used to describe extended error information for a command +that completed with error, or may report an error that is not specific to a +particular command. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_fw_slot.2 b/doc/man/nvme_get_log_fw_slot.2 new file mode 100644 index 00000000..8c956525 --- /dev/null +++ b/doc/man/nvme_get_log_fw_slot.2 @@ -0,0 +1,22 @@ +.TH "nvme_get_log_fw_slot" 2 "nvme_get_log_fw_slot" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_fw_slot \- Retrieves the controller firmware log +.SH SYNOPSIS +.B "int" nvme_get_log_fw_slot +.BI "(int " fd "," +.BI "bool " rae "," +.BI "struct nvme_firmware_slot *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "rae" 12 +Retain asynchronous events +.IP "log" 12 +-- undescribed -- +.SH "DESCRIPTION" +This log page is used to describe the firmware revision stored in each +firmware slot supported. The firmware revision is indicated as an ASCII +string. The log page also indicates the active slot number. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_lba_status.2 b/doc/man/nvme_get_log_lba_status.2 new file mode 100644 index 00000000..6ada5ec8 --- /dev/null +++ b/doc/man/nvme_get_log_lba_status.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_log_lba_status" 2 "nvme_get_log_lba_status" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_lba_status \- +.SH SYNOPSIS +.B "int" nvme_get_log_lba_status +.BI "(int " fd "," +.BI "bool " rae "," +.BI "__u64 " offset "," +.BI "__u32 " len "," +.BI "void *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "rae" 12 +Retain asynchronous events +.IP "offset" 12 +-- undescribed -- +.IP "len" 12 +-- undescribed -- +.IP "log" 12 +-- undescribed -- diff --git a/doc/man/nvme_get_log_page.2 b/doc/man/nvme_get_log_page.2 new file mode 100644 index 00000000..09a71826 --- /dev/null +++ b/doc/man/nvme_get_log_page.2 @@ -0,0 +1,25 @@ +.TH "nvme_get_log_page" 2 "nvme_get_log_page" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_page \- +.SH SYNOPSIS +.B "int" nvme_get_log_page +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u8 " log_id "," +.BI "bool " rae "," +.BI "__u32 " data_len "," +.BI "void *" data ");" +.SH ARGUMENTS +.IP "fd" 12 +-- undescribed -- +.IP "nsid" 12 +-- undescribed -- +.IP "log_id" 12 +-- undescribed -- +.IP "rae" 12 +-- undescribed -- +.IP "data_len" 12 +-- undescribed -- +.IP "data" 12 +.SH "DESCRIPTION" +Calls \fB__nvme_get_log_page\fP with a default 4k transfer length. diff --git a/doc/man/nvme_get_log_predictable_lat_event.2 b/doc/man/nvme_get_log_predictable_lat_event.2 new file mode 100644 index 00000000..d5ed8c07 --- /dev/null +++ b/doc/man/nvme_get_log_predictable_lat_event.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_log_predictable_lat_event" 2 "nvme_get_log_predictable_lat_event" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_predictable_lat_event \- +.SH SYNOPSIS +.B "int" nvme_get_log_predictable_lat_event +.BI "(int " fd "," +.BI "bool " rae "," +.BI "__u32 " offset "," +.BI "__u32 " len "," +.BI "void *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "rae" 12 +Retain asynchronous events +.IP "offset" 12 +-- undescribed -- +.IP "len" 12 +-- undescribed -- +.IP "log" 12 +-- undescribed -- diff --git a/doc/man/nvme_get_log_predictable_lat_nvmset.2 b/doc/man/nvme_get_log_predictable_lat_nvmset.2 new file mode 100644 index 00000000..2302b013 --- /dev/null +++ b/doc/man/nvme_get_log_predictable_lat_nvmset.2 @@ -0,0 +1,17 @@ +.TH "nvme_get_log_predictable_lat_nvmset" 2 "nvme_get_log_predictable_lat_nvmset" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_predictable_lat_nvmset \- +.SH SYNOPSIS +.B "int" nvme_get_log_predictable_lat_nvmset +.BI "(int " fd "," +.BI "__u16 " nvmsetid "," +.BI "struct nvme_nvmset_predictable_lat_log *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +-- undescribed -- +.IP "nvmsetid" 12 +.IP "log" 12 +-- undescribed -- +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_reservation.2 b/doc/man/nvme_get_log_reservation.2 new file mode 100644 index 00000000..8311e66f --- /dev/null +++ b/doc/man/nvme_get_log_reservation.2 @@ -0,0 +1,15 @@ +.TH "nvme_get_log_reservation" 2 "nvme_get_log_reservation" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_reservation \- +.SH SYNOPSIS +.B "int" nvme_get_log_reservation +.BI "(int " fd "," +.BI "bool " rae "," +.BI "struct nvme_resv_notification_log *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "rae" 12 +Retain asynchronous events +.IP "log" 12 +-- undescribed -- diff --git a/doc/man/nvme_get_log_sanitize.2 b/doc/man/nvme_get_log_sanitize.2 new file mode 100644 index 00000000..177ffe2b --- /dev/null +++ b/doc/man/nvme_get_log_sanitize.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_log_sanitize" 2 "nvme_get_log_sanitize" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_sanitize \- +.SH SYNOPSIS +.B "int" nvme_get_log_sanitize +.BI "(int " fd "," +.BI "bool " rae "," +.BI "struct nvme_sanitize_log_page *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "rae" 12 +Retain asynchronous events +.IP "log" 12 +User address to store the sanitize log +.SH "DESCRIPTION" +The Sanitize Status log page is used to report sanitize operation time +estimates and information about the most recent sanitize operation. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_smart.2 b/doc/man/nvme_get_log_smart.2 new file mode 100644 index 00000000..ba619ecd --- /dev/null +++ b/doc/man/nvme_get_log_smart.2 @@ -0,0 +1,28 @@ +.TH "nvme_get_log_smart" 2 "nvme_get_log_smart" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_smart \- Retrieve nvme smart log +.SH SYNOPSIS +.B "int" nvme_get_log_smart +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "bool " rae "," +.BI "struct nvme_smart_log *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Optional namespace identifier +.IP "rae" 12 +Retain asynchronous events +.IP "log" 12 +-- undescribed -- +.SH "DESCRIPTION" +This log page is used to provide SMART and general health information. The +information provided is over the life of the controller and is retained +across power cycles. To request the controller log page, the namespace +identifier specified is FFFFFFFFh. The controller may also support +requesting the log page on a per namespace basis, as indicated by bit 0 of +the LPA field in the Identify Controller data structure. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_log_telemetry_ctrl.2 b/doc/man/nvme_get_log_telemetry_ctrl.2 new file mode 100644 index 00000000..0a62767b --- /dev/null +++ b/doc/man/nvme_get_log_telemetry_ctrl.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_log_telemetry_ctrl" 2 "nvme_get_log_telemetry_ctrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_telemetry_ctrl \- +.SH SYNOPSIS +.B "int" nvme_get_log_telemetry_ctrl +.BI "(int " fd "," +.BI "bool " rae "," +.BI "__u64 " offset "," +.BI "__u32 " len "," +.BI "void *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "rae" 12 +Retain asynchronous events +.IP "offset" 12 +Offset into the telemetry data +.IP "len" 12 +Length of provided user buffer to hold the log data in bytes +.IP "log" 12 +User address for log page data diff --git a/doc/man/nvme_get_log_telemetry_host.2 b/doc/man/nvme_get_log_telemetry_host.2 new file mode 100644 index 00000000..2aff066b --- /dev/null +++ b/doc/man/nvme_get_log_telemetry_host.2 @@ -0,0 +1,24 @@ +.TH "nvme_get_log_telemetry_host" 2 "nvme_get_log_telemetry_host" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_log_telemetry_host \- +.SH SYNOPSIS +.B "int" nvme_get_log_telemetry_host +.BI "(int " fd "," +.BI "__u64 " offset "," +.BI "__u32 " len "," +.BI "void *" log ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "offset" 12 +Offset into the telemetry data +.IP "len" 12 +Length of provided user buffer to hold the log data in bytes +.IP "log" 12 +User address for log page data +.SH "DESCRIPTION" +Retreives the Telemetry Host-Initiated log page at the requested offset +using the previously existing capture. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_new_host_telemetry.2 b/doc/man/nvme_get_new_host_telemetry.2 new file mode 100644 index 00000000..2084fc68 --- /dev/null +++ b/doc/man/nvme_get_new_host_telemetry.2 @@ -0,0 +1,14 @@ +.TH "nvme_get_new_host_telemetry" 2 "nvme_get_new_host_telemetry" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_new_host_telemetry \- +.SH SYNOPSIS +.B "int" nvme_get_new_host_telemetry +.BI "(int " fd "," +.BI "void **" buf "," +.BI "__u32 *" log_size ");" +.SH ARGUMENTS +.IP "fd" 12 +-- undescribed -- +.IP "buf" 12 +-- undescribed -- +.IP "log_size" 12 diff --git a/doc/man/nvme_get_ns_attr.2 b/doc/man/nvme_get_ns_attr.2 new file mode 100644 index 00000000..b0155581 --- /dev/null +++ b/doc/man/nvme_get_ns_attr.2 @@ -0,0 +1,11 @@ +.TH "nvme_get_ns_attr" 2 "nvme_get_ns_attr" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_ns_attr \- +.SH SYNOPSIS +.B "char *" nvme_get_ns_attr +.BI "(nvme_ns_t " n "," +.BI "const char *" attr ");" +.SH ARGUMENTS +.IP "n" 12 +-- undescribed -- +.IP "attr" 12 diff --git a/doc/man/nvme_get_nsid.2 b/doc/man/nvme_get_nsid.2 new file mode 100644 index 00000000..0b82f628 --- /dev/null +++ b/doc/man/nvme_get_nsid.2 @@ -0,0 +1,14 @@ +.TH "nvme_get_nsid" 2 "nvme_get_nsid" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_nsid \- Retrieve the NSID from a namespace file descriptor +.SH SYNOPSIS +.B "int" nvme_get_nsid +.BI "(int " fd ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme namespace +.SH "DESCRIPTION" +This should only be sent to namespace handles, not to controllers. +.SH "RETURN" +The namespace identifier if a succecssful or -1 with errno set +otherwise. diff --git a/doc/man/nvme_get_path_attr.2 b/doc/man/nvme_get_path_attr.2 new file mode 100644 index 00000000..bf798592 --- /dev/null +++ b/doc/man/nvme_get_path_attr.2 @@ -0,0 +1,11 @@ +.TH "nvme_get_path_attr" 2 "nvme_get_path_attr" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_path_attr \- +.SH SYNOPSIS +.B "char *" nvme_get_path_attr +.BI "(nvme_path_t " p "," +.BI "const char *" attr ");" +.SH ARGUMENTS +.IP "p" 12 +-- undescribed -- +.IP "attr" 12 diff --git a/doc/man/nvme_get_property.2 b/doc/man/nvme_get_property.2 new file mode 100644 index 00000000..30469f28 --- /dev/null +++ b/doc/man/nvme_get_property.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_property" 2 "nvme_get_property" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_property \- Get a controller property +.SH SYNOPSIS +.B "int" nvme_get_property +.BI "(int " fd "," +.BI "int " offset "," +.BI "__u64 *" value ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "offset" 12 +Property offset from the base to retrieve +.IP "value" 12 +Where the property's value will be stored on success +.SH "DESCRIPTION" +This is an NVMe-over-Fabrics specific command, not applicable to PCIe. These +properties align to the PCI MMIO controller registers. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_get_subsys_attr.2 b/doc/man/nvme_get_subsys_attr.2 new file mode 100644 index 00000000..5691cc59 --- /dev/null +++ b/doc/man/nvme_get_subsys_attr.2 @@ -0,0 +1,11 @@ +.TH "nvme_get_subsys_attr" 2 "nvme_get_subsys_attr" "February 2020" "libnvme Manual" +.SH NAME +nvme_get_subsys_attr \- +.SH SYNOPSIS +.B "char *" nvme_get_subsys_attr +.BI "(nvme_subsystem_t " s "," +.BI "const char *" attr ");" +.SH ARGUMENTS +.IP "s" 12 +-- undescribed -- +.IP "attr" 12 diff --git a/doc/man/nvme_identify.2 b/doc/man/nvme_identify.2 new file mode 100644 index 00000000..cbf56d81 --- /dev/null +++ b/doc/man/nvme_identify.2 @@ -0,0 +1,33 @@ +.TH "nvme_identify" 2 "nvme_identify" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify \- Send the NVMe Identify command +.SH SYNOPSIS +.B "int" nvme_identify +.BI "(int " fd "," +.BI "enum nvme_identify_cns " cns "," +.BI "__u32 " nsid "," +.BI "__u16 " cntid "," +.BI "__u16 " nvmsetid "," +.BI "__u8 " uuidx "," +.BI "void *" data ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "cns" 12 +The Controller or Namespace structure, see \fIenum\fP nvme_identify_cns +.IP "nsid" 12 +Namespace identifier, if applicable +.IP "cntid" 12 +The Controller Identifier, if applicable +.IP "nvmsetid" 12 +The NVMe Set ID if CNS is 04h +.IP "uuidx" 12 +UUID Index if controller supports this id selection method +.IP "data" 12 +User space destination address to transfer the data +.SH "DESCRIPTION" +The Identify command returns a data buffer that describes information about +the NVM subsystem, the controller or the namespace(s). +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_identify_active_ns_list.2 b/doc/man/nvme_identify_active_ns_list.2 new file mode 100644 index 00000000..2edd8fae --- /dev/null +++ b/doc/man/nvme_identify_active_ns_list.2 @@ -0,0 +1,24 @@ +.TH "nvme_identify_active_ns_list" 2 "nvme_identify_active_ns_list" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_active_ns_list \- Retrieves active namespaces id list +.SH SYNOPSIS +.B "int" nvme_identify_active_ns_list +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "struct nvme_ns_list *" list ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Return namespaces greater than this identifer +.IP "list" 12 +-- undescribed -- +.SH "DESCRIPTION" +A list of 1024 namespace IDs is returned to the host containing NSIDs in +increasing order that are greater than the value specified in the Namespace +Identifier (nsid) field of the command. + +See \fIstruct nvme_ns_list\fP for the definition of the returned structure. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_identify_allocated_ns.2 b/doc/man/nvme_identify_allocated_ns.2 new file mode 100644 index 00000000..ae37636e --- /dev/null +++ b/doc/man/nvme_identify_allocated_ns.2 @@ -0,0 +1,18 @@ +.TH "nvme_identify_allocated_ns" 2 "nvme_identify_allocated_ns" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_allocated_ns \- Same as nvme_identify_ns, but only for allocated namespaces +.SH SYNOPSIS +.B "int" nvme_identify_allocated_ns +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "struct nvme_id_ns *" ns ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace to identify +.IP "ns" 12 +User space destination address to transfer the data +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_identify_allocated_ns_list.2 b/doc/man/nvme_identify_allocated_ns_list.2 new file mode 100644 index 00000000..d44a9c01 --- /dev/null +++ b/doc/man/nvme_identify_allocated_ns_list.2 @@ -0,0 +1,24 @@ +.TH "nvme_identify_allocated_ns_list" 2 "nvme_identify_allocated_ns_list" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_allocated_ns_list \- Retrieves allocated namespace id list +.SH SYNOPSIS +.B "int" nvme_identify_allocated_ns_list +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "struct nvme_ns_list *" list ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Return namespaces greater than this identifer +.IP "list" 12 +-- undescribed -- +.SH "DESCRIPTION" +A list of 1024 namespace IDs is returned to the host containing NSIDs in +increasing order that are greater than the value specified in the Namespace +Identifier (nsid) field of the command. + +See \fIstruct nvme_ns_list\fP for the definition of the returned structure. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_identify_ctrl.2 b/doc/man/nvme_identify_ctrl.2 new file mode 100644 index 00000000..32cde036 --- /dev/null +++ b/doc/man/nvme_identify_ctrl.2 @@ -0,0 +1,20 @@ +.TH "nvme_identify_ctrl" 2 "nvme_identify_ctrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_ctrl \- Retrieves nvme identify controller +.SH SYNOPSIS +.B "int" nvme_identify_ctrl +.BI "(int " fd "," +.BI "struct nvme_id_ctrl *" id ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +id: User space destination address to transfer the data, +.IP "id" 12 +-- undescribed -- +.SH "DESCRIPTION" +Sends nvme identify with CNS value NVME_IDENTIFY_CNS_CTRL. + +See \fIstruct nvme_id_ctrl\fP for details on the data returned. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_identify_ctrl_list.2 b/doc/man/nvme_identify_ctrl_list.2 new file mode 100644 index 00000000..a0aa18dd --- /dev/null +++ b/doc/man/nvme_identify_ctrl_list.2 @@ -0,0 +1,24 @@ +.TH "nvme_identify_ctrl_list" 2 "nvme_identify_ctrl_list" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_ctrl_list \- Retrieves identify controller list +.SH SYNOPSIS +.B "int" nvme_identify_ctrl_list +.BI "(int " fd "," +.BI "__u16 " cntid "," +.BI "struct nvme_ctrl_list *" ctrlist ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "cntid" 12 +-- undescribed -- +.IP "ctrlist" 12 +-- undescribed -- +.SH "DESCRIPTION" +Up to 2047 controller identifiers is returned containing a controller +identifier greater than or equal to the controller identifier specified in +\fIcntid\fP. + +See \fIstruct nvme_ctrl_list\fP for a definition of the structure returned. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_identify_ns.2 b/doc/man/nvme_identify_ns.2 new file mode 100644 index 00000000..fa6e8b57 --- /dev/null +++ b/doc/man/nvme_identify_ns.2 @@ -0,0 +1,29 @@ +.TH "nvme_identify_ns" 2 "nvme_identify_ns" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_ns \- Retrieves nvme identify namespace +.SH SYNOPSIS +.B "int" nvme_identify_ns +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "struct nvme_id_ns *" ns ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace to identify +.IP "ns" 12 +User space destination address to transfer the data +.SH "DESCRIPTION" +If the Namespace Identifier (NSID) field specifies an active NSID, then the +Identify Namespace data structure is returned to the host for that specified +namespace. + +If the controller supports the Namespace Management capability and the NSID +field is set to NVME_NSID_ALL, then the controller returns an Identify Namespace +data structure that specifies capabilities that are common across namespaces +for this controller. + +See \fIstruct nvme_id_ns\fP for details on the structure returned. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_identify_ns_descs.2 b/doc/man/nvme_identify_ns_descs.2 new file mode 100644 index 00000000..28673b31 --- /dev/null +++ b/doc/man/nvme_identify_ns_descs.2 @@ -0,0 +1,26 @@ +.TH "nvme_identify_ns_descs" 2 "nvme_identify_ns_descs" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_ns_descs \- Retrieves namespace descriptor list +.SH SYNOPSIS +.B "int" nvme_identify_ns_descs +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "struct nvme_ns_id_desc *" descs ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +The namespace id to retrieve destriptors +.IP "descs" 12 +User space destination address to transfer the data +.SH "DESCRIPTION" +A list of Namespace Identification Descriptor structures is returned to the +host for the namespace specified in the Namespace Identifier (NSID) field if +it is an active NSID. + +The data returned is in the form of an arrray of 'struct nvme_ns_id_desc'. + +See \fIstruct nvme_ns_id_desc\fP for the definition of the returned structure. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_identify_ns_granularity.2 b/doc/man/nvme_identify_ns_granularity.2 new file mode 100644 index 00000000..1987855c --- /dev/null +++ b/doc/man/nvme_identify_ns_granularity.2 @@ -0,0 +1,22 @@ +.TH "nvme_identify_ns_granularity" 2 "nvme_identify_ns_granularity" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_ns_granularity \- Retrieves namespace granularity identification +.SH SYNOPSIS +.B "int" nvme_identify_ns_granularity +.BI "(int " fd "," +.BI "struct nvme_id_ns_granularity_list *" list ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "list" 12 +-- undescribed -- +.SH "DESCRIPTION" +If the controller supports reporting of Namespace Granularity, then a +Namespace Granularity List is returned to the host for up to sixteen +namespace granularity descriptors + +See \fIstruct nvme_id_ns_granularity_list\fP for the definition of the returned +structure. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_identify_nsid_ctrl_list.2 b/doc/man/nvme_identify_nsid_ctrl_list.2 new file mode 100644 index 00000000..484dd981 --- /dev/null +++ b/doc/man/nvme_identify_nsid_ctrl_list.2 @@ -0,0 +1,26 @@ +.TH "nvme_identify_nsid_ctrl_list" 2 "nvme_identify_nsid_ctrl_list" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_nsid_ctrl_list \- +.SH SYNOPSIS +.B "int" nvme_identify_nsid_ctrl_list +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u16 " cntid "," +.BI "struct nvme_ctrl_list *" ctrlist ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Return controllers that are attached to this nsid +.IP "cntid" 12 +-- undescribed -- +.IP "ctrlist" 12 +-- undescribed -- +.SH "DESCRIPTION" +Up to 2047 controller identifiers is returned containing a controller +identifier greater than or equal to the controller identifier specified in +\fIcntid\fP. + +See \fIstruct nvme_ctrl_list\fP for a definition of the structure returned. +.SH "RETURN" +The nvme command status if a response was received or -1 diff --git a/doc/man/nvme_identify_nvmset_list.2 b/doc/man/nvme_identify_nvmset_list.2 new file mode 100644 index 00000000..5b794549 --- /dev/null +++ b/doc/man/nvme_identify_nvmset_list.2 @@ -0,0 +1,25 @@ +.TH "nvme_identify_nvmset_list" 2 "nvme_identify_nvmset_list" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_nvmset_list \- Retrieves NVM Set List +.SH SYNOPSIS +.B "int" nvme_identify_nvmset_list +.BI "(int " fd "," +.BI "__u16 " nvmsetid "," +.BI "struct nvme_id_nvmset_list *" nvmset ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nvmsetid" 12 +-- undescribed -- +.IP "nvmset" 12 +User space destination address to transfer the data +.SH "DESCRIPTION" +Retrieves an NVM Set List, struct nvme_id_nvmset. The data structure is an +ordered list by NVM Set Identifier, starting with the first NVM Set +Identifier supported by the NVM subsystem that is equal to or greater than +the NVM Set Identifier. + +See \fIstruct nvme_id_nvmset_list\fP for the defintion of the returned structure. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_identify_primary_ctrl.2 b/doc/man/nvme_identify_primary_ctrl.2 new file mode 100644 index 00000000..c0d31678 --- /dev/null +++ b/doc/man/nvme_identify_primary_ctrl.2 @@ -0,0 +1,19 @@ +.TH "nvme_identify_primary_ctrl" 2 "nvme_identify_primary_ctrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_primary_ctrl \- Retrieve NVMe Primary Controller identification &fd: +.SH SYNOPSIS +.B "int" nvme_identify_primary_ctrl +.BI "(int " fd "," +.BI "__u16 " cntid "," +.BI "struct nvme_primary_ctrl_cap *" cap ");" +.SH ARGUMENTS +.IP "fd" 12 +-- undescribed -- +.IP "cntid" 12 +-- undescribed -- +.IP "cap" 12 +.SH "DESCRIPTION" +See \fIstruct nvme_primary_ctrl_cap\fP for the defintion of the returned structure, \fIcap\fP. +.SH "RETURN" +The nvme command status if a response was received or -1 +with errno set otherwise. diff --git a/doc/man/nvme_identify_secondary_ctrl_list.2 b/doc/man/nvme_identify_secondary_ctrl_list.2 new file mode 100644 index 00000000..976418aa --- /dev/null +++ b/doc/man/nvme_identify_secondary_ctrl_list.2 @@ -0,0 +1,26 @@ +.TH "nvme_identify_secondary_ctrl_list" 2 "nvme_identify_secondary_ctrl_list" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_secondary_ctrl_list \- Retrieves secondary controller list +.SH SYNOPSIS +.B "int" nvme_identify_secondary_ctrl_list +.BI "(int " fd "," +.BI "__u16 " cntid "," +.BI "struct nvme_secondary_ctrl_list *" list ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "cntid" 12 +Return controllers starting at this identifier +.IP "list" 12 +-- undescribed -- +.SH "DESCRIPTION" +A Secondary Controller List is returned to the host for up to 127 secondary +controllers associated with the primary controller processing this command. +The list contains entries for controller identifiers greater than or equal +to the value specified in the Controller Identifier (cntid). + +See \fIstruct nvme_secondary_ctrls_list\fP for a defintion of the returned +structure. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_identify_uuid.2 b/doc/man/nvme_identify_uuid.2 new file mode 100644 index 00000000..2e4c28f0 --- /dev/null +++ b/doc/man/nvme_identify_uuid.2 @@ -0,0 +1,20 @@ +.TH "nvme_identify_uuid" 2 "nvme_identify_uuid" "February 2020" "libnvme Manual" +.SH NAME +nvme_identify_uuid \- Retrieves device's UUIDs +.SH SYNOPSIS +.B "int" nvme_identify_uuid +.BI "(int " fd "," +.BI "struct nvme_id_uuid_list *" list ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "list" 12 +-- undescribed -- +.SH "DESCRIPTION" +Each UUID List entry is either 0h, the NVMe Invalid UUID, or a valid UUID. +Valid UUIDs are those which are non-zero and are not the NVMe Invalid UUID. + +See \fIstruct nvme_id_uuid_list\fP for the definition of the returned structure. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_io_passthru.2 b/doc/man/nvme_io_passthru.2 new file mode 100644 index 00000000..beb467c9 --- /dev/null +++ b/doc/man/nvme_io_passthru.2 @@ -0,0 +1,71 @@ +.TH "nvme_io_passthru" 2 "nvme_io_passthru" "February 2020" "libnvme Manual" +.SH NAME +nvme_io_passthru \- Submit an nvme io passthrough command +.SH SYNOPSIS +.B "int" nvme_io_passthru +.BI "(int " fd "," +.BI "__u8 " opcode "," +.BI "__u8 " flags "," +.BI "__u16 " rsvd "," +.BI "__u32 " nsid "," +.BI "__u32 " cdw2 "," +.BI "__u32 " cdw3 "," +.BI "__u32 " cdw10 "," +.BI "__u32 " cdw11 "," +.BI "__u32 " cdw12 "," +.BI "__u32 " cdw13 "," +.BI "__u32 " cdw14 "," +.BI "__u32 " cdw15 "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 " metadata_len "," +.BI "void *" metadata "," +.BI "__u32 " timeout_ms "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "opcode" 12 +The nvme io command to send +.IP "flags" 12 +NVMe command flags (not used) +.IP "rsvd" 12 +Reserevd for future use +.IP "nsid" 12 +Namespace identifier +.IP "cdw2" 12 +Command dword 2 +.IP "cdw3" 12 +Command dword 3 +.IP "cdw10" 12 +Command dword 10 +.IP "cdw11" 12 +Command dword 11 +.IP "cdw12" 12 +Command dword 12 +.IP "cdw13" 12 +Command dword 13 +.IP "cdw14" 12 +Command dword 14 +.IP "cdw15" 12 +Command dword 15 +.IP "data_len" 12 +Length of the data transfered in this command in bytes +.IP "data" 12 +Pointer to user address of the data buffer +.IP "metadata_len" 12 +Length of metadata transfered in this command +.IP "metadata" 12 +Pointer to user address of the metadata buffer +.IP "timeout_ms" 12 +How long the kernel waits for the command to complete +.IP "result" 12 +Optional field to return the result from the CQE dword 0 +.SH "DESCRIPTION" +Parameterized form of \fBnvme_submit_io_passthru\fP. This sets up and submits +a \fIstruct nvme_passthru_cmd\fP. + +Known values for \fIopcode\fP are defined in \fIenum nvme_io_opcode\fP. +.SH "RETURN" +The nvme command status if a response was received or -1 +with errno set otherwise. diff --git a/doc/man/nvme_io_passthru64.2 b/doc/man/nvme_io_passthru64.2 new file mode 100644 index 00000000..9456bbc2 --- /dev/null +++ b/doc/man/nvme_io_passthru64.2 @@ -0,0 +1,71 @@ +.TH "nvme_io_passthru64" 2 "nvme_io_passthru64" "February 2020" "libnvme Manual" +.SH NAME +nvme_io_passthru64 \- Submit an nvme io passthrough command +.SH SYNOPSIS +.B "int" nvme_io_passthru64 +.BI "(int " fd "," +.BI "__u8 " opcode "," +.BI "__u8 " flags "," +.BI "__u16 " rsvd "," +.BI "__u32 " nsid "," +.BI "__u32 " cdw2 "," +.BI "__u32 " cdw3 "," +.BI "__u32 " cdw10 "," +.BI "__u32 " cdw11 "," +.BI "__u32 " cdw12 "," +.BI "__u32 " cdw13 "," +.BI "__u32 " cdw14 "," +.BI "__u32 " cdw15 "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 " metadata_len "," +.BI "void *" metadata "," +.BI "__u32 " timeout_ms "," +.BI "__u64 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "opcode" 12 +The nvme io command to send +.IP "flags" 12 +NVMe command flags (not used) +.IP "rsvd" 12 +Reserevd for future use +.IP "nsid" 12 +Namespace identifier +.IP "cdw2" 12 +Command dword 2 +.IP "cdw3" 12 +Command dword 3 +.IP "cdw10" 12 +Command dword 10 +.IP "cdw11" 12 +Command dword 11 +.IP "cdw12" 12 +Command dword 12 +.IP "cdw13" 12 +Command dword 13 +.IP "cdw14" 12 +Command dword 14 +.IP "cdw15" 12 +Command dword 15 +.IP "data_len" 12 +Length of the data transfered in this command in bytes +.IP "data" 12 +Pointer to user address of the data buffer +.IP "metadata_len" 12 +Length of metadata transfered in this command +.IP "metadata" 12 +Pointer to user address of the metadata buffer +.IP "timeout_ms" 12 +How long the kernel waits for the command to complete +.IP "result" 12 +Optional field to return the result from the CQE dword 0 +.SH "DESCRIPTION" +Parameterized form of \fBnvme_submit_io_passthru64\fP. This sets up and submits +a \fIstruct nvme_passthru_cmd64\fP. + +Known values for \fIopcode\fP are defined in \fIenum nvme_io_opcode\fP. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_namespace_attach_ctrls.2 b/doc/man/nvme_namespace_attach_ctrls.2 new file mode 100644 index 00000000..1459ed4a --- /dev/null +++ b/doc/man/nvme_namespace_attach_ctrls.2 @@ -0,0 +1,21 @@ +.TH "nvme_namespace_attach_ctrls" 2 "nvme_namespace_attach_ctrls" "February 2020" "libnvme Manual" +.SH NAME +nvme_namespace_attach_ctrls \- Attach namespace to controller(s) +.SH SYNOPSIS +.B "int" nvme_namespace_attach_ctrls +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u16 " num_ctrls "," +.BI "__u16 *" ctrlist ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID to attach +.IP "num_ctrls" 12 +Number of controllers in ctrlist +.IP "ctrlist" 12 +List of controller IDs to perform the attach action +.SH "RETURN" +The nvme command status if a response was received or -1 +with errno set otherwise. diff --git a/doc/man/nvme_namespace_detach_ctrls.2 b/doc/man/nvme_namespace_detach_ctrls.2 new file mode 100644 index 00000000..dfc12eae --- /dev/null +++ b/doc/man/nvme_namespace_detach_ctrls.2 @@ -0,0 +1,21 @@ +.TH "nvme_namespace_detach_ctrls" 2 "nvme_namespace_detach_ctrls" "February 2020" "libnvme Manual" +.SH NAME +nvme_namespace_detach_ctrls \- Detach namespace from controller(s) +.SH SYNOPSIS +.B "int" nvme_namespace_detach_ctrls +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u16 " num_ctrls "," +.BI "__u16 *" ctrlist ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID to detach +.IP "num_ctrls" 12 +Number of controllers in ctrlist +.IP "ctrlist" 12 +List of controller IDs to perform the detach action +.SH "RETURN" +The nvme command status if a response was received or -1 +with errno set otherwise. diff --git a/doc/man/nvme_namespace_filter.2 b/doc/man/nvme_namespace_filter.2 new file mode 100644 index 00000000..35cdfdeb --- /dev/null +++ b/doc/man/nvme_namespace_filter.2 @@ -0,0 +1,8 @@ +.TH "nvme_namespace_filter" 2 "nvme_namespace_filter" "February 2020" "libnvme Manual" +.SH NAME +nvme_namespace_filter \- +.SH SYNOPSIS +.B "int" nvme_namespace_filter +.BI "(const struct dirent *" d ");" +.SH ARGUMENTS +.IP "d" 12 diff --git a/doc/man/nvme_next_subsystem.2 b/doc/man/nvme_next_subsystem.2 new file mode 100644 index 00000000..c1449046 --- /dev/null +++ b/doc/man/nvme_next_subsystem.2 @@ -0,0 +1,11 @@ +.TH "nvme_next_subsystem" 2 "nvme_next_subsystem" "February 2020" "libnvme Manual" +.SH NAME +nvme_next_subsystem \- +.SH SYNOPSIS +.B "nvme_subsystem_t" nvme_next_subsystem +.BI "(nvme_root_t " r "," +.BI "nvme_subsystem_t " s ");" +.SH ARGUMENTS +.IP "r" 12 +-- undescribed -- +.IP "s" 12 diff --git a/doc/man/nvme_ns_attach.2 b/doc/man/nvme_ns_attach.2 new file mode 100644 index 00000000..48607c47 --- /dev/null +++ b/doc/man/nvme_ns_attach.2 @@ -0,0 +1,18 @@ +.TH "nvme_ns_attach" 2 "nvme_ns_attach" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_attach \- Attach or detach namespace to controller(s) +.SH SYNOPSIS +.B "int" nvme_ns_attach +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "enum nvme_ns_attach_sel " sel "," +.BI "struct nvme_ctrl_list *" ctrlist ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID to execute attach selection +.IP "sel" 12 +Attachment selection, see \fIenum nvme_ns_attach_sel\fP +.IP "ctrlist" 12 +Controller list to modify attachment state of nsid diff --git a/doc/man/nvme_ns_attach_ctrls.2 b/doc/man/nvme_ns_attach_ctrls.2 new file mode 100644 index 00000000..be131410 --- /dev/null +++ b/doc/man/nvme_ns_attach_ctrls.2 @@ -0,0 +1,15 @@ +.TH "nvme_ns_attach_ctrls" 2 "nvme_ns_attach_ctrls" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_attach_ctrls \- +.SH SYNOPSIS +.B "int" nvme_ns_attach_ctrls +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "struct nvme_ctrl_list *" ctrlist ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID to attach +.IP "ctrlist" 12 +Controller list to modify attachment state of nsid diff --git a/doc/man/nvme_ns_compare.2 b/doc/man/nvme_ns_compare.2 new file mode 100644 index 00000000..bf3f6118 --- /dev/null +++ b/doc/man/nvme_ns_compare.2 @@ -0,0 +1,17 @@ +.TH "nvme_ns_compare" 2 "nvme_ns_compare" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_compare \- +.SH SYNOPSIS +.B "int" nvme_ns_compare +.BI "(nvme_ns_t " n "," +.BI "void *" buf "," +.BI "off_t " offset "," +.BI "size_t " count ");" +.SH ARGUMENTS +.IP "n" 12 +-- undescribed -- +.IP "buf" 12 +-- undescribed -- +.IP "offset" 12 +-- undescribed -- +.IP "count" 12 diff --git a/doc/man/nvme_ns_dettach_ctrls.2 b/doc/man/nvme_ns_dettach_ctrls.2 new file mode 100644 index 00000000..9bc4df1b --- /dev/null +++ b/doc/man/nvme_ns_dettach_ctrls.2 @@ -0,0 +1,15 @@ +.TH "nvme_ns_dettach_ctrls" 2 "nvme_ns_dettach_ctrls" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_dettach_ctrls \- +.SH SYNOPSIS +.B "int" nvme_ns_dettach_ctrls +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "struct nvme_ctrl_list *" ctrlist ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID to dettach +.IP "ctrlist" 12 +Controller list to modify attachment state of nsid diff --git a/doc/man/nvme_ns_flush.2 b/doc/man/nvme_ns_flush.2 new file mode 100644 index 00000000..0d0cae6b --- /dev/null +++ b/doc/man/nvme_ns_flush.2 @@ -0,0 +1,8 @@ +.TH "nvme_ns_flush" 2 "nvme_ns_flush" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_flush \- +.SH SYNOPSIS +.B "int" nvme_ns_flush +.BI "(nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "n" 12 diff --git a/doc/man/nvme_ns_get_ctrl.2 b/doc/man/nvme_ns_get_ctrl.2 new file mode 100644 index 00000000..084cf2eb --- /dev/null +++ b/doc/man/nvme_ns_get_ctrl.2 @@ -0,0 +1,8 @@ +.TH "nvme_ns_get_ctrl" 2 "nvme_ns_get_ctrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_get_ctrl \- +.SH SYNOPSIS +.B "nvme_ctrl_t" nvme_ns_get_ctrl +.BI "(nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "n" 12 diff --git a/doc/man/nvme_ns_get_fd.2 b/doc/man/nvme_ns_get_fd.2 new file mode 100644 index 00000000..c65fea1b --- /dev/null +++ b/doc/man/nvme_ns_get_fd.2 @@ -0,0 +1,8 @@ +.TH "nvme_ns_get_fd" 2 "nvme_ns_get_fd" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_get_fd \- +.SH SYNOPSIS +.B "int" nvme_ns_get_fd +.BI "(nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "n" 12 diff --git a/doc/man/nvme_ns_get_lba_count.2 b/doc/man/nvme_ns_get_lba_count.2 new file mode 100644 index 00000000..77fc445f --- /dev/null +++ b/doc/man/nvme_ns_get_lba_count.2 @@ -0,0 +1,8 @@ +.TH "nvme_ns_get_lba_count" 2 "nvme_ns_get_lba_count" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_get_lba_count \- +.SH SYNOPSIS +.B "uint64_t" nvme_ns_get_lba_count +.BI "(nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "n" 12 diff --git a/doc/man/nvme_ns_get_lba_size.2 b/doc/man/nvme_ns_get_lba_size.2 new file mode 100644 index 00000000..9b3d2d86 --- /dev/null +++ b/doc/man/nvme_ns_get_lba_size.2 @@ -0,0 +1,8 @@ +.TH "nvme_ns_get_lba_size" 2 "nvme_ns_get_lba_size" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_get_lba_size \- +.SH SYNOPSIS +.B "int" nvme_ns_get_lba_size +.BI "(nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "n" 12 diff --git a/doc/man/nvme_ns_get_lba_util.2 b/doc/man/nvme_ns_get_lba_util.2 new file mode 100644 index 00000000..bbcef5a2 --- /dev/null +++ b/doc/man/nvme_ns_get_lba_util.2 @@ -0,0 +1,8 @@ +.TH "nvme_ns_get_lba_util" 2 "nvme_ns_get_lba_util" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_get_lba_util \- +.SH SYNOPSIS +.B "uint64_t" nvme_ns_get_lba_util +.BI "(nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "n" 12 diff --git a/doc/man/nvme_ns_get_name.2 b/doc/man/nvme_ns_get_name.2 new file mode 100644 index 00000000..351d848d --- /dev/null +++ b/doc/man/nvme_ns_get_name.2 @@ -0,0 +1,8 @@ +.TH "nvme_ns_get_name" 2 "nvme_ns_get_name" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_get_name \- +.SH SYNOPSIS +.B "const char *" nvme_ns_get_name +.BI "(nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "n" 12 diff --git a/doc/man/nvme_ns_get_nsid.2 b/doc/man/nvme_ns_get_nsid.2 new file mode 100644 index 00000000..a831344d --- /dev/null +++ b/doc/man/nvme_ns_get_nsid.2 @@ -0,0 +1,8 @@ +.TH "nvme_ns_get_nsid" 2 "nvme_ns_get_nsid" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_get_nsid \- +.SH SYNOPSIS +.B "int" nvme_ns_get_nsid +.BI "(nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "n" 12 diff --git a/doc/man/nvme_ns_get_subsystem.2 b/doc/man/nvme_ns_get_subsystem.2 new file mode 100644 index 00000000..185dc9f3 --- /dev/null +++ b/doc/man/nvme_ns_get_subsystem.2 @@ -0,0 +1,8 @@ +.TH "nvme_ns_get_subsystem" 2 "nvme_ns_get_subsystem" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_get_subsystem \- +.SH SYNOPSIS +.B "nvme_subsystem_t" nvme_ns_get_subsystem +.BI "(nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "n" 12 diff --git a/doc/man/nvme_ns_get_sysfs_dir.2 b/doc/man/nvme_ns_get_sysfs_dir.2 new file mode 100644 index 00000000..16e4312b --- /dev/null +++ b/doc/man/nvme_ns_get_sysfs_dir.2 @@ -0,0 +1,8 @@ +.TH "nvme_ns_get_sysfs_dir" 2 "nvme_ns_get_sysfs_dir" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_get_sysfs_dir \- +.SH SYNOPSIS +.B "const char *" nvme_ns_get_sysfs_dir +.BI "(nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "n" 12 diff --git a/doc/man/nvme_ns_identify.2 b/doc/man/nvme_ns_identify.2 new file mode 100644 index 00000000..cf455cd2 --- /dev/null +++ b/doc/man/nvme_ns_identify.2 @@ -0,0 +1,11 @@ +.TH "nvme_ns_identify" 2 "nvme_ns_identify" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_identify \- +.SH SYNOPSIS +.B "int" nvme_ns_identify +.BI "(nvme_ns_t " n "," +.BI "struct nvme_id_ns *" ns ");" +.SH ARGUMENTS +.IP "n" 12 +-- undescribed -- +.IP "ns" 12 diff --git a/doc/man/nvme_ns_mgmt.2 b/doc/man/nvme_ns_mgmt.2 new file mode 100644 index 00000000..420489b2 --- /dev/null +++ b/doc/man/nvme_ns_mgmt.2 @@ -0,0 +1,24 @@ +.TH "nvme_ns_mgmt" 2 "nvme_ns_mgmt" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_mgmt \- +.SH SYNOPSIS +.B "int" nvme_ns_mgmt +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "enum nvme_ns_mgmt_sel " sel "," +.BI "struct nvme_id_ns *" ns "," +.BI "__u32 *" result "," +.BI "__u32 " timeout ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +-- undescribed -- +.IP "sel" 12 +-- undescribed -- +.IP "ns" 12 +-- undescribed -- +.IP "result" 12 +-- undescribed -- +.IP "timeout" 12 +-- undescribed -- diff --git a/doc/man/nvme_ns_mgmt_create.2 b/doc/man/nvme_ns_mgmt_create.2 new file mode 100644 index 00000000..6ad9c85c --- /dev/null +++ b/doc/man/nvme_ns_mgmt_create.2 @@ -0,0 +1,26 @@ +.TH "nvme_ns_mgmt_create" 2 "nvme_ns_mgmt_create" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_mgmt_create \- +.SH SYNOPSIS +.B "int" nvme_ns_mgmt_create +.BI "(int " fd "," +.BI "struct nvme_id_ns *" ns "," +.BI "__u32 *" nsid "," +.BI "__u32 " timeout ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "ns" 12 +Namespace identifiaction that defines creation parameters +.IP "nsid" 12 +On success, set to the namespace id that was created +.IP "timeout" 12 +Overide the default timeout to this value in milliseconds; +set to 0 to use the system default. +.SH "DESCRIPTION" +On successful creation, the namespace exists in the subsystem, but is not +attached to any controller. Use the \fBnvme_ns_attach_ctrls\fP to assign the +namespace to one or more controllers. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_ns_mgmt_delete.2 b/doc/man/nvme_ns_mgmt_delete.2 new file mode 100644 index 00000000..c8ddda41 --- /dev/null +++ b/doc/man/nvme_ns_mgmt_delete.2 @@ -0,0 +1,19 @@ +.TH "nvme_ns_mgmt_delete" 2 "nvme_ns_mgmt_delete" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_mgmt_delete \- +.SH SYNOPSIS +.B "int" nvme_ns_mgmt_delete +.BI "(int " fd "," +.BI "__u32 " nsid ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace identifier to delete +.SH "DESCRIPTION" +It is recommended that a namespace being deleted is not attached to any +controller. Use the \fBnvme_ns_detach_ctrls\fP first if the namespace is still +attached. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_ns_read.2 b/doc/man/nvme_ns_read.2 new file mode 100644 index 00000000..d29b246d --- /dev/null +++ b/doc/man/nvme_ns_read.2 @@ -0,0 +1,17 @@ +.TH "nvme_ns_read" 2 "nvme_ns_read" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_read \- +.SH SYNOPSIS +.B "int" nvme_ns_read +.BI "(nvme_ns_t " n "," +.BI "void *" buf "," +.BI "off_t " offset "," +.BI "size_t " count ");" +.SH ARGUMENTS +.IP "n" 12 +-- undescribed -- +.IP "buf" 12 +-- undescribed -- +.IP "offset" 12 +-- undescribed -- +.IP "count" 12 diff --git a/doc/man/nvme_ns_rescan.2 b/doc/man/nvme_ns_rescan.2 new file mode 100644 index 00000000..a2e402f1 --- /dev/null +++ b/doc/man/nvme_ns_rescan.2 @@ -0,0 +1,13 @@ +.TH "nvme_ns_rescan" 2 "nvme_ns_rescan" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_rescan \- Initiate a controller rescan +.SH SYNOPSIS +.B "int" nvme_ns_rescan +.BI "(int " fd ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.SH "DESCRIPTION" +This should only be sent to controller handles, not to namespaces. +.SH "RETURN" +Zero if a rescan was initiated or -1 with errno set otherwise. diff --git a/doc/man/nvme_ns_verify.2 b/doc/man/nvme_ns_verify.2 new file mode 100644 index 00000000..aa8c132a --- /dev/null +++ b/doc/man/nvme_ns_verify.2 @@ -0,0 +1,14 @@ +.TH "nvme_ns_verify" 2 "nvme_ns_verify" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_verify \- +.SH SYNOPSIS +.B "int" nvme_ns_verify +.BI "(nvme_ns_t " n "," +.BI "off_t " offset "," +.BI "size_t " count ");" +.SH ARGUMENTS +.IP "n" 12 +-- undescribed -- +.IP "offset" 12 +-- undescribed -- +.IP "count" 12 diff --git a/doc/man/nvme_ns_write.2 b/doc/man/nvme_ns_write.2 new file mode 100644 index 00000000..9e0df756 --- /dev/null +++ b/doc/man/nvme_ns_write.2 @@ -0,0 +1,17 @@ +.TH "nvme_ns_write" 2 "nvme_ns_write" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_write \- +.SH SYNOPSIS +.B "int" nvme_ns_write +.BI "(nvme_ns_t " n "," +.BI "void *" buf "," +.BI "off_t " offset "," +.BI "size_t " count ");" +.SH ARGUMENTS +.IP "n" 12 +-- undescribed -- +.IP "buf" 12 +-- undescribed -- +.IP "offset" 12 +-- undescribed -- +.IP "count" 12 diff --git a/doc/man/nvme_ns_write_uncorrectable.2 b/doc/man/nvme_ns_write_uncorrectable.2 new file mode 100644 index 00000000..45a3d69a --- /dev/null +++ b/doc/man/nvme_ns_write_uncorrectable.2 @@ -0,0 +1,14 @@ +.TH "nvme_ns_write_uncorrectable" 2 "nvme_ns_write_uncorrectable" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_write_uncorrectable \- +.SH SYNOPSIS +.B "int" nvme_ns_write_uncorrectable +.BI "(nvme_ns_t " n "," +.BI "off_t " offset "," +.BI "size_t " count ");" +.SH ARGUMENTS +.IP "n" 12 +-- undescribed -- +.IP "offset" 12 +-- undescribed -- +.IP "count" 12 diff --git a/doc/man/nvme_ns_write_zeros.2 b/doc/man/nvme_ns_write_zeros.2 new file mode 100644 index 00000000..6674ad1e --- /dev/null +++ b/doc/man/nvme_ns_write_zeros.2 @@ -0,0 +1,14 @@ +.TH "nvme_ns_write_zeros" 2 "nvme_ns_write_zeros" "February 2020" "libnvme Manual" +.SH NAME +nvme_ns_write_zeros \- +.SH SYNOPSIS +.B "int" nvme_ns_write_zeros +.BI "(nvme_ns_t " n "," +.BI "off_t " offset "," +.BI "size_t " count ");" +.SH ARGUMENTS +.IP "n" 12 +-- undescribed -- +.IP "offset" 12 +-- undescribed -- +.IP "count" 12 diff --git a/doc/man/nvme_open.2 b/doc/man/nvme_open.2 new file mode 100644 index 00000000..c7ba11dd --- /dev/null +++ b/doc/man/nvme_open.2 @@ -0,0 +1,15 @@ +.TH "nvme_open" 2 "nvme_open" "February 2020" "libnvme Manual" +.SH NAME +nvme_open \- Open an nvme controller or namespace device +.SH SYNOPSIS +.B "int" nvme_open +.BI "(const char *" name ");" +.SH ARGUMENTS +.IP "name" 12 +The basename of the device to open +.SH "DESCRIPTION" +This will look for the handle in /dev/ and validate the name and filetype +match linux conventions. +.SH "RETURN" +A file descriptor for the device on a successful open, or -1 with +errno set otherwise. diff --git a/doc/man/nvme_path_get_ana_state.2 b/doc/man/nvme_path_get_ana_state.2 new file mode 100644 index 00000000..99a6b79b --- /dev/null +++ b/doc/man/nvme_path_get_ana_state.2 @@ -0,0 +1,8 @@ +.TH "nvme_path_get_ana_state" 2 "nvme_path_get_ana_state" "February 2020" "libnvme Manual" +.SH NAME +nvme_path_get_ana_state \- +.SH SYNOPSIS +.B "const char *" nvme_path_get_ana_state +.BI "(nvme_path_t " p ");" +.SH ARGUMENTS +.IP "p" 12 diff --git a/doc/man/nvme_path_get_name.2 b/doc/man/nvme_path_get_name.2 new file mode 100644 index 00000000..c0e10c5d --- /dev/null +++ b/doc/man/nvme_path_get_name.2 @@ -0,0 +1,8 @@ +.TH "nvme_path_get_name" 2 "nvme_path_get_name" "February 2020" "libnvme Manual" +.SH NAME +nvme_path_get_name \- +.SH SYNOPSIS +.B "const char *" nvme_path_get_name +.BI "(nvme_path_t " p ");" +.SH ARGUMENTS +.IP "p" 12 diff --git a/doc/man/nvme_path_get_ns.2 b/doc/man/nvme_path_get_ns.2 new file mode 100644 index 00000000..6b5da073 --- /dev/null +++ b/doc/man/nvme_path_get_ns.2 @@ -0,0 +1,8 @@ +.TH "nvme_path_get_ns" 2 "nvme_path_get_ns" "February 2020" "libnvme Manual" +.SH NAME +nvme_path_get_ns \- +.SH SYNOPSIS +.B "nvme_ns_t" nvme_path_get_ns +.BI "(nvme_path_t " p ");" +.SH ARGUMENTS +.IP "p" 12 diff --git a/doc/man/nvme_path_get_subsystem.2 b/doc/man/nvme_path_get_subsystem.2 new file mode 100644 index 00000000..17222ecd --- /dev/null +++ b/doc/man/nvme_path_get_subsystem.2 @@ -0,0 +1,8 @@ +.TH "nvme_path_get_subsystem" 2 "nvme_path_get_subsystem" "February 2020" "libnvme Manual" +.SH NAME +nvme_path_get_subsystem \- +.SH SYNOPSIS +.B "nvme_ctrl_t" nvme_path_get_subsystem +.BI "(nvme_path_t " p ");" +.SH ARGUMENTS +.IP "p" 12 diff --git a/doc/man/nvme_path_get_sysfs_dir.2 b/doc/man/nvme_path_get_sysfs_dir.2 new file mode 100644 index 00000000..6d0dcd44 --- /dev/null +++ b/doc/man/nvme_path_get_sysfs_dir.2 @@ -0,0 +1,8 @@ +.TH "nvme_path_get_sysfs_dir" 2 "nvme_path_get_sysfs_dir" "February 2020" "libnvme Manual" +.SH NAME +nvme_path_get_sysfs_dir \- +.SH SYNOPSIS +.B "const char *" nvme_path_get_sysfs_dir +.BI "(nvme_path_t " p ");" +.SH ARGUMENTS +.IP "p" 12 diff --git a/doc/man/nvme_paths_filter.2 b/doc/man/nvme_paths_filter.2 new file mode 100644 index 00000000..737305c0 --- /dev/null +++ b/doc/man/nvme_paths_filter.2 @@ -0,0 +1,8 @@ +.TH "nvme_paths_filter" 2 "nvme_paths_filter" "February 2020" "libnvme Manual" +.SH NAME +nvme_paths_filter \- +.SH SYNOPSIS +.B "int" nvme_paths_filter +.BI "(const struct dirent *" d ");" +.SH ARGUMENTS +.IP "d" 12 diff --git a/doc/man/nvme_psd_power_scale.2 b/doc/man/nvme_psd_power_scale.2 new file mode 100644 index 00000000..5261ebb2 --- /dev/null +++ b/doc/man/nvme_psd_power_scale.2 @@ -0,0 +1,9 @@ +.TH "nvme_psd_power_scale" 2 "nvme_psd_power_scale" "February 2020" "libnvme Manual" +.SH NAME +nvme_psd_power_scale \- power scale occupies the upper 3 bits +.SH SYNOPSIS +.B "unsigned" nvme_psd_power_scale +.BI "(__u8 " ps ");" +.SH ARGUMENTS +.IP "ps" 12 +-- undescribed -- diff --git a/doc/man/nvme_read.2 b/doc/man/nvme_read.2 new file mode 100644 index 00000000..b0bed151 --- /dev/null +++ b/doc/man/nvme_read.2 @@ -0,0 +1,55 @@ +.TH "nvme_read" 2 "nvme_read" "February 2020" "libnvme Manual" +.SH NAME +nvme_read \- Submit an nvme user read command +.SH SYNOPSIS +.B "int" nvme_read +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u64 " slba "," +.BI "__u16 " nlb "," +.BI "__u16 " control "," +.BI "__u8 " dsm "," +.BI "__u32 " reftag "," +.BI "__u16 " apptag "," +.BI "__u16 " appmask "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 " metadata_len "," +.BI "void *" metadata ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "slba" 12 +Starting logical block +.IP "nlb" 12 +-- undescribed -- +.IP "control" 12 +Command control flags, see \fIenum nvme_io_control_flags\fP. +.IP "dsm" 12 +Data set management attributes, see \fIenum nvme_io_dsm_flags\fP +.IP "reftag" 12 +This field specifies the Initial Logical Block Reference Tag +expected value. Used only if the namespace is formatted to use +end-to-end protection information. +.IP "apptag" 12 +This field specifies the Application Tag Mask expected value. +Used only if the namespace is formatted to use end-to-end +protection information. +.IP "appmask" 12 +This field specifies the Application Tag expected value. Used +only if the namespace is formatted to use end-to-end protection +information. +.IP "data_len" 12 +Length of user buffer, \fIdata\fP, in bytes +.IP "data" 12 +Pointer to user address of the data buffer +metadata_len:Length of user buffer, \fImetadata\fP, in bytes +.IP "metadata_len" 12 +-- undescribed -- +.IP "metadata" 12 +Pointer to user address of the metadata buffer +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_refresh_topology.2 b/doc/man/nvme_refresh_topology.2 new file mode 100644 index 00000000..9a4b3404 --- /dev/null +++ b/doc/man/nvme_refresh_topology.2 @@ -0,0 +1,9 @@ +.TH "nvme_refresh_topology" 2 "nvme_refresh_topology" "February 2020" "libnvme Manual" +.SH NAME +nvme_refresh_topology \- +.SH SYNOPSIS +.B "void" nvme_refresh_topology +.BI "(nvme_root_t " r ");" +.SH ARGUMENTS +.IP "r" 12 +-- undescribed -- diff --git a/doc/man/nvme_reset_topology.2 b/doc/man/nvme_reset_topology.2 new file mode 100644 index 00000000..3a25e7e3 --- /dev/null +++ b/doc/man/nvme_reset_topology.2 @@ -0,0 +1,9 @@ +.TH "nvme_reset_topology" 2 "nvme_reset_topology" "February 2020" "libnvme Manual" +.SH NAME +nvme_reset_topology \- +.SH SYNOPSIS +.B "void" nvme_reset_topology +.BI "(nvme_root_t " r ");" +.SH ARGUMENTS +.IP "r" 12 +-- undescribed -- diff --git a/doc/man/nvme_resv_acquire.2 b/doc/man/nvme_resv_acquire.2 new file mode 100644 index 00000000..b607dd2c --- /dev/null +++ b/doc/man/nvme_resv_acquire.2 @@ -0,0 +1,35 @@ +.TH "nvme_resv_acquire" 2 "nvme_resv_acquire" "February 2020" "libnvme Manual" +.SH NAME +nvme_resv_acquire \- Send an nvme reservation acquire +.SH SYNOPSIS +.B "int" nvme_resv_acquire +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "enum nvme_reservation_rtype " rtype "," +.BI "enum nvme_reservation_racqa " racqa "," +.BI "bool " iekey "," +.BI "__u64 " crkey "," +.BI "__u64 " nrkey ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace identifier +.IP "rtype" 12 +The type of reservation to be create, see \fIenum nvme_reservation_rtype\fP +.IP "racqa" 12 +The action that is performed by the command, see \fIenum nvme_reservation_racqa\fP +.IP "iekey" 12 +Set to ignore the existing key +.IP "crkey" 12 +The current reservation key associated with the host +.IP "nrkey" 12 +The reservation key to be unregistered from the namespace if +the action is preempt +.SH "DESCRIPTION" +The Reservation Acquire command is used to acquire a reservation on a +namespace, preempt a reservation held on a namespace, and abort a +reservation held on a namespace. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_resv_register.2 b/doc/man/nvme_resv_register.2 new file mode 100644 index 00000000..fbe29c97 --- /dev/null +++ b/doc/man/nvme_resv_register.2 @@ -0,0 +1,34 @@ +.TH "nvme_resv_register" 2 "nvme_resv_register" "February 2020" "libnvme Manual" +.SH NAME +nvme_resv_register \- Send an nvme reservation register +.SH SYNOPSIS +.B "int" nvme_resv_register +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "enum nvme_reservation_rrega " rrega "," +.BI "enum nvme_reservation_cptpl " cptpl "," +.BI "bool " iekey "," +.BI "__u64 " crkey "," +.BI "__u64 " nrkey ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace identifier +.IP "rrega" 12 +The registration action, see \fIenum nvme_reservation_rrega\fP +.IP "cptpl" 12 +Change persist through power loss, see \fIenum nvme_reservation_cptpl\fP +.IP "iekey" 12 +Set to ignore the existing key +.IP "crkey" 12 +The current reservation key associated with the host +.IP "nrkey" 12 +The new reservation key to be register if action is register or +replace +.SH "DESCRIPTION" +The Reservation Register command is used to register, unregister, or replace +a reservation key. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_resv_release.2 b/doc/man/nvme_resv_release.2 new file mode 100644 index 00000000..748375dd --- /dev/null +++ b/doc/man/nvme_resv_release.2 @@ -0,0 +1,27 @@ +.TH "nvme_resv_release" 2 "nvme_resv_release" "February 2020" "libnvme Manual" +.SH NAME +nvme_resv_release \- Send an nvme reservation release +.SH SYNOPSIS +.B "int" nvme_resv_release +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "enum nvme_reservation_rtype " rtype "," +.BI "enum nvme_reservation_rrela " rrela "," +.BI "bool " iekey "," +.BI "__u64 " crkey ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace identifier +.IP "rtype" 12 +The type of reservation to be create, see \fIenum nvme_reservation_rtype\fP +.IP "rrela" 12 +Reservation releast action, see \fIenum nvme_reservation_rrela\fP +.IP "iekey" 12 +Set to ignore the existing key +.IP "crkey" 12 +The current reservation key to release +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_resv_report.2 b/doc/man/nvme_resv_report.2 new file mode 100644 index 00000000..7421b6fb --- /dev/null +++ b/doc/man/nvme_resv_report.2 @@ -0,0 +1,28 @@ +.TH "nvme_resv_report" 2 "nvme_resv_report" "February 2020" "libnvme Manual" +.SH NAME +nvme_resv_report \- Send an nvme reservation report +.SH SYNOPSIS +.B "int" nvme_resv_report +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "bool " eds "," +.BI "__u32 " len "," +.BI "struct nvme_reservation_status *" report ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace identifier +.IP "eds" 12 +Request extended Data Structure +.IP "len" 12 +Number of bytes to request transfered with this command +.IP "report" 12 +The user space destination address to store the reservation report +.SH "DESCRIPTION" +Returns a Reservation Status data structure to memory that describes the +registration and reservation status of a namespace. See the defintion for +the returned structure, \fIstruct nvme_reservation_status\fP, for more details. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_sanitize_nvm.2 b/doc/man/nvme_sanitize_nvm.2 new file mode 100644 index 00000000..3e1cf91a --- /dev/null +++ b/doc/man/nvme_sanitize_nvm.2 @@ -0,0 +1,40 @@ +.TH "nvme_sanitize_nvm" 2 "nvme_sanitize_nvm" "February 2020" "libnvme Manual" +.SH NAME +nvme_sanitize_nvm \- Start a sanitize operation +.SH SYNOPSIS +.B "int" nvme_sanitize_nvm +.BI "(int " fd "," +.BI "enum nvme_sanitize_sanact " sanact "," +.BI "bool " ause "," +.BI "__u8 " owpass "," +.BI "bool " oipbp "," +.BI "bool " nodas "," +.BI "__u32 " ovrpat ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sanact" 12 +Sanitize action, see \fIenum nvme_sanitize_sanact\fP +.IP "ause" 12 +Set to allow unrestriced sanitize exit +.IP "owpass" 12 +Overwrite pass count +.IP "oipbp" 12 +Set to overwrite invert pattern between passes +.IP "nodas" 12 +Set to not deallocate blocks after sanitizing +.IP "ovrpat" 12 +Overwrite pattern +.SH "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 is used to start 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. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_scan.2 b/doc/man/nvme_scan.2 new file mode 100644 index 00000000..4ee2bace --- /dev/null +++ b/doc/man/nvme_scan.2 @@ -0,0 +1,6 @@ +.TH "nvme_scan" 2 "nvme_scan" "February 2020" "libnvme Manual" +.SH NAME +nvme_scan \- +.SH SYNOPSIS +.B "nvme_root_t" nvme_scan +.SH ARGUMENTS diff --git a/doc/man/nvme_scan_ctrl.2 b/doc/man/nvme_scan_ctrl.2 new file mode 100644 index 00000000..260804b3 --- /dev/null +++ b/doc/man/nvme_scan_ctrl.2 @@ -0,0 +1,8 @@ +.TH "nvme_scan_ctrl" 2 "nvme_scan_ctrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_scan_ctrl \- +.SH SYNOPSIS +.B "nvme_ctrl_t" nvme_scan_ctrl +.BI "(const char *" name ");" +.SH ARGUMENTS +.IP "name" 12 diff --git a/doc/man/nvme_scan_ctrl_namespace_paths.2 b/doc/man/nvme_scan_ctrl_namespace_paths.2 new file mode 100644 index 00000000..78b95e37 --- /dev/null +++ b/doc/man/nvme_scan_ctrl_namespace_paths.2 @@ -0,0 +1,11 @@ +.TH "nvme_scan_ctrl_namespace_paths" 2 "nvme_scan_ctrl_namespace_paths" "February 2020" "libnvme Manual" +.SH NAME +nvme_scan_ctrl_namespace_paths \- +.SH SYNOPSIS +.B "int" nvme_scan_ctrl_namespace_paths +.BI "(nvme_ctrl_t " c "," +.BI "struct dirent ***" namespaces ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- +.IP "namespaces" 12 diff --git a/doc/man/nvme_scan_ctrl_namespaces.2 b/doc/man/nvme_scan_ctrl_namespaces.2 new file mode 100644 index 00000000..b059979c --- /dev/null +++ b/doc/man/nvme_scan_ctrl_namespaces.2 @@ -0,0 +1,11 @@ +.TH "nvme_scan_ctrl_namespaces" 2 "nvme_scan_ctrl_namespaces" "February 2020" "libnvme Manual" +.SH NAME +nvme_scan_ctrl_namespaces \- +.SH SYNOPSIS +.B "int" nvme_scan_ctrl_namespaces +.BI "(nvme_ctrl_t " c "," +.BI "struct dirent ***" namespaces ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- +.IP "namespaces" 12 diff --git a/doc/man/nvme_scan_filter.2 b/doc/man/nvme_scan_filter.2 new file mode 100644 index 00000000..8e9e62e3 --- /dev/null +++ b/doc/man/nvme_scan_filter.2 @@ -0,0 +1,8 @@ +.TH "nvme_scan_filter" 2 "nvme_scan_filter" "February 2020" "libnvme Manual" +.SH NAME +nvme_scan_filter \- +.SH SYNOPSIS +.B "nvme_root_t" nvme_scan_filter +.BI "(nvme_scan_filter_t " f ");" +.SH ARGUMENTS +.IP "f" 12 diff --git a/doc/man/nvme_scan_subsystem_ctrls.2 b/doc/man/nvme_scan_subsystem_ctrls.2 new file mode 100644 index 00000000..a5968788 --- /dev/null +++ b/doc/man/nvme_scan_subsystem_ctrls.2 @@ -0,0 +1,11 @@ +.TH "nvme_scan_subsystem_ctrls" 2 "nvme_scan_subsystem_ctrls" "February 2020" "libnvme Manual" +.SH NAME +nvme_scan_subsystem_ctrls \- +.SH SYNOPSIS +.B "int" nvme_scan_subsystem_ctrls +.BI "(nvme_subsystem_t " s "," +.BI "struct dirent ***" ctrls ");" +.SH ARGUMENTS +.IP "s" 12 +-- undescribed -- +.IP "ctrls" 12 diff --git a/doc/man/nvme_scan_subsystem_namespaces.2 b/doc/man/nvme_scan_subsystem_namespaces.2 new file mode 100644 index 00000000..0e7a7745 --- /dev/null +++ b/doc/man/nvme_scan_subsystem_namespaces.2 @@ -0,0 +1,11 @@ +.TH "nvme_scan_subsystem_namespaces" 2 "nvme_scan_subsystem_namespaces" "February 2020" "libnvme Manual" +.SH NAME +nvme_scan_subsystem_namespaces \- +.SH SYNOPSIS +.B "int" nvme_scan_subsystem_namespaces +.BI "(nvme_subsystem_t " s "," +.BI "struct dirent ***" namespaces ");" +.SH ARGUMENTS +.IP "s" 12 +-- undescribed -- +.IP "namespaces" 12 diff --git a/doc/man/nvme_scan_subsystems.2 b/doc/man/nvme_scan_subsystems.2 new file mode 100644 index 00000000..701660dd --- /dev/null +++ b/doc/man/nvme_scan_subsystems.2 @@ -0,0 +1,8 @@ +.TH "nvme_scan_subsystems" 2 "nvme_scan_subsystems" "February 2020" "libnvme Manual" +.SH NAME +nvme_scan_subsystems \- +.SH SYNOPSIS +.B "int" nvme_scan_subsystems +.BI "(struct dirent ***" subsys ");" +.SH ARGUMENTS +.IP "subsys" 12 diff --git a/doc/man/nvme_security_receive.2 b/doc/man/nvme_security_receive.2 new file mode 100644 index 00000000..8774e7a7 --- /dev/null +++ b/doc/man/nvme_security_receive.2 @@ -0,0 +1,39 @@ +.TH "nvme_security_receive" 2 "nvme_security_receive" "February 2020" "libnvme Manual" +.SH NAME +nvme_security_receive \- +.SH SYNOPSIS +.B "int" nvme_security_receive +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u8 " nssf "," +.BI "__u8 " spsp0 "," +.BI "__u8 " spsp1 "," +.BI "__u8 " secp "," +.BI "__u32 " al "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID to issue security command on +.IP "nssf" 12 +NVMe Security Specific field +.IP "spsp0" 12 +Security Protocol Specific field +.IP "spsp1" 12 +Security Protocol Specific field +.IP "secp" 12 +Security Protocol +.IP "al" 12 +Protocol specific allocation length +.IP "data_len" 12 +Data length of the payload in bytes +.IP "data" 12 +Security data payload to send +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_security_send.2 b/doc/man/nvme_security_send.2 new file mode 100644 index 00000000..8849171b --- /dev/null +++ b/doc/man/nvme_security_send.2 @@ -0,0 +1,48 @@ +.TH "nvme_security_send" 2 "nvme_security_send" "February 2020" "libnvme Manual" +.SH NAME +nvme_security_send \- +.SH SYNOPSIS +.B "int" nvme_security_send +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u8 " nssf "," +.BI "__u8 " spsp0 "," +.BI "__u8 " spsp1 "," +.BI "__u8 " secp "," +.BI "__u32 " tl "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID to issue security command on +.IP "nssf" 12 +NVMe Security Specific field +.IP "spsp0" 12 +Security Protocol Specific field +.IP "spsp1" 12 +Security Protocol Specific field +.IP "secp" 12 +Security Protocol +.IP "tl" 12 +Protocol specific transfer length +.IP "data_len" 12 +Data length of the payload in bytes +.IP "data" 12 +Security data payload to send +.IP "result" 12 +The command completion result from CQE dword0 +.SH "DESCRIPTION" +The Security Send command is used to transfer 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. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_attr.2 b/doc/man/nvme_set_attr.2 new file mode 100644 index 00000000..677b801e --- /dev/null +++ b/doc/man/nvme_set_attr.2 @@ -0,0 +1,16 @@ +.TH "nvme_set_attr" 2 "nvme_set_attr" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_attr \- +.SH SYNOPSIS +.B "int" nvme_set_attr +.BI "(const char *" dir "," +.BI "const char *" attr "," +.BI "const char *" value ");" +.SH ARGUMENTS +.IP "dir" 12 +-- undescribed -- +.IP "attr" 12 +-- undescribed -- +.IP "value" 12 +.SH "DESCRIPTION" +Return diff --git a/doc/man/nvme_set_features.2 b/doc/man/nvme_set_features.2 new file mode 100644 index 00000000..267ee06b --- /dev/null +++ b/doc/man/nvme_set_features.2 @@ -0,0 +1,42 @@ +.TH "nvme_set_features" 2 "nvme_set_features" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features \- Set a feature attribute +.SH SYNOPSIS +.B "int" nvme_set_features +.BI "(int " fd "," +.BI "__u8 " fid "," +.BI "__u32 " nsid "," +.BI "__u32 " cdw11 "," +.BI "__u32 " cdw12 "," +.BI "bool " save "," +.BI "__u8 " uuidx "," +.BI "__u32 " cdw15 "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "fid" 12 +Feature identifier +.IP "nsid" 12 +Namespace ID, if applicable +.IP "cdw11" 12 +Value to set the feature to +.IP "cdw12" 12 +Feature specific command dword12 field +.IP "save" 12 +Save value across power states +.IP "uuidx" 12 +UUID Index for differentiating vendor specific encoding +.IP "cdw15" 12 +-- undescribed -- +.IP "data_len" 12 +Length of feature data, if applicable, in bytes +.IP "data" 12 +User address of feature data, if applicable +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_arbitration.2 b/doc/man/nvme_set_features_arbitration.2 new file mode 100644 index 00000000..1a688f3e --- /dev/null +++ b/doc/man/nvme_set_features_arbitration.2 @@ -0,0 +1,30 @@ +.TH "nvme_set_features_arbitration" 2 "nvme_set_features_arbitration" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_arbitration \- +.SH SYNOPSIS +.B "int" nvme_set_features_arbitration +.BI "(int " fd "," +.BI "__u8 " ab "," +.BI "__u8 " lpw "," +.BI "__u8 " mpw "," +.BI "__u8 " hpw "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "ab" 12 +-- undescribed -- +.IP "lpw" 12 +-- undescribed -- +.IP "mpw" 12 +-- undescribed -- +.IP "hpw" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_async_event.2 b/doc/man/nvme_set_features_async_event.2 new file mode 100644 index 00000000..98cc6a8a --- /dev/null +++ b/doc/man/nvme_set_features_async_event.2 @@ -0,0 +1,21 @@ +.TH "nvme_set_features_async_event" 2 "nvme_set_features_async_event" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_async_event \- +.SH SYNOPSIS +.B "int" nvme_set_features_async_event +.BI "(int " fd "," +.BI "__u32 " events "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "events" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_auto_pst.2 b/doc/man/nvme_set_features_auto_pst.2 new file mode 100644 index 00000000..40406f6f --- /dev/null +++ b/doc/man/nvme_set_features_auto_pst.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_auto_pst" 2 "nvme_set_features_auto_pst" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_auto_pst \- +.SH SYNOPSIS +.B "int" nvme_set_features_auto_pst +.BI "(int " fd "," +.BI "bool " apste "," +.BI "bool " save "," +.BI "struct nvme_feat_auto_pst *" apst "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "apste" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "apst" 12 +-- undescribed -- +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_endurance_evt_cfg.2 b/doc/man/nvme_set_features_endurance_evt_cfg.2 new file mode 100644 index 00000000..4b56a97e --- /dev/null +++ b/doc/man/nvme_set_features_endurance_evt_cfg.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_endurance_evt_cfg" 2 "nvme_set_features_endurance_evt_cfg" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_endurance_evt_cfg \- +.SH SYNOPSIS +.B "int" nvme_set_features_endurance_evt_cfg +.BI "(int " fd "," +.BI "__u16 " endgid "," +.BI "__u8 " egwarn "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "endgid" 12 +-- undescribed -- +.IP "egwarn" 12 +Flags to enable warning, see \fIenum nvme_eg_critical_warning_flags\fP +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_err_recovery.2 b/doc/man/nvme_set_features_err_recovery.2 new file mode 100644 index 00000000..5da3dc90 --- /dev/null +++ b/doc/man/nvme_set_features_err_recovery.2 @@ -0,0 +1,27 @@ +.TH "nvme_set_features_err_recovery" 2 "nvme_set_features_err_recovery" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_err_recovery \- +.SH SYNOPSIS +.B "int" nvme_set_features_err_recovery +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u16 " tler "," +.BI "bool " dulbe "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +-- undescribed -- +.IP "tler" 12 +-- undescribed -- +.IP "dulbe" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_hctm.2 b/doc/man/nvme_set_features_hctm.2 new file mode 100644 index 00000000..a02f42f0 --- /dev/null +++ b/doc/man/nvme_set_features_hctm.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_hctm" 2 "nvme_set_features_hctm" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_hctm \- +.SH SYNOPSIS +.B "int" nvme_set_features_hctm +.BI "(int " fd "," +.BI "__u16 " tmt2 "," +.BI "__u16 " tmt1 "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "tmt2" 12 +-- undescribed -- +.IP "tmt1" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_host_behavior.2 b/doc/man/nvme_set_features_host_behavior.2 new file mode 100644 index 00000000..27534b53 --- /dev/null +++ b/doc/man/nvme_set_features_host_behavior.2 @@ -0,0 +1,18 @@ +.TH "nvme_set_features_host_behavior" 2 "nvme_set_features_host_behavior" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_host_behavior \- +.SH SYNOPSIS +.B "int" nvme_set_features_host_behavior +.BI "(int " fd "," +.BI "bool " save "," +.BI "struct nvme_feat_host_behavior *" data ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "save" 12 +Save value across power states +.IP "data" 12 +-- undescribed -- +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_host_id.2 b/doc/man/nvme_set_features_host_id.2 new file mode 100644 index 00000000..b9ec6637 --- /dev/null +++ b/doc/man/nvme_set_features_host_id.2 @@ -0,0 +1,21 @@ +.TH "nvme_set_features_host_id" 2 "nvme_set_features_host_id" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_host_id \- +.SH SYNOPSIS +.B "int" nvme_set_features_host_id +.BI "(int " fd "," +.BI "bool " exhid "," +.BI "bool " save "," +.BI "__u8 *" hostid ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "exhid" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "hostid" 12 +-- undescribed -- +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_irq_coalesce.2 b/doc/man/nvme_set_features_irq_coalesce.2 new file mode 100644 index 00000000..89f87f54 --- /dev/null +++ b/doc/man/nvme_set_features_irq_coalesce.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_irq_coalesce" 2 "nvme_set_features_irq_coalesce" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_irq_coalesce \- +.SH SYNOPSIS +.B "int" nvme_set_features_irq_coalesce +.BI "(int " fd "," +.BI "__u8 " thr "," +.BI "__u8 " time "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "thr" 12 +-- undescribed -- +.IP "time" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_irq_config.2 b/doc/man/nvme_set_features_irq_config.2 new file mode 100644 index 00000000..a5fa413e --- /dev/null +++ b/doc/man/nvme_set_features_irq_config.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_irq_config" 2 "nvme_set_features_irq_config" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_irq_config \- +.SH SYNOPSIS +.B "int" nvme_set_features_irq_config +.BI "(int " fd "," +.BI "__u16 " iv "," +.BI "bool " cd "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "iv" 12 +-- undescribed -- +.IP "cd" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_lba_range.2 b/doc/man/nvme_set_features_lba_range.2 new file mode 100644 index 00000000..c94f4720 --- /dev/null +++ b/doc/man/nvme_set_features_lba_range.2 @@ -0,0 +1,27 @@ +.TH "nvme_set_features_lba_range" 2 "nvme_set_features_lba_range" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_lba_range \- +.SH SYNOPSIS +.B "int" nvme_set_features_lba_range +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u32 " nr_ranges "," +.BI "bool " save "," +.BI "struct nvme_lba_range_type *" data "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +-- undescribed -- +.IP "nr_ranges" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "data" 12 +-- undescribed -- +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_lba_sts_interval.2 b/doc/man/nvme_set_features_lba_sts_interval.2 new file mode 100644 index 00000000..03f1d35c --- /dev/null +++ b/doc/man/nvme_set_features_lba_sts_interval.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_lba_sts_interval" 2 "nvme_set_features_lba_sts_interval" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_lba_sts_interval \- +.SH SYNOPSIS +.B "int" nvme_set_features_lba_sts_interval +.BI "(int " fd "," +.BI "__u16 " lsiri "," +.BI "__u16 " lsipi "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "lsiri" 12 +-- undescribed -- +.IP "lsipi" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_nopsc.2 b/doc/man/nvme_set_features_nopsc.2 new file mode 100644 index 00000000..25723c1d --- /dev/null +++ b/doc/man/nvme_set_features_nopsc.2 @@ -0,0 +1,18 @@ +.TH "nvme_set_features_nopsc" 2 "nvme_set_features_nopsc" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_nopsc \- +.SH SYNOPSIS +.B "int" nvme_set_features_nopsc +.BI "(int " fd "," +.BI "bool " noppme "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +-- undescribed -- +.IP "noppme" 12 +-- undescribed -- +.IP "save" 12 +-- undescribed -- +.IP "result" 12 +-- undescribed -- diff --git a/doc/man/nvme_set_features_plm_config.2 b/doc/man/nvme_set_features_plm_config.2 new file mode 100644 index 00000000..8e0c7d1f --- /dev/null +++ b/doc/man/nvme_set_features_plm_config.2 @@ -0,0 +1,27 @@ +.TH "nvme_set_features_plm_config" 2 "nvme_set_features_plm_config" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_plm_config \- +.SH SYNOPSIS +.B "int" nvme_set_features_plm_config +.BI "(int " fd "," +.BI "bool " enable "," +.BI "__u16 " nvmsetid "," +.BI "bool " save "," +.BI "struct nvme_plm_config *" data "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "enable" 12 +-- undescribed -- +.IP "nvmsetid" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "data" 12 +-- undescribed -- +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_plm_window.2 b/doc/man/nvme_set_features_plm_window.2 new file mode 100644 index 00000000..f3292299 --- /dev/null +++ b/doc/man/nvme_set_features_plm_window.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_plm_window" 2 "nvme_set_features_plm_window" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_plm_window \- +.SH SYNOPSIS +.B "int" nvme_set_features_plm_window +.BI "(int " fd "," +.BI "enum nvme_feat_plm_window_select " sel "," +.BI "__u16 " nvmsetid "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "sel" 12 +-- undescribed -- +.IP "nvmsetid" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_power_mgmt.2 b/doc/man/nvme_set_features_power_mgmt.2 new file mode 100644 index 00000000..f63c6664 --- /dev/null +++ b/doc/man/nvme_set_features_power_mgmt.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_power_mgmt" 2 "nvme_set_features_power_mgmt" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_power_mgmt \- +.SH SYNOPSIS +.B "int" nvme_set_features_power_mgmt +.BI "(int " fd "," +.BI "__u8 " ps "," +.BI "__u8 " wh "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "ps" 12 +-- undescribed -- +.IP "wh" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_resv_mask.2 b/doc/man/nvme_set_features_resv_mask.2 new file mode 100644 index 00000000..3b3842cb --- /dev/null +++ b/doc/man/nvme_set_features_resv_mask.2 @@ -0,0 +1,21 @@ +.TH "nvme_set_features_resv_mask" 2 "nvme_set_features_resv_mask" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_resv_mask \- +.SH SYNOPSIS +.B "int" nvme_set_features_resv_mask +.BI "(int " fd "," +.BI "__u32 " mask "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "mask" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_resv_persist.2 b/doc/man/nvme_set_features_resv_persist.2 new file mode 100644 index 00000000..5a1e0e99 --- /dev/null +++ b/doc/man/nvme_set_features_resv_persist.2 @@ -0,0 +1,21 @@ +.TH "nvme_set_features_resv_persist" 2 "nvme_set_features_resv_persist" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_resv_persist \- +.SH SYNOPSIS +.B "int" nvme_set_features_resv_persist +.BI "(int " fd "," +.BI "bool " ptpl "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "ptpl" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_rrl.2 b/doc/man/nvme_set_features_rrl.2 new file mode 100644 index 00000000..997efaa0 --- /dev/null +++ b/doc/man/nvme_set_features_rrl.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_rrl" 2 "nvme_set_features_rrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_rrl \- +.SH SYNOPSIS +.B "int" nvme_set_features_rrl +.BI "(int " fd "," +.BI "__u8 " rrl "," +.BI "__u16 " nvmsetid "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "rrl" 12 +-- undescribed -- +.IP "nvmsetid" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_sanitize.2 b/doc/man/nvme_set_features_sanitize.2 new file mode 100644 index 00000000..380408c2 --- /dev/null +++ b/doc/man/nvme_set_features_sanitize.2 @@ -0,0 +1,21 @@ +.TH "nvme_set_features_sanitize" 2 "nvme_set_features_sanitize" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_sanitize \- +.SH SYNOPSIS +.B "int" nvme_set_features_sanitize +.BI "(int " fd "," +.BI "bool " nodrm "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nodrm" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_sw_progress.2 b/doc/man/nvme_set_features_sw_progress.2 new file mode 100644 index 00000000..3a4ba7b4 --- /dev/null +++ b/doc/man/nvme_set_features_sw_progress.2 @@ -0,0 +1,21 @@ +.TH "nvme_set_features_sw_progress" 2 "nvme_set_features_sw_progress" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_sw_progress \- +.SH SYNOPSIS +.B "int" nvme_set_features_sw_progress +.BI "(int " fd "," +.BI "__u8 " pbslc "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "pbslc" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_temp_thresh.2 b/doc/man/nvme_set_features_temp_thresh.2 new file mode 100644 index 00000000..cec95565 --- /dev/null +++ b/doc/man/nvme_set_features_temp_thresh.2 @@ -0,0 +1,27 @@ +.TH "nvme_set_features_temp_thresh" 2 "nvme_set_features_temp_thresh" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_temp_thresh \- +.SH SYNOPSIS +.B "int" nvme_set_features_temp_thresh +.BI "(int " fd "," +.BI "__u16 " tmpth "," +.BI "__u8 " tmpsel "," +.BI "enum nvme_feat_tmpthresh_thsel " thsel "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "tmpth" 12 +-- undescribed -- +.IP "tmpsel" 12 +-- undescribed -- +.IP "thsel" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_timestamp.2 b/doc/man/nvme_set_features_timestamp.2 new file mode 100644 index 00000000..0abf98cf --- /dev/null +++ b/doc/man/nvme_set_features_timestamp.2 @@ -0,0 +1,18 @@ +.TH "nvme_set_features_timestamp" 2 "nvme_set_features_timestamp" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_timestamp \- +.SH SYNOPSIS +.B "int" nvme_set_features_timestamp +.BI "(int " fd "," +.BI "bool " save "," +.BI "__u64 " timestamp ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "save" 12 +Save value across power states +.IP "timestamp" 12 +The current timestamp value to assign to this this feature +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_volatile_wc.2 b/doc/man/nvme_set_features_volatile_wc.2 new file mode 100644 index 00000000..34425fb9 --- /dev/null +++ b/doc/man/nvme_set_features_volatile_wc.2 @@ -0,0 +1,21 @@ +.TH "nvme_set_features_volatile_wc" 2 "nvme_set_features_volatile_wc" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_volatile_wc \- +.SH SYNOPSIS +.B "int" nvme_set_features_volatile_wc +.BI "(int " fd "," +.BI "bool " wce "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "wce" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_write_atomic.2 b/doc/man/nvme_set_features_write_atomic.2 new file mode 100644 index 00000000..0b1ffad1 --- /dev/null +++ b/doc/man/nvme_set_features_write_atomic.2 @@ -0,0 +1,21 @@ +.TH "nvme_set_features_write_atomic" 2 "nvme_set_features_write_atomic" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_write_atomic \- +.SH SYNOPSIS +.B "int" nvme_set_features_write_atomic +.BI "(int " fd "," +.BI "bool " dn "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "dn" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_features_write_protect.2 b/doc/man/nvme_set_features_write_protect.2 new file mode 100644 index 00000000..b9be1290 --- /dev/null +++ b/doc/man/nvme_set_features_write_protect.2 @@ -0,0 +1,21 @@ +.TH "nvme_set_features_write_protect" 2 "nvme_set_features_write_protect" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_features_write_protect \- +.SH SYNOPSIS +.B "int" nvme_set_features_write_protect +.BI "(int " fd "," +.BI "enum nvme_feat_nswpcfg_state " state "," +.BI "bool " save "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "state" 12 +-- undescribed -- +.IP "save" 12 +Save value across power states +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_set_property.2 b/doc/man/nvme_set_property.2 new file mode 100644 index 00000000..307fc104 --- /dev/null +++ b/doc/man/nvme_set_property.2 @@ -0,0 +1,21 @@ +.TH "nvme_set_property" 2 "nvme_set_property" "February 2020" "libnvme Manual" +.SH NAME +nvme_set_property \- Set controller property +.SH SYNOPSIS +.B "int" nvme_set_property +.BI "(int " fd "," +.BI "int " offset "," +.BI "__u64 " value ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "offset" 12 +Property offset from the base to set +.IP "value" 12 +The value to set the property +.SH "DESCRIPTION" +This is an NVMe-over-Fabrics specific command, not applicable to PCIe. These +properties align to the PCI MMIO controller registers. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_setup_ctrl_list.2 b/doc/man/nvme_setup_ctrl_list.2 new file mode 100644 index 00000000..53ff1955 --- /dev/null +++ b/doc/man/nvme_setup_ctrl_list.2 @@ -0,0 +1,15 @@ +.TH "nvme_setup_ctrl_list" 2 "nvme_setup_ctrl_list" "February 2020" "libnvme Manual" +.SH NAME +nvme_setup_ctrl_list \- +.SH SYNOPSIS +.B "void" nvme_setup_ctrl_list +.BI "(struct nvme_ctrl_list *" cntlist "," +.BI "__u16 " num_ctrls "," +.BI "__u16 *" ctrlist ");" +.SH ARGUMENTS +.IP "cntlist" 12 +-- undescribed -- +.IP "num_ctrls" 12 +-- undescribed -- +.IP "ctrlist" 12 +-- undescribed -- diff --git a/doc/man/nvme_setup_dsm_range.2 b/doc/man/nvme_setup_dsm_range.2 new file mode 100644 index 00000000..9f7b9dc5 --- /dev/null +++ b/doc/man/nvme_setup_dsm_range.2 @@ -0,0 +1,26 @@ +.TH "nvme_setup_dsm_range" 2 "nvme_setup_dsm_range" "February 2020" "libnvme Manual" +.SH NAME +nvme_setup_dsm_range \- Constructs a data set range structure +.SH SYNOPSIS +.B "void" nvme_setup_dsm_range +.BI "(struct nvme_dsm_range *" dsm "," +.BI "__u32 *" ctx_attrs "," +.BI "__u32 *" llbas "," +.BI "__u64 *" slbas "," +.BI "__u16 " nr_ranges ");" +.SH ARGUMENTS +.IP "dsm" 12 +DSM range array +.IP "ctx_attrs" 12 +Array of context attributes +.IP "llbas" 12 +Array of length in logical blocks +.IP "slbas" 12 +Array of starting logical blocks +.IP "nr_ranges" 12 +The size of the dsm arrays +.SH "DESCRIPTION" +Each array must be the same size of size 'nr_ranges'. +.SH "RETURN" +The nvme command status if a response was received or -errno +otherwise. diff --git a/doc/man/nvme_setup_id_ns.2 b/doc/man/nvme_setup_id_ns.2 new file mode 100644 index 00000000..ced1fa84 --- /dev/null +++ b/doc/man/nvme_setup_id_ns.2 @@ -0,0 +1,30 @@ +.TH "nvme_setup_id_ns" 2 "nvme_setup_id_ns" "February 2020" "libnvme Manual" +.SH NAME +nvme_setup_id_ns \- +.SH SYNOPSIS +.B "void" nvme_setup_id_ns +.BI "(struct nvme_id_ns *" ns "," +.BI "__u64 " nsze "," +.BI "__u64 " ncap "," +.BI "__u8 " flbas "," +.BI "__u8 " dps "," +.BI "__u8 " nmic "," +.BI "__u32 " anagrpid "," +.BI "__u16 " nvmsetid ");" +.SH ARGUMENTS +.IP "ns" 12 +-- undescribed -- +.IP "nsze" 12 +-- undescribed -- +.IP "ncap" 12 +-- undescribed -- +.IP "flbas" 12 +-- undescribed -- +.IP "dps" 12 +-- undescribed -- +.IP "nmic" 12 +-- undescribed -- +.IP "anagrpid" 12 +-- undescribed -- +.IP "nvmsetid" 12 +-- undescribed -- diff --git a/doc/man/nvme_status_to_errno.2 b/doc/man/nvme_status_to_errno.2 new file mode 100644 index 00000000..aca2e930 --- /dev/null +++ b/doc/man/nvme_status_to_errno.2 @@ -0,0 +1,16 @@ +.TH "nvme_status_to_errno" 2 "nvme_status_to_errno" "February 2020" "libnvme Manual" +.SH NAME +nvme_status_to_errno \- Converts nvme return status to errno +.SH SYNOPSIS +.B "__u8" nvme_status_to_errno +.BI "(int " status "," +.BI "bool " fabrics ");" +.SH ARGUMENTS +.IP "status" 12 +Return status from an nvme passthrough commmand +.IP "fabrics" 12 +true if given status is for fabrics +.SH "DESCRIPTION" +If status < 0, errno is already set. +.SH "RETURN" +Appropriate errno for the given nvme status diff --git a/doc/man/nvme_submit_admin_passthru.2 b/doc/man/nvme_submit_admin_passthru.2 new file mode 100644 index 00000000..46854048 --- /dev/null +++ b/doc/man/nvme_submit_admin_passthru.2 @@ -0,0 +1,20 @@ +.TH "nvme_submit_admin_passthru" 2 "nvme_submit_admin_passthru" "February 2020" "libnvme Manual" +.SH NAME +nvme_submit_admin_passthru \- Submit an nvme passthrough admin command +.SH SYNOPSIS +.B "int" nvme_submit_admin_passthru +.BI "(int " fd "," +.BI "struct nvme_passthru_cmd *" cmd "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "cmd" 12 +The nvme admin command to send +.IP "result" 12 +Optional field to return the result from the CQE DW0 +.SH "DESCRIPTION" +Uses NVME_IOCTL_ADMIN_CMD for the ioctl request. +.SH "RETURN" +The nvme command status if a response was received or -1 +with errno set otherwise. diff --git a/doc/man/nvme_submit_admin_passthru64.2 b/doc/man/nvme_submit_admin_passthru64.2 new file mode 100644 index 00000000..5763bfde --- /dev/null +++ b/doc/man/nvme_submit_admin_passthru64.2 @@ -0,0 +1,20 @@ +.TH "nvme_submit_admin_passthru64" 2 "nvme_submit_admin_passthru64" "February 2020" "libnvme Manual" +.SH NAME +nvme_submit_admin_passthru64 \- Submit a 64-bit nvme passthrough admin command +.SH SYNOPSIS +.B "int" nvme_submit_admin_passthru64 +.BI "(int " fd "," +.BI "struct nvme_passthru_cmd64 *" cmd "," +.BI "__u64 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "cmd" 12 +The nvme admin command to send +.IP "result" 12 +Optional field to return the result from the CQE DW0-1 +.SH "DESCRIPTION" +Uses NVME_IOCTL_ADMIN64_CMD for the ioctl request. +.SH "RETURN" +The nvme command status if a response was received or -1 +with errno set otherwise. diff --git a/doc/man/nvme_submit_io_passthru.2 b/doc/man/nvme_submit_io_passthru.2 new file mode 100644 index 00000000..7c425b09 --- /dev/null +++ b/doc/man/nvme_submit_io_passthru.2 @@ -0,0 +1,20 @@ +.TH "nvme_submit_io_passthru" 2 "nvme_submit_io_passthru" "February 2020" "libnvme Manual" +.SH NAME +nvme_submit_io_passthru \- Submit an nvme passthrough command +.SH SYNOPSIS +.B "int" nvme_submit_io_passthru +.BI "(int " fd "," +.BI "struct nvme_passthru_cmd *" cmd "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "cmd" 12 +The nvme io command to send +.IP "result" 12 +Optional field to return the result from the CQE DW0 +.SH "DESCRIPTION" +Uses NVME_IOCTL_IO_CMD for the ioctl request. +.SH "RETURN" +The nvme command status if a response was received or -1 +with errno set otherwise. diff --git a/doc/man/nvme_submit_io_passthru64.2 b/doc/man/nvme_submit_io_passthru64.2 new file mode 100644 index 00000000..9c408201 --- /dev/null +++ b/doc/man/nvme_submit_io_passthru64.2 @@ -0,0 +1,20 @@ +.TH "nvme_submit_io_passthru64" 2 "nvme_submit_io_passthru64" "February 2020" "libnvme Manual" +.SH NAME +nvme_submit_io_passthru64 \- Submit a 64-bit nvme passthrough command +.SH SYNOPSIS +.B "int" nvme_submit_io_passthru64 +.BI "(int " fd "," +.BI "struct nvme_passthru_cmd64 *" cmd "," +.BI "__u64 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "cmd" 12 +The nvme io command to send +.IP "result" 12 +Optional field to return the result from the CQE DW0-1 +.SH "DESCRIPTION" +Uses NVME_IOCTL_IO64_CMD for the ioctl request. +.SH "RETURN" +The nvme command status if a response was received or -1 +with errno set otherwise. diff --git a/doc/man/nvme_subsys_filter.2 b/doc/man/nvme_subsys_filter.2 new file mode 100644 index 00000000..272cd637 --- /dev/null +++ b/doc/man/nvme_subsys_filter.2 @@ -0,0 +1,8 @@ +.TH "nvme_subsys_filter" 2 "nvme_subsys_filter" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsys_filter \- +.SH SYNOPSIS +.B "int" nvme_subsys_filter +.BI "(const struct dirent *" d ");" +.SH ARGUMENTS +.IP "d" 12 diff --git a/doc/man/nvme_subsystem_first_ctrl.2 b/doc/man/nvme_subsystem_first_ctrl.2 new file mode 100644 index 00000000..fd7f2b99 --- /dev/null +++ b/doc/man/nvme_subsystem_first_ctrl.2 @@ -0,0 +1,8 @@ +.TH "nvme_subsystem_first_ctrl" 2 "nvme_subsystem_first_ctrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_first_ctrl \- +.SH SYNOPSIS +.B "nvme_ctrl_t" nvme_subsystem_first_ctrl +.BI "(nvme_subsystem_t " s ");" +.SH ARGUMENTS +.IP "s" 12 diff --git a/doc/man/nvme_subsystem_first_ns.2 b/doc/man/nvme_subsystem_first_ns.2 new file mode 100644 index 00000000..1045846e --- /dev/null +++ b/doc/man/nvme_subsystem_first_ns.2 @@ -0,0 +1,8 @@ +.TH "nvme_subsystem_first_ns" 2 "nvme_subsystem_first_ns" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_first_ns \- +.SH SYNOPSIS +.B "nvme_ns_t" nvme_subsystem_first_ns +.BI "(nvme_subsystem_t " s ");" +.SH ARGUMENTS +.IP "s" 12 diff --git a/doc/man/nvme_subsystem_for_each_ctrl.2 b/doc/man/nvme_subsystem_for_each_ctrl.2 new file mode 100644 index 00000000..9a829004 --- /dev/null +++ b/doc/man/nvme_subsystem_for_each_ctrl.2 @@ -0,0 +1,12 @@ +.TH "nvme_subsystem_for_each_ctrl" 2 "nvme_subsystem_for_each_ctrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_for_each_ctrl \- +.SH SYNOPSIS +.B "nvme_subsystem_for_each_ctrl +.BI "(" s "," +.BI "" c ");" +.SH ARGUMENTS +.IP "s" 12 +-- undescribed -- +.IP "c" 12 +-- undescribed -- diff --git a/doc/man/nvme_subsystem_for_each_ctrl_safe.2 b/doc/man/nvme_subsystem_for_each_ctrl_safe.2 new file mode 100644 index 00000000..44ea0d5a --- /dev/null +++ b/doc/man/nvme_subsystem_for_each_ctrl_safe.2 @@ -0,0 +1,15 @@ +.TH "nvme_subsystem_for_each_ctrl_safe" 2 "nvme_subsystem_for_each_ctrl_safe" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_for_each_ctrl_safe \- +.SH SYNOPSIS +.B "nvme_subsystem_for_each_ctrl_safe +.BI "(" s "," +.BI "" c "," +.BI "" _c ");" +.SH ARGUMENTS +.IP "s" 12 +-- undescribed -- +.IP "c" 12 +-- undescribed -- +.IP "_c" 12 +-- undescribed -- diff --git a/doc/man/nvme_subsystem_for_each_ns.2 b/doc/man/nvme_subsystem_for_each_ns.2 new file mode 100644 index 00000000..6a0be80c --- /dev/null +++ b/doc/man/nvme_subsystem_for_each_ns.2 @@ -0,0 +1,12 @@ +.TH "nvme_subsystem_for_each_ns" 2 "nvme_subsystem_for_each_ns" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_for_each_ns \- +.SH SYNOPSIS +.B "nvme_subsystem_for_each_ns +.BI "(" s "," +.BI "" n ");" +.SH ARGUMENTS +.IP "s" 12 +-- undescribed -- +.IP "n" 12 +-- undescribed -- diff --git a/doc/man/nvme_subsystem_for_each_ns_safe.2 b/doc/man/nvme_subsystem_for_each_ns_safe.2 new file mode 100644 index 00000000..e1cc8ff3 --- /dev/null +++ b/doc/man/nvme_subsystem_for_each_ns_safe.2 @@ -0,0 +1,15 @@ +.TH "nvme_subsystem_for_each_ns_safe" 2 "nvme_subsystem_for_each_ns_safe" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_for_each_ns_safe \- +.SH SYNOPSIS +.B "nvme_subsystem_for_each_ns_safe +.BI "(" s "," +.BI "" n "," +.BI "" _n ");" +.SH ARGUMENTS +.IP "s" 12 +-- undescribed -- +.IP "n" 12 +-- undescribed -- +.IP "_n" 12 +-- undescribed -- diff --git a/doc/man/nvme_subsystem_get_name.2 b/doc/man/nvme_subsystem_get_name.2 new file mode 100644 index 00000000..33cadbb3 --- /dev/null +++ b/doc/man/nvme_subsystem_get_name.2 @@ -0,0 +1,8 @@ +.TH "nvme_subsystem_get_name" 2 "nvme_subsystem_get_name" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_get_name \- +.SH SYNOPSIS +.B "const char *" nvme_subsystem_get_name +.BI "(nvme_subsystem_t " s ");" +.SH ARGUMENTS +.IP "s" 12 diff --git a/doc/man/nvme_subsystem_get_nqn.2 b/doc/man/nvme_subsystem_get_nqn.2 new file mode 100644 index 00000000..43e2d7b6 --- /dev/null +++ b/doc/man/nvme_subsystem_get_nqn.2 @@ -0,0 +1,8 @@ +.TH "nvme_subsystem_get_nqn" 2 "nvme_subsystem_get_nqn" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_get_nqn \- +.SH SYNOPSIS +.B "const char *" nvme_subsystem_get_nqn +.BI "(nvme_subsystem_t " s ");" +.SH ARGUMENTS +.IP "s" 12 diff --git a/doc/man/nvme_subsystem_get_sysfs_dir.2 b/doc/man/nvme_subsystem_get_sysfs_dir.2 new file mode 100644 index 00000000..9ed21040 --- /dev/null +++ b/doc/man/nvme_subsystem_get_sysfs_dir.2 @@ -0,0 +1,8 @@ +.TH "nvme_subsystem_get_sysfs_dir" 2 "nvme_subsystem_get_sysfs_dir" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_get_sysfs_dir \- +.SH SYNOPSIS +.B "const char *" nvme_subsystem_get_sysfs_dir +.BI "(nvme_subsystem_t " s ");" +.SH ARGUMENTS +.IP "s" 12 diff --git a/doc/man/nvme_subsystem_next_ctrl.2 b/doc/man/nvme_subsystem_next_ctrl.2 new file mode 100644 index 00000000..fce9cf3c --- /dev/null +++ b/doc/man/nvme_subsystem_next_ctrl.2 @@ -0,0 +1,11 @@ +.TH "nvme_subsystem_next_ctrl" 2 "nvme_subsystem_next_ctrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_next_ctrl \- +.SH SYNOPSIS +.B "nvme_ctrl_t" nvme_subsystem_next_ctrl +.BI "(nvme_subsystem_t " s "," +.BI "nvme_ctrl_t " c ");" +.SH ARGUMENTS +.IP "s" 12 +-- undescribed -- +.IP "c" 12 diff --git a/doc/man/nvme_subsystem_next_ns.2 b/doc/man/nvme_subsystem_next_ns.2 new file mode 100644 index 00000000..7f453447 --- /dev/null +++ b/doc/man/nvme_subsystem_next_ns.2 @@ -0,0 +1,11 @@ +.TH "nvme_subsystem_next_ns" 2 "nvme_subsystem_next_ns" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_next_ns \- +.SH SYNOPSIS +.B "nvme_ns_t" nvme_subsystem_next_ns +.BI "(nvme_subsystem_t " s "," +.BI "nvme_ns_t " n ");" +.SH ARGUMENTS +.IP "s" 12 +-- undescribed -- +.IP "n" 12 diff --git a/doc/man/nvme_subsystem_reset.2 b/doc/man/nvme_subsystem_reset.2 new file mode 100644 index 00000000..5ca788e2 --- /dev/null +++ b/doc/man/nvme_subsystem_reset.2 @@ -0,0 +1,14 @@ +.TH "nvme_subsystem_reset" 2 "nvme_subsystem_reset" "February 2020" "libnvme Manual" +.SH NAME +nvme_subsystem_reset \- Initiate a subsystem reset +.SH SYNOPSIS +.B "int" nvme_subsystem_reset +.BI "(int " fd ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.SH "DESCRIPTION" +This should only be sent to controller handles, not to namespaces. +.SH "RETURN" +Zero if a subsystem reset was initiated or -1 with errno set +otherwise. diff --git a/doc/man/nvme_unlink_ctrl.2 b/doc/man/nvme_unlink_ctrl.2 new file mode 100644 index 00000000..6fa9407d --- /dev/null +++ b/doc/man/nvme_unlink_ctrl.2 @@ -0,0 +1,9 @@ +.TH "nvme_unlink_ctrl" 2 "nvme_unlink_ctrl" "February 2020" "libnvme Manual" +.SH NAME +nvme_unlink_ctrl \- +.SH SYNOPSIS +.B "void" nvme_unlink_ctrl +.BI "(struct nvme_ctrl *" c ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- diff --git a/doc/man/nvme_verify.2 b/doc/man/nvme_verify.2 new file mode 100644 index 00000000..5b02470c --- /dev/null +++ b/doc/man/nvme_verify.2 @@ -0,0 +1,43 @@ +.TH "nvme_verify" 2 "nvme_verify" "February 2020" "libnvme Manual" +.SH NAME +nvme_verify \- Send an nvme verify command +.SH SYNOPSIS +.B "int" nvme_verify +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u64 " slba "," +.BI "__u16 " nlb "," +.BI "__u16 " control "," +.BI "__u32 " reftag "," +.BI "__u16 " apptag "," +.BI "__u16 " appmask ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace identifier +.IP "slba" 12 +Starting logical block +.IP "nlb" 12 +Number of logical blocks to verify (0's based value) +.IP "control" 12 +Command control flags, see \fIenum nvme_io_control_flags\fP. +.IP "reftag" 12 +This field specifies the Initial Logical Block Reference Tag +expected value. Used only if the namespace is formatted to use +end-to-end protection information. +.IP "apptag" 12 +This field specifies the Application Tag Mask expected value. +Used only if the namespace is formatted to use end-to-end +protection information. +.IP "appmask" 12 +This field specifies the Application Tag expected value. Used +only if the namespace is formatted to use end-to-end protection +information. +.SH "DESCRIPTION" +The Verify command verifies integrity of stored information by reading data +and metadata, if applicable, for the LBAs indicated without transferring any +data or metadata to the host. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_virtual_mgmt.2 b/doc/man/nvme_virtual_mgmt.2 new file mode 100644 index 00000000..bef9c634 --- /dev/null +++ b/doc/man/nvme_virtual_mgmt.2 @@ -0,0 +1,35 @@ +.TH "nvme_virtual_mgmt" 2 "nvme_virtual_mgmt" "February 2020" "libnvme Manual" +.SH NAME +nvme_virtual_mgmt \- Virtualization resource management +.SH SYNOPSIS +.B "int" nvme_virtual_mgmt +.BI "(int " fd "," +.BI "enum nvme_virt_mgmt_act " act "," +.BI "enum nvme_virt_mgmt_rt " rt "," +.BI "__u16 " cntlid "," +.BI "__u16 " nr "," +.BI "__u32 *" result ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "act" 12 +Virtual resource action, see \fIenum nvme_virt_mgmt_act\fP +.IP "rt" 12 +Resource type to modify, see \fIenum nvme_virt_mgmt_rt\fP +.IP "cntlid" 12 +Controller id for which resources are bing modified +.IP "nr" 12 +Number of resources being allocated or assigned +.IP "result" 12 +If successful, the CQE dword0 +.SH "DESCRIPTION" +The Virtualization Management command is supported by primary controllers +that support the Virtualization Enhancements capability. This command is +used for several functions: + +- Modifying Flexible Resource allocation for the primary controller +- Assigning Flexible Resources for secondary controllers +- Setting the Online and Offline state for secondary controllers +.SH "RETURN" +The nvme command status if a response was received or -1 +with errno set otherwise. diff --git a/doc/man/nvme_write.2 b/doc/man/nvme_write.2 new file mode 100644 index 00000000..55f3d0c5 --- /dev/null +++ b/doc/man/nvme_write.2 @@ -0,0 +1,58 @@ +.TH "nvme_write" 2 "nvme_write" "February 2020" "libnvme Manual" +.SH NAME +nvme_write \- Submit an nvme user write command +.SH SYNOPSIS +.B "int" nvme_write +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u64 " slba "," +.BI "__u16 " nlb "," +.BI "__u16 " control "," +.BI "__u8 " dsm "," +.BI "__u16 " dspec "," +.BI "__u32 " reftag "," +.BI "__u16 " apptag "," +.BI "__u16 " appmask "," +.BI "__u32 " data_len "," +.BI "void *" data "," +.BI "__u32 " metadata_len "," +.BI "void *" metadata ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "slba" 12 +Starting logical block +.IP "nlb" 12 +-- undescribed -- +.IP "control" 12 +Command control flags, see \fIenum nvme_io_control_flags\fP. +.IP "dsm" 12 +Data set management attributes, see \fIenum nvme_io_dsm_flags\fP +.IP "dspec" 12 +Directive specific command, eg: stream identifier +.IP "reftag" 12 +This field specifies the Initial Logical Block Reference Tag +expected value. Used only if the namespace is formatted to use +end-to-end protection information. +.IP "apptag" 12 +This field specifies the Application Tag Mask expected value. +Used only if the namespace is formatted to use end-to-end +protection information. +.IP "appmask" 12 +This field specifies the Application Tag expected value. Used +only if the namespace is formatted to use end-to-end protection +information. +.IP "data_len" 12 +Length of user buffer, \fIdata\fP, in bytes +.IP "data" 12 +Pointer to user address of the data buffer +metadata_len:Length of user buffer, \fImetadata\fP, in bytes +.IP "metadata_len" 12 +-- undescribed -- +.IP "metadata" 12 +Pointer to user address of the metadata buffer +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_write_uncorrectable.2 b/doc/man/nvme_write_uncorrectable.2 new file mode 100644 index 00000000..53755c5a --- /dev/null +++ b/doc/man/nvme_write_uncorrectable.2 @@ -0,0 +1,27 @@ +.TH "nvme_write_uncorrectable" 2 "nvme_write_uncorrectable" "February 2020" "libnvme Manual" +.SH NAME +nvme_write_uncorrectable \- Submit an nvme write uncorrectable command +.SH SYNOPSIS +.B "int" nvme_write_uncorrectable +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u64 " slba "," +.BI "__u16 " nlb ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace identifier +.IP "slba" 12 +Starting logical block +.IP "nlb" 12 +Number of logical blocks to invalidate (0's based value) +.SH "DESCRIPTION" +The Write Uncorrectable command is used to mark a range of logical blocks as +invalid. When the specified logical block(s) are read after this operation, +a failure is returned with Unrecovered Read Error status. To clear the +invalid logical block status, a write operation on those logical blocks is +required. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvme_write_zeros.2 b/doc/man/nvme_write_zeros.2 new file mode 100644 index 00000000..b37919a2 --- /dev/null +++ b/doc/man/nvme_write_zeros.2 @@ -0,0 +1,44 @@ +.TH "nvme_write_zeros" 2 "nvme_write_zeros" "February 2020" "libnvme Manual" +.SH NAME +nvme_write_zeros \- Submit an nvme write zeroes command +.SH SYNOPSIS +.B "int" nvme_write_zeros +.BI "(int " fd "," +.BI "__u32 " nsid "," +.BI "__u64 " slba "," +.BI "__u16 " nlb "," +.BI "__u16 " control "," +.BI "__u32 " reftag "," +.BI "__u16 " apptag "," +.BI "__u16 " appmask ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace identifier +.IP "slba" 12 +Starting logical block +.IP "nlb" 12 +Number of logical blocks to clear (0's based value) +.IP "control" 12 +Command control flags, see \fIenum nvme_io_control_flags\fP. +.IP "reftag" 12 +This field specifies the Initial Logical Block Reference Tag +expected value. Used only if the namespace is formatted to use +end-to-end protection information. +.IP "apptag" 12 +This field specifies the Application Tag Mask expected value. +Used only if the namespace is formatted to use end-to-end +protection information. +.IP "appmask" 12 +This field specifies the Application Tag expected value. Used +only if the namespace is formatted to use end-to-end protection +information. +.SH "DESCRIPTION" +The Write Zeroes command is used to set a range of logical blocks to zero. +After successful completion of this command, the value returned by +subsequent reads of logical blocks in this range shall be all bytes cleared +to 0h until a write occurs to this LBA range. +.SH "RETURN" +The nvme command status if a response was received or -1 with errno +set otherwise. diff --git a/doc/man/nvmf_add_ctrl.2 b/doc/man/nvmf_add_ctrl.2 new file mode 100644 index 00000000..61d54cb4 --- /dev/null +++ b/doc/man/nvmf_add_ctrl.2 @@ -0,0 +1,9 @@ +.TH "nvmf_add_ctrl" 2 "nvmf_add_ctrl" "February 2020" "libnvme Manual" +.SH NAME +nvmf_add_ctrl \- +.SH SYNOPSIS +.B "nvme_ctrl_t" nvmf_add_ctrl +.BI "(struct nvme_fabrics_config *" cfg ");" +.SH ARGUMENTS +.IP "cfg" 12 +-- undescribed -- diff --git a/doc/man/nvmf_add_ctrl_opts.2 b/doc/man/nvmf_add_ctrl_opts.2 new file mode 100644 index 00000000..00094fc0 --- /dev/null +++ b/doc/man/nvmf_add_ctrl_opts.2 @@ -0,0 +1,9 @@ +.TH "nvmf_add_ctrl_opts" 2 "nvmf_add_ctrl_opts" "February 2020" "libnvme Manual" +.SH NAME +nvmf_add_ctrl_opts \- +.SH SYNOPSIS +.B "int" nvmf_add_ctrl_opts +.BI "(struct nvme_fabrics_config *" cfg ");" +.SH ARGUMENTS +.IP "cfg" 12 +-- undescribed -- diff --git a/doc/man/nvmf_adrfam_str.2 b/doc/man/nvmf_adrfam_str.2 new file mode 100644 index 00000000..57aecef7 --- /dev/null +++ b/doc/man/nvmf_adrfam_str.2 @@ -0,0 +1,9 @@ +.TH "nvmf_adrfam_str" 2 "nvmf_adrfam_str" "February 2020" "libnvme Manual" +.SH NAME +nvmf_adrfam_str \- +.SH SYNOPSIS +.B "const char *" nvmf_adrfam_str +.BI "(__u8 " adrfam ");" +.SH ARGUMENTS +.IP "adrfam" 12 +-- undescribed -- diff --git a/doc/man/nvmf_cms_str.2 b/doc/man/nvmf_cms_str.2 new file mode 100644 index 00000000..51f7214f --- /dev/null +++ b/doc/man/nvmf_cms_str.2 @@ -0,0 +1,9 @@ +.TH "nvmf_cms_str" 2 "nvmf_cms_str" "February 2020" "libnvme Manual" +.SH NAME +nvmf_cms_str \- +.SH SYNOPSIS +.B "const char *" nvmf_cms_str +.BI "(__u8 " cm ");" +.SH ARGUMENTS +.IP "cm" 12 +-- undescribed -- diff --git a/doc/man/nvmf_connect_disc_entry.2 b/doc/man/nvmf_connect_disc_entry.2 new file mode 100644 index 00000000..1f07ece1 --- /dev/null +++ b/doc/man/nvmf_connect_disc_entry.2 @@ -0,0 +1,15 @@ +.TH "nvmf_connect_disc_entry" 2 "nvmf_connect_disc_entry" "February 2020" "libnvme Manual" +.SH NAME +nvmf_connect_disc_entry \- +.SH SYNOPSIS +.B "nvme_ctrl_t" nvmf_connect_disc_entry +.BI "(struct nvmf_disc_log_entry *" e "," +.BI "const struct nvme_fabrics_config *" defcfg "," +.BI "bool *" discover ");" +.SH ARGUMENTS +.IP "e" 12 +-- undescribed -- +.IP "defcfg" 12 +-- undescribed -- +.IP "discover" 12 +-- undescribed -- diff --git a/doc/man/nvmf_get_discovery_log.2 b/doc/man/nvmf_get_discovery_log.2 new file mode 100644 index 00000000..55e9e62c --- /dev/null +++ b/doc/man/nvmf_get_discovery_log.2 @@ -0,0 +1,15 @@ +.TH "nvmf_get_discovery_log" 2 "nvmf_get_discovery_log" "February 2020" "libnvme Manual" +.SH NAME +nvmf_get_discovery_log \- +.SH SYNOPSIS +.B "int" nvmf_get_discovery_log +.BI "(nvme_ctrl_t " c "," +.BI "struct nvmf_discovery_log **" logp "," +.BI "int " max_retries ");" +.SH ARGUMENTS +.IP "c" 12 +-- undescribed -- +.IP "logp" 12 +-- undescribed -- +.IP "max_retries" 12 +-- undescribed -- diff --git a/doc/man/nvmf_hostid_from_file.2 b/doc/man/nvmf_hostid_from_file.2 new file mode 100644 index 00000000..bf0132f9 --- /dev/null +++ b/doc/man/nvmf_hostid_from_file.2 @@ -0,0 +1,6 @@ +.TH "nvmf_hostid_from_file" 2 "nvmf_hostid_from_file" "February 2020" "libnvme Manual" +.SH NAME +nvmf_hostid_from_file \- +.SH SYNOPSIS +.B "char *" nvmf_hostid_from_file +.SH ARGUMENTS diff --git a/doc/man/nvmf_hostnqn_from_file.2 b/doc/man/nvmf_hostnqn_from_file.2 new file mode 100644 index 00000000..0db32664 --- /dev/null +++ b/doc/man/nvmf_hostnqn_from_file.2 @@ -0,0 +1,6 @@ +.TH "nvmf_hostnqn_from_file" 2 "nvmf_hostnqn_from_file" "February 2020" "libnvme Manual" +.SH NAME +nvmf_hostnqn_from_file \- +.SH SYNOPSIS +.B "char *" nvmf_hostnqn_from_file +.SH ARGUMENTS diff --git a/doc/man/nvmf_hostnqn_generate.2 b/doc/man/nvmf_hostnqn_generate.2 new file mode 100644 index 00000000..59e65069 --- /dev/null +++ b/doc/man/nvmf_hostnqn_generate.2 @@ -0,0 +1,6 @@ +.TH "nvmf_hostnqn_generate" 2 "nvmf_hostnqn_generate" "February 2020" "libnvme Manual" +.SH NAME +nvmf_hostnqn_generate \- +.SH SYNOPSIS +.B "char *" nvmf_hostnqn_generate +.SH ARGUMENTS diff --git a/doc/man/nvmf_prtype_str.2 b/doc/man/nvmf_prtype_str.2 new file mode 100644 index 00000000..812a35e3 --- /dev/null +++ b/doc/man/nvmf_prtype_str.2 @@ -0,0 +1,9 @@ +.TH "nvmf_prtype_str" 2 "nvmf_prtype_str" "February 2020" "libnvme Manual" +.SH NAME +nvmf_prtype_str \- +.SH SYNOPSIS +.B "const char *" nvmf_prtype_str +.BI "(__u8 " prtype ");" +.SH ARGUMENTS +.IP "prtype" 12 +-- undescribed -- diff --git a/doc/man/nvmf_qptype_str.2 b/doc/man/nvmf_qptype_str.2 new file mode 100644 index 00000000..61a524fa --- /dev/null +++ b/doc/man/nvmf_qptype_str.2 @@ -0,0 +1,9 @@ +.TH "nvmf_qptype_str" 2 "nvmf_qptype_str" "February 2020" "libnvme Manual" +.SH NAME +nvmf_qptype_str \- +.SH SYNOPSIS +.B "const char *" nvmf_qptype_str +.BI "(__u8 " qptype ");" +.SH ARGUMENTS +.IP "qptype" 12 +-- undescribed -- diff --git a/doc/man/nvmf_sectype_str.2 b/doc/man/nvmf_sectype_str.2 new file mode 100644 index 00000000..1f6058fb --- /dev/null +++ b/doc/man/nvmf_sectype_str.2 @@ -0,0 +1,9 @@ +.TH "nvmf_sectype_str" 2 "nvmf_sectype_str" "February 2020" "libnvme Manual" +.SH NAME +nvmf_sectype_str \- +.SH SYNOPSIS +.B "const char *" nvmf_sectype_str +.BI "(__u8 " sectype ");" +.SH ARGUMENTS +.IP "sectype" 12 +-- undescribed -- diff --git a/doc/man/nvmf_subtype_str.2 b/doc/man/nvmf_subtype_str.2 new file mode 100644 index 00000000..40cc9749 --- /dev/null +++ b/doc/man/nvmf_subtype_str.2 @@ -0,0 +1,9 @@ +.TH "nvmf_subtype_str" 2 "nvmf_subtype_str" "February 2020" "libnvme Manual" +.SH NAME +nvmf_subtype_str \- +.SH SYNOPSIS +.B "const char *" nvmf_subtype_str +.BI "(__u8 " subtype ");" +.SH ARGUMENTS +.IP "subtype" 12 +-- undescribed -- diff --git a/doc/man/nvmf_treq_str.2 b/doc/man/nvmf_treq_str.2 new file mode 100644 index 00000000..4d5c292e --- /dev/null +++ b/doc/man/nvmf_treq_str.2 @@ -0,0 +1,9 @@ +.TH "nvmf_treq_str" 2 "nvmf_treq_str" "February 2020" "libnvme Manual" +.SH NAME +nvmf_treq_str \- +.SH SYNOPSIS +.B "const char *" nvmf_treq_str +.BI "(__u8 " treq ");" +.SH ARGUMENTS +.IP "treq" 12 +-- undescribed -- diff --git a/doc/man/nvmf_trtype_str.2 b/doc/man/nvmf_trtype_str.2 new file mode 100644 index 00000000..afcff2f1 --- /dev/null +++ b/doc/man/nvmf_trtype_str.2 @@ -0,0 +1,9 @@ +.TH "nvmf_trtype_str" 2 "nvmf_trtype_str" "February 2020" "libnvme Manual" +.SH NAME +nvmf_trtype_str \- +.SH SYNOPSIS +.B "const char *" nvmf_trtype_str +.BI "(__u8 " trtype ");" +.SH ARGUMENTS +.IP "trtype" 12 +-- undescribed -- diff --git a/doc/man/struct nvme_aggregate_endurance_group_event.2 b/doc/man/struct nvme_aggregate_endurance_group_event.2 new file mode 100644 index 00000000..0325867d --- /dev/null +++ b/doc/man/struct nvme_aggregate_endurance_group_event.2 @@ -0,0 +1,15 @@ +.TH "libnvme" 2 "struct nvme_aggregate_endurance_group_event" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_aggregate_endurance_group_event \- +.SH SYNOPSIS +struct nvme_aggregate_endurance_group_event { +.br +.BI " __le64 num_entries;" +.br +.BI " __le16 entries[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_aggregate_predictable_lat_event.2 b/doc/man/struct nvme_aggregate_predictable_lat_event.2 new file mode 100644 index 00000000..963591ed --- /dev/null +++ b/doc/man/struct nvme_aggregate_predictable_lat_event.2 @@ -0,0 +1,15 @@ +.TH "libnvme" 2 "struct nvme_aggregate_predictable_lat_event" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_aggregate_predictable_lat_event \- +.SH SYNOPSIS +struct nvme_aggregate_predictable_lat_event { +.br +.BI " __le64 num_entries;" +.br +.BI " __le16 entries[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_ana_group_desc.2 b/doc/man/struct nvme_ana_group_desc.2 new file mode 100644 index 00000000..5e5722e1 --- /dev/null +++ b/doc/man/struct nvme_ana_group_desc.2 @@ -0,0 +1,23 @@ +.TH "libnvme" 2 "struct nvme_ana_group_desc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_ana_group_desc \- +.SH SYNOPSIS +struct nvme_ana_group_desc { +.br +.BI " __le32 grpid;" +.br +.BI " __le32 nnsids;" +.br +.BI " __le64 chgcnt;" +.br +.BI " __u8 state;" +.br +.BI " __u8 rsvd17[15];" +.br +.BI " __le32 nsids[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_ana_log.2 b/doc/man/struct nvme_ana_log.2 new file mode 100644 index 00000000..8d0176d4 --- /dev/null +++ b/doc/man/struct nvme_ana_log.2 @@ -0,0 +1,19 @@ +.TH "libnvme" 2 "struct nvme_ana_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_ana_log \- +.SH SYNOPSIS +struct nvme_ana_log { +.br +.BI " __le64 chgcnt;" +.br +.BI " __le16 ngrps;" +.br +.BI " __u8 rsvd10[6];" +.br +.BI " struct nvme_ana_group_desc descs[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_cmd_effects_log.2 b/doc/man/struct nvme_cmd_effects_log.2 new file mode 100644 index 00000000..0ddfb551 --- /dev/null +++ b/doc/man/struct nvme_cmd_effects_log.2 @@ -0,0 +1,17 @@ +.TH "libnvme" 2 "struct nvme_cmd_effects_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_cmd_effects_log \- +.SH SYNOPSIS +struct nvme_cmd_effects_log { +.br +.BI " __le32 acs[256];" +.br +.BI " __le32 iocs[256];" +.br +.BI " __u8 resv[2048];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_ctrl_list.2 b/doc/man/struct nvme_ctrl_list.2 new file mode 100644 index 00000000..70fc9e0e --- /dev/null +++ b/doc/man/struct nvme_ctrl_list.2 @@ -0,0 +1,15 @@ +.TH "libnvme" 2 "struct nvme_ctrl_list" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_ctrl_list \- @num; +.SH SYNOPSIS +struct nvme_ctrl_list { +.br +.BI " __le16 num;" +.br +.BI " __le16 identifier[NVME_ID_CTRL_LIST_MAX];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_dsm_range.2 b/doc/man/struct nvme_dsm_range.2 new file mode 100644 index 00000000..ef9b4d0b --- /dev/null +++ b/doc/man/struct nvme_dsm_range.2 @@ -0,0 +1,17 @@ +.TH "libnvme" 2 "struct nvme_dsm_range" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_dsm_range \- +.SH SYNOPSIS +struct nvme_dsm_range { +.br +.BI " __le32 cattr;" +.br +.BI " __le32 nlb;" +.br +.BI " __le64 slba;" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_eg_event_aggregate_log.2 b/doc/man/struct nvme_eg_event_aggregate_log.2 new file mode 100644 index 00000000..15e19159 --- /dev/null +++ b/doc/man/struct nvme_eg_event_aggregate_log.2 @@ -0,0 +1,15 @@ +.TH "libnvme" 2 "struct nvme_eg_event_aggregate_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_eg_event_aggregate_log \- +.SH SYNOPSIS +struct nvme_eg_event_aggregate_log { +.br +.BI " __le64 nr_entries;" +.br +.BI " __le16 egids[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_endurance_group_log.2 b/doc/man/struct nvme_endurance_group_log.2 new file mode 100644 index 00000000..48e75e86 --- /dev/null +++ b/doc/man/struct nvme_endurance_group_log.2 @@ -0,0 +1,41 @@ +.TH "libnvme" 2 "struct nvme_endurance_group_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_endurance_group_log \- +.SH SYNOPSIS +struct nvme_endurance_group_log { +.br +.BI " __u8 critical_warning;" +.br +.BI " __u8 rsvd1[2];" +.br +.BI " __u8 avl_spare;" +.br +.BI " __u8 avl_spare_threshold;" +.br +.BI " __u8 percent_used;" +.br +.BI " __u8 rsvd6[26];" +.br +.BI " __u8 endurance_estimate[16];" +.br +.BI " __u8 data_units_read[16];" +.br +.BI " __u8 data_units_written[16];" +.br +.BI " __u8 media_units_written[16];" +.br +.BI " __u8 host_read_cmds[16];" +.br +.BI " __u8 host_write_cmds[16];" +.br +.BI " __u8 media_data_integrity_err[16];" +.br +.BI " __u8 num_err_info_log_entries[16];" +.br +.BI " __u8 rsvd160[352];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_error_log_page.2 b/doc/man/struct nvme_error_log_page.2 new file mode 100644 index 00000000..48ee5cb2 --- /dev/null +++ b/doc/man/struct nvme_error_log_page.2 @@ -0,0 +1,37 @@ +.TH "libnvme" 2 "struct nvme_error_log_page" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_error_log_page \- +.SH SYNOPSIS +struct nvme_error_log_page { +.br +.BI " __le64 error_count;" +.br +.BI " __le16 sqid;" +.br +.BI " __le16 cmdid;" +.br +.BI " __le16 status_field;" +.br +.BI " __le16 parm_error_location;" +.br +.BI " __le64 lba;" +.br +.BI " __le32 nsid;" +.br +.BI " __u8 vs;" +.br +.BI " __u8 trtype;" +.br +.BI " __u8 resv[2];" +.br +.BI " __le64 cs;" +.br +.BI " __le16 trtype_spec_info;" +.br +.BI " __u8 resv2[22];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_fabrics_config.2 b/doc/man/struct nvme_fabrics_config.2 new file mode 100644 index 00000000..ebc8f260 --- /dev/null +++ b/doc/man/struct nvme_fabrics_config.2 @@ -0,0 +1,51 @@ +.TH "libnvme" 2 "struct nvme_fabrics_config" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_fabrics_config \- +.SH SYNOPSIS +struct nvme_fabrics_config { +.br +.BI " const char *transport;" +.br +.BI " const char *traddr;" +.br +.BI " const char *trsvcid;" +.br +.BI " const char *nqn;" +.br +.BI " const char *hostnqn;" +.br +.BI " const char *host_traddr;" +.br +.BI " const char *hostid;" +.br +.BI " int queue_size;" +.br +.BI " int nr_io_queues;" +.br +.BI " int reconnect_delay;" +.br +.BI " int ctrl_loss_tmo;" +.br +.BI " int keep_alive_tmo;" +.br +.BI " int nr_write_queues;" +.br +.BI " int nr_poll_queues;" +.br +.BI " int tos;" +.br +.BI " bool duplicate_connect;" +.br +.BI " bool disable_sqflow;" +.br +.BI " bool hdr_digest;" +.br +.BI " bool data_digest;" +.br +.BI " uint8_t rsvd[0x200];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_feat_auto_pst.2 b/doc/man/struct nvme_feat_auto_pst.2 new file mode 100644 index 00000000..4642cecc --- /dev/null +++ b/doc/man/struct nvme_feat_auto_pst.2 @@ -0,0 +1,13 @@ +.TH "libnvme" 2 "struct nvme_feat_auto_pst" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_feat_auto_pst \- +.SH SYNOPSIS +struct nvme_feat_auto_pst { +.br +.BI " __le64 apst_entry[32];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_feat_host_behavior.2 b/doc/man/struct nvme_feat_host_behavior.2 new file mode 100644 index 00000000..5950a725 --- /dev/null +++ b/doc/man/struct nvme_feat_host_behavior.2 @@ -0,0 +1,15 @@ +.TH "libnvme" 2 "struct nvme_feat_host_behavior" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_feat_host_behavior \- +.SH SYNOPSIS +struct nvme_feat_host_behavior { +.br +.BI " __u8 acre;" +.br +.BI " __u8 resv1[511];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_firmware_slot.2 b/doc/man/struct nvme_firmware_slot.2 new file mode 100644 index 00000000..b98c8a23 --- /dev/null +++ b/doc/man/struct nvme_firmware_slot.2 @@ -0,0 +1,19 @@ +.TH "libnvme" 2 "struct nvme_firmware_slot" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_firmware_slot \- +.SH SYNOPSIS +struct nvme_firmware_slot { +.br +.BI " __u8 afi;" +.br +.BI " __u8 resv[7];" +.br +.BI " struct nvme_frs frs[7];" +.br +.BI " __u8 resv2[448];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_frs.2 b/doc/man/struct nvme_frs.2 new file mode 100644 index 00000000..7ee2e706 --- /dev/null +++ b/doc/man/struct nvme_frs.2 @@ -0,0 +1,13 @@ +.TH "libnvme" 2 "struct nvme_frs" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_frs \- +.SH SYNOPSIS +struct nvme_frs { +.br +.BI " char frs[8];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_host_mem_buf_desc.2 b/doc/man/struct nvme_host_mem_buf_desc.2 new file mode 100644 index 00000000..66bead31 --- /dev/null +++ b/doc/man/struct nvme_host_mem_buf_desc.2 @@ -0,0 +1,17 @@ +.TH "libnvme" 2 "struct nvme_host_mem_buf_desc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_host_mem_buf_desc \- +.SH SYNOPSIS +struct nvme_host_mem_buf_desc { +.br +.BI " __le64 addr;" +.br +.BI " __le32 size;" +.br +.BI " __u32 rsvd;" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_id_ctrl.2 b/doc/man/struct nvme_id_ctrl.2 new file mode 100644 index 00000000..f3dab11b --- /dev/null +++ b/doc/man/struct nvme_id_ctrl.2 @@ -0,0 +1,455 @@ +.TH "libnvme" 2 "struct nvme_id_ctrl" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_id_ctrl \- Identify Controller data structure +.SH SYNOPSIS +struct nvme_id_ctrl { +.br +.BI " __le16 vid;" +.br +.BI " __le16 ssvid;" +.br +.BI " char sn[20];" +.br +.BI " char mn[40];" +.br +.BI " char fr[8];" +.br +.BI " __u8 rab;" +.br +.BI " __u8 ieee[3];" +.br +.BI " __u8 cmic;" +.br +.BI " __u8 mdts;" +.br +.BI " __le16 cntlid;" +.br +.BI " __le32 ver;" +.br +.BI " __le32 rtd3r;" +.br +.BI " __le32 rtd3e;" +.br +.BI " __le32 oaes;" +.br +.BI " __le32 ctratt;" +.br +.BI " __le16 rrls;" +.br +.BI " __u8 rsvd102[9];" +.br +.BI " __u8 cntrltype;" +.br +.BI " __u8 fguid[16];" +.br +.BI " __le16 crdt1;" +.br +.BI " __le16 crdt2;" +.br +.BI " __le16 crdt3;" +.br +.BI " __u8 rsvd134[119];" +.br +.BI " __u8 nvmsr;" +.br +.BI " __u8 vwci;" +.br +.BI " __u8 mec;" +.br +.BI " __le16 oacs;" +.br +.BI " __u8 acl;" +.br +.BI " __u8 aerl;" +.br +.BI " __u8 frmw;" +.br +.BI " __u8 lpa;" +.br +.BI " __u8 elpe;" +.br +.BI " __u8 npss;" +.br +.BI " __u8 avscc;" +.br +.BI " __u8 apsta;" +.br +.BI " __le16 wctemp;" +.br +.BI " __le16 cctemp;" +.br +.BI " __le16 mtfa;" +.br +.BI " __le32 hmpre;" +.br +.BI " __le32 hmmin;" +.br +.BI " __u8 tnvmcap[16];" +.br +.BI " __u8 unvmcap[16];" +.br +.BI " __le32 rpmbs;" +.br +.BI " __le16 edstt;" +.br +.BI " __u8 dsto;" +.br +.BI " __u8 fwug;" +.br +.BI " __le16 kas;" +.br +.BI " __le16 hctma;" +.br +.BI " __le16 mntmt;" +.br +.BI " __le16 mxtmt;" +.br +.BI " __le32 sanicap;" +.br +.BI " __le32 hmminds;" +.br +.BI " __le16 hmmaxd;" +.br +.BI " __le16 nsetidmax;" +.br +.BI " __le16 endgidmax;" +.br +.BI " __u8 anatt;" +.br +.BI " __u8 anacap;" +.br +.BI " __le32 anagrpmax;" +.br +.BI " __le32 nanagrpid;" +.br +.BI " __le32 pels;" +.br +.BI " __u8 rsvd356[156];" +.br +.BI " __u8 sqes;" +.br +.BI " __u8 cqes;" +.br +.BI " __le16 maxcmd;" +.br +.BI " __le32 nn;" +.br +.BI " __le16 oncs;" +.br +.BI " __le16 fuses;" +.br +.BI " __u8 fna;" +.br +.BI " __u8 vwc;" +.br +.BI " __le16 awun;" +.br +.BI " __le16 awupf;" +.br +.BI " __u8 nvscc;" +.br +.BI " __u8 nwpc;" +.br +.BI " __le16 acwu;" +.br +.BI " __u8 rsvd534[2];" +.br +.BI " __le32 sgls;" +.br +.BI " __le32 mnan;" +.br +.BI " __u8 rsvd544[224];" +.br +.BI " char subnqn[256];" +.br +.BI " __u8 rsvd1024[768];" +.br +.BI " __le32 ioccsz;" +.br +.BI " __le32 iorcsz;" +.br +.BI " __le16 icdoff;" +.br +.BI " __u8 fcatt;" +.br +.BI " __u8 msdbd;" +.br +.BI " __le16 ofcs;" +.br +.BI " __u8 rsvd1806[242];" +.br +.BI " struct nvme_id_psd psd[32];" +.br +.BI " __u8 vs[1024];" +.br +.BI " +}; +.br + +.SH Members +.IP "vid" 12 +PCI Vendor ID, the company vendor identifier that is assigned by +the PCI SIG. +.IP "ssvid" 12 +PCI Subsystem Vendor ID, the company vendor identifier that is +assigned by the PCI SIG for the subsystem. +.IP "sn" 12 +Serial Number in ascii +.IP "mn" 12 +Model Number in ascii +.IP "fr" 12 +Firmware Revision in ascii, the currently active firmware +revision for the NVM subsystem +.IP "rab" 12 +Recommended Arbitration Burst, reported as a power of two +.IP "ieee" 12 +IEEE assigned Organization Unique Identifier +.IP "cmic" 12 +Controller Multipath IO and Namespace Sharing Capabilities of +the controller and NVM subsystem. See \fIenum nvme_id_ctrl_cmic\fP. +.IP "mdts" 12 +Max Data Transfer Size is the largest data transfer size. The +host should not submit a command that exceeds this maximum data +transfer size. The value is in units of the minimum memory page +size (CAP.MPSMIN) and is reported as a power of two +.IP "cntlid" 12 +Controller ID, the NVM subsystem unique controller identifier +associated with the controller. +.IP "ver" 12 +Version, this field contains the value reported in the Version +register, or property (see \fIenum nvme_registers\fP NVME_REG_VS). +.IP "rtd3r" 12 +RTD3 Resume Latency, the expected latency in microseconds to resume +from Runtime D3 +.IP "rtd3e" 12 +RTD3 Exit Latency, the typical latency in microseconds to enter +Runtime D3. +.IP "oaes" 12 +Optional Async Events Supported, see \fIenum\fP nvme_id_ctrl_oaes . +.IP "ctratt" 12 +Controller Attributes, see \fIenum\fP nvme_id_ctrl_ctratt +.IP "rrls" 12 +Read Recovery Levels. If a bit is set, then the corresponding +Read Recovery Level is supported. If a bit is cleared, then the +corresponding Read Recovery Level is not supported. +.IP "cntrltype" 12 +Controller Type, see \fIenum nvme_id_ctrl_cntrltype\fP +.IP "fguid" 12 +FRU GUID, a 128-bit value that is globally unique for a given +Field Replaceable Unit +.IP "crdt1" 12 +Controller Retry Delay time in 100 millisecod units if CQE CRD +field is 1 +.IP "crdt2" 12 +Controller Retry Delay time in 100 millisecod units if CQE CRD +field is 2 +.IP "crdt3" 12 +Controller Retry Delay time in 100 millisecod units if CQE CRD +field is 3 +.IP "nvmsr" 12 +NVM Subsystem Report, see \fIenum nvme_id_ctrl_nvmsr\fP +.IP "vwci" 12 +VPD Write Cycle Information, see \fIenum nvme_id_ctrl_vwci\fP +.IP "mec" 12 +Management Endpoint Capabilities, see \fIenum nvme_id_ctrl_mec\fP +.IP "oacs" 12 +Optional Admin Command Support,the optional Admin commands and +features supported by the controller, see \fIenum nvme_id_ctrl_oacs\fP. +.IP "acl" 12 +Abort Command Limit, the maximum number of concurrently +executing Abort commands supported by the controller. This is a +0's based value. +.IP "aerl" 12 +Async Event Request Limit, the maximum number of concurrently +outstanding Asynchronous Event Request commands supported by the +controller This is a 0's based value. +.IP "frmw" 12 +Firmware Updates indicates capabilities regarding firmware +updates. See \fIenum nvme_id_ctrl_frmw\fP. +.IP "lpa" 12 +Log Page Attributes, see \fIenum nvme_id_ctrl_lpa\fP. +.IP "elpe" 12 +Error Log Page Entries, the maximum number of Error Information +log entries that are stored by the controller. This field is a +0's based value. +.IP "npss" 12 +Number of Power States Supported, the number of NVM Express +power states supported by the controller, indicating the number +of valid entries in \fIstruct nvme_id_ctrl\fP.psd. This is a 0's +based value. +.IP "avscc" 12 +Admin Vendor Specific Command Configuration, see \fIenum +nvme_id_ctrl_avscc\fP. +.IP "apsta" 12 +Autonomous Power State Transition Attributes, see \fIenum +nvme_id_ctrl_apsta\fP. +.IP "wctemp" 12 +Warning Composite Temperature Threshold indicates +the minimum Composite Temperature field value (see \fIstruct +nvme_smart_log\fP.critical_comp_time) that indicates an overheating +condition during which controller operation continues. +.IP "cctemp" 12 +Critical Composite Temperature Threshold, field indicates the +minimum Composite Temperature field value (see \fIstruct +nvme_smart_log\fP.critical_comp_time) that indicates a critical +overheating condition. +.IP "mtfa" 12 +Maximum Time for Firmware Activation indicates the maximum time +the controller temporarily stops processing commands to activate +the firmware image, specified in 100 millisecond units. This +field is always valid if the controller supports firmware +activation without a reset. +.IP "hmpre" 12 +Host Memory Buffer Preferred Size indicates the preferred size +that the host is requested to allocate for the Host Memory +Buffer feature in 4 KiB units. +.IP "hmmin" 12 +Host Memory Buffer Minimum Size indicates the minimum size that +the host is requested to allocate for the Host Memory Buffer +feature in 4 KiB units. +.IP "tnvmcap" 12 +Total NVM Capacity, the total NVM capacity in the NVM subsystem. +The value is in bytes. +.IP "unvmcap" 12 +Unallocated NVM Capacity, the unallocated NVM capacity in the +NVM subsystem. The value is in bytes. +\fIrpmbs\fP Replay Protected Memory Block Support, see \fIenum +nvme_id_ctrl_rpmbs\fP. +\fIedstt\fP Extended Device Self-test Time, if Device Self-test command is +supported (see \fIstruct nvme_id_ctrl\fP.oacs, NVME_CTRL_OACS_SELF_TEST), +then this field indicates the nominal amount of time in one +minute units that the controller takes to complete an extended +device self-test operation when in power state 0. +.IP "dsto" 12 +Device Self-test Options, see \fIenum nvme_id_ctrl_dsto\fP. +.IP "fwug" 12 +Firmware Update Granularity indicates the granularity and +alignment requirement of the firmware image being updated by the +Firmware Image Download command. The value is reported in 4 KiB +units. A value of 0h indicates no information on granularity is +provided. A value of FFh indicates no restriction +.IP "kas" 12 +Keep Alive Support indicates the granularity of the Keep Alive +Timer in 100 millisecond units. +.IP "hctma" 12 +Host Controlled Thermal Management Attributes, see \fIenum nvme_id_ctrl_hctm\fP. +.IP "mntmt" 12 +Minimum Thermal Management Temperature indicates the minimum +temperature, in degrees Kelvin, that the host may request in the +Thermal Management Temperature 1 field and Thermal Management +Temperature 2 field of a Set Features command with the Feature +Identifier field set to #NVME_FEAT_FID_HCTM. +.IP "mxtmt" 12 +Maximum Thermal Management Temperature indicates the maximum +temperature, in degrees Kelvin, that the host may request in the +Thermal Management Temperature 1 field and Thermal Management +Temperature 2 field of the Set Features command with the Feature +Identifier set to #NVME_FEAT_FID_HCTM. +.IP "sanicap" 12 +Sanitize Capabilities, see \fIenum nvme_id_ctrl_sanicap\fP +.IP "hmminds" 12 +Host Memory Buffer Minimum Descriptor Entry Size indicates the +minimum usable size of a Host Memory Buffer Descriptor Entry in +4 KiB units. +.IP "hmmaxd" 12 +Host Memory Maximum Descriptors Entries indicates the number of +usable Host Memory Buffer Descriptor Entries. +.IP "nsetidmax" 12 +NVM Set Identifier Maximum, defines the maximum value of a valid +NVM Set Identifier for any controller in the NVM subsystem. +.IP "endgidmax" 12 +Endurance Group Identifier Maximum, defines the maximum value of +a valid Endurance Group Identifier for any controller in the NVM +subsystem. +.IP "anatt" 12 +ANA Transition Time indicates the maximum amount of time, in +seconds, for a transition between ANA states or the maximum +amount of time, in seconds, that the controller reports the ANA +change state. +.IP "anacap" 12 +Asymmetric Namespace Access Capabilities, see \fIenum +nvme_id_ctrl_anacap\fP. +.IP "anagrpmax" 12 +ANA Group Identifier Maximum indicates the maximum value of a +valid ANA Group Identifier for any controller in the NVM +subsystem. +.IP "nanagrpid" 12 +Number of ANA Group Identifiers indicates the number of ANA +groups supported by this controller. +.IP "pels" 12 +Persistent Event Log Size indicates the maximum reportable size +for the Persistent Event Log. +.IP "sqes" 12 +Submission Queue Entry Size, see \fIenum nvme_id_ctrl_sqes\fP. +.IP "cqes" 12 +Completion Queue Entry Size, see \fIenum nvme_id_ctrl_cqes\fP. +.IP "maxcmd" 12 +Maximum Outstanding Commands indicates the maximum number of +commands that the controller processes at one time for a +particular queue. +.IP "nn" 12 +Number of Namespaces indicates the maximum value of a valid +nsid for the NVM subsystem. If the MNAN (\fIstruct nvme_id_ctrl\fP.mnan +field is cleared to 0h, then this field also indicates the +maximum number of namespaces supported by the NVM. subsystem. +.IP "oncs" 12 +Optional NVM Command Support, see \fIenum nvme_id_ctrl_oncs\fP. +.IP "fuses" 12 +Fused Operation Support, see \fIenum nvme_id_ctrl_fuses\fP. +.IP "fna" 12 +Format NVM Attributes, see \fIenum nvme_id_ctrl_fna\fP. +.IP "vwc" 12 +Volatile Write Cache, see \fIenum nvme_id_ctrl_vwc\fP. +.IP "awun" 12 +Atomic Write Unit Normal indicates the size of the write +operation guaranteed to be written atomically to the NVM across +all namespaces with any supported namespace format during normal +operation. This field is specified in logical blocks and is a +0's based value. +.IP "awupf" 12 +Atomic Write Unit Power Fail indicates the size of the write +operation guaranteed to be written atomically to the NVM across +all namespaces with any supported namespace format during a +power fail or error condition. This field is specified in +logical blocks and is a 0’s based value. +.IP "nvscc" 12 +NVM Vendor Specific Command Configuration, see \fIenum +nvme_id_ctrl_nvscc\fP. +.IP "nwpc" 12 +Namespace Write Protection Capabilities, see \fIenum +nvme_id_ctrl_nwpc\fP. +.IP "acwu" 12 +Atomic Compare & Write Unit indicates the size of the write +operation guaranteed to be written atomically to the NVM across +all namespaces with any supported namespace format for a Compare +and Write fused operation. This field is specified in logical +blocks and is a 0’s based value. +.IP "sgls" 12 +SGL Support, see \fIenum nvme_id_ctrl_sgls\fP +.IP "mnan" 12 +Maximum Number of Allowed Namespaces indicates the maximum +number of namespaces supported by the NVM subsystem. +.IP "subnqn" 12 +NVM Subsystem NVMe Qualified Name, UTF-8 null terminated string +.IP "ioccsz" 12 +I/O Queue Command Capsule Supported Size, defines the maximum +I/O command capsule size in 16 byte units. +.IP "iorcsz" 12 +I/O Queue Response Capsule Supported Size, defines the maximum +I/O response capsule size in 16 byte units. +.IP "icdoff" 12 +In Capsule Data Offset, defines the offset where data starts +within a capsule. This value is applicable to I/O Queues only. +.IP "fcatt" 12 +Fabrics Controller Attributes, see \fIenum nvme_id_ctrl_fcatt\fP. +.IP "msdbd" 12 +Maximum SGL Data Block Descriptors indicates the maximum +number of SGL Data Block or Keyed SGL Data Block descriptors +that a host is allowed to place in a capsule. A value of 0h +indicates no limit. +.IP "ofcs" 12 +Optional Fabric Commands Support, see \fIenum nvme_id_ctrl_ofcs\fP. +.IP "psd" 12 +Power State Descriptors, see \fIstruct nvme_id_psd\fP. +.IP "vs" 12 +Vendor Specific diff --git a/doc/man/struct nvme_id_directives.2 b/doc/man/struct nvme_id_directives.2 new file mode 100644 index 00000000..93818244 --- /dev/null +++ b/doc/man/struct nvme_id_directives.2 @@ -0,0 +1,17 @@ +.TH "libnvme" 2 "struct nvme_id_directives" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_id_directives \- +.SH SYNOPSIS +struct nvme_id_directives { +.br +.BI " __u8 supported[32];" +.br +.BI " __u8 enabled[32];" +.br +.BI " __u8 rsvd64[4032];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_id_ns.2 b/doc/man/struct nvme_id_ns.2 new file mode 100644 index 00000000..d4ea7588 --- /dev/null +++ b/doc/man/struct nvme_id_ns.2 @@ -0,0 +1,203 @@ +.TH "libnvme" 2 "struct nvme_id_ns" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_id_ns \- Identify Namespace data structure +.SH SYNOPSIS +struct nvme_id_ns { +.br +.BI " __le64 nsze;" +.br +.BI " __le64 ncap;" +.br +.BI " __le64 nuse;" +.br +.BI " __u8 nsfeat;" +.br +.BI " __u8 nlbaf;" +.br +.BI " __u8 flbas;" +.br +.BI " __u8 mc;" +.br +.BI " __u8 dpc;" +.br +.BI " __u8 dps;" +.br +.BI " __u8 nmic;" +.br +.BI " __u8 rescap;" +.br +.BI " __u8 fpi;" +.br +.BI " __u8 dlfeat;" +.br +.BI " __le16 nawun;" +.br +.BI " __le16 nawupf;" +.br +.BI " __le16 nacwu;" +.br +.BI " __le16 nabsn;" +.br +.BI " __le16 nabo;" +.br +.BI " __le16 nabspf;" +.br +.BI " __le16 noiob;" +.br +.BI " __u8 nvmcap[16];" +.br +.BI " __le16 npwg;" +.br +.BI " __le16 npwa;" +.br +.BI " __le16 npdg;" +.br +.BI " __le16 npda;" +.br +.BI " __le16 nows;" +.br +.BI " __u8 rsvd74[18];" +.br +.BI " __le32 anagrpid;" +.br +.BI " __u8 rsvd96[3];" +.br +.BI " __u8 nsattr;" +.br +.BI " __le16 nvmsetid;" +.br +.BI " __le16 endgid;" +.br +.BI " __u8 nguid[16];" +.br +.BI " __u8 eui64[8];" +.br +.BI " struct nvme_lbaf lbaf[16];" +.br +.BI " __u8 rsvd192[192];" +.br +.BI " __u8 vs[3712];" +.br +.BI " +}; +.br + +.SH Members +.IP "nsze" 12 +Namespace Size indicates the total size of the namespace in +logical blocks. The number of logical blocks is based on the +formatted LBA size. +.IP "ncap" 12 +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. +.IP "nuse" 12 +Namespace Utilization indicates the current number of logical +blocks allocated in the namespace. This field is smaller than or +equal to the Namespace Capacity. The number of logical blocks is +based on the formatted LBA size. +.IP "nsfeat" 12 +Namespace Features, see \fIenum nvme_id_nsfeat\fP. +.IP "nlbaf" 12 +Number of LBA Formats defines the number of supported LBA data +size and metadata size combinations supported by the namespace +and the highest possible index to \fIstruct nvme_id_ns\fP.labf. +.IP "flbas" 12 +Formatted LBA Size, see \fIenum nvme_id_ns_flbas\fP. +.IP "mc" 12 +Metadata Capabilities, see \fIenum nvme_id_ns_mc\fP. +.IP "dpc" 12 +End-to-end Data Protection Capabilities, see \fIenum +nvme_id_ns_dpc\fP. +.IP "dps" 12 +End-to-end Data Protection Type Settings, see \fIenum +nvme_id_ns_dps\fP. +.IP "nmic" 12 +Namespace Multi-path I/O and Namespace Sharing Capabilities, see +\fIenum nvme_id_ns_nmic\fP. +.IP "rescap" 12 +Reservation Capabilities, see \fIenum nvme_id_ns_rescap\fP. +.IP "fpi" 12 +Format Progress Indicator, see \fIenum nvme_nd_ns_fpi\fP. +.IP "dlfeat" 12 +Deallocate Logical Block Features, see \fIenum nvme_id_ns_dlfeat\fP. +.IP "nawun" 12 +Namespace Atomic Write Unit Normal indicates the +namespace specific size of the write operation guaranteed to be +written atomically to the NVM during normal operation. +.IP "nawupf" 12 +Namespace Atomic Write Unit Power Fail indicates the +namespace specific size of the write operation guaranteed to be +written atomically to the NVM during a power fail or error +condition. +.IP "nacwu" 12 +Namespace Atomic Compare & Write Unit indicates the namespace +specific size of the write operation guaranteed to be written +atomically to the NVM for a Compare and Write fused command. +.IP "nabsn" 12 +Namespace Atomic Boundary Size Normal indicates the atomic +boundary size for this namespace for the NAWUN value. This field +is specified in logical blocks. +.IP "nabo" 12 +Namespace Atomic Boundary Offset indicates the LBA on this +namespace where the first atomic boundary starts. +.IP "nabspf" 12 +Namespace Atomic Boundary Size Power Fail indicates the atomic +boundary size for this namespace specific to the Namespace Atomic +Write Unit Power Fail value. This field is specified in logical +blocks. +.IP "noiob" 12 +Namespace Optimal I/O Boundary indicates the optimal I/O boundary +for this namespace. This field is specified in logical blocks. +The host should construct Read and Write commands that do not +cross the I/O boundary to achieve optimal performance. +.IP "nvmcap" 12 +NVM Capacity indicates the total size of the NVM allocated to +this namespace. The value is in bytes. +.IP "npwg" 12 +Namespace Preferred Write Granularity indicates the smallest +recommended write granularity in logical blocks for this +namespace. This is a 0's based value. +.IP "npwa" 12 +Namespace Preferred Write Alignment indicates the recommended +write alignment in logical blocks for this namespace. This is a +0's based value. +.IP "npdg" 12 +Namespace Preferred Deallocate Granularity indicates the +recommended granularity in logical blocks for the Dataset +Management command with the Attribute - Deallocate bit. +.IP "npda" 12 +Namespace Preferred Deallocate Alignment indicates the +recommended alignment in logical blocks for the Dataset +Management command with the Attribute - Deallocate bit +.IP "nows" 12 +Namespace Optimal Write Size indicates the size in logical blocks +for optimal write performance for this namespace. This is a 0's +based value. +.IP "anagrpid" 12 +ANA Group Identifier indicates the ANA Group Identifier of the +ANA group of which the namespace is a member. +.IP "nsattr" 12 +Namespace Attributes, see \fIenum nvme_id_ns_attr\fP. +.IP "nvmsetid" 12 +NVM Set Identifier indicates the NVM Set with which this +namespace is associated. +.IP "endgid" 12 +Endurance Group Identifier indicates the Endurance Group with +which this namespace is associated. +.IP "nguid" 12 +Namespace Globally Unique Identifier contains a 128-bit value +that is globally unique and assigned to the namespace when the +namespace is created. This field remains fixed throughout the +life of the namespace and is preserved across namespace and +controller operations +.IP "eui64" 12 +IEEE Extended Unique Identifier contains a 64-bit IEEE Extended +Unique Identifier (EUI-64) that is globally unique and assigned +to the namespace when the namespace is created. This field +remains fixed throughout the life of the namespace and is +preserved across namespace and controller operations +.IP "lbaf" 12 +LBA Format, see \fIstruct nvme_lbaf\fP. +.IP "vs" 12 +Vendor Specific diff --git a/doc/man/struct nvme_id_ns_granularity_desc.2 b/doc/man/struct nvme_id_ns_granularity_desc.2 new file mode 100644 index 00000000..7f099ed5 --- /dev/null +++ b/doc/man/struct nvme_id_ns_granularity_desc.2 @@ -0,0 +1,15 @@ +.TH "libnvme" 2 "struct nvme_id_ns_granularity_desc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_id_ns_granularity_desc \- +.SH SYNOPSIS +struct nvme_id_ns_granularity_desc { +.br +.BI " __le64 namespace_size_granularity;" +.br +.BI " __le64 namespace_capacity_granularity;" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_id_ns_granularity_list.2 b/doc/man/struct nvme_id_ns_granularity_list.2 new file mode 100644 index 00000000..d0ca8b99 --- /dev/null +++ b/doc/man/struct nvme_id_ns_granularity_list.2 @@ -0,0 +1,21 @@ +.TH "libnvme" 2 "struct nvme_id_ns_granularity_list" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_id_ns_granularity_list \- +.SH SYNOPSIS +struct nvme_id_ns_granularity_list { +.br +.BI " __le32 attributes;" +.br +.BI " __u8 num_descriptors;" +.br +.BI " __u8 rsvd[27];" +.br +.BI " struct nvme_id_ns_granularity_desc entry[NVME_ID_ND_DESCRIPTOR_MAX];" +.br +.BI " __u8 rsvd288[3808];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_id_nvmset_list.2 b/doc/man/struct nvme_id_nvmset_list.2 new file mode 100644 index 00000000..6a9dc4a2 --- /dev/null +++ b/doc/man/struct nvme_id_nvmset_list.2 @@ -0,0 +1,19 @@ +.TH "libnvme" 2 "struct nvme_id_nvmset_list" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_id_nvmset_list \- @nid; +.SH SYNOPSIS +struct nvme_id_nvmset_list { +.br +.BI " __u8 nid;" +.br +.BI " __u8 rsvd1[127];" +.br +.BI " struct nvme_nvmset_attr ent[NVME_ID_NVMSET_LIST_MAX];" +.br +.BI " +}; +.br + +.SH Members +.IP "ent" 12 +; diff --git a/doc/man/struct nvme_id_psd.2 b/doc/man/struct nvme_id_psd.2 new file mode 100644 index 00000000..d990aeb9 --- /dev/null +++ b/doc/man/struct nvme_id_psd.2 @@ -0,0 +1,92 @@ +.TH "libnvme" 2 "struct nvme_id_psd" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_id_psd \- +.SH SYNOPSIS +struct nvme_id_psd { +.br +.BI " __le16 mp;" +.br +.BI " __u8 rsvd2;" +.br +.BI " __u8 flags;" +.br +.BI " __le32 enlat;" +.br +.BI " __le32 exlat;" +.br +.BI " __u8 rrt;" +.br +.BI " __u8 rrl;" +.br +.BI " __u8 rwt;" +.br +.BI " __u8 rwl;" +.br +.BI " __le16 idlp;" +.br +.BI " __u8 ips;" +.br +.BI " __u8 rsvd19;" +.br +.BI " __le16 actp;" +.br +.BI " __u8 apw;" +.br +.BI " __u8 aps;" +.br +.BI " __u8 rsvd23[8];" +.br +.BI " +}; +.br + +.SH Members +.IP "mp" 12 +Maximum Power indicates the sustained maximum power consumed by the +NVM subsystem in this power state. The power in Watts is equal to +the value in this field multiplied by the scale specified in the Max +Power Scale bit (see \fIenum nvme_psd_flags\fP). A value of 0 indicates +Maximum Power is not reported. +.IP "flags" 12 +Additional decoding flags, see \fIenum nvme_psd_flags\fP. +.IP "enlat" 12 +Entry Latency indicates the maximum latency in microseconds +associated with entering this power state. A value of 0 indicates +Entry Latency is not reported. +.IP "exlat" 12 +Exit Latency indicates the maximum latency in microseconds +associated with exiting this power state. A value of 0 indicates +Exit Latency is not reported. +.IP "rrt" 12 +Relative Read Throughput indicates the read throughput rank +associated with this power state relative to others. The value in +this is less than the number of supported power states. +.IP "rrl" 12 +Relative Reade Latency indicates the read latency rank associated +with this power state relative to others. The value in this field is +less than the number of supported power states. +.IP "rwt" 12 +Relative Write Throughput indicates write throughput rank associated +with this power state relative to others. The value in this field is +less than the number of supported power states +.IP "rwl" 12 +Relative Write Latency indicates the write latency rank associated +with this power state relative to others. The value in this field is +less than the number of supported power states +.IP "idlp" 12 +Idle Power indicates the typical power consumed by the NVM +subsystem over 30 seconds in this power state when idle. +.IP "ips" 12 +Idle Power Scale indicates the scale for \fIstruct nvme_id_psd\fP.idlp, +see \fIenum nvme_psd_ps\fP for decoding this field. +.IP "actp" 12 +Active Power indicates the largest average power consumed by the +NVM subsystem over a 10 second period in this power state with +the workload indicated in the Active Power Workload field. +.IP "apw" 12 +Active Power Workload indicates the workload used to calculate +maximum power for this power state. See \fIenum nvme_psd_workload\fP for +decoding this field. +.IP "aps" 12 +Active Power Scale indicates the scale for the \fIstruct +nvme_id_psd\fP.actp, see \fIenum nvme_psd_ps\fP for decoding this value. diff --git a/doc/man/struct nvme_id_uuid_list.2 b/doc/man/struct nvme_id_uuid_list.2 new file mode 100644 index 00000000..75f2f917 --- /dev/null +++ b/doc/man/struct nvme_id_uuid_list.2 @@ -0,0 +1,15 @@ +.TH "libnvme" 2 "struct nvme_id_uuid_list" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_id_uuid_list \- +.SH SYNOPSIS +struct nvme_id_uuid_list { +.br +.BI " __u8 rsvd0[32];" +.br +.BI " struct nvme_id_uuid_list_entry entry[NVME_ID_UUID_LIST_MAX];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_id_uuid_list_entry.2 b/doc/man/struct nvme_id_uuid_list_entry.2 new file mode 100644 index 00000000..e8d80ac7 --- /dev/null +++ b/doc/man/struct nvme_id_uuid_list_entry.2 @@ -0,0 +1,17 @@ +.TH "libnvme" 2 "struct nvme_id_uuid_list_entry" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_id_uuid_list_entry \- +.SH SYNOPSIS +struct nvme_id_uuid_list_entry { +.br +.BI " __u8 header;" +.br +.BI " __u8 rsvd1[15];" +.br +.BI " __u8 uuid[16];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_lba_range_type.2 b/doc/man/struct nvme_lba_range_type.2 new file mode 100644 index 00000000..ec4d3da3 --- /dev/null +++ b/doc/man/struct nvme_lba_range_type.2 @@ -0,0 +1,13 @@ +.TH "libnvme" 2 "struct nvme_lba_range_type" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_lba_range_type \- +.SH SYNOPSIS +struct nvme_lba_range_type { +.br +.BI " struct nvme_lba_range_type_entry entry[NVME_FEAT_LBA_RANGE_MAX];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_lba_range_type_entry.2 b/doc/man/struct nvme_lba_range_type_entry.2 new file mode 100644 index 00000000..f1cecdc9 --- /dev/null +++ b/doc/man/struct nvme_lba_range_type_entry.2 @@ -0,0 +1,25 @@ +.TH "libnvme" 2 "struct nvme_lba_range_type_entry" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_lba_range_type_entry \- +.SH SYNOPSIS +struct nvme_lba_range_type_entry { +.br +.BI " __u8 type;" +.br +.BI " __u8 attributes;" +.br +.BI " __u8 rsvd2[14];" +.br +.BI " __u64 slba;" +.br +.BI " __u64 nlb;" +.br +.BI " __u8 guid[16];" +.br +.BI " __u8 rsvd48[16];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_lba_rd.2 b/doc/man/struct nvme_lba_rd.2 new file mode 100644 index 00000000..3aec3a5f --- /dev/null +++ b/doc/man/struct nvme_lba_rd.2 @@ -0,0 +1,17 @@ +.TH "libnvme" 2 "struct nvme_lba_rd" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_lba_rd \- +.SH SYNOPSIS +struct nvme_lba_rd { +.br +.BI " __le64 rslba;" +.br +.BI " __le32 rnlb;" +.br +.BI " __u8 rsvd12[4];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_lba_status.2 b/doc/man/struct nvme_lba_status.2 new file mode 100644 index 00000000..7223af30 --- /dev/null +++ b/doc/man/struct nvme_lba_status.2 @@ -0,0 +1,19 @@ +.TH "libnvme" 2 "struct nvme_lba_status" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_lba_status \- +.SH SYNOPSIS +struct nvme_lba_status { +.br +.BI " __le32 nlsd;" +.br +.BI " __u8 cmpc;" +.br +.BI " __u8 rsvd5[3];" +.br +.BI " struct nvme_lba_status_desc descs[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_lba_status_desc.2 b/doc/man/struct nvme_lba_status_desc.2 new file mode 100644 index 00000000..81973bf0 --- /dev/null +++ b/doc/man/struct nvme_lba_status_desc.2 @@ -0,0 +1,21 @@ +.TH "libnvme" 2 "struct nvme_lba_status_desc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_lba_status_desc \- +.SH SYNOPSIS +struct nvme_lba_status_desc { +.br +.BI " __le64 dslba;" +.br +.BI " __le32 nlb;" +.br +.BI " __u8 rsvd12;" +.br +.BI " __u8 status;" +.br +.BI " __u8 rsvd14[2];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_lba_status_log.2 b/doc/man/struct nvme_lba_status_log.2 new file mode 100644 index 00000000..32b53913 --- /dev/null +++ b/doc/man/struct nvme_lba_status_log.2 @@ -0,0 +1,23 @@ +.TH "libnvme" 2 "struct nvme_lba_status_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_lba_status_log \- +.SH SYNOPSIS +struct nvme_lba_status_log { +.br +.BI " __le32 lslplen;" +.br +.BI " __le32 nlslne;" +.br +.BI " __le32 estulb;" +.br +.BI " __u8 rsvd12[2];" +.br +.BI " __le16 lsgc;" +.br +.BI " struct nvme_lbas_ns_element elements[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_lbaf.2 b/doc/man/struct nvme_lbaf.2 new file mode 100644 index 00000000..7518de00 --- /dev/null +++ b/doc/man/struct nvme_lbaf.2 @@ -0,0 +1,25 @@ +.TH "libnvme" 2 "struct nvme_lbaf" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_lbaf \- LBA Format Data Structure +.SH SYNOPSIS +struct nvme_lbaf { +.br +.BI " __le16 ms;" +.br +.BI " __u8 ds;" +.br +.BI " __u8 rp;" +.br +.BI " +}; +.br + +.SH Members +.IP "ms" 12 +Metadata Size indicates the number of metadata bytes provided per LBA +based on the LBA Data Size indicated. +.IP "ds" 12 +LBA Data Size indicates the LBA data size supported, reported as a +power of two. +.IP "rp" 12 +Relative Performance, see \fIenum nvme_lbaf_rp\fP. diff --git a/doc/man/struct nvme_lbas_ns_element.2 b/doc/man/struct nvme_lbas_ns_element.2 new file mode 100644 index 00000000..00536062 --- /dev/null +++ b/doc/man/struct nvme_lbas_ns_element.2 @@ -0,0 +1,21 @@ +.TH "libnvme" 2 "struct nvme_lbas_ns_element" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_lbas_ns_element \- +.SH SYNOPSIS +struct nvme_lbas_ns_element { +.br +.BI " __le32 neid;" +.br +.BI " __le32 nrld;" +.br +.BI " __u8 ratype;" +.br +.BI " __u8 rsvd8[7];" +.br +.BI " struct nvme_lba_rd lba_rd[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_ctrl_heal_status.2 b/doc/man/struct nvme_mi_ctrl_heal_status.2 new file mode 100644 index 00000000..97be2653 --- /dev/null +++ b/doc/man/struct nvme_mi_ctrl_heal_status.2 @@ -0,0 +1,25 @@ +.TH "libnvme" 2 "struct nvme_mi_ctrl_heal_status" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_ctrl_heal_status \- +.SH SYNOPSIS +struct nvme_mi_ctrl_heal_status { +.br +.BI " __le16 ctlid;" +.br +.BI " __le16 csts;" +.br +.BI " __le16 ctemp;" +.br +.BI " __u8 pdlu;" +.br +.BI " __u8 spare;" +.br +.BI " __u8 cwarn;" +.br +.BI " __u8 rsvd9[7];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_nvm_ss_health_status.2 b/doc/man/struct nvme_mi_nvm_ss_health_status.2 new file mode 100644 index 00000000..60c8fc92 --- /dev/null +++ b/doc/man/struct nvme_mi_nvm_ss_health_status.2 @@ -0,0 +1,23 @@ +.TH "libnvme" 2 "struct nvme_mi_nvm_ss_health_status" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_nvm_ss_health_status \- +.SH SYNOPSIS +struct nvme_mi_nvm_ss_health_status { +.br +.BI " __u8 nss;" +.br +.BI " __u8 sw;" +.br +.BI " __u8 ctemp;" +.br +.BI " __u8 pdlu;" +.br +.BI " __le16 ccs;" +.br +.BI " __u8 rsvd8[2];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_osc.2 b/doc/man/struct nvme_mi_osc.2 new file mode 100644 index 00000000..b8a9b6a1 --- /dev/null +++ b/doc/man/struct nvme_mi_osc.2 @@ -0,0 +1,15 @@ +.TH "libnvme" 2 "struct nvme_mi_osc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_osc \- @type; @opc; +.SH SYNOPSIS +struct nvme_mi_osc { +.br +.BI " __u8 type;" +.br +.BI " __u8 opc;" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_port_pcie.2 b/doc/man/struct nvme_mi_port_pcie.2 new file mode 100644 index 00000000..5a57f972 --- /dev/null +++ b/doc/man/struct nvme_mi_port_pcie.2 @@ -0,0 +1,25 @@ +.TH "libnvme" 2 "struct nvme_mi_port_pcie" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_port_pcie \- +.SH SYNOPSIS +struct nvme_mi_port_pcie { +.br +.BI " __u8 mps;" +.br +.BI " __u8 sls;" +.br +.BI " __u8 cls;" +.br +.BI " __u8 mlw;" +.br +.BI " __u8 nlw;" +.br +.BI " __u8 pn;" +.br +.BI " __u8 rsvd14[18];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_port_smb.2 b/doc/man/struct nvme_mi_port_smb.2 new file mode 100644 index 00000000..d6ec195f --- /dev/null +++ b/doc/man/struct nvme_mi_port_smb.2 @@ -0,0 +1,23 @@ +.TH "libnvme" 2 "struct nvme_mi_port_smb" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_port_smb \- +.SH SYNOPSIS +struct nvme_mi_port_smb { +.br +.BI " __u8 vpd_addr;" +.br +.BI " __u8 mvpd_freq;" +.br +.BI " __u8 mme_addr;" +.br +.BI " __u8 mme_freq;" +.br +.BI " __u8 nvmebm;" +.br +.BI " __u8 rsvd13[19];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_read_ctrl_info.2 b/doc/man/struct nvme_mi_read_ctrl_info.2 new file mode 100644 index 00000000..baa8497e --- /dev/null +++ b/doc/man/struct nvme_mi_read_ctrl_info.2 @@ -0,0 +1,29 @@ +.TH "libnvme" 2 "struct nvme_mi_read_ctrl_info" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_read_ctrl_info \- @portid; @prii; @pri; @vid; @did; @ssvid; @ssid; +.SH SYNOPSIS +struct nvme_mi_read_ctrl_info { +.br +.BI " __u8 portid;" +.br +.BI " __u8 rsvd1[4];" +.br +.BI " __u8 prii;" +.br +.BI " __le16 pri;" +.br +.BI " __le16 vid;" +.br +.BI " __le16 did;" +.br +.BI " __le16 ssvid;" +.br +.BI " __le16 ssid;" +.br +.BI " __u8 rsvd16[16];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_read_nvm_ss_info.2 b/doc/man/struct nvme_mi_read_nvm_ss_info.2 new file mode 100644 index 00000000..2883b615 --- /dev/null +++ b/doc/man/struct nvme_mi_read_nvm_ss_info.2 @@ -0,0 +1,19 @@ +.TH "libnvme" 2 "struct nvme_mi_read_nvm_ss_info" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_read_nvm_ss_info \- +.SH SYNOPSIS +struct nvme_mi_read_nvm_ss_info { +.br +.BI " __u8 nump;" +.br +.BI " __u8 mjr;" +.br +.BI " __u8 mnr;" +.br +.BI " __u8 rsvd3[29];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_read_port_info.2 b/doc/man/struct nvme_mi_read_port_info.2 new file mode 100644 index 00000000..fba36f93 --- /dev/null +++ b/doc/man/struct nvme_mi_read_port_info.2 @@ -0,0 +1,31 @@ +.TH "libnvme" 2 "struct nvme_mi_read_port_info" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_read_port_info \- +.SH SYNOPSIS +struct nvme_mi_read_port_info { +.br +.BI " __u8 portt;" +.br +.BI " __u8 rsvd1;" +.br +.BI " __le16 mmctptus;" +.br +.BI " __le32 meb;" +.br +.BI " union {" +.br +.BI " struct nvme_mi_port_pcie pcie;" +.br +.BI " struct nvme_mi_port_smb smb;" +.br +.BI " };" +.br +.BI " +}; +.br + +.SH Members +.IP "portt" 12 +\fImmctptus\fP; +.IP "{unnamed_union}" 12 +anonymous diff --git a/doc/man/struct nvme_mi_read_sc_list.2 b/doc/man/struct nvme_mi_read_sc_list.2 new file mode 100644 index 00000000..7b0b924b --- /dev/null +++ b/doc/man/struct nvme_mi_read_sc_list.2 @@ -0,0 +1,15 @@ +.TH "libnvme" 2 "struct nvme_mi_read_sc_list" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_read_sc_list \- +.SH SYNOPSIS +struct nvme_mi_read_sc_list { +.br +.BI " __le16 numcmd;" +.br +.BI " struct nvme_mi_osc cmds[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_vpd_hdr.2 b/doc/man/struct nvme_mi_vpd_hdr.2 new file mode 100644 index 00000000..d337d7c6 --- /dev/null +++ b/doc/man/struct nvme_mi_vpd_hdr.2 @@ -0,0 +1,29 @@ +.TH "libnvme" 2 "struct nvme_mi_vpd_hdr" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_vpd_hdr \- +.SH SYNOPSIS +struct nvme_mi_vpd_hdr { +.br +.BI " __u8 ipmiver;" +.br +.BI " __u8 iuaoff;" +.br +.BI " __u8 ciaoff;" +.br +.BI " __u8 biaoff;" +.br +.BI " __u8 piaoff;" +.br +.BI " __u8 mrioff;" +.br +.BI " __u8 rsvd6;" +.br +.BI " __u8 chchk;" +.br +.BI " __u8 vpd[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_vpd_mr_common.2 b/doc/man/struct nvme_mi_vpd_mr_common.2 new file mode 100644 index 00000000..e1dbe16e --- /dev/null +++ b/doc/man/struct nvme_mi_vpd_mr_common.2 @@ -0,0 +1,33 @@ +.TH "libnvme" 2 "struct nvme_mi_vpd_mr_common" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_vpd_mr_common \- @type; @rf; @rlen; @rchksum; @hchksum; @ppmra; @tmra; +.SH SYNOPSIS +struct nvme_mi_vpd_mr_common { +.br +.BI " __u8 type;" +.br +.BI " __u8 rf;" +.br +.BI " __u8 rlen;" +.br +.BI " __u8 rchksum;" +.br +.BI " __u8 hchksum;" +.br +.BI " union {" +.br +.BI " struct nvme_mi_vpd_mra nmra;" +.br +.BI " struct nvme_mi_vpd_ppmra ppmra;" +.br +.BI " struct nvme_mi_vpd_tra tmra;" +.br +.BI " };" +.br +.BI " +}; +.br + +.SH Members +.IP "{unnamed_union}" 12 +anonymous diff --git a/doc/man/struct nvme_mi_vpd_mra.2 b/doc/man/struct nvme_mi_vpd_mra.2 new file mode 100644 index 00000000..185a6af7 --- /dev/null +++ b/doc/man/struct nvme_mi_vpd_mra.2 @@ -0,0 +1,43 @@ +.TH "libnvme" 2 "struct nvme_mi_vpd_mra" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_vpd_mra \- @nmravn; @ff; @i18vpwr; @m18vpwr; @i33vpwr; @m33vpwr; @m33vapsr; @i5vapsr; @m5vapsr; @i12vapsr; @m12vapsr; @mtl; @tnvmcap[16]; +.SH SYNOPSIS +struct nvme_mi_vpd_mra { +.br +.BI " __u8 nmravn;" +.br +.BI " __u8 ff;" +.br +.BI " __u8 rsvd7[6];" +.br +.BI " __u8 i18vpwr;" +.br +.BI " __u8 m18vpwr;" +.br +.BI " __u8 i33vpwr;" +.br +.BI " __u8 m33vpwr;" +.br +.BI " __u8 rsvd17;" +.br +.BI " __u8 m33vapsr;" +.br +.BI " __u8 i5vapsr;" +.br +.BI " __u8 m5vapsr;" +.br +.BI " __u8 i12vapsr;" +.br +.BI " __u8 m12vapsr;" +.br +.BI " __u8 mtl;" +.br +.BI " __u8 tnvmcap[16];" +.br +.BI " __u8 rsvd37[27];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_vpd_ppmra.2 b/doc/man/struct nvme_mi_vpd_ppmra.2 new file mode 100644 index 00000000..3d1a4ebb --- /dev/null +++ b/doc/man/struct nvme_mi_vpd_ppmra.2 @@ -0,0 +1,29 @@ +.TH "libnvme" 2 "struct nvme_mi_vpd_ppmra" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_vpd_ppmra \- +.SH SYNOPSIS +struct nvme_mi_vpd_ppmra { +.br +.BI " __u8 nppmravn;" +.br +.BI " __u8 pn;" +.br +.BI " __u8 ppi;" +.br +.BI " __u8 ls;" +.br +.BI " __u8 mlw;" +.br +.BI " __u8 mctp;" +.br +.BI " __u8 refccap;" +.br +.BI " __u8 pi;" +.br +.BI " __u8 rsvd13[3];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_vpd_telem.2 b/doc/man/struct nvme_mi_vpd_telem.2 new file mode 100644 index 00000000..7d26464e --- /dev/null +++ b/doc/man/struct nvme_mi_vpd_telem.2 @@ -0,0 +1,19 @@ +.TH "libnvme" 2 "struct nvme_mi_vpd_telem" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_vpd_telem \- +.SH SYNOPSIS +struct nvme_mi_vpd_telem { +.br +.BI " __u8 type;" +.br +.BI " __u8 rev;" +.br +.BI " __u8 len;" +.br +.BI " __u8 data[0];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_mi_vpd_tra.2 b/doc/man/struct nvme_mi_vpd_tra.2 new file mode 100644 index 00000000..bb593315 --- /dev/null +++ b/doc/man/struct nvme_mi_vpd_tra.2 @@ -0,0 +1,19 @@ +.TH "libnvme" 2 "struct nvme_mi_vpd_tra" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_mi_vpd_tra \- +.SH SYNOPSIS +struct nvme_mi_vpd_tra { +.br +.BI " __u8 vn;" +.br +.BI " __u8 rsvd6;" +.br +.BI " __u8 ec;" +.br +.BI " struct nvme_mi_vpd_telem elems[0];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_ns_id_desc.2 b/doc/man/struct nvme_ns_id_desc.2 new file mode 100644 index 00000000..b743b584 --- /dev/null +++ b/doc/man/struct nvme_ns_id_desc.2 @@ -0,0 +1,28 @@ +.TH "libnvme" 2 "struct nvme_ns_id_desc" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_ns_id_desc \- +.SH SYNOPSIS +struct nvme_ns_id_desc { +.br +.BI " __u8 nidt;" +.br +.BI " __u8 nidl;" +.br +.BI " __le16 reserved;" +.br +.BI " __u8 nid[];" +.br +.BI " +}; +.br + +.SH Members +.IP "nidt" 12 +Namespace Identifier Type, see \fIenum nvme_ns_id_desc_nidt\fP +.IP "nidl" 12 +Namespace Identifier Length contains the length in bytes of the +\fIstruct nvme_id_ns\fP.nid. +.IP "nid" 12 +Namespace Identifier contains a value that is globally unique and +assigned to the namespace when the namespace is created. The length +is defined in \fIstruct nvme_id_ns\fP.nidl. diff --git a/doc/man/struct nvme_ns_list.2 b/doc/man/struct nvme_ns_list.2 new file mode 100644 index 00000000..505f9041 --- /dev/null +++ b/doc/man/struct nvme_ns_list.2 @@ -0,0 +1,13 @@ +.TH "libnvme" 2 "struct nvme_ns_list" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_ns_list \- +.SH SYNOPSIS +struct nvme_ns_list { +.br +.BI " __le32 ns[NVME_ID_NS_LIST_MAX];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_nvmset_attr.2 b/doc/man/struct nvme_nvmset_attr.2 new file mode 100644 index 00000000..6054d067 --- /dev/null +++ b/doc/man/struct nvme_nvmset_attr.2 @@ -0,0 +1,37 @@ +.TH "libnvme" 2 "struct nvme_nvmset_attr" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_nvmset_attr \- NVM Set Attributes Entry +.SH SYNOPSIS +struct nvme_nvmset_attr { +.br +.BI " __le16 id;" +.br +.BI " __le16 endurance_group_id;" +.br +.BI " __u8 rsvd4[4];" +.br +.BI " __le32 random_4k_read_typical;" +.br +.BI " __le32 opt_write_size;" +.br +.BI " __u8 total_nvmset_cap[16];" +.br +.BI " __u8 unalloc_nvmset_cap[16];" +.br +.BI " __u8 rsvd48[80];" +.br +.BI " +}; +.br + +.SH Members +.IP "id" 12 +NVM Set Identifier +.IP "endurance_group_id" 12 +Endurance Group Identifier +.IP "random_4k_read_typical" 12 +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. diff --git a/doc/man/struct nvme_nvmset_predictable_lat_log.2 b/doc/man/struct nvme_nvmset_predictable_lat_log.2 new file mode 100644 index 00000000..1819b1c4 --- /dev/null +++ b/doc/man/struct nvme_nvmset_predictable_lat_log.2 @@ -0,0 +1,39 @@ +.TH "libnvme" 2 "struct nvme_nvmset_predictable_lat_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_nvmset_predictable_lat_log \- +.SH SYNOPSIS +struct nvme_nvmset_predictable_lat_log { +.br +.BI " __u8 status;" +.br +.BI " __u8 rsvd1;" +.br +.BI " __le16 event_type;" +.br +.BI " __u8 rsvd4[28];" +.br +.BI " __le64 dtwin_rt;" +.br +.BI " __le64 dtwin_wt;" +.br +.BI " __le64 dtwin_tmax;" +.br +.BI " __le64 dtwin_tmin_hi;" +.br +.BI " __le64 dtwin_tmin_lo;" +.br +.BI " __u8 rsvd72[56];" +.br +.BI " __le64 dtwin_re;" +.br +.BI " __le64 dtwin_we;" +.br +.BI " __le64 dtwin_te;" +.br +.BI " __u8 rsvd152[360];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_passthru_cmd.2 b/doc/man/struct nvme_passthru_cmd.2 new file mode 100644 index 00000000..b76b9c50 --- /dev/null +++ b/doc/man/struct nvme_passthru_cmd.2 @@ -0,0 +1,83 @@ +.TH "libnvme" 2 "struct nvme_passthru_cmd" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_passthru_cmd \- +.SH SYNOPSIS +struct nvme_passthru_cmd { +.br +.BI " __u8 opcode;" +.br +.BI " __u8 flags;" +.br +.BI " __u16 rsvd1;" +.br +.BI " __u32 nsid;" +.br +.BI " __u32 cdw2;" +.br +.BI " __u32 cdw3;" +.br +.BI " __u64 metadata;" +.br +.BI " __u64 addr;" +.br +.BI " __u32 metadata_len;" +.br +.BI " __u32 data_len;" +.br +.BI " __u32 cdw10;" +.br +.BI " __u32 cdw11;" +.br +.BI " __u32 cdw12;" +.br +.BI " __u32 cdw13;" +.br +.BI " __u32 cdw14;" +.br +.BI " __u32 cdw15;" +.br +.BI " __u32 timeout_ms;" +.br +.BI " __u32 result;" +.br +.BI " +}; +.br + +.SH Members +.IP "opcode" 12 +Operation code, see \fIenum nvme_io_opcodes\fP and \fIenum nvme_admin_opcodes\fP +.IP "flags" 12 +Not supported: intended for command flags (eg: SGL, FUSE) +.IP "rsvd1" 12 +Reserved for future use +.IP "nsid" 12 +Namespace Identifier, or Fabrics type +.IP "cdw2" 12 +Command Dword 2 (no spec defined use) +.IP "cdw3" 12 +Command Dword 3 (no spec defined use) +.IP "metadata" 12 +User space address to metadata buffer (NULL if not used) +.IP "addr" 12 +User space address to data buffer (NULL if not used) +.IP "metadata_len" 12 +Metadata buffer transfer length +.IP "data_len" 12 +Data buffer transfer length +.IP "cdw10" 12 +Command Dword 10 (command specific) +.IP "cdw11" 12 +Command Dword 11 (command specific) +.IP "cdw12" 12 +Command Dword 12 (command specific) +.IP "cdw13" 12 +Command Dword 13 (command specific) +.IP "cdw14" 12 +Command Dword 14 (command specific) +.IP "cdw15" 12 +Command Dword 15 (command specific) +.IP "timeout_ms" 12 +If non-zero, overrides system default timeout in milliseconds +.IP "result" 12 +Set on completion to the command's CQE DWORD 0 controller response diff --git a/doc/man/struct nvme_passthru_cmd64.2 b/doc/man/struct nvme_passthru_cmd64.2 new file mode 100644 index 00000000..dd56d9a0 --- /dev/null +++ b/doc/man/struct nvme_passthru_cmd64.2 @@ -0,0 +1,87 @@ +.TH "libnvme" 2 "struct nvme_passthru_cmd64" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_passthru_cmd64 \- +.SH SYNOPSIS +struct nvme_passthru_cmd64 { +.br +.BI " __u8 opcode;" +.br +.BI " __u8 flags;" +.br +.BI " __u16 rsvd1;" +.br +.BI " __u32 nsid;" +.br +.BI " __u32 cdw2;" +.br +.BI " __u32 cdw3;" +.br +.BI " __u64 metadata;" +.br +.BI " __u64 addr;" +.br +.BI " __u32 metadata_len;" +.br +.BI " __u32 data_len;" +.br +.BI " __u32 cdw10;" +.br +.BI " __u32 cdw11;" +.br +.BI " __u32 cdw12;" +.br +.BI " __u32 cdw13;" +.br +.BI " __u32 cdw14;" +.br +.BI " __u32 cdw15;" +.br +.BI " __u32 timeout_ms;" +.br +.BI " __u32 rsvd2;" +.br +.BI " __u64 result;" +.br +.BI " +}; +.br + +.SH Members +.IP "opcode" 12 +Operation code, see \fIenum nvme_io_opcodes\fP and \fIenum nvme_admin_opcodes\fP +.IP "flags" 12 +Not supported: intended for command flags (eg: SGL, FUSE) +.IP "rsvd1" 12 +Reserved for future use +.IP "nsid" 12 +Namespace Identifier, or Fabrics type +.IP "cdw2" 12 +Command Dword 2 (no spec defined use) +.IP "cdw3" 12 +Command Dword 3 (no spec defined use) +.IP "metadata" 12 +User space address to metadata buffer (NULL if not used) +.IP "addr" 12 +User space address to data buffer (NULL if not used) +.IP "metadata_len" 12 +Metadata buffer transfer length +.IP "data_len" 12 +Data buffer transfer length +.IP "cdw10" 12 +Command Dword 10 (command specific) +.IP "cdw11" 12 +Command Dword 11 (command specific) +.IP "cdw12" 12 +Command Dword 12 (command specific) +.IP "cdw13" 12 +Command Dword 13 (command specific) +.IP "cdw14" 12 +Command Dword 14 (command specific) +.IP "cdw15" 12 +Command Dword 15 (command specific) +.IP "timeout_ms" 12 +If non-zero, overrides system default timeout in milliseconds +.IP "rsvd2" 12 +Reserved for future use (and fills an impicit struct pad +.IP "result" 12 +Set on completion to the command's CQE DWORD 0-1 controller response diff --git a/doc/man/struct nvme_persistent_event_log.2 b/doc/man/struct nvme_persistent_event_log.2 new file mode 100644 index 00000000..2d9bb475 --- /dev/null +++ b/doc/man/struct nvme_persistent_event_log.2 @@ -0,0 +1,43 @@ +.TH "libnvme" 2 "struct nvme_persistent_event_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_persistent_event_log \- +.SH SYNOPSIS +struct nvme_persistent_event_log { +.br +.BI " __u8 lid;" +.br +.BI " __u8 rsvd1[3];" +.br +.BI " __le32 ttl;" +.br +.BI " __u8 rv;" +.br +.BI " __u8 rsvd17;" +.br +.BI " __le16 lht;" +.br +.BI " __le64 ts;" +.br +.BI " __u8 poh[16];" +.br +.BI " __le64 pcc;" +.br +.BI " __le16 vid;" +.br +.BI " __le16 ssvid;" +.br +.BI " char sn[20];" +.br +.BI " char mn[40];" +.br +.BI " char subnqn[256];" +.br +.BI " __u8 rsvd372;" +.br +.BI " __u8 seb[32];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_plm_config.2 b/doc/man/struct nvme_plm_config.2 new file mode 100644 index 00000000..f322ff5c --- /dev/null +++ b/doc/man/struct nvme_plm_config.2 @@ -0,0 +1,23 @@ +.TH "libnvme" 2 "struct nvme_plm_config" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_plm_config \- @ee; @dtwinrt; @dtwinwt; @dtwintt; +.SH SYNOPSIS +struct nvme_plm_config { +.br +.BI " __le16 ee;" +.br +.BI " __u8 rsvd2[30];" +.br +.BI " __le64 dtwinrt;" +.br +.BI " __le64 dtwinwt;" +.br +.BI " __le64 dtwintt;" +.br +.BI " __u8 rsvd56[456];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_primary_ctrl_cap.2 b/doc/man/struct nvme_primary_ctrl_cap.2 new file mode 100644 index 00000000..18f2113f --- /dev/null +++ b/doc/man/struct nvme_primary_ctrl_cap.2 @@ -0,0 +1,47 @@ +.TH "libnvme" 2 "struct nvme_primary_ctrl_cap" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_primary_ctrl_cap \- +.SH SYNOPSIS +struct nvme_primary_ctrl_cap { +.br +.BI " __le16 cntlid;" +.br +.BI " __le16 portid;" +.br +.BI " __u8 crt;" +.br +.BI " __u8 rsvd5[27];" +.br +.BI " __le32 vqfrt;" +.br +.BI " __le32 vqrfa;" +.br +.BI " __le16 vqrfap;" +.br +.BI " __le16 vqprt;" +.br +.BI " __le16 vqfrsm;" +.br +.BI " __le16 vqgran;" +.br +.BI " __u8 rsvd48[16];" +.br +.BI " __le32 vifrt;" +.br +.BI " __le32 virfa;" +.br +.BI " __le16 virfap;" +.br +.BI " __le16 viprt;" +.br +.BI " __le16 vifrsm;" +.br +.BI " __le16 vigran;" +.br +.BI " __u8 rsvd80[4016];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_registered_ctrl.2 b/doc/man/struct nvme_registered_ctrl.2 new file mode 100644 index 00000000..ff52acab --- /dev/null +++ b/doc/man/struct nvme_registered_ctrl.2 @@ -0,0 +1,21 @@ +.TH "libnvme" 2 "struct nvme_registered_ctrl" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_registered_ctrl \- +.SH SYNOPSIS +struct nvme_registered_ctrl { +.br +.BI " __le16 cntlid;" +.br +.BI " __u8 rcsts;" +.br +.BI " __u8 rsvd3[5];" +.br +.BI " __le64 hostid;" +.br +.BI " __le64 rkey;" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_registered_ctrl_ext.2 b/doc/man/struct nvme_registered_ctrl_ext.2 new file mode 100644 index 00000000..d686cd85 --- /dev/null +++ b/doc/man/struct nvme_registered_ctrl_ext.2 @@ -0,0 +1,23 @@ +.TH "libnvme" 2 "struct nvme_registered_ctrl_ext" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_registered_ctrl_ext \- +.SH SYNOPSIS +struct nvme_registered_ctrl_ext { +.br +.BI " __le16 cntlid;" +.br +.BI " __u8 rcsts;" +.br +.BI " __u8 resv3[5];" +.br +.BI " __le64 rkey;" +.br +.BI " __u8 hostid[16];" +.br +.BI " __u8 resv32[32];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_reservation_status.2 b/doc/man/struct nvme_reservation_status.2 new file mode 100644 index 00000000..02f877a2 --- /dev/null +++ b/doc/man/struct nvme_reservation_status.2 @@ -0,0 +1,41 @@ +.TH "libnvme" 2 "struct nvme_reservation_status" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_reservation_status \- { +.SH SYNOPSIS +struct nvme_reservation_status { +.br +.BI " __le32 gen;" +.br +.BI " __u8 rtype;" +.br +.BI " __u8 regctl[2];" +.br +.BI " __u8 rsvd7[2];" +.br +.BI " __u8 ptpls;" +.br +.BI " __u8 rsvd10[14];" +.br +.BI " union {" +.br +.BI " struct {" +.br +.BI " __u8 resv24[40];" +.br +.BI " struct nvme_registered_ctrl_ext regctl_eds[0];" +.br +.BI " };" +.br +.BI " struct nvme_registered_ctrl regctl_ds[0];" +.br +.BI " };" +.br +.BI " +}; +.br + +.SH Members +.IP "{unnamed_union}" 12 +anonymous +.IP "{unnamed_struct}" 12 +anonymous diff --git a/doc/man/struct nvme_resv_notification_log.2 b/doc/man/struct nvme_resv_notification_log.2 new file mode 100644 index 00000000..ecab19cb --- /dev/null +++ b/doc/man/struct nvme_resv_notification_log.2 @@ -0,0 +1,23 @@ +.TH "libnvme" 2 "struct nvme_resv_notification_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_resv_notification_log \- +.SH SYNOPSIS +struct nvme_resv_notification_log { +.br +.BI " __le64 lpc;" +.br +.BI " __u8 rnlpt;" +.br +.BI " __u8 nalp;" +.br +.BI " __u8 rsvd9[2];" +.br +.BI " __le32 nsid;" +.br +.BI " __u8 rsvd16[48];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_sanitize_log_page.2 b/doc/man/struct nvme_sanitize_log_page.2 new file mode 100644 index 00000000..09e523c1 --- /dev/null +++ b/doc/man/struct nvme_sanitize_log_page.2 @@ -0,0 +1,31 @@ +.TH "libnvme" 2 "struct nvme_sanitize_log_page" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_sanitize_log_page \- +.SH SYNOPSIS +struct nvme_sanitize_log_page { +.br +.BI " __le16 sprog;" +.br +.BI " __le16 sstat;" +.br +.BI " __le32 scdw10;" +.br +.BI " __le32 eto;" +.br +.BI " __le32 etbe;" +.br +.BI " __le32 etce;" +.br +.BI " __le32 etond;" +.br +.BI " __le32 etbend;" +.br +.BI " __le32 etcend;" +.br +.BI " __u8 rsvd32[480];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_secondary_ctrl.2 b/doc/man/struct nvme_secondary_ctrl.2 new file mode 100644 index 00000000..c5c81634 --- /dev/null +++ b/doc/man/struct nvme_secondary_ctrl.2 @@ -0,0 +1,27 @@ +.TH "libnvme" 2 "struct nvme_secondary_ctrl" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_secondary_ctrl \- +.SH SYNOPSIS +struct nvme_secondary_ctrl { +.br +.BI " __le16 scid;" +.br +.BI " __le16 pcid;" +.br +.BI " __u8 scs;" +.br +.BI " __u8 rsvd5[3];" +.br +.BI " __le16 vfn;" +.br +.BI " __le16 nvq;" +.br +.BI " __le16 nvi;" +.br +.BI " __u8 rsvd14[18];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_secondary_ctrl_list.2 b/doc/man/struct nvme_secondary_ctrl_list.2 new file mode 100644 index 00000000..04e17eab --- /dev/null +++ b/doc/man/struct nvme_secondary_ctrl_list.2 @@ -0,0 +1,17 @@ +.TH "libnvme" 2 "struct nvme_secondary_ctrl_list" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_secondary_ctrl_list \- @num; +.SH SYNOPSIS +struct nvme_secondary_ctrl_list { +.br +.BI " __u8 num;" +.br +.BI " __u8 rsvd[31];" +.br +.BI " struct nvme_secondary_ctrl sc_entry[NVME_ID_SECONDARY_CTRL_MAX];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_self_test_log.2 b/doc/man/struct nvme_self_test_log.2 new file mode 100644 index 00000000..677cd873 --- /dev/null +++ b/doc/man/struct nvme_self_test_log.2 @@ -0,0 +1,19 @@ +.TH "libnvme" 2 "struct nvme_self_test_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_self_test_log \- +.SH SYNOPSIS +struct nvme_self_test_log { +.br +.BI " __u8 current_operation;" +.br +.BI " __u8 completion;" +.br +.BI " __u8 rsvd[2];" +.br +.BI " struct nvme_st_result result[NVME_LOG_ST_MAX_RESULTS];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_smart_log.2 b/doc/man/struct nvme_smart_log.2 new file mode 100644 index 00000000..78dd11d7 --- /dev/null +++ b/doc/man/struct nvme_smart_log.2 @@ -0,0 +1,61 @@ +.TH "libnvme" 2 "struct nvme_smart_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_smart_log \- +.SH SYNOPSIS +struct nvme_smart_log { +.br +.BI " __u8 critical_warning;" +.br +.BI " __u8 temperature[2];" +.br +.BI " __u8 avail_spare;" +.br +.BI " __u8 spare_thresh;" +.br +.BI " __u8 percent_used;" +.br +.BI " __u8 endu_grp_crit_warn_sumry;" +.br +.BI " __u8 rsvd7[25];" +.br +.BI " __u8 data_units_read[16];" +.br +.BI " __u8 data_units_written[16];" +.br +.BI " __u8 host_reads[16];" +.br +.BI " __u8 host_writes[16];" +.br +.BI " __u8 ctrl_busy_time[16];" +.br +.BI " __u8 power_cycles[16];" +.br +.BI " __u8 power_on_hours[16];" +.br +.BI " __u8 unsafe_shutdowns[16];" +.br +.BI " __u8 media_errors[16];" +.br +.BI " __u8 num_err_log_entries[16];" +.br +.BI " __le32 warning_temp_time;" +.br +.BI " __le32 critical_comp_time;" +.br +.BI " __le16 temp_sensor[8];" +.br +.BI " __le32 thm_temp1_trans_count;" +.br +.BI " __le32 thm_temp2_trans_count;" +.br +.BI " __le32 thm_temp1_total_time;" +.br +.BI " __le32 thm_temp2_total_time;" +.br +.BI " __u8 rsvd232[280];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_st_result.2 b/doc/man/struct nvme_st_result.2 new file mode 100644 index 00000000..afd33b20 --- /dev/null +++ b/doc/man/struct nvme_st_result.2 @@ -0,0 +1,31 @@ +.TH "libnvme" 2 "struct nvme_st_result" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_st_result \- +.SH SYNOPSIS +struct nvme_st_result { +.br +.BI " __u8 dsts;" +.br +.BI " __u8 seg;" +.br +.BI " __u8 vdi;" +.br +.BI " __u8 rsvd;" +.br +.BI " __le64 poh;" +.br +.BI " __le32 nsid;" +.br +.BI " __le64 flba;" +.br +.BI " __u8 sct;" +.br +.BI " __u8 sc;" +.br +.BI " __u8 vs[2];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_streams_directive_params.2 b/doc/man/struct nvme_streams_directive_params.2 new file mode 100644 index 00000000..2f3edfbc --- /dev/null +++ b/doc/man/struct nvme_streams_directive_params.2 @@ -0,0 +1,31 @@ +.TH "libnvme" 2 "struct nvme_streams_directive_params" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_streams_directive_params \- +.SH SYNOPSIS +struct nvme_streams_directive_params { +.br +.BI " __le16 msl;" +.br +.BI " __le16 nssa;" +.br +.BI " __le16 nsso;" +.br +.BI " __u8 nssc;" +.br +.BI " __u8 rsvd[9];" +.br +.BI " __le32 sws;" +.br +.BI " __le16 sgs;" +.br +.BI " __le16 nsa;" +.br +.BI " __le16 nso;" +.br +.BI " __u8 rsvd2[6];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_streams_directive_status.2 b/doc/man/struct nvme_streams_directive_status.2 new file mode 100644 index 00000000..af03551a --- /dev/null +++ b/doc/man/struct nvme_streams_directive_status.2 @@ -0,0 +1,15 @@ +.TH "libnvme" 2 "struct nvme_streams_directive_status" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_streams_directive_status \- +.SH SYNOPSIS +struct nvme_streams_directive_status { +.br +.BI " __le16 osc;" +.br +.BI " __le16 sid[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_telemetry_log.2 b/doc/man/struct nvme_telemetry_log.2 new file mode 100644 index 00000000..6785c87a --- /dev/null +++ b/doc/man/struct nvme_telemetry_log.2 @@ -0,0 +1,33 @@ +.TH "libnvme" 2 "struct nvme_telemetry_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_telemetry_log \- +.SH SYNOPSIS +struct nvme_telemetry_log { +.br +.BI " __u8 lpi;" +.br +.BI " __u8 rsvd[4];" +.br +.BI " __u8 ieee[3];" +.br +.BI " __le16 dalb1;" +.br +.BI " __le16 dalb2;" +.br +.BI " __le16 dalb3;" +.br +.BI " __u8 rsvd1[368];" +.br +.BI " __u8 ctrlavail;" +.br +.BI " __u8 ctrldgn;" +.br +.BI " __u8 rsnident[128];" +.br +.BI " __u8 telemetry_dataarea[];" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvme_timestamp.2 b/doc/man/struct nvme_timestamp.2 new file mode 100644 index 00000000..cacee999 --- /dev/null +++ b/doc/man/struct nvme_timestamp.2 @@ -0,0 +1,17 @@ +.TH "libnvme" 2 "struct nvme_timestamp" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvme_timestamp \- timestamp: +.SH SYNOPSIS +struct nvme_timestamp { +.br +.BI " __u8 timestamp[6];" +.br +.BI " __u8 attr;" +.br +.BI " __u8 rsvd;" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvmf_connect_data.2 b/doc/man/struct nvmf_connect_data.2 new file mode 100644 index 00000000..9f2227c6 --- /dev/null +++ b/doc/man/struct nvmf_connect_data.2 @@ -0,0 +1,26 @@ +.TH "libnvme" 2 "struct nvmf_connect_data" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvmf_connect_data \- +.SH SYNOPSIS +struct nvmf_connect_data { +.br +.BI " __u8 hostid[16];" +.br +.BI " __le16 cntlid;" +.br +.BI " char resv4[238];" +.br +.BI " char subsysnqn[NVMF_NQN_FIELD_LEN];" +.br +.BI " char hostnqn[NVMF_NQN_FIELD_LEN];" +.br +.BI " char resv5[256];" +.br +.BI " +}; +.br + +.SH Members +.IP "cntlid" 12 +\fIsubsysnqn\fP +\fIhostnqn\fP diff --git a/doc/man/struct nvmf_disc_log_entry.2 b/doc/man/struct nvmf_disc_log_entry.2 new file mode 100644 index 00000000..f1c2e461 --- /dev/null +++ b/doc/man/struct nvmf_disc_log_entry.2 @@ -0,0 +1,63 @@ +.TH "libnvme" 2 "struct nvmf_disc_log_entry" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvmf_disc_log_entry \- Discovery log page entry +.SH SYNOPSIS +struct nvmf_disc_log_entry { +.br +.BI " __u8 trtype;" +.br +.BI " __u8 adrfam;" +.br +.BI " __u8 subtype;" +.br +.BI " __u8 treq;" +.br +.BI " __le16 portid;" +.br +.BI " __le16 cntlid;" +.br +.BI " __le16 asqsz;" +.br +.BI " __u8 resv10[22];" +.br +.BI " char trsvcid[NVMF_TRSVCID_SIZE];" +.br +.BI " __u8 resv64[192];" +.br +.BI " char subnqn[NVMF_NQN_FIELD_LEN];" +.br +.BI " char traddr[NVMF_TRADDR_SIZE];" +.br +.BI " union tsas {" +.br +.BI " char common[NVMF_TSAS_SIZE];" +.br +.BI " struct rdma {" +.br +.BI " __u8 qptype;" +.br +.BI " __u8 prtype;" +.br +.BI " __u8 cms;" +.br +.BI " __u8 resv3[5];" +.br +.BI " __u16 pkey;" +.br +.BI " __u8 resv10[246];" +.br +.BI " } rdma;" +.br +.BI " struct tcp {" +.br +.BI " __u8 sectype;" +.br +.BI " } tcp;" +.br +.BI " } tsas;" +.br +.BI " +}; +.br + +.SH Members diff --git a/doc/man/struct nvmf_discovery_log.2 b/doc/man/struct nvmf_discovery_log.2 new file mode 100644 index 00000000..ba22896a --- /dev/null +++ b/doc/man/struct nvmf_discovery_log.2 @@ -0,0 +1,21 @@ +.TH "libnvme" 2 "struct nvmf_discovery_log" "February 2020" "LIBNVME API Manual" LINUX +.SH NAME +struct nvmf_discovery_log \- +.SH SYNOPSIS +struct nvmf_discovery_log { +.br +.BI " __le64 genctr;" +.br +.BI " __le64 numrec;" +.br +.BI " __le16 recfmt;" +.br +.BI " __u8 resv14[1006];" +.br +.BI " struct nvmf_disc_log_entry entries[0];" +.br +.BI " +}; +.br + +.SH Members