diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0a9a369..382f237 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -17,9 +17,9 @@ jobs: compiler: [gcc, clang] buildtype: [debug, release] container: - image: ghcr.io/igaw/linux-nvme/debian:0.30 + image: ghcr.io/igaw/linux-nvme/debian:latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: actions/setup-python@v4 with: python-version: '3.x' @@ -40,33 +40,22 @@ jobs: matrix: include: - arch: armhf - port: armhf - compiler: gcc-arm-linux-gnueabihf - packages: - arch: s390x - port: s390x - compiler: gcc-s390x-linux-gnu - packages: libgcc-s1:s390x - arch: ppc64le - port: ppc64el - compiler: gcc-powerpc64le-linux-gnu - packges: steps: - - uses: actions/checkout@v3 - - name: set up arm architecture - run: | - export release=$(lsb_release -c -s) - sudo dpkg --add-architecture ${{ matrix.port }} - sudo sed -i -e 's/deb http/deb [arch=amd64] http/g' /etc/apt/sources.list - sudo dd of=/etc/apt/sources.list.d/${{ matrix.arch }}.list < - --werror - --buildtype=release - --wrap-mode=nofallback - -Dlibdbus=enabled - -Db_coverage=true - meson-version: 0.61.2 - - name: Generate Coverage Report - # Can't use meson here, see - # https://github.com/mesonbuild/meson/issues/7895 - run: ninja -C build coverage --verbose + - uses: actions/checkout@v4 + - name: build + run: | + scripts/build.sh coverage - uses: codecov/codecov-action@v3 with: fail_ci_if_error: false diff --git a/.github/workflows/release-python.yml b/.github/workflows/release-python.yml index 86dc0de..d30aacc 100644 --- a/.github/workflows/release-python.yml +++ b/.github/workflows/release-python.yml @@ -15,11 +15,13 @@ jobs: build_sdist: name: Build source distribution runs-on: ubuntu-latest + container: + image: ghcr.io/igaw/linux-nvme/debian.python:latest steps: - - name: install libraries - run: sudo apt-get install gcc pkg-config libjson-c-dev libssl-dev python3-dev + - uses: actions/checkout@v4 - - uses: actions/checkout@v3 + - name: Allow workspace + run: git config --global --add safe.directory "$GITHUB_WORKSPACE" - name: Build sdist run: pipx run build --sdist diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 6ca2741..63bb5e1 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -14,7 +14,7 @@ jobs: permissions: contents: write steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ncipollo/release-action@v1 with: token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.readthedocs.yaml b/.readthedocs.yaml index 283a2dc..3505101 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -2,9 +2,6 @@ version: 2 -python: - system_packages: true - build: os: ubuntu-22.04 tools: diff --git a/README.md b/README.md index 0b0fae8..c493ef7 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # libnvme -![MesonBuild](https://github.com/linux-nvme/libnvme/actions/workflows/meson.yml/badge.svg) -![PyBuild](https://github.com/linux-nvme/libnvme/actions/workflows/python-publish.yml/badge.svg) +![MesonBuild](https://github.com/linux-nvme/libnvme/actions/workflows/build.yml/badge.svg) +![PyBuild](https://github.com/linux-nvme/libnvme/actions/workflows/release-python.yml/badge.svg) [![PyPI](https://img.shields.io/pypi/v/libnvme)](https://pypi.org/project/libnvme/) [![PyPI - Wheel](https://img.shields.io/pypi/wheel/libnvme)](https://pypi.org/project/libnvme/) ![GitHub](https://img.shields.io/github/license/linux-nvme/libnvme) @@ -106,7 +106,7 @@ completely "clean" all the build artifacts, one need only delete the To compile: ``` -meson -C .build +meson compile -C .build ``` ## To install libnvme @@ -145,10 +145,10 @@ A few build options can be specified on the command line when invoking meson. | docs | [false], html, man, rst, all | Install documentation | | docs-build | [false], true | Enable build documentation | | python | [auto], enabled, disabled | Whether to build the Python bindings. When set to `auto`, the default, meson will check for the presence of the tools and libraries (e.g. `swig`) required to build the Python bindings. If found, meson will configure the project to build the Python bindings. If a tool or library is missing, then the Python bindings won't be built. Setting this to `enabled`, forces the Python bindings to be built. When set to `disabled`, meson will configure the project to not build the Python bindings.
Example: `meson setup .build -Dpython=disabled` | -| openssl | [auto], enabled, disabled | Enables OpenSSL dependend features (e.g. authentication), adds build dependency on OpenSSL | -| libdbus | auto, enabled, [disabled] | Enables D-Bus dependend features (libnvme-mi: End point discovery), adds build dependency on libdbus | +| openssl | [auto], enabled, disabled | Enables OpenSSL dependent features (e.g. TLS over TCP), adds build dependency on OpenSSL | +| libdbus | auto, enabled, [disabled] | Enables D-Bus dependent features (libnvme-mi: End point discovery), adds build dependency on libdbus | | json-c | [auto], enabled, disabled | (recommended) Enables JSON-C dependend features (e.g. config.json parsing), adds build depdency on json-c | -| keyutils | [auto], enabled, disabled | Enables keyutils dependend features (e.g. TLS over TCP), adds build dependency on keyutils | +| keyutils | [auto], enabled, disabled | Enables keyutils dependent features (e.g. authentication), adds build dependency on keyutils | See the full configuration options with diff --git a/doc/conf.py b/doc/conf.py index fe594e8..9198df3 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -12,7 +12,7 @@ copyright = '2020, Keith Busch' author = 'Keith Busch ' master_doc = 'index' -release = '1.5' +release = '1.6' # -- General configuration --------------------------------------------------- diff --git a/doc/man/nbft_control.2 b/doc/man/nbft_control.2 index 7da4f26..ef31f64 100644 --- a/doc/man/nbft_control.2 +++ b/doc/man/nbft_control.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_control" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_control" "September 2023" "API Manual" LINUX .SH NAME struct nbft_control \- NBFT Table - Control Descriptor (Figure 8) .SH SYNOPSIS diff --git a/doc/man/nbft_control_flags.2 b/doc/man/nbft_control_flags.2 index e2f6e0f..edbf8be 100644 --- a/doc/man/nbft_control_flags.2 +++ b/doc/man/nbft_control_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_control_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_control_flags" "September 2023" "API Manual" LINUX .SH NAME enum nbft_control_flags \- Control Descriptor Flags .SH SYNOPSIS diff --git a/doc/man/nbft_desc_type.2 b/doc/man/nbft_desc_type.2 index 40d00f6..86de9a1 100644 --- a/doc/man/nbft_desc_type.2 +++ b/doc/man/nbft_desc_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_desc_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_desc_type" "September 2023" "API Manual" LINUX .SH NAME enum nbft_desc_type \- NBFT Elements - Descriptor Types (Figure 5) .SH SYNOPSIS diff --git a/doc/man/nbft_discovery.2 b/doc/man/nbft_discovery.2 index 61614ff..db4190f 100644 --- a/doc/man/nbft_discovery.2 +++ b/doc/man/nbft_discovery.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_discovery" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_discovery" "September 2023" "API Manual" LINUX .SH NAME struct nbft_discovery \- Discovery Descriptor (Figure 24) .SH SYNOPSIS diff --git a/doc/man/nbft_discovery_flags.2 b/doc/man/nbft_discovery_flags.2 index 9d0685c..198e688 100644 --- a/doc/man/nbft_discovery_flags.2 +++ b/doc/man/nbft_discovery_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_discovery_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_discovery_flags" "September 2023" "API Manual" LINUX .SH NAME enum nbft_discovery_flags \- Discovery Descriptor Flags .SH SYNOPSIS diff --git a/doc/man/nbft_header.2 b/doc/man/nbft_header.2 index 2990736..2fd88f7 100644 --- a/doc/man/nbft_header.2 +++ b/doc/man/nbft_header.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_header" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_header" "September 2023" "API Manual" LINUX .SH NAME struct nbft_header \- NBFT Table - Header (Figure 8) .SH SYNOPSIS diff --git a/doc/man/nbft_heap_obj.2 b/doc/man/nbft_heap_obj.2 index 81d6425..47f575b 100644 --- a/doc/man/nbft_heap_obj.2 +++ b/doc/man/nbft_heap_obj.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_heap_obj" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_heap_obj" "September 2023" "API Manual" LINUX .SH NAME struct nbft_heap_obj \- NBFT Header Driver Signature .SH SYNOPSIS diff --git a/doc/man/nbft_hfi.2 b/doc/man/nbft_hfi.2 index 7679e0f..30daf0d 100644 --- a/doc/man/nbft_hfi.2 +++ b/doc/man/nbft_hfi.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_hfi" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_hfi" "September 2023" "API Manual" LINUX .SH NAME struct nbft_hfi \- Host Fabric Interface (HFI) Descriptor (Figure 11) .SH SYNOPSIS diff --git a/doc/man/nbft_hfi_flags.2 b/doc/man/nbft_hfi_flags.2 index 74ba678..8209aa6 100644 --- a/doc/man/nbft_hfi_flags.2 +++ b/doc/man/nbft_hfi_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_hfi_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_hfi_flags" "September 2023" "API Manual" LINUX .SH NAME enum nbft_hfi_flags \- HFI Descriptor Flags .SH SYNOPSIS diff --git a/doc/man/nbft_hfi_info_tcp.2 b/doc/man/nbft_hfi_info_tcp.2 index 5419330..417e217 100644 --- a/doc/man/nbft_hfi_info_tcp.2 +++ b/doc/man/nbft_hfi_info_tcp.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_hfi_info_tcp" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_hfi_info_tcp" "September 2023" "API Manual" LINUX .SH NAME struct nbft_hfi_info_tcp \- HFI Transport Info Descriptor - NVMe/TCP (Figure 13) .SH SYNOPSIS diff --git a/doc/man/nbft_hfi_info_tcp_flags.2 b/doc/man/nbft_hfi_info_tcp_flags.2 index f3d8173..f64fa0c 100644 --- a/doc/man/nbft_hfi_info_tcp_flags.2 +++ b/doc/man/nbft_hfi_info_tcp_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_hfi_info_tcp_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_hfi_info_tcp_flags" "September 2023" "API Manual" LINUX .SH NAME enum nbft_hfi_info_tcp_flags \- HFI Transport Flags .SH SYNOPSIS diff --git a/doc/man/nbft_host.2 b/doc/man/nbft_host.2 index a747255..8276c07 100644 --- a/doc/man/nbft_host.2 +++ b/doc/man/nbft_host.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_host" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_host" "September 2023" "API Manual" LINUX .SH NAME struct nbft_host \- Host Descriptor (Figure 9) .SH SYNOPSIS diff --git a/doc/man/nbft_host_flags.2 b/doc/man/nbft_host_flags.2 index f5ef688..bec8790 100644 --- a/doc/man/nbft_host_flags.2 +++ b/doc/man/nbft_host_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_host_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_host_flags" "September 2023" "API Manual" LINUX .SH NAME enum nbft_host_flags \- Host Flags .SH SYNOPSIS diff --git a/doc/man/nbft_info.2 b/doc/man/nbft_info.2 index 38b2ffd..4a28139 100644 --- a/doc/man/nbft_info.2 +++ b/doc/man/nbft_info.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_info" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_info" "September 2023" "API Manual" LINUX .SH NAME struct nbft_info \- The parsed NBFT table data. .SH SYNOPSIS diff --git a/doc/man/nbft_info_discovery.2 b/doc/man/nbft_info_discovery.2 index 03e5245..ef7ef62 100644 --- a/doc/man/nbft_info_discovery.2 +++ b/doc/man/nbft_info_discovery.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_info_discovery" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_info_discovery" "September 2023" "API Manual" LINUX .SH NAME struct nbft_info_discovery \- Discovery Descriptor .SH SYNOPSIS diff --git a/doc/man/nbft_info_hfi.2 b/doc/man/nbft_info_hfi.2 index 438e76a..f5571c5 100644 --- a/doc/man/nbft_info_hfi.2 +++ b/doc/man/nbft_info_hfi.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_info_hfi" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_info_hfi" "September 2023" "API Manual" LINUX .SH NAME struct nbft_info_hfi \- Host Fabric Interface (HFI) Descriptor .SH SYNOPSIS diff --git a/doc/man/nbft_info_hfi_info_tcp.2 b/doc/man/nbft_info_hfi_info_tcp.2 index 23a35a2..49e128f 100644 --- a/doc/man/nbft_info_hfi_info_tcp.2 +++ b/doc/man/nbft_info_hfi_info_tcp.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_info_hfi_info_tcp" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_info_hfi_info_tcp" "September 2023" "API Manual" LINUX .SH NAME struct nbft_info_hfi_info_tcp \- HFI Transport Info Descriptor - NVMe/TCP .SH SYNOPSIS diff --git a/doc/man/nbft_info_host.2 b/doc/man/nbft_info_host.2 index f664b6d..75fc729 100644 --- a/doc/man/nbft_info_host.2 +++ b/doc/man/nbft_info_host.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_info_host" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_info_host" "September 2023" "API Manual" LINUX .SH NAME struct nbft_info_host \- Host Descriptor .SH SYNOPSIS diff --git a/doc/man/nbft_info_nid_type.2 b/doc/man/nbft_info_nid_type.2 index e4bae03..4b3b1a0 100644 --- a/doc/man/nbft_info_nid_type.2 +++ b/doc/man/nbft_info_nid_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_info_nid_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_info_nid_type" "September 2023" "API Manual" LINUX .SH NAME enum nbft_info_nid_type \- Namespace Identifier Type (NIDT) .SH SYNOPSIS diff --git a/doc/man/nbft_info_primary_admin_host_flag.2 b/doc/man/nbft_info_primary_admin_host_flag.2 index ccfcf22..cd652ef 100644 --- a/doc/man/nbft_info_primary_admin_host_flag.2 +++ b/doc/man/nbft_info_primary_admin_host_flag.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_info_primary_admin_host_flag" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_info_primary_admin_host_flag" "September 2023" "API Manual" LINUX .SH NAME enum nbft_info_primary_admin_host_flag \- Primary Administrative Host Descriptor Flags .SH SYNOPSIS diff --git a/doc/man/nbft_info_security.2 b/doc/man/nbft_info_security.2 index ab46e20..821c3a2 100644 --- a/doc/man/nbft_info_security.2 +++ b/doc/man/nbft_info_security.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_info_security" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_info_security" "September 2023" "API Manual" LINUX .SH NAME struct nbft_info_security \- Security Profile Descriptor .SH SYNOPSIS diff --git a/doc/man/nbft_info_subsystem_ns.2 b/doc/man/nbft_info_subsystem_ns.2 index fc5a441..7c79042 100644 --- a/doc/man/nbft_info_subsystem_ns.2 +++ b/doc/man/nbft_info_subsystem_ns.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_info_subsystem_ns" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_info_subsystem_ns" "September 2023" "API Manual" LINUX .SH NAME struct nbft_info_subsystem_ns \- Subsystem Namespace (SSNS) info .SH SYNOPSIS diff --git a/doc/man/nbft_security.2 b/doc/man/nbft_security.2 index df97f10..643c6bc 100644 --- a/doc/man/nbft_security.2 +++ b/doc/man/nbft_security.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_security" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_security" "September 2023" "API Manual" LINUX .SH NAME struct nbft_security \- Security Profile Descriptor (Figure 21) .SH SYNOPSIS diff --git a/doc/man/nbft_security_flags.2 b/doc/man/nbft_security_flags.2 index 10185ce..ab0dc3e 100644 --- a/doc/man/nbft_security_flags.2 +++ b/doc/man/nbft_security_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_security_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_security_flags" "September 2023" "API Manual" LINUX .SH NAME enum nbft_security_flags \- Security Profile Descriptor Flags (Figure 22) .SH SYNOPSIS diff --git a/doc/man/nbft_security_secret_type.2 b/doc/man/nbft_security_secret_type.2 index 76cc048..4880458 100644 --- a/doc/man/nbft_security_secret_type.2 +++ b/doc/man/nbft_security_secret_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_security_secret_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_security_secret_type" "September 2023" "API Manual" LINUX .SH NAME enum nbft_security_secret_type \- Security Profile Descriptor Secret Type .SH SYNOPSIS diff --git a/doc/man/nbft_ssns.2 b/doc/man/nbft_ssns.2 index 91eb2c5..24a4276 100644 --- a/doc/man/nbft_ssns.2 +++ b/doc/man/nbft_ssns.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_ssns" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_ssns" "September 2023" "API Manual" LINUX .SH NAME struct nbft_ssns \- Subsystem Namespace (SSNS) Descriptor (Figure 15) .SH SYNOPSIS diff --git a/doc/man/nbft_ssns_ext_info.2 b/doc/man/nbft_ssns_ext_info.2 index 63cd106..f8ca186 100644 --- a/doc/man/nbft_ssns_ext_info.2 +++ b/doc/man/nbft_ssns_ext_info.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nbft_ssns_ext_info" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nbft_ssns_ext_info" "September 2023" "API Manual" LINUX .SH NAME struct nbft_ssns_ext_info \- Subsystem and Namespace Extended Information Descriptor (Figure 19) .SH SYNOPSIS diff --git a/doc/man/nbft_ssns_ext_info_flags.2 b/doc/man/nbft_ssns_ext_info_flags.2 index 2723c61..c6d0402 100644 --- a/doc/man/nbft_ssns_ext_info_flags.2 +++ b/doc/man/nbft_ssns_ext_info_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_ssns_ext_info_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_ssns_ext_info_flags" "September 2023" "API Manual" LINUX .SH NAME enum nbft_ssns_ext_info_flags \- Subsystem and Namespace Extended Information Descriptor Flags .SH SYNOPSIS diff --git a/doc/man/nbft_ssns_flags.2 b/doc/man/nbft_ssns_flags.2 index 10237e6..ab61ffe 100644 --- a/doc/man/nbft_ssns_flags.2 +++ b/doc/man/nbft_ssns_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_ssns_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_ssns_flags" "September 2023" "API Manual" LINUX .SH NAME enum nbft_ssns_flags \- Subsystem and Namespace Specific Flags Field (Figure 16) .SH SYNOPSIS diff --git a/doc/man/nbft_ssns_trflags.2 b/doc/man/nbft_ssns_trflags.2 index 0a52871..e21d45a 100644 --- a/doc/man/nbft_ssns_trflags.2 +++ b/doc/man/nbft_ssns_trflags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_ssns_trflags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_ssns_trflags" "September 2023" "API Manual" LINUX .SH NAME enum nbft_ssns_trflags \- SSNS Transport Specific Flags Field (Figure 17) .SH SYNOPSIS diff --git a/doc/man/nbft_trtype.2 b/doc/man/nbft_trtype.2 index 2af7850..936109a 100644 --- a/doc/man/nbft_trtype.2 +++ b/doc/man/nbft_trtype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nbft_trtype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nbft_trtype" "September 2023" "API Manual" LINUX .SH NAME enum nbft_trtype \- NBFT Interface Transport Types (Figure 7) .SH SYNOPSIS diff --git a/doc/man/nvme_admin_opcode.2 b/doc/man/nvme_admin_opcode.2 index fc95c2f..973ad7d 100644 --- a/doc/man/nvme_admin_opcode.2 +++ b/doc/man/nvme_admin_opcode.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_admin_opcode" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_admin_opcode" "September 2023" "API Manual" LINUX .SH NAME enum nvme_admin_opcode \- Known NVMe admin opcodes .SH SYNOPSIS diff --git a/doc/man/nvme_admin_passthru.2 b/doc/man/nvme_admin_passthru.2 index 3a382eb..1428889 100644 --- a/doc/man/nvme_admin_passthru.2 +++ b/doc/man/nvme_admin_passthru.2 @@ -1,4 +1,4 @@ -.TH "nvme_admin_passthru" 9 "nvme_admin_passthru" "June 2023" "libnvme API manual" LINUX +.TH "nvme_admin_passthru" 9 "nvme_admin_passthru" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_admin_passthru \- Submit an nvme passthrough command .SH SYNOPSIS diff --git a/doc/man/nvme_admin_passthru64.2 b/doc/man/nvme_admin_passthru64.2 index c770c60..9bafc34 100644 --- a/doc/man/nvme_admin_passthru64.2 +++ b/doc/man/nvme_admin_passthru64.2 @@ -1,4 +1,4 @@ -.TH "nvme_admin_passthru64" 9 "nvme_admin_passthru64" "June 2023" "libnvme API manual" LINUX +.TH "nvme_admin_passthru64" 9 "nvme_admin_passthru64" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_admin_passthru64 \- Submit a 64-bit nvme passthrough command .SH SYNOPSIS diff --git a/doc/man/nvme_ae_info_css_nvm.2 b/doc/man/nvme_ae_info_css_nvm.2 index ea0128d..fb0acf8 100644 --- a/doc/man/nvme_ae_info_css_nvm.2 +++ b/doc/man/nvme_ae_info_css_nvm.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ae_info_css_nvm" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ae_info_css_nvm" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ae_info_css_nvm \- Asynchronous Event Information - I/O Command Specific Status .SH SYNOPSIS diff --git a/doc/man/nvme_ae_info_error.2 b/doc/man/nvme_ae_info_error.2 index 85de328..db76a02 100644 --- a/doc/man/nvme_ae_info_error.2 +++ b/doc/man/nvme_ae_info_error.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ae_info_error" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ae_info_error" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ae_info_error \- Asynchronous Event Information - Error Status .SH SYNOPSIS diff --git a/doc/man/nvme_ae_info_notice.2 b/doc/man/nvme_ae_info_notice.2 index b5257d8..d60ef1e 100644 --- a/doc/man/nvme_ae_info_notice.2 +++ b/doc/man/nvme_ae_info_notice.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ae_info_notice" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ae_info_notice" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ae_info_notice \- Asynchronous Event Information - Notice .SH SYNOPSIS diff --git a/doc/man/nvme_ae_info_smart.2 b/doc/man/nvme_ae_info_smart.2 index 2b290b6..764797d 100644 --- a/doc/man/nvme_ae_info_smart.2 +++ b/doc/man/nvme_ae_info_smart.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ae_info_smart" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ae_info_smart" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ae_info_smart \- Asynchronous Event Information - SMART / Health Status .SH SYNOPSIS diff --git a/doc/man/nvme_ae_type.2 b/doc/man/nvme_ae_type.2 index 2ab217d..3316776 100644 --- a/doc/man/nvme_ae_type.2 +++ b/doc/man/nvme_ae_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ae_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ae_type" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ae_type \- Asynchronous Event Type .SH SYNOPSIS diff --git a/doc/man/nvme_aggregate_endurance_group_event.2 b/doc/man/nvme_aggregate_endurance_group_event.2 index 1f9dc9c..ee8cf52 100644 --- a/doc/man/nvme_aggregate_endurance_group_event.2 +++ b/doc/man/nvme_aggregate_endurance_group_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_aggregate_endurance_group_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_aggregate_endurance_group_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_aggregate_endurance_group_event \- Endurance Group Event Aggregate .SH SYNOPSIS diff --git a/doc/man/nvme_aggregate_predictable_lat_event.2 b/doc/man/nvme_aggregate_predictable_lat_event.2 index c860a99..ebe86c2 100644 --- a/doc/man/nvme_aggregate_predictable_lat_event.2 +++ b/doc/man/nvme_aggregate_predictable_lat_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_aggregate_predictable_lat_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_aggregate_predictable_lat_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_aggregate_predictable_lat_event \- Predictable Latency Event Aggregate Log Page .SH SYNOPSIS diff --git a/doc/man/nvme_ana_group_desc.2 b/doc/man/nvme_ana_group_desc.2 index 941ff9b..acba0bd 100644 --- a/doc/man/nvme_ana_group_desc.2 +++ b/doc/man/nvme_ana_group_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_ana_group_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_ana_group_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_ana_group_desc \- ANA Group Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_ana_log.2 b/doc/man/nvme_ana_log.2 index 66cada5..980fff0 100644 --- a/doc/man/nvme_ana_log.2 +++ b/doc/man/nvme_ana_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_ana_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_ana_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_ana_log \- Asymmetric Namespace Access Log .SH SYNOPSIS diff --git a/doc/man/nvme_ana_state.2 b/doc/man/nvme_ana_state.2 index 18b0070..2f50dac 100644 --- a/doc/man/nvme_ana_state.2 +++ b/doc/man/nvme_ana_state.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ana_state" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ana_state" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ana_state \- ANA Group Descriptor - Asymmetric Namespace Access State .SH SYNOPSIS diff --git a/doc/man/nvme_apst_entry.2 b/doc/man/nvme_apst_entry.2 index db6419f..30eaa48 100644 --- a/doc/man/nvme_apst_entry.2 +++ b/doc/man/nvme_apst_entry.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_apst_entry" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_apst_entry" "September 2023" "API Manual" LINUX .SH NAME enum nvme_apst_entry \- Autonomous Power State Transition .SH SYNOPSIS diff --git a/doc/man/nvme_boot_partition.2 b/doc/man/nvme_boot_partition.2 index 2bb6065..604c9c6 100644 --- a/doc/man/nvme_boot_partition.2 +++ b/doc/man/nvme_boot_partition.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_boot_partition" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_boot_partition" "September 2023" "API Manual" LINUX .SH NAME struct nvme_boot_partition \- Boot Partition Log .SH SYNOPSIS diff --git a/doc/man/nvme_capacity_config_desc.2 b/doc/man/nvme_capacity_config_desc.2 index 298ac63..7e05c7c 100644 --- a/doc/man/nvme_capacity_config_desc.2 +++ b/doc/man/nvme_capacity_config_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_capacity_config_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_capacity_config_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_capacity_config_desc \- Capacity Configuration structure definitions .SH SYNOPSIS diff --git a/doc/man/nvme_capacity_mgmt.2 b/doc/man/nvme_capacity_mgmt.2 index d75a6fb..79cc70c 100644 --- a/doc/man/nvme_capacity_mgmt.2 +++ b/doc/man/nvme_capacity_mgmt.2 @@ -1,4 +1,4 @@ -.TH "nvme_capacity_mgmt" 9 "nvme_capacity_mgmt" "June 2023" "libnvme API manual" LINUX +.TH "nvme_capacity_mgmt" 9 "nvme_capacity_mgmt" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_capacity_mgmt \- Capacity management command .SH SYNOPSIS diff --git a/doc/man/nvme_change_ns_event.2 b/doc/man/nvme_change_ns_event.2 index b1dd10f..3a99ab8 100644 --- a/doc/man/nvme_change_ns_event.2 +++ b/doc/man/nvme_change_ns_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_change_ns_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_change_ns_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_change_ns_event \- Change Namespace Event Data .SH SYNOPSIS diff --git a/doc/man/nvme_channel_config_desc.2 b/doc/man/nvme_channel_config_desc.2 index 1860f91..ad9cdeb 100644 --- a/doc/man/nvme_channel_config_desc.2 +++ b/doc/man/nvme_channel_config_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_channel_config_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_channel_config_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_channel_config_desc \- Channel Configuration Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_cmb_size.2 b/doc/man/nvme_cmb_size.2 index 8e369d8..34dbfb5 100644 --- a/doc/man/nvme_cmb_size.2 +++ b/doc/man/nvme_cmb_size.2 @@ -1,4 +1,4 @@ -.TH "nvme_cmb_size" 9 "nvme_cmb_size" "June 2023" "libnvme API manual" LINUX +.TH "nvme_cmb_size" 9 "nvme_cmb_size" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_cmb_size \- Calculate size of the controller memory buffer .SH SYNOPSIS diff --git a/doc/man/nvme_cmd_effects.2 b/doc/man/nvme_cmd_effects.2 index 6559bd8..b22c72a 100644 --- a/doc/man/nvme_cmd_effects.2 +++ b/doc/man/nvme_cmd_effects.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_cmd_effects" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_cmd_effects" "September 2023" "API Manual" LINUX .SH NAME enum nvme_cmd_effects \- Commands Supported and Effects .SH SYNOPSIS diff --git a/doc/man/nvme_cmd_effects_log.2 b/doc/man/nvme_cmd_effects_log.2 index 90cba63..7821f88 100644 --- a/doc/man/nvme_cmd_effects_log.2 +++ b/doc/man/nvme_cmd_effects_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_cmd_effects_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_cmd_effects_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_cmd_effects_log \- Commands Supported and Effects Log .SH SYNOPSIS diff --git a/doc/man/nvme_cmd_format_mset.2 b/doc/man/nvme_cmd_format_mset.2 index c827719..6cbccc2 100644 --- a/doc/man/nvme_cmd_format_mset.2 +++ b/doc/man/nvme_cmd_format_mset.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_cmd_format_mset" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_cmd_format_mset" "September 2023" "API Manual" LINUX .SH NAME enum nvme_cmd_format_mset \- Format NVM - Metadata Settings .SH SYNOPSIS diff --git a/doc/man/nvme_cmd_format_pi.2 b/doc/man/nvme_cmd_format_pi.2 index 29d6609..a7d244b 100644 --- a/doc/man/nvme_cmd_format_pi.2 +++ b/doc/man/nvme_cmd_format_pi.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_cmd_format_pi" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_cmd_format_pi" "September 2023" "API Manual" LINUX .SH NAME enum nvme_cmd_format_pi \- Format NVM - Protection Information .SH SYNOPSIS diff --git a/doc/man/nvme_cmd_format_pil.2 b/doc/man/nvme_cmd_format_pil.2 index f8d5110..fcc5775 100644 --- a/doc/man/nvme_cmd_format_pil.2 +++ b/doc/man/nvme_cmd_format_pil.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_cmd_format_pil" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_cmd_format_pil" "September 2023" "API Manual" LINUX .SH NAME enum nvme_cmd_format_pil \- Format NVM - Protection Information Location .SH SYNOPSIS diff --git a/doc/man/nvme_cmd_format_ses.2 b/doc/man/nvme_cmd_format_ses.2 index 028c59f..cbbcbe0 100644 --- a/doc/man/nvme_cmd_format_ses.2 +++ b/doc/man/nvme_cmd_format_ses.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_cmd_format_ses" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_cmd_format_ses" "September 2023" "API Manual" LINUX .SH NAME enum nvme_cmd_format_ses \- Format NVM - Secure Erase Settings .SH SYNOPSIS diff --git a/doc/man/nvme_cmd_get_log_lid.2 b/doc/man/nvme_cmd_get_log_lid.2 index 755e38b..31f2e7c 100644 --- a/doc/man/nvme_cmd_get_log_lid.2 +++ b/doc/man/nvme_cmd_get_log_lid.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_cmd_get_log_lid" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_cmd_get_log_lid" "September 2023" "API Manual" LINUX .SH NAME enum nvme_cmd_get_log_lid \- Get Log Page -Log Page Identifiers .SH SYNOPSIS @@ -88,6 +88,10 @@ enum nvme_cmd_get_log_lid { , .br .br +.BI " NVME_LOG_LID_PHY_RX_EOM" +, +.br +.br .BI " NVME_LOG_LID_FDP_CONFIGS" , .br @@ -162,6 +166,8 @@ Feature Identifiers Supported and Effects NVMe-MI Commands Supported and Effects .IP "NVME_LOG_LID_BOOT_PARTITION" 12 Boot Partition +.IP "NVME_LOG_LID_PHY_RX_EOM" 12 +Physical Interface Receiver Eye Opening Measurement .IP "NVME_LOG_LID_FDP_CONFIGS" 12 FDP Configurations .IP "NVME_LOG_LID_FDP_RUH_USAGE" 12 diff --git a/doc/man/nvme_cmd_get_log_telemetry_host_lsp.2 b/doc/man/nvme_cmd_get_log_telemetry_host_lsp.2 index 486c355..89c81b7 100644 --- a/doc/man/nvme_cmd_get_log_telemetry_host_lsp.2 +++ b/doc/man/nvme_cmd_get_log_telemetry_host_lsp.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_cmd_get_log_telemetry_host_lsp" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_cmd_get_log_telemetry_host_lsp" "September 2023" "API Manual" LINUX .SH NAME enum nvme_cmd_get_log_telemetry_host_lsp \- Telemetry Host-Initiated log specific field .SH SYNOPSIS diff --git a/doc/man/nvme_compare.2 b/doc/man/nvme_compare.2 index ef2c020..f53e37e 100644 --- a/doc/man/nvme_compare.2 +++ b/doc/man/nvme_compare.2 @@ -1,4 +1,4 @@ -.TH "nvme_compare" 9 "nvme_compare" "June 2023" "libnvme API manual" LINUX +.TH "nvme_compare" 9 "nvme_compare" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_compare \- Submit an nvme user compare command .SH SYNOPSIS diff --git a/doc/man/nvme_connect_err.2 b/doc/man/nvme_connect_err.2 index 0cd9568..7052116 100644 --- a/doc/man/nvme_connect_err.2 +++ b/doc/man/nvme_connect_err.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_connect_err" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_connect_err" "September 2023" "API Manual" LINUX .SH NAME enum nvme_connect_err \- nvme connect error codes .SH SYNOPSIS diff --git a/doc/man/nvme_constants.2 b/doc/man/nvme_constants.2 index b83d506..47ca5a2 100644 --- a/doc/man/nvme_constants.2 +++ b/doc/man/nvme_constants.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_constants" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_constants" "September 2023" "API Manual" LINUX .SH NAME enum nvme_constants \- A place to stash various constant nvme values .SH SYNOPSIS diff --git a/doc/man/nvme_copy.2 b/doc/man/nvme_copy.2 index 4cc230d..af40f25 100644 --- a/doc/man/nvme_copy.2 +++ b/doc/man/nvme_copy.2 @@ -1,4 +1,4 @@ -.TH "nvme_copy" 9 "nvme_copy" "June 2023" "libnvme API manual" LINUX +.TH "nvme_copy" 9 "nvme_copy" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_copy \- Copy command .SH SYNOPSIS diff --git a/doc/man/nvme_copy_range.2 b/doc/man/nvme_copy_range.2 index f470dcf..76dcedf 100644 --- a/doc/man/nvme_copy_range.2 +++ b/doc/man/nvme_copy_range.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_copy_range" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_copy_range" "September 2023" "API Manual" LINUX .SH NAME struct nvme_copy_range \- Copy - Source Range Entries Descriptor Format .SH SYNOPSIS diff --git a/doc/man/nvme_copy_range_f1.2 b/doc/man/nvme_copy_range_f1.2 index 069bff6..75319cc 100644 --- a/doc/man/nvme_copy_range_f1.2 +++ b/doc/man/nvme_copy_range_f1.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_copy_range_f1" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_copy_range_f1" "September 2023" "API Manual" LINUX .SH NAME struct nvme_copy_range_f1 \- Copy - Source Range Entries Descriptor Format 1h .SH SYNOPSIS diff --git a/doc/man/nvme_create_ctrl.2 b/doc/man/nvme_create_ctrl.2 index 217235c..f4f8ebb 100644 --- a/doc/man/nvme_create_ctrl.2 +++ b/doc/man/nvme_create_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_create_ctrl" 9 "nvme_create_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_create_ctrl" 9 "nvme_create_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_create_ctrl \- Allocate an unconnected NVMe controller .SH SYNOPSIS diff --git a/doc/man/nvme_create_root.2 b/doc/man/nvme_create_root.2 index b41325d..d50cf09 100644 --- a/doc/man/nvme_create_root.2 +++ b/doc/man/nvme_create_root.2 @@ -1,4 +1,4 @@ -.TH "nvme_create_root" 9 "nvme_create_root" "June 2023" "libnvme API manual" LINUX +.TH "nvme_create_root" 9 "nvme_create_root" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_create_root \- Initialize root object .SH SYNOPSIS diff --git a/doc/man/nvme_csi.2 b/doc/man/nvme_csi.2 index 7a0a7f1..272ea6e 100644 --- a/doc/man/nvme_csi.2 +++ b/doc/man/nvme_csi.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_csi" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_csi" "September 2023" "API Manual" LINUX .SH NAME enum nvme_csi \- Defined command set indicators .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_config_match.2 b/doc/man/nvme_ctrl_config_match.2 new file mode 100644 index 0000000..a288fc6 --- /dev/null +++ b/doc/man/nvme_ctrl_config_match.2 @@ -0,0 +1,33 @@ +.TH "nvme_ctrl_config_match" 9 "nvme_ctrl_config_match" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_ctrl_config_match \- Check if ctrl @c matches config params +.SH SYNOPSIS +.B "bool" nvme_ctrl_config_match +.BI "(struct nvme_ctrl *c " "," +.BI "const char *transport " "," +.BI "const char *traddr " "," +.BI "const char *trsvcid " "," +.BI "const char *subsysnqn " "," +.BI "const char *host_traddr " "," +.BI "const char *host_iface " ");" +.SH ARGUMENTS +.IP "c" 12 +An existing controller instance +.IP "transport" 12 +Transport name +.IP "traddr" 12 +Transport address +.IP "trsvcid" 12 +Transport service identifier +.IP "subsysnqn" 12 +Subsystem NQN +.IP "host_traddr" 12 +Host transport address +.IP "host_iface" 12 +Host interface name +.SH "DESCRIPTION" +Check that controller \fIc\fP matches parameters: \fItransport\fP, \fItraddr\fP, +\fItrsvcid\fP, \fIsubsysnqn\fP, \fIhost_traddr\fP, and \fIhost_iface\fP. Parameters set +to NULL will be ignored. +.SH "RETURN" +true if there's a match, false otherwise. diff --git a/doc/man/nvme_ctrl_find.2 b/doc/man/nvme_ctrl_find.2 new file mode 100644 index 0000000..d11b733 --- /dev/null +++ b/doc/man/nvme_ctrl_find.2 @@ -0,0 +1,37 @@ +.TH "nvme_ctrl_find" 9 "nvme_ctrl_find" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_ctrl_find \- Locate an existing controller +.SH SYNOPSIS +.B "nvme_ctrl_t" nvme_ctrl_find +.BI "(nvme_subsystem_t s " "," +.BI "const char *transport " "," +.BI "const char *traddr " "," +.BI "const char *trsvcid " "," +.BI "const char *subsysnqn " "," +.BI "const char *host_traddr " "," +.BI "const char *host_iface " ");" +.SH ARGUMENTS +.IP "s" 12 +\fInvme_subsystem_t\fP object +.IP "transport" 12 +Transport name +.IP "traddr" 12 +Transport address +.IP "trsvcid" 12 +Transport service identifier +.IP "subsysnqn" 12 +Subsystem NQN +.IP "host_traddr" 12 +Host transport address +.IP "host_iface" 12 +Host interface name +.SH "DESCRIPTION" +Lookup a controller in \fIs\fP based on \fItransport\fP, \fItraddr\fP, \fItrsvcid\fP, +\fIsubsysnqn\fP, \fIhost_traddr\fP, and \fIhost_iface\fP. \fItransport\fP must be specified, +other fields may be required depending on the transport. Parameters set +to NULL will be ignored. + +Unlike \fBnvme_lookup_ctrl\fP, this function does not create a new object if +an existing controller cannot be found. +.SH "RETURN" +Controller instance on success, NULL otherwise. diff --git a/doc/man/nvme_ctrl_first_ns.2 b/doc/man/nvme_ctrl_first_ns.2 index ed38019..7293134 100644 --- a/doc/man/nvme_ctrl_first_ns.2 +++ b/doc/man/nvme_ctrl_first_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_first_ns" 9 "nvme_ctrl_first_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_first_ns" 9 "nvme_ctrl_first_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_first_ns \- Start namespace iterator .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_first_path.2 b/doc/man/nvme_ctrl_first_path.2 index 29f7436..baebf19 100644 --- a/doc/man/nvme_ctrl_first_path.2 +++ b/doc/man/nvme_ctrl_first_path.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_first_path" 9 "nvme_ctrl_first_path" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_first_path" 9 "nvme_ctrl_first_path" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_first_path \- Start path iterator .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_for_each_ns.2 b/doc/man/nvme_ctrl_for_each_ns.2 index 139126d..0dc8f3a 100644 --- a/doc/man/nvme_ctrl_for_each_ns.2 +++ b/doc/man/nvme_ctrl_for_each_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_for_each_ns" 9 "nvme_ctrl_for_each_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_for_each_ns" 9 "nvme_ctrl_for_each_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_for_each_ns \- Traverse namespaces .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_for_each_ns_safe.2 b/doc/man/nvme_ctrl_for_each_ns_safe.2 index 3420e49..f09fb9d 100644 --- a/doc/man/nvme_ctrl_for_each_ns_safe.2 +++ b/doc/man/nvme_ctrl_for_each_ns_safe.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_for_each_ns_safe" 9 "nvme_ctrl_for_each_ns_safe" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_for_each_ns_safe" 9 "nvme_ctrl_for_each_ns_safe" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_for_each_ns_safe \- Traverse namespaces .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_for_each_path.2 b/doc/man/nvme_ctrl_for_each_path.2 index c98f33b..8c212bc 100644 --- a/doc/man/nvme_ctrl_for_each_path.2 +++ b/doc/man/nvme_ctrl_for_each_path.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_for_each_path" 9 "nvme_ctrl_for_each_path" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_for_each_path" 9 "nvme_ctrl_for_each_path" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_for_each_path \- Traverse paths .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_for_each_path_safe.2 b/doc/man/nvme_ctrl_for_each_path_safe.2 index b7da27f..1da88c6 100644 --- a/doc/man/nvme_ctrl_for_each_path_safe.2 +++ b/doc/man/nvme_ctrl_for_each_path_safe.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_for_each_path_safe" 9 "nvme_ctrl_for_each_path_safe" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_for_each_path_safe" 9 "nvme_ctrl_for_each_path_safe" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_for_each_path_safe \- Traverse paths .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_address.2 b/doc/man/nvme_ctrl_get_address.2 index 44de2a2..b7cfd1c 100644 --- a/doc/man/nvme_ctrl_get_address.2 +++ b/doc/man/nvme_ctrl_get_address.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_address" 9 "nvme_ctrl_get_address" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_address" 9 "nvme_ctrl_get_address" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_address \- Address string of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_config.2 b/doc/man/nvme_ctrl_get_config.2 index 8fbc976..16edd91 100644 --- a/doc/man/nvme_ctrl_get_config.2 +++ b/doc/man/nvme_ctrl_get_config.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_config" 9 "nvme_ctrl_get_config" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_config" 9 "nvme_ctrl_get_config" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_config \- Fabrics configuration of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_dhchap_host_key.2 b/doc/man/nvme_ctrl_get_dhchap_host_key.2 index 48526e5..26e2f2c 100644 --- a/doc/man/nvme_ctrl_get_dhchap_host_key.2 +++ b/doc/man/nvme_ctrl_get_dhchap_host_key.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_dhchap_host_key" 9 "nvme_ctrl_get_dhchap_host_key" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_dhchap_host_key" 9 "nvme_ctrl_get_dhchap_host_key" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_dhchap_host_key \- Return host key .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_dhchap_key.2 b/doc/man/nvme_ctrl_get_dhchap_key.2 index f190577..75b0f15 100644 --- a/doc/man/nvme_ctrl_get_dhchap_key.2 +++ b/doc/man/nvme_ctrl_get_dhchap_key.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_dhchap_key" 9 "nvme_ctrl_get_dhchap_key" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_dhchap_key" 9 "nvme_ctrl_get_dhchap_key" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_dhchap_key \- Return controller key .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_fd.2 b/doc/man/nvme_ctrl_get_fd.2 index f8a92a4..b873126 100644 --- a/doc/man/nvme_ctrl_get_fd.2 +++ b/doc/man/nvme_ctrl_get_fd.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_fd" 9 "nvme_ctrl_get_fd" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_fd" 9 "nvme_ctrl_get_fd" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_fd \- Get associated file descriptor .SH SYNOPSIS @@ -7,5 +7,12 @@ nvme_ctrl_get_fd \- Get associated file descriptor .SH ARGUMENTS .IP "c" 12 Controller instance +.SH "DESCRIPTION" +libnvme will \fBopen\fP the file (if not already opened) and keep +an internal copy of the file descriptor. Following calls to +this API retrieve the internal cached copy of the file +descriptor. The file will remain opened and the fd will +remain cached until the controller object is deleted or +\fBnvme_ctrl_release_fd\fP is called. .SH "RETURN" File descriptor associated with \fIc\fP or -1 diff --git a/doc/man/nvme_ctrl_get_firmware.2 b/doc/man/nvme_ctrl_get_firmware.2 index 45d2c1a..1bc3c70 100644 --- a/doc/man/nvme_ctrl_get_firmware.2 +++ b/doc/man/nvme_ctrl_get_firmware.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_firmware" 9 "nvme_ctrl_get_firmware" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_firmware" 9 "nvme_ctrl_get_firmware" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_firmware \- Firmware string of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_host_iface.2 b/doc/man/nvme_ctrl_get_host_iface.2 index 1130ad0..7b29e22 100644 --- a/doc/man/nvme_ctrl_get_host_iface.2 +++ b/doc/man/nvme_ctrl_get_host_iface.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_host_iface" 9 "nvme_ctrl_get_host_iface" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_host_iface" 9 "nvme_ctrl_get_host_iface" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_host_iface \- Host interface name of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_host_traddr.2 b/doc/man/nvme_ctrl_get_host_traddr.2 index bc3d2e0..ea17815 100644 --- a/doc/man/nvme_ctrl_get_host_traddr.2 +++ b/doc/man/nvme_ctrl_get_host_traddr.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_host_traddr" 9 "nvme_ctrl_get_host_traddr" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_host_traddr" 9 "nvme_ctrl_get_host_traddr" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_host_traddr \- Host transport address of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_model.2 b/doc/man/nvme_ctrl_get_model.2 index d2f2e26..428d567 100644 --- a/doc/man/nvme_ctrl_get_model.2 +++ b/doc/man/nvme_ctrl_get_model.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_model" 9 "nvme_ctrl_get_model" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_model" 9 "nvme_ctrl_get_model" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_model \- Model of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_name.2 b/doc/man/nvme_ctrl_get_name.2 index bdcbc7c..34a6091 100644 --- a/doc/man/nvme_ctrl_get_name.2 +++ b/doc/man/nvme_ctrl_get_name.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_name" 9 "nvme_ctrl_get_name" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_name" 9 "nvme_ctrl_get_name" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_name \- sysfs name of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_numa_node.2 b/doc/man/nvme_ctrl_get_numa_node.2 index b0625cd..2eda337 100644 --- a/doc/man/nvme_ctrl_get_numa_node.2 +++ b/doc/man/nvme_ctrl_get_numa_node.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_numa_node" 9 "nvme_ctrl_get_numa_node" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_numa_node" 9 "nvme_ctrl_get_numa_node" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_numa_node \- NUMA node of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_phy_slot.2 b/doc/man/nvme_ctrl_get_phy_slot.2 index 3427078..b94706c 100644 --- a/doc/man/nvme_ctrl_get_phy_slot.2 +++ b/doc/man/nvme_ctrl_get_phy_slot.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_phy_slot" 9 "nvme_ctrl_get_phy_slot" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_phy_slot" 9 "nvme_ctrl_get_phy_slot" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_phy_slot \- PCI physical slot number of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_queue_count.2 b/doc/man/nvme_ctrl_get_queue_count.2 index 6d5753f..cce03d5 100644 --- a/doc/man/nvme_ctrl_get_queue_count.2 +++ b/doc/man/nvme_ctrl_get_queue_count.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_queue_count" 9 "nvme_ctrl_get_queue_count" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_queue_count" 9 "nvme_ctrl_get_queue_count" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_queue_count \- Queue count of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_serial.2 b/doc/man/nvme_ctrl_get_serial.2 index 7ca8800..0c556e5 100644 --- a/doc/man/nvme_ctrl_get_serial.2 +++ b/doc/man/nvme_ctrl_get_serial.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_serial" 9 "nvme_ctrl_get_serial" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_serial" 9 "nvme_ctrl_get_serial" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_serial \- Serial number of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_sqsize.2 b/doc/man/nvme_ctrl_get_sqsize.2 index 46d91ce..3f61d33 100644 --- a/doc/man/nvme_ctrl_get_sqsize.2 +++ b/doc/man/nvme_ctrl_get_sqsize.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_sqsize" 9 "nvme_ctrl_get_sqsize" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_sqsize" 9 "nvme_ctrl_get_sqsize" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_sqsize \- SQ size of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_src_addr.2 b/doc/man/nvme_ctrl_get_src_addr.2 new file mode 100644 index 0000000..8a25ded --- /dev/null +++ b/doc/man/nvme_ctrl_get_src_addr.2 @@ -0,0 +1,17 @@ +.TH "nvme_ctrl_get_src_addr" 9 "nvme_ctrl_get_src_addr" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_ctrl_get_src_addr \- Extract src_addr from the c->address string +.SH SYNOPSIS +.B "char *" nvme_ctrl_get_src_addr +.BI "(nvme_ctrl_t c " "," +.BI "char *src_addr " "," +.BI "size_t src_addr_len " ");" +.SH ARGUMENTS +.IP "c" 12 +Controller instance +.IP "src_addr" 12 +Where to copy the src_addr. Size must be at least INET6_ADDRSTRLEN. +.IP "src_addr_len" 12 +Length of the buffer \fIsrc_addr\fP. +.SH "RETURN" +Pointer to \fIsrc_addr\fP on success. NULL on failure to extract the src_addr. diff --git a/doc/man/nvme_ctrl_get_state.2 b/doc/man/nvme_ctrl_get_state.2 index 5336673..991b9fd 100644 --- a/doc/man/nvme_ctrl_get_state.2 +++ b/doc/man/nvme_ctrl_get_state.2 @@ -1,6 +1,6 @@ -.TH "nvme_ctrl_get_state" 9 "nvme_ctrl_get_state" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_state" 9 "nvme_ctrl_get_state" "September 2023" "libnvme API manual" LINUX .SH NAME -nvme_ctrl_get_state \- Running state of an controller +nvme_ctrl_get_state \- Running state of a controller .SH SYNOPSIS .B "const char *" nvme_ctrl_get_state .BI "(nvme_ctrl_t c " ");" diff --git a/doc/man/nvme_ctrl_get_subsysnqn.2 b/doc/man/nvme_ctrl_get_subsysnqn.2 index 7bb8c7e..82bea3b 100644 --- a/doc/man/nvme_ctrl_get_subsysnqn.2 +++ b/doc/man/nvme_ctrl_get_subsysnqn.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_subsysnqn" 9 "nvme_ctrl_get_subsysnqn" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_subsysnqn" 9 "nvme_ctrl_get_subsysnqn" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_subsysnqn \- Subsystem NQN of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_subsystem.2 b/doc/man/nvme_ctrl_get_subsystem.2 index 83380fe..4ac9e90 100644 --- a/doc/man/nvme_ctrl_get_subsystem.2 +++ b/doc/man/nvme_ctrl_get_subsystem.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_subsystem" 9 "nvme_ctrl_get_subsystem" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_subsystem" 9 "nvme_ctrl_get_subsystem" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_subsystem \- Parent subsystem of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_sysfs_dir.2 b/doc/man/nvme_ctrl_get_sysfs_dir.2 index a2115b9..0496c0f 100644 --- a/doc/man/nvme_ctrl_get_sysfs_dir.2 +++ b/doc/man/nvme_ctrl_get_sysfs_dir.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_sysfs_dir" 9 "nvme_ctrl_get_sysfs_dir" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_sysfs_dir" 9 "nvme_ctrl_get_sysfs_dir" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_sysfs_dir \- sysfs directory of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_traddr.2 b/doc/man/nvme_ctrl_get_traddr.2 index e1ec4a9..1cc6737 100644 --- a/doc/man/nvme_ctrl_get_traddr.2 +++ b/doc/man/nvme_ctrl_get_traddr.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_traddr" 9 "nvme_ctrl_get_traddr" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_traddr" 9 "nvme_ctrl_get_traddr" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_traddr \- Transport address of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_transport.2 b/doc/man/nvme_ctrl_get_transport.2 index b69b72b..0fbe51b 100644 --- a/doc/man/nvme_ctrl_get_transport.2 +++ b/doc/man/nvme_ctrl_get_transport.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_transport" 9 "nvme_ctrl_get_transport" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_transport" 9 "nvme_ctrl_get_transport" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_transport \- Transport type of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_get_trsvcid.2 b/doc/man/nvme_ctrl_get_trsvcid.2 index 8d17c64..d39c0d2 100644 --- a/doc/man/nvme_ctrl_get_trsvcid.2 +++ b/doc/man/nvme_ctrl_get_trsvcid.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_get_trsvcid" 9 "nvme_ctrl_get_trsvcid" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_get_trsvcid" 9 "nvme_ctrl_get_trsvcid" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_get_trsvcid \- Transport service identifier of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_identify.2 b/doc/man/nvme_ctrl_identify.2 index 32e2d34..2f3cac4 100644 --- a/doc/man/nvme_ctrl_identify.2 +++ b/doc/man/nvme_ctrl_identify.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_identify" 9 "nvme_ctrl_identify" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_identify" 9 "nvme_ctrl_identify" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_identify \- Issues an 'identify controller' command .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_is_discovered.2 b/doc/man/nvme_ctrl_is_discovered.2 index 27c3c4b..3e222fa 100644 --- a/doc/man/nvme_ctrl_is_discovered.2 +++ b/doc/man/nvme_ctrl_is_discovered.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_is_discovered" 9 "nvme_ctrl_is_discovered" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_is_discovered" 9 "nvme_ctrl_is_discovered" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_is_discovered \- Returns the value of the 'discovered' flag .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_is_discovery_ctrl.2 b/doc/man/nvme_ctrl_is_discovery_ctrl.2 index fc105d6..ca4c50f 100644 --- a/doc/man/nvme_ctrl_is_discovery_ctrl.2 +++ b/doc/man/nvme_ctrl_is_discovery_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_is_discovery_ctrl" 9 "nvme_ctrl_is_discovery_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_is_discovery_ctrl" 9 "nvme_ctrl_is_discovery_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_is_discovery_ctrl \- Check the 'discovery_ctrl' flag .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_is_persistent.2 b/doc/man/nvme_ctrl_is_persistent.2 index e6abc2b..168036a 100644 --- a/doc/man/nvme_ctrl_is_persistent.2 +++ b/doc/man/nvme_ctrl_is_persistent.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_is_persistent" 9 "nvme_ctrl_is_persistent" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_is_persistent" 9 "nvme_ctrl_is_persistent" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_is_persistent \- Returns the value of the 'persistent' flag .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_is_unique_discovery_ctrl.2 b/doc/man/nvme_ctrl_is_unique_discovery_ctrl.2 index c3e6fc4..ec5cd8d 100644 --- a/doc/man/nvme_ctrl_is_unique_discovery_ctrl.2 +++ b/doc/man/nvme_ctrl_is_unique_discovery_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_is_unique_discovery_ctrl" 9 "nvme_ctrl_is_unique_discovery_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_is_unique_discovery_ctrl" 9 "nvme_ctrl_is_unique_discovery_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_is_unique_discovery_ctrl \- Check the 'unique_discovery_ctrl' flag .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_list.2 b/doc/man/nvme_ctrl_list.2 index 6e2ae8d..e8b4df6 100644 --- a/doc/man/nvme_ctrl_list.2 +++ b/doc/man/nvme_ctrl_list.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_ctrl_list" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_ctrl_list" "September 2023" "API Manual" LINUX .SH NAME struct nvme_ctrl_list \- Controller List .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_metadata_type.2 b/doc/man/nvme_ctrl_metadata_type.2 index 61e1785..8a5f448 100644 --- a/doc/man/nvme_ctrl_metadata_type.2 +++ b/doc/man/nvme_ctrl_metadata_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ctrl_metadata_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ctrl_metadata_type" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ctrl_metadata_type \- Controller Metadata Element Types .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_next_ns.2 b/doc/man/nvme_ctrl_next_ns.2 index 0dcedec..fe3e391 100644 --- a/doc/man/nvme_ctrl_next_ns.2 +++ b/doc/man/nvme_ctrl_next_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_next_ns" 9 "nvme_ctrl_next_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_next_ns" 9 "nvme_ctrl_next_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_next_ns \- Next namespace iterator .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_next_path.2 b/doc/man/nvme_ctrl_next_path.2 index 1d16b54..72026ae 100644 --- a/doc/man/nvme_ctrl_next_path.2 +++ b/doc/man/nvme_ctrl_next_path.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_next_path" 9 "nvme_ctrl_next_path" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_next_path" 9 "nvme_ctrl_next_path" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_next_path \- Next path iterator .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_release_fd.2 b/doc/man/nvme_ctrl_release_fd.2 new file mode 100644 index 0000000..8ac01ad --- /dev/null +++ b/doc/man/nvme_ctrl_release_fd.2 @@ -0,0 +1,9 @@ +.TH "nvme_ctrl_release_fd" 9 "nvme_ctrl_release_fd" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_ctrl_release_fd \- Close fd and clear fd from controller object +.SH SYNOPSIS +.B "void" nvme_ctrl_release_fd +.BI "(nvme_ctrl_t c " ");" +.SH ARGUMENTS +.IP "c" 12 +Controller instance diff --git a/doc/man/nvme_ctrl_reset.2 b/doc/man/nvme_ctrl_reset.2 index 07e09c0..c1443e6 100644 --- a/doc/man/nvme_ctrl_reset.2 +++ b/doc/man/nvme_ctrl_reset.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_reset" 9 "nvme_ctrl_reset" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_reset" 9 "nvme_ctrl_reset" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_reset \- Initiate a controller reset .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_set_dhchap_host_key.2 b/doc/man/nvme_ctrl_set_dhchap_host_key.2 index 29f3ada..73c529a 100644 --- a/doc/man/nvme_ctrl_set_dhchap_host_key.2 +++ b/doc/man/nvme_ctrl_set_dhchap_host_key.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_set_dhchap_host_key" 9 "nvme_ctrl_set_dhchap_host_key" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_set_dhchap_host_key" 9 "nvme_ctrl_set_dhchap_host_key" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_set_dhchap_host_key \- Set host key .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_set_dhchap_key.2 b/doc/man/nvme_ctrl_set_dhchap_key.2 index a2fed0e..a312844 100644 --- a/doc/man/nvme_ctrl_set_dhchap_key.2 +++ b/doc/man/nvme_ctrl_set_dhchap_key.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_set_dhchap_key" 9 "nvme_ctrl_set_dhchap_key" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_set_dhchap_key" 9 "nvme_ctrl_set_dhchap_key" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_set_dhchap_key \- Set controller key .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_set_discovered.2 b/doc/man/nvme_ctrl_set_discovered.2 index bc7ae03..ec8f3a6 100644 --- a/doc/man/nvme_ctrl_set_discovered.2 +++ b/doc/man/nvme_ctrl_set_discovered.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_set_discovered" 9 "nvme_ctrl_set_discovered" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_set_discovered" 9 "nvme_ctrl_set_discovered" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_set_discovered \- Set the 'discovered' flag .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_set_discovery_ctrl.2 b/doc/man/nvme_ctrl_set_discovery_ctrl.2 index c018fff..392345f 100644 --- a/doc/man/nvme_ctrl_set_discovery_ctrl.2 +++ b/doc/man/nvme_ctrl_set_discovery_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_set_discovery_ctrl" 9 "nvme_ctrl_set_discovery_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_set_discovery_ctrl" 9 "nvme_ctrl_set_discovery_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_set_discovery_ctrl \- Set the 'discovery_ctrl' flag .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_set_persistent.2 b/doc/man/nvme_ctrl_set_persistent.2 index 11cfc17..05e8da2 100644 --- a/doc/man/nvme_ctrl_set_persistent.2 +++ b/doc/man/nvme_ctrl_set_persistent.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_set_persistent" 9 "nvme_ctrl_set_persistent" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_set_persistent" 9 "nvme_ctrl_set_persistent" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_set_persistent \- Set the 'persistent' flag .SH SYNOPSIS diff --git a/doc/man/nvme_ctrl_set_unique_discovery_ctrl.2 b/doc/man/nvme_ctrl_set_unique_discovery_ctrl.2 index ae9963f..5c9c03f 100644 --- a/doc/man/nvme_ctrl_set_unique_discovery_ctrl.2 +++ b/doc/man/nvme_ctrl_set_unique_discovery_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrl_set_unique_discovery_ctrl" 9 "nvme_ctrl_set_unique_discovery_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrl_set_unique_discovery_ctrl" 9 "nvme_ctrl_set_unique_discovery_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrl_set_unique_discovery_ctrl \- Set the 'unique_discovery_ctrl' flag .SH SYNOPSIS diff --git a/doc/man/nvme_ctrls_filter.2 b/doc/man/nvme_ctrls_filter.2 index a3f99d2..cfdaa0c 100644 --- a/doc/man/nvme_ctrls_filter.2 +++ b/doc/man/nvme_ctrls_filter.2 @@ -1,4 +1,4 @@ -.TH "nvme_ctrls_filter" 9 "nvme_ctrls_filter" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ctrls_filter" 9 "nvme_ctrls_filter" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ctrls_filter \- Filter for controllers .SH SYNOPSIS diff --git a/doc/man/nvme_data_tfr.2 b/doc/man/nvme_data_tfr.2 index 53dced7..e03677d 100644 --- a/doc/man/nvme_data_tfr.2 +++ b/doc/man/nvme_data_tfr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_data_tfr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_data_tfr" "September 2023" "API Manual" LINUX .SH NAME enum nvme_data_tfr \- Data transfer direction of the command .SH SYNOPSIS diff --git a/doc/man/nvme_default_host.2 b/doc/man/nvme_default_host.2 index ae32203..bfaa64d 100644 --- a/doc/man/nvme_default_host.2 +++ b/doc/man/nvme_default_host.2 @@ -1,4 +1,4 @@ -.TH "nvme_default_host" 9 "nvme_default_host" "June 2023" "libnvme API manual" LINUX +.TH "nvme_default_host" 9 "nvme_default_host" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_default_host \- Initializes the default host .SH SYNOPSIS diff --git a/doc/man/nvme_describe_key_serial.2 b/doc/man/nvme_describe_key_serial.2 index 96dc547..58bb2e0 100644 --- a/doc/man/nvme_describe_key_serial.2 +++ b/doc/man/nvme_describe_key_serial.2 @@ -1,4 +1,4 @@ -.TH "nvme_describe_key_serial" 9 "nvme_describe_key_serial" "June 2023" "libnvme API manual" LINUX +.TH "nvme_describe_key_serial" 9 "nvme_describe_key_serial" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_describe_key_serial \- Return key description .SH SYNOPSIS diff --git a/doc/man/nvme_dev_self_test.2 b/doc/man/nvme_dev_self_test.2 index 7e26efc..005b90a 100644 --- a/doc/man/nvme_dev_self_test.2 +++ b/doc/man/nvme_dev_self_test.2 @@ -1,4 +1,4 @@ -.TH "nvme_dev_self_test" 9 "nvme_dev_self_test" "June 2023" "libnvme API manual" LINUX +.TH "nvme_dev_self_test" 9 "nvme_dev_self_test" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_dev_self_test \- Start or abort a self test .SH SYNOPSIS diff --git a/doc/man/nvme_directive_dtype.2 b/doc/man/nvme_directive_dtype.2 index 8a19713..493b887 100644 --- a/doc/man/nvme_directive_dtype.2 +++ b/doc/man/nvme_directive_dtype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_directive_dtype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_directive_dtype" "September 2023" "API Manual" LINUX .SH NAME enum nvme_directive_dtype \- Directive Types .SH SYNOPSIS diff --git a/doc/man/nvme_directive_receive_doper.2 b/doc/man/nvme_directive_receive_doper.2 index ed2acc7..66d9ce8 100644 --- a/doc/man/nvme_directive_receive_doper.2 +++ b/doc/man/nvme_directive_receive_doper.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_directive_receive_doper" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_directive_receive_doper" "September 2023" "API Manual" LINUX .SH NAME enum nvme_directive_receive_doper \- Directive Receive Directive Operation .SH SYNOPSIS diff --git a/doc/man/nvme_directive_recv.2 b/doc/man/nvme_directive_recv.2 index 2ca72f3..8a204a6 100644 --- a/doc/man/nvme_directive_recv.2 +++ b/doc/man/nvme_directive_recv.2 @@ -1,4 +1,4 @@ -.TH "nvme_directive_recv" 9 "nvme_directive_recv" "June 2023" "libnvme API manual" LINUX +.TH "nvme_directive_recv" 9 "nvme_directive_recv" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_directive_recv \- Receive directive specific data .SH SYNOPSIS diff --git a/doc/man/nvme_directive_recv_identify_parameters.2 b/doc/man/nvme_directive_recv_identify_parameters.2 index 5272e40..0a43eeb 100644 --- a/doc/man/nvme_directive_recv_identify_parameters.2 +++ b/doc/man/nvme_directive_recv_identify_parameters.2 @@ -1,4 +1,4 @@ -.TH "nvme_directive_recv_identify_parameters" 9 "nvme_directive_recv_identify_parameters" "June 2023" "libnvme API manual" LINUX +.TH "nvme_directive_recv_identify_parameters" 9 "nvme_directive_recv_identify_parameters" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_directive_recv_identify_parameters \- Directive receive identifier parameters .SH SYNOPSIS diff --git a/doc/man/nvme_directive_recv_stream_allocate.2 b/doc/man/nvme_directive_recv_stream_allocate.2 index a818f9d..fb55c59 100644 --- a/doc/man/nvme_directive_recv_stream_allocate.2 +++ b/doc/man/nvme_directive_recv_stream_allocate.2 @@ -1,4 +1,4 @@ -.TH "nvme_directive_recv_stream_allocate" 9 "nvme_directive_recv_stream_allocate" "June 2023" "libnvme API manual" LINUX +.TH "nvme_directive_recv_stream_allocate" 9 "nvme_directive_recv_stream_allocate" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_directive_recv_stream_allocate \- Directive receive stream allocate .SH SYNOPSIS diff --git a/doc/man/nvme_directive_recv_stream_parameters.2 b/doc/man/nvme_directive_recv_stream_parameters.2 index af7c367..e2f5647 100644 --- a/doc/man/nvme_directive_recv_stream_parameters.2 +++ b/doc/man/nvme_directive_recv_stream_parameters.2 @@ -1,4 +1,4 @@ -.TH "nvme_directive_recv_stream_parameters" 9 "nvme_directive_recv_stream_parameters" "June 2023" "libnvme API manual" LINUX +.TH "nvme_directive_recv_stream_parameters" 9 "nvme_directive_recv_stream_parameters" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_directive_recv_stream_parameters \- Directive receive stream parameters .SH SYNOPSIS diff --git a/doc/man/nvme_directive_recv_stream_status.2 b/doc/man/nvme_directive_recv_stream_status.2 index 13a69ca..4035e8b 100644 --- a/doc/man/nvme_directive_recv_stream_status.2 +++ b/doc/man/nvme_directive_recv_stream_status.2 @@ -1,4 +1,4 @@ -.TH "nvme_directive_recv_stream_status" 9 "nvme_directive_recv_stream_status" "June 2023" "libnvme API manual" LINUX +.TH "nvme_directive_recv_stream_status" 9 "nvme_directive_recv_stream_status" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_directive_recv_stream_status \- Directive receive stream status .SH SYNOPSIS diff --git a/doc/man/nvme_directive_send.2 b/doc/man/nvme_directive_send.2 index 7c50c76..977512a 100644 --- a/doc/man/nvme_directive_send.2 +++ b/doc/man/nvme_directive_send.2 @@ -1,4 +1,4 @@ -.TH "nvme_directive_send" 9 "nvme_directive_send" "June 2023" "libnvme API manual" LINUX +.TH "nvme_directive_send" 9 "nvme_directive_send" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_directive_send \- Send directive command .SH SYNOPSIS diff --git a/doc/man/nvme_directive_send_doper.2 b/doc/man/nvme_directive_send_doper.2 index da6d395..ec96197 100644 --- a/doc/man/nvme_directive_send_doper.2 +++ b/doc/man/nvme_directive_send_doper.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_directive_send_doper" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_directive_send_doper" "September 2023" "API Manual" LINUX .SH NAME enum nvme_directive_send_doper \- Directive Send Directive Operation .SH SYNOPSIS diff --git a/doc/man/nvme_directive_send_id_endir.2 b/doc/man/nvme_directive_send_id_endir.2 index 14affd7..b0ffc72 100644 --- a/doc/man/nvme_directive_send_id_endir.2 +++ b/doc/man/nvme_directive_send_id_endir.2 @@ -1,4 +1,4 @@ -.TH "nvme_directive_send_id_endir" 9 "nvme_directive_send_id_endir" "June 2023" "libnvme API manual" LINUX +.TH "nvme_directive_send_id_endir" 9 "nvme_directive_send_id_endir" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_directive_send_id_endir \- Directive Send Enable Directive .SH SYNOPSIS diff --git a/doc/man/nvme_directive_send_identify_endir.2 b/doc/man/nvme_directive_send_identify_endir.2 index 9e31733..ba04450 100644 --- a/doc/man/nvme_directive_send_identify_endir.2 +++ b/doc/man/nvme_directive_send_identify_endir.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_directive_send_identify_endir" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_directive_send_identify_endir" "September 2023" "API Manual" LINUX .SH NAME enum nvme_directive_send_identify_endir \- Enable Directive .SH SYNOPSIS diff --git a/doc/man/nvme_directive_send_stream_release_identifier.2 b/doc/man/nvme_directive_send_stream_release_identifier.2 index 9529463..088803b 100644 --- a/doc/man/nvme_directive_send_stream_release_identifier.2 +++ b/doc/man/nvme_directive_send_stream_release_identifier.2 @@ -1,4 +1,4 @@ -.TH "nvme_directive_send_stream_release_identifier" 9 "nvme_directive_send_stream_release_identifier" "June 2023" "libnvme API manual" LINUX +.TH "nvme_directive_send_stream_release_identifier" 9 "nvme_directive_send_stream_release_identifier" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_directive_send_stream_release_identifier \- Directive Send Stream release .SH SYNOPSIS diff --git a/doc/man/nvme_directive_send_stream_release_resource.2 b/doc/man/nvme_directive_send_stream_release_resource.2 index 0a75237..b350616 100644 --- a/doc/man/nvme_directive_send_stream_release_resource.2 +++ b/doc/man/nvme_directive_send_stream_release_resource.2 @@ -1,4 +1,4 @@ -.TH "nvme_directive_send_stream_release_resource" 9 "nvme_directive_send_stream_release_resource" "June 2023" "libnvme API manual" LINUX +.TH "nvme_directive_send_stream_release_resource" 9 "nvme_directive_send_stream_release_resource" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_directive_send_stream_release_resource \- Directive Send Stream release resources .SH SYNOPSIS diff --git a/doc/man/nvme_directive_types.2 b/doc/man/nvme_directive_types.2 index fa74691..dfe2eec 100644 --- a/doc/man/nvme_directive_types.2 +++ b/doc/man/nvme_directive_types.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_directive_types" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_directive_types" "September 2023" "API Manual" LINUX .SH NAME enum nvme_directive_types \- Directives Supported or Enabled .SH SYNOPSIS diff --git a/doc/man/nvme_disconnect_ctrl.2 b/doc/man/nvme_disconnect_ctrl.2 index dad0253..14379a9 100644 --- a/doc/man/nvme_disconnect_ctrl.2 +++ b/doc/man/nvme_disconnect_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_disconnect_ctrl" 9 "nvme_disconnect_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_disconnect_ctrl" 9 "nvme_disconnect_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_disconnect_ctrl \- Disconnect a controller .SH SYNOPSIS diff --git a/doc/man/nvme_dsm.2 b/doc/man/nvme_dsm.2 index 1b7cac0..2ce2477 100644 --- a/doc/man/nvme_dsm.2 +++ b/doc/man/nvme_dsm.2 @@ -1,4 +1,4 @@ -.TH "nvme_dsm" 9 "nvme_dsm" "June 2023" "libnvme API manual" LINUX +.TH "nvme_dsm" 9 "nvme_dsm" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_dsm \- Send an nvme data set management command .SH SYNOPSIS diff --git a/doc/man/nvme_dsm_attributes.2 b/doc/man/nvme_dsm_attributes.2 index 7bf524c..b08b4e8 100644 --- a/doc/man/nvme_dsm_attributes.2 +++ b/doc/man/nvme_dsm_attributes.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_dsm_attributes" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_dsm_attributes" "September 2023" "API Manual" LINUX .SH NAME enum nvme_dsm_attributes \- Dataset Management attributes .SH SYNOPSIS diff --git a/doc/man/nvme_dsm_range.2 b/doc/man/nvme_dsm_range.2 index d251d23..fbaa276 100644 --- a/doc/man/nvme_dsm_range.2 +++ b/doc/man/nvme_dsm_range.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_dsm_range" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_dsm_range" "September 2023" "API Manual" LINUX .SH NAME struct nvme_dsm_range \- Dataset Management - Range Definition .SH SYNOPSIS diff --git a/doc/man/nvme_dst_stc.2 b/doc/man/nvme_dst_stc.2 index e6eeb5e..c34a890 100644 --- a/doc/man/nvme_dst_stc.2 +++ b/doc/man/nvme_dst_stc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_dst_stc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_dst_stc" "September 2023" "API Manual" LINUX .SH NAME enum nvme_dst_stc \- Action taken by the Device Self-test command .SH SYNOPSIS diff --git a/doc/man/nvme_dump_config.2 b/doc/man/nvme_dump_config.2 index 583c6c2..49e0678 100644 --- a/doc/man/nvme_dump_config.2 +++ b/doc/man/nvme_dump_config.2 @@ -1,4 +1,4 @@ -.TH "nvme_dump_config" 9 "nvme_dump_config" "June 2023" "libnvme API manual" LINUX +.TH "nvme_dump_config" 9 "nvme_dump_config" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_dump_config \- Print the JSON configuration .SH SYNOPSIS diff --git a/doc/man/nvme_dump_tree.2 b/doc/man/nvme_dump_tree.2 index e096496..5817d90 100644 --- a/doc/man/nvme_dump_tree.2 +++ b/doc/man/nvme_dump_tree.2 @@ -1,4 +1,4 @@ -.TH "nvme_dump_tree" 9 "nvme_dump_tree" "June 2023" "libnvme API manual" LINUX +.TH "nvme_dump_tree" 9 "nvme_dump_tree" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_dump_tree \- Dump internal object tree .SH SYNOPSIS diff --git a/doc/man/nvme_eg_critical_warning_flags.2 b/doc/man/nvme_eg_critical_warning_flags.2 index 3c95a7d..4e7ed01 100644 --- a/doc/man/nvme_eg_critical_warning_flags.2 +++ b/doc/man/nvme_eg_critical_warning_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_eg_critical_warning_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_eg_critical_warning_flags" "September 2023" "API Manual" LINUX .SH NAME enum nvme_eg_critical_warning_flags \- Endurance Group Information Log - Critical Warning .SH SYNOPSIS diff --git a/doc/man/nvme_eg_event_aggregate_log.2 b/doc/man/nvme_eg_event_aggregate_log.2 index 443257d..96f9b7f 100644 --- a/doc/man/nvme_eg_event_aggregate_log.2 +++ b/doc/man/nvme_eg_event_aggregate_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_eg_event_aggregate_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_eg_event_aggregate_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_eg_event_aggregate_log \- Endurance Group Event Aggregate .SH SYNOPSIS diff --git a/doc/man/nvme_end_grp_chan_desc.2 b/doc/man/nvme_end_grp_chan_desc.2 index 169cb24..d7fa68c 100644 --- a/doc/man/nvme_end_grp_chan_desc.2 +++ b/doc/man/nvme_end_grp_chan_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_end_grp_chan_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_end_grp_chan_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_end_grp_chan_desc \- Endurance Group Channel Configuration Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_end_grp_config_desc.2 b/doc/man/nvme_end_grp_config_desc.2 index 25bf2cd..df2a6e0 100644 --- a/doc/man/nvme_end_grp_config_desc.2 +++ b/doc/man/nvme_end_grp_config_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_end_grp_config_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_end_grp_config_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_end_grp_config_desc \- Endurance Group Configuration Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_endurance_group_log.2 b/doc/man/nvme_endurance_group_log.2 index ccf7ecc..c290a93 100644 --- a/doc/man/nvme_endurance_group_log.2 +++ b/doc/man/nvme_endurance_group_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_endurance_group_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_endurance_group_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_endurance_group_log \- Endurance Group Information Log .SH SYNOPSIS @@ -6,7 +6,9 @@ struct nvme_endurance_group_log { .br .BI " __u8 critical_warning;" .br -.BI " __u8 rsvd1[2];" +.BI " __u8 endurance_group_features;" +.br +.BI " __u8 rsvd2;" .br .BI " __u8 avl_spare;" .br @@ -14,7 +16,9 @@ struct nvme_endurance_group_log { .br .BI " __u8 percent_used;" .br -.BI " __u8 rsvd6[26];" +.BI " __le16 domain_identifier;" +.br +.BI " __u8 rsvd8[24];" .br .BI " __u8 endurance_estimate[16];" .br @@ -32,7 +36,11 @@ struct nvme_endurance_group_log { .br .BI " __u8 num_err_info_log_entries[16];" .br -.BI " __u8 rsvd160[352];" +.BI " __u8 total_end_grp_cap[16];" +.br +.BI " __u8 unalloc_end_grp_cap[16];" +.br +.BI " __u8 rsvd192[320];" .br .BI " }; @@ -41,7 +49,9 @@ struct nvme_endurance_group_log { .SH Members .IP "critical_warning" 12 Critical Warning -.IP "rsvd1" 12 +.IP "endurance_group_features" 12 +Endurance Group Features +.IP "rsvd2" 12 Reserved .IP "avl_spare" 12 Available Spare @@ -49,7 +59,9 @@ Available Spare Available Spare Threshold .IP "percent_used" 12 Percentage Used -.IP "rsvd6" 12 +.IP "domain_identifier" 12 +Domain Identifier +.IP "rsvd8" 12 Reserved .IP "endurance_estimate" 12 Endurance Estimate @@ -67,5 +79,9 @@ Host Write Commands Media and Data Integrity Errors .IP "num_err_info_log_entries" 12 Number of Error Information Log Entries -.IP "rsvd160" 12 +.IP "total_end_grp_cap" 12 +Total Endurance Group Capacity +.IP "unalloc_end_grp_cap" 12 +Unallocated Endurance Group Capacity +.IP "rsvd192" 12 Reserved diff --git a/doc/man/nvme_eom_lane_desc.2 b/doc/man/nvme_eom_lane_desc.2 new file mode 100644 index 0000000..419d00d --- /dev/null +++ b/doc/man/nvme_eom_lane_desc.2 @@ -0,0 +1,63 @@ +.TH "libnvme" 9 "struct nvme_eom_lane_desc" "September 2023" "API Manual" LINUX +.SH NAME +struct nvme_eom_lane_desc \- EOM Lane Descriptor +.SH SYNOPSIS +struct nvme_eom_lane_desc { +.br +.BI " __u8 rsvd0;" +.br +.BI " __u8 mstatus;" +.br +.BI " __u8 lane;" +.br +.BI " __u8 eye;" +.br +.BI " __le16 top;" +.br +.BI " __le16 bottom;" +.br +.BI " __le16 left;" +.br +.BI " __le16 right;" +.br +.BI " __le16 nrows;" +.br +.BI " __le16 ncols;" +.br +.BI " __le16 edlen;" +.br +.BI " __u8 rsvd18[14];" +.br +.BI " __u8 eye_desc[];" +.br +.BI " +}; +.br + +.SH Members +.IP "rsvd0" 12 +Reserved +.IP "mstatus" 12 +Measurement Status +.IP "lane" 12 +Lane number +.IP "eye" 12 +Eye number +.IP "top" 12 +Absolute number of rows from center to top edge of eye +.IP "bottom" 12 +Absolute number of rows from center to bottom edge of eye +.IP "left" 12 +Absolute number of rows from center to left edge of eye +.IP "right" 12 +Absolute number of rows from center to right edge of eye +.IP "nrows" 12 +Number of Rows +.IP "ncols" 12 +Number of Columns +.IP "edlen" 12 +Eye Data Length +.IP "rsvd18" 12 +Reserved +.IP "eye_desc" 12 +Printable Eye, Eye Data, and any Padding diff --git a/doc/man/nvme_eom_optional_data.2 b/doc/man/nvme_eom_optional_data.2 new file mode 100644 index 0000000..3ca69ab --- /dev/null +++ b/doc/man/nvme_eom_optional_data.2 @@ -0,0 +1,18 @@ +.TH "libnvme" 9 "enum nvme_eom_optional_data" "September 2023" "API Manual" LINUX +.SH NAME +enum nvme_eom_optional_data \- EOM Optional Data Present Fields +.SH SYNOPSIS +enum nvme_eom_optional_data { +.br +.BI " NVME_EOM_EYE_DATA_PRESENT" +, +.br +.br +.BI " NVME_EOM_PRINTABLE_EYE_PRESENT" + +}; +.SH Constants +.IP "NVME_EOM_EYE_DATA_PRESENT" 12 +Eye Data Present +.IP "NVME_EOM_PRINTABLE_EYE_PRESENT" 12 +Printable Eye Present diff --git a/doc/man/nvme_errno_to_string.2 b/doc/man/nvme_errno_to_string.2 index f0b2839..869f36f 100644 --- a/doc/man/nvme_errno_to_string.2 +++ b/doc/man/nvme_errno_to_string.2 @@ -1,4 +1,4 @@ -.TH "nvme_errno_to_string" 9 "nvme_errno_to_string" "June 2023" "libnvme API manual" LINUX +.TH "nvme_errno_to_string" 9 "nvme_errno_to_string" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_errno_to_string \- Returns string describing nvme connect failures .SH SYNOPSIS diff --git a/doc/man/nvme_error_log_page.2 b/doc/man/nvme_error_log_page.2 index d11eff3..ccef177 100644 --- a/doc/man/nvme_error_log_page.2 +++ b/doc/man/nvme_error_log_page.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_error_log_page" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_error_log_page" "September 2023" "API Manual" LINUX .SH NAME struct nvme_error_log_page \- Error Information Log Entry (Log Identifier 01h) .SH SYNOPSIS diff --git a/doc/man/nvme_fabrics_config.2 b/doc/man/nvme_fabrics_config.2 index 6a80747..02d0f3b 100644 --- a/doc/man/nvme_fabrics_config.2 +++ b/doc/man/nvme_fabrics_config.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fabrics_config" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fabrics_config" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fabrics_config \- Defines all linux nvme fabrics initiator options .SH SYNOPSIS diff --git a/doc/man/nvme_fctype.2 b/doc/man/nvme_fctype.2 index 3e8fc4f..8d8f008 100644 --- a/doc/man/nvme_fctype.2 +++ b/doc/man/nvme_fctype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_fctype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_fctype" "September 2023" "API Manual" LINUX .SH NAME enum nvme_fctype \- Fabrics Command Types .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_config_desc.2 b/doc/man/nvme_fdp_config_desc.2 index a00ac72..e9f9b7e 100644 --- a/doc/man/nvme_fdp_config_desc.2 +++ b/doc/man/nvme_fdp_config_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_config_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_config_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_config_desc \- FDP Configuration Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_config_fdpa.2 b/doc/man/nvme_fdp_config_fdpa.2 index 4a2796a..2f343df 100644 --- a/doc/man/nvme_fdp_config_fdpa.2 +++ b/doc/man/nvme_fdp_config_fdpa.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_fdp_config_fdpa" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_fdp_config_fdpa" "September 2023" "API Manual" LINUX .SH NAME enum nvme_fdp_config_fdpa \- FDP Attributes .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_config_log.2 b/doc/man/nvme_fdp_config_log.2 index d839eb1..547f8f4 100644 --- a/doc/man/nvme_fdp_config_log.2 +++ b/doc/man/nvme_fdp_config_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_config_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_config_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_config_log \- FDP Configurations Log Page .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_event.2 b/doc/man/nvme_fdp_event.2 index f310d53..b7ed21e 100644 --- a/doc/man/nvme_fdp_event.2 +++ b/doc/man/nvme_fdp_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_event \- FDP Event .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_event_flags.2 b/doc/man/nvme_fdp_event_flags.2 index f7e7387..74536ae 100644 --- a/doc/man/nvme_fdp_event_flags.2 +++ b/doc/man/nvme_fdp_event_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_fdp_event_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_fdp_event_flags" "September 2023" "API Manual" LINUX .SH NAME enum nvme_fdp_event_flags \- FDP Event Flags .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_event_realloc.2 b/doc/man/nvme_fdp_event_realloc.2 index e32e2aa..03f47e5 100644 --- a/doc/man/nvme_fdp_event_realloc.2 +++ b/doc/man/nvme_fdp_event_realloc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_event_realloc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_event_realloc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_event_realloc \- Media Reallocated Event Type Specific Information .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_event_realloc_flags.2 b/doc/man/nvme_fdp_event_realloc_flags.2 index 3072bc3..769d5ab 100644 --- a/doc/man/nvme_fdp_event_realloc_flags.2 +++ b/doc/man/nvme_fdp_event_realloc_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_fdp_event_realloc_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_fdp_event_realloc_flags" "September 2023" "API Manual" LINUX .SH NAME enum nvme_fdp_event_realloc_flags \- Media Reallocated Event Type Specific Flags .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_event_type.2 b/doc/man/nvme_fdp_event_type.2 index 8ddbcbd..2c7d9cd 100644 --- a/doc/man/nvme_fdp_event_type.2 +++ b/doc/man/nvme_fdp_event_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_fdp_event_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_fdp_event_type" "September 2023" "API Manual" LINUX .SH NAME enum nvme_fdp_event_type \- FDP Event Types .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_events_log.2 b/doc/man/nvme_fdp_events_log.2 index cbc6021..484c4b4 100644 --- a/doc/man/nvme_fdp_events_log.2 +++ b/doc/man/nvme_fdp_events_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_events_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_events_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_events_log \- FDP Events Log Page .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_reclaim_unit_handle_status.2 b/doc/man/nvme_fdp_reclaim_unit_handle_status.2 index 5b25da2..f84ec7e 100644 --- a/doc/man/nvme_fdp_reclaim_unit_handle_status.2 +++ b/doc/man/nvme_fdp_reclaim_unit_handle_status.2 @@ -1,4 +1,4 @@ -.TH "nvme_fdp_reclaim_unit_handle_status" 9 "nvme_fdp_reclaim_unit_handle_status" "June 2023" "libnvme API manual" LINUX +.TH "nvme_fdp_reclaim_unit_handle_status" 9 "nvme_fdp_reclaim_unit_handle_status" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_fdp_reclaim_unit_handle_status \- Get reclaim unit handle status .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_reclaim_unit_handle_update.2 b/doc/man/nvme_fdp_reclaim_unit_handle_update.2 index 8459a3c..ceb29d9 100644 --- a/doc/man/nvme_fdp_reclaim_unit_handle_update.2 +++ b/doc/man/nvme_fdp_reclaim_unit_handle_update.2 @@ -1,4 +1,4 @@ -.TH "nvme_fdp_reclaim_unit_handle_update" 9 "nvme_fdp_reclaim_unit_handle_update" "June 2023" "libnvme API manual" LINUX +.TH "nvme_fdp_reclaim_unit_handle_update" 9 "nvme_fdp_reclaim_unit_handle_update" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_fdp_reclaim_unit_handle_update \- Update a list of reclaim unit handles .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_ruh_desc.2 b/doc/man/nvme_fdp_ruh_desc.2 index 9072eea..bde67c9 100644 --- a/doc/man/nvme_fdp_ruh_desc.2 +++ b/doc/man/nvme_fdp_ruh_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_ruh_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_ruh_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_ruh_desc \- Reclaim Unit Handle Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_ruh_status.2 b/doc/man/nvme_fdp_ruh_status.2 index 7378076..6fe1c02 100644 --- a/doc/man/nvme_fdp_ruh_status.2 +++ b/doc/man/nvme_fdp_ruh_status.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_ruh_status" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_ruh_status" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_ruh_status \- Reclaim Unit Handle Status .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_ruh_status_desc.2 b/doc/man/nvme_fdp_ruh_status_desc.2 index 17adbbd..e038cea 100644 --- a/doc/man/nvme_fdp_ruh_status_desc.2 +++ b/doc/man/nvme_fdp_ruh_status_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_ruh_status_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_ruh_status_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_ruh_status_desc \- Reclaim Unit Handle Status Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_ruh_type.2 b/doc/man/nvme_fdp_ruh_type.2 index 7fb5c73..ecc8273 100644 --- a/doc/man/nvme_fdp_ruh_type.2 +++ b/doc/man/nvme_fdp_ruh_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_fdp_ruh_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_fdp_ruh_type" "September 2023" "API Manual" LINUX .SH NAME enum nvme_fdp_ruh_type \- Reclaim Unit Handle Type .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_ruha.2 b/doc/man/nvme_fdp_ruha.2 index 509f0b7..beb3dae 100644 --- a/doc/man/nvme_fdp_ruha.2 +++ b/doc/man/nvme_fdp_ruha.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_fdp_ruha" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_fdp_ruha" "September 2023" "API Manual" LINUX .SH NAME enum nvme_fdp_ruha \- Reclaim Unit Handle Attributes .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_ruhu_desc.2 b/doc/man/nvme_fdp_ruhu_desc.2 index 53ed484..6af01f5 100644 --- a/doc/man/nvme_fdp_ruhu_desc.2 +++ b/doc/man/nvme_fdp_ruhu_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_ruhu_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_ruhu_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_ruhu_desc \- Reclaim Unit Handle Usage Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_ruhu_log.2 b/doc/man/nvme_fdp_ruhu_log.2 index 25c1813..1d8ca82 100644 --- a/doc/man/nvme_fdp_ruhu_log.2 +++ b/doc/man/nvme_fdp_ruhu_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_ruhu_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_ruhu_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_ruhu_log \- Reclaim Unit Handle Usage Log Page .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_stats_log.2 b/doc/man/nvme_fdp_stats_log.2 index 11f3dd6..e15e5bf 100644 --- a/doc/man/nvme_fdp_stats_log.2 +++ b/doc/man/nvme_fdp_stats_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_stats_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_stats_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_stats_log \- FDP Statistics Log Page .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_supported_event_attributes.2 b/doc/man/nvme_fdp_supported_event_attributes.2 index 83e350f..dddc607 100644 --- a/doc/man/nvme_fdp_supported_event_attributes.2 +++ b/doc/man/nvme_fdp_supported_event_attributes.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_fdp_supported_event_attributes" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_fdp_supported_event_attributes" "September 2023" "API Manual" LINUX .SH NAME enum nvme_fdp_supported_event_attributes \- Supported FDP Event Attributes .SH SYNOPSIS diff --git a/doc/man/nvme_fdp_supported_event_desc.2 b/doc/man/nvme_fdp_supported_event_desc.2 index d18673f..6ea01a9 100644 --- a/doc/man/nvme_fdp_supported_event_desc.2 +++ b/doc/man/nvme_fdp_supported_event_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fdp_supported_event_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fdp_supported_event_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fdp_supported_event_desc \- Supported FDP Event Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_feat.2 b/doc/man/nvme_feat.2 index b758af5..a3b0248 100644 --- a/doc/man/nvme_feat.2 +++ b/doc/man/nvme_feat.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_feat" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_feat" "September 2023" "API Manual" LINUX .SH NAME enum nvme_feat \- Features Access Shifts/Masks values .SH SYNOPSIS diff --git a/doc/man/nvme_feat_auto_pst.2 b/doc/man/nvme_feat_auto_pst.2 index 90c8a9b..524d2f3 100644 --- a/doc/man/nvme_feat_auto_pst.2 +++ b/doc/man/nvme_feat_auto_pst.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_feat_auto_pst" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_feat_auto_pst" "September 2023" "API Manual" LINUX .SH NAME struct nvme_feat_auto_pst \- Autonomous Power State Transition .SH SYNOPSIS diff --git a/doc/man/nvme_feat_fdp_events_cdw11.2 b/doc/man/nvme_feat_fdp_events_cdw11.2 index b1ef1ab..7447a33 100644 --- a/doc/man/nvme_feat_fdp_events_cdw11.2 +++ b/doc/man/nvme_feat_fdp_events_cdw11.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_feat_fdp_events_cdw11" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_feat_fdp_events_cdw11" "September 2023" "API Manual" LINUX .SH NAME struct nvme_feat_fdp_events_cdw11 \- FDP Events Feature Command Dword 11 .SH SYNOPSIS diff --git a/doc/man/nvme_feat_host_behavior.2 b/doc/man/nvme_feat_host_behavior.2 index 4c4afd7..26840e2 100644 --- a/doc/man/nvme_feat_host_behavior.2 +++ b/doc/man/nvme_feat_host_behavior.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_feat_host_behavior" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_feat_host_behavior" "September 2023" "API Manual" LINUX .SH NAME struct nvme_feat_host_behavior \- Host Behavior Support - Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_feat_nswpcfg_state.2 b/doc/man/nvme_feat_nswpcfg_state.2 index 102043b..ca81bf8 100644 --- a/doc/man/nvme_feat_nswpcfg_state.2 +++ b/doc/man/nvme_feat_nswpcfg_state.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_feat_nswpcfg_state" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_feat_nswpcfg_state" "September 2023" "API Manual" LINUX .SH NAME enum nvme_feat_nswpcfg_state \- Write Protection - Write Protection State .SH SYNOPSIS diff --git a/doc/man/nvme_feat_plm_window_select.2 b/doc/man/nvme_feat_plm_window_select.2 index ff3d979..5c349ee 100644 --- a/doc/man/nvme_feat_plm_window_select.2 +++ b/doc/man/nvme_feat_plm_window_select.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_feat_plm_window_select" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_feat_plm_window_select" "September 2023" "API Manual" LINUX .SH NAME enum nvme_feat_plm_window_select \- Predictable Latency Per NVM Set Log .SH SYNOPSIS diff --git a/doc/man/nvme_feat_resv_notify_flags.2 b/doc/man/nvme_feat_resv_notify_flags.2 index 341331e..13984ff 100644 --- a/doc/man/nvme_feat_resv_notify_flags.2 +++ b/doc/man/nvme_feat_resv_notify_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_feat_resv_notify_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_feat_resv_notify_flags" "September 2023" "API Manual" LINUX .SH NAME enum nvme_feat_resv_notify_flags \- Reservation Notification Configuration .SH SYNOPSIS diff --git a/doc/man/nvme_feat_tmpthresh_thsel.2 b/doc/man/nvme_feat_tmpthresh_thsel.2 index de1bc85..7a45d32 100644 --- a/doc/man/nvme_feat_tmpthresh_thsel.2 +++ b/doc/man/nvme_feat_tmpthresh_thsel.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_feat_tmpthresh_thsel" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_feat_tmpthresh_thsel" "September 2023" "API Manual" LINUX .SH NAME enum nvme_feat_tmpthresh_thsel \- Temperature Threshold - Threshold Type Select .SH SYNOPSIS diff --git a/doc/man/nvme_features_async_event_config_flags.2 b/doc/man/nvme_features_async_event_config_flags.2 index 0e3be08..6ec7a45 100644 --- a/doc/man/nvme_features_async_event_config_flags.2 +++ b/doc/man/nvme_features_async_event_config_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_features_async_event_config_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_features_async_event_config_flags" "September 2023" "API Manual" LINUX .SH NAME enum nvme_features_async_event_config_flags \- Asynchronous Event Configuration configuration flags .SH SYNOPSIS diff --git a/doc/man/nvme_features_id.2 b/doc/man/nvme_features_id.2 index dbbb7ef..2390b13 100644 --- a/doc/man/nvme_features_id.2 +++ b/doc/man/nvme_features_id.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_features_id" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_features_id" "September 2023" "API Manual" LINUX .SH NAME enum nvme_features_id \- Features - Feature Identifiers .SH SYNOPSIS diff --git a/doc/man/nvme_fid_supported_effects.2 b/doc/man/nvme_fid_supported_effects.2 index 43b31f8..7c4138b 100644 --- a/doc/man/nvme_fid_supported_effects.2 +++ b/doc/man/nvme_fid_supported_effects.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_fid_supported_effects" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_fid_supported_effects" "September 2023" "API Manual" LINUX .SH NAME enum nvme_fid_supported_effects \- FID Supported and Effects Data Structure definitions .SH SYNOPSIS diff --git a/doc/man/nvme_fid_supported_effects_log.2 b/doc/man/nvme_fid_supported_effects_log.2 index b1a6fba..ed82a01 100644 --- a/doc/man/nvme_fid_supported_effects_log.2 +++ b/doc/man/nvme_fid_supported_effects_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fid_supported_effects_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fid_supported_effects_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fid_supported_effects_log \- Feature Identifiers Supported and Effects .SH SYNOPSIS diff --git a/doc/man/nvme_firmware_slot.2 b/doc/man/nvme_firmware_slot.2 index 259fcf9..6d8cf4c 100644 --- a/doc/man/nvme_firmware_slot.2 +++ b/doc/man/nvme_firmware_slot.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_firmware_slot" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_firmware_slot" "September 2023" "API Manual" LINUX .SH NAME struct nvme_firmware_slot \- Firmware Slot Information Log .SH SYNOPSIS diff --git a/doc/man/nvme_first_host.2 b/doc/man/nvme_first_host.2 index 41e8582..2aeac78 100644 --- a/doc/man/nvme_first_host.2 +++ b/doc/man/nvme_first_host.2 @@ -1,4 +1,4 @@ -.TH "nvme_first_host" 9 "nvme_first_host" "June 2023" "libnvme API manual" LINUX +.TH "nvme_first_host" 9 "nvme_first_host" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_first_host \- Start host iterator .SH SYNOPSIS diff --git a/doc/man/nvme_first_subsystem.2 b/doc/man/nvme_first_subsystem.2 index 292d6d0..5d94618 100644 --- a/doc/man/nvme_first_subsystem.2 +++ b/doc/man/nvme_first_subsystem.2 @@ -1,4 +1,4 @@ -.TH "nvme_first_subsystem" 9 "nvme_first_subsystem" "June 2023" "libnvme API manual" LINUX +.TH "nvme_first_subsystem" 9 "nvme_first_subsystem" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_first_subsystem \- Start subsystem iterator .SH SYNOPSIS diff --git a/doc/man/nvme_flush.2 b/doc/man/nvme_flush.2 index e10af5b..b371d01 100644 --- a/doc/man/nvme_flush.2 +++ b/doc/man/nvme_flush.2 @@ -1,4 +1,4 @@ -.TH "nvme_flush" 9 "nvme_flush" "June 2023" "libnvme API manual" LINUX +.TH "nvme_flush" 9 "nvme_flush" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_flush \- Send an nvme flush command .SH SYNOPSIS diff --git a/doc/man/nvme_for_each_host.2 b/doc/man/nvme_for_each_host.2 index bec20b3..5b43798 100644 --- a/doc/man/nvme_for_each_host.2 +++ b/doc/man/nvme_for_each_host.2 @@ -1,4 +1,4 @@ -.TH "nvme_for_each_host" 9 "nvme_for_each_host" "June 2023" "libnvme API manual" LINUX +.TH "nvme_for_each_host" 9 "nvme_for_each_host" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_for_each_host \- Traverse host list .SH SYNOPSIS diff --git a/doc/man/nvme_for_each_host_safe.2 b/doc/man/nvme_for_each_host_safe.2 index 2b5764c..551f0ac 100644 --- a/doc/man/nvme_for_each_host_safe.2 +++ b/doc/man/nvme_for_each_host_safe.2 @@ -1,4 +1,4 @@ -.TH "nvme_for_each_host_safe" 9 "nvme_for_each_host_safe" "June 2023" "libnvme API manual" LINUX +.TH "nvme_for_each_host_safe" 9 "nvme_for_each_host_safe" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_for_each_host_safe \- Traverse host list .SH SYNOPSIS diff --git a/doc/man/nvme_for_each_subsystem.2 b/doc/man/nvme_for_each_subsystem.2 index c85cbbe..9e2c25f 100644 --- a/doc/man/nvme_for_each_subsystem.2 +++ b/doc/man/nvme_for_each_subsystem.2 @@ -1,4 +1,4 @@ -.TH "nvme_for_each_subsystem" 9 "nvme_for_each_subsystem" "June 2023" "libnvme API manual" LINUX +.TH "nvme_for_each_subsystem" 9 "nvme_for_each_subsystem" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_for_each_subsystem \- Traverse subsystems .SH SYNOPSIS diff --git a/doc/man/nvme_for_each_subsystem_safe.2 b/doc/man/nvme_for_each_subsystem_safe.2 index e05ea41..6d37051 100644 --- a/doc/man/nvme_for_each_subsystem_safe.2 +++ b/doc/man/nvme_for_each_subsystem_safe.2 @@ -1,4 +1,4 @@ -.TH "nvme_for_each_subsystem_safe" 9 "nvme_for_each_subsystem_safe" "June 2023" "libnvme API manual" LINUX +.TH "nvme_for_each_subsystem_safe" 9 "nvme_for_each_subsystem_safe" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_for_each_subsystem_safe \- Traverse subsystems .SH SYNOPSIS diff --git a/doc/man/nvme_format_nvm.2 b/doc/man/nvme_format_nvm.2 index 144ba44..7a59644 100644 --- a/doc/man/nvme_format_nvm.2 +++ b/doc/man/nvme_format_nvm.2 @@ -1,4 +1,4 @@ -.TH "nvme_format_nvm" 9 "nvme_format_nvm" "June 2023" "libnvme API manual" LINUX +.TH "nvme_format_nvm" 9 "nvme_format_nvm" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_format_nvm \- Format nvme namespace(s) .SH SYNOPSIS diff --git a/doc/man/nvme_format_nvm_compln_event.2 b/doc/man/nvme_format_nvm_compln_event.2 index 82fd397..ae4b8f8 100644 --- a/doc/man/nvme_format_nvm_compln_event.2 +++ b/doc/man/nvme_format_nvm_compln_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_format_nvm_compln_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_format_nvm_compln_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_format_nvm_compln_event \- Format NVM Completion Event Data .SH SYNOPSIS diff --git a/doc/man/nvme_format_nvm_start_event.2 b/doc/man/nvme_format_nvm_start_event.2 index 2d3607b..d200210 100644 --- a/doc/man/nvme_format_nvm_start_event.2 +++ b/doc/man/nvme_format_nvm_start_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_format_nvm_start_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_format_nvm_start_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_format_nvm_start_event \- Format NVM Start Event Data .SH SYNOPSIS diff --git a/doc/man/nvme_free_ctrl.2 b/doc/man/nvme_free_ctrl.2 index 2f4a593..5b5d5e9 100644 --- a/doc/man/nvme_free_ctrl.2 +++ b/doc/man/nvme_free_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_free_ctrl" 9 "nvme_free_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_free_ctrl" 9 "nvme_free_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_free_ctrl \- Free controller .SH SYNOPSIS diff --git a/doc/man/nvme_free_host.2 b/doc/man/nvme_free_host.2 index 75ce5c4..3041b33 100644 --- a/doc/man/nvme_free_host.2 +++ b/doc/man/nvme_free_host.2 @@ -1,4 +1,4 @@ -.TH "nvme_free_host" 9 "nvme_free_host" "June 2023" "libnvme API manual" LINUX +.TH "nvme_free_host" 9 "nvme_free_host" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_free_host \- Free nvme_host_t object .SH SYNOPSIS diff --git a/doc/man/nvme_free_ns.2 b/doc/man/nvme_free_ns.2 index 9844898..e9b6595 100644 --- a/doc/man/nvme_free_ns.2 +++ b/doc/man/nvme_free_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_free_ns" 9 "nvme_free_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_free_ns" 9 "nvme_free_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_free_ns \- Free a namespace object .SH SYNOPSIS diff --git a/doc/man/nvme_free_subsystem.2 b/doc/man/nvme_free_subsystem.2 index 2f8cf6c..03c97ef 100644 --- a/doc/man/nvme_free_subsystem.2 +++ b/doc/man/nvme_free_subsystem.2 @@ -1,4 +1,4 @@ -.TH "nvme_free_subsystem" 9 "nvme_free_subsystem" "June 2023" "libnvme API manual" LINUX +.TH "nvme_free_subsystem" 9 "nvme_free_subsystem" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_free_subsystem \- Free a subsystem .SH SYNOPSIS diff --git a/doc/man/nvme_free_tree.2 b/doc/man/nvme_free_tree.2 index a493818..c89d274 100644 --- a/doc/man/nvme_free_tree.2 +++ b/doc/man/nvme_free_tree.2 @@ -1,4 +1,4 @@ -.TH "nvme_free_tree" 9 "nvme_free_tree" "June 2023" "libnvme API manual" LINUX +.TH "nvme_free_tree" 9 "nvme_free_tree" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_free_tree \- Free root object .SH SYNOPSIS diff --git a/doc/man/nvme_fw_commit.2 b/doc/man/nvme_fw_commit.2 index 66c1ab3..8f0df59 100644 --- a/doc/man/nvme_fw_commit.2 +++ b/doc/man/nvme_fw_commit.2 @@ -1,4 +1,4 @@ -.TH "nvme_fw_commit" 9 "nvme_fw_commit" "June 2023" "libnvme API manual" LINUX +.TH "nvme_fw_commit" 9 "nvme_fw_commit" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_fw_commit \- Commit firmware using the specified action .SH SYNOPSIS diff --git a/doc/man/nvme_fw_commit_ca.2 b/doc/man/nvme_fw_commit_ca.2 index b3c4acb..42a13cf 100644 --- a/doc/man/nvme_fw_commit_ca.2 +++ b/doc/man/nvme_fw_commit_ca.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_fw_commit_ca" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_fw_commit_ca" "September 2023" "API Manual" LINUX .SH NAME enum nvme_fw_commit_ca \- Firmware Commit - Commit Action .SH SYNOPSIS diff --git a/doc/man/nvme_fw_commit_event.2 b/doc/man/nvme_fw_commit_event.2 index f1fa3b0..2624cf2 100644 --- a/doc/man/nvme_fw_commit_event.2 +++ b/doc/man/nvme_fw_commit_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_fw_commit_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_fw_commit_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_fw_commit_event \- Firmware Commit Event Data .SH SYNOPSIS diff --git a/doc/man/nvme_fw_download.2 b/doc/man/nvme_fw_download.2 index 319370e..267fdb2 100644 --- a/doc/man/nvme_fw_download.2 +++ b/doc/man/nvme_fw_download.2 @@ -1,4 +1,4 @@ -.TH "nvme_fw_download" 9 "nvme_fw_download" "June 2023" "libnvme API manual" LINUX +.TH "nvme_fw_download" 9 "nvme_fw_download" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_fw_download \- Download part or all of a firmware image to the controller .SH SYNOPSIS diff --git a/doc/man/nvme_fw_download_seq.2 b/doc/man/nvme_fw_download_seq.2 index 614e51b..e441e1c 100644 --- a/doc/man/nvme_fw_download_seq.2 +++ b/doc/man/nvme_fw_download_seq.2 @@ -1,4 +1,4 @@ -.TH "nvme_fw_download_seq" 9 "nvme_fw_download_seq" "June 2023" "libnvme API manual" LINUX +.TH "nvme_fw_download_seq" 9 "nvme_fw_download_seq" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_fw_download_seq \- Firmware download sequence .SH SYNOPSIS diff --git a/doc/man/nvme_gen_dhchap_key.2 b/doc/man/nvme_gen_dhchap_key.2 index 93980cc..f0675d7 100644 --- a/doc/man/nvme_gen_dhchap_key.2 +++ b/doc/man/nvme_gen_dhchap_key.2 @@ -1,4 +1,4 @@ -.TH "nvme_gen_dhchap_key" 9 "nvme_gen_dhchap_key" "June 2023" "libnvme API manual" LINUX +.TH "nvme_gen_dhchap_key" 9 "nvme_gen_dhchap_key" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_gen_dhchap_key \- DH-HMAC-CHAP key generation .SH SYNOPSIS diff --git a/doc/man/nvme_get_ana_log_len.2 b/doc/man/nvme_get_ana_log_len.2 index d9076c3..6c4055e 100644 --- a/doc/man/nvme_get_ana_log_len.2 +++ b/doc/man/nvme_get_ana_log_len.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_ana_log_len" 9 "nvme_get_ana_log_len" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_ana_log_len" 9 "nvme_get_ana_log_len" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_ana_log_len \- Retrieve size of the current ANA log .SH SYNOPSIS diff --git a/doc/man/nvme_get_attr.2 b/doc/man/nvme_get_attr.2 index 0250c1e..29e8295 100644 --- a/doc/man/nvme_get_attr.2 +++ b/doc/man/nvme_get_attr.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_attr" 9 "nvme_get_attr" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_attr" 9 "nvme_get_attr" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_attr \- Read sysfs attribute .SH SYNOPSIS diff --git a/doc/man/nvme_get_ctrl_attr.2 b/doc/man/nvme_get_ctrl_attr.2 index dc6ddc2..c242c1e 100644 --- a/doc/man/nvme_get_ctrl_attr.2 +++ b/doc/man/nvme_get_ctrl_attr.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_ctrl_attr" 9 "nvme_get_ctrl_attr" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_ctrl_attr" 9 "nvme_get_ctrl_attr" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_ctrl_attr \- Read controller sysfs attribute .SH SYNOPSIS diff --git a/doc/man/nvme_get_ctrl_telemetry.2 b/doc/man/nvme_get_ctrl_telemetry.2 index ba520be..6859c07 100644 --- a/doc/man/nvme_get_ctrl_telemetry.2 +++ b/doc/man/nvme_get_ctrl_telemetry.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_ctrl_telemetry" 9 "nvme_get_ctrl_telemetry" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_ctrl_telemetry" 9 "nvme_get_ctrl_telemetry" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_ctrl_telemetry \- Get controller telemetry log .SH SYNOPSIS diff --git a/doc/man/nvme_get_directive_receive_length.2 b/doc/man/nvme_get_directive_receive_length.2 index e7d00a3..7ac9fe5 100644 --- a/doc/man/nvme_get_directive_receive_length.2 +++ b/doc/man/nvme_get_directive_receive_length.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_directive_receive_length" 9 "nvme_get_directive_receive_length" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_directive_receive_length" 9 "nvme_get_directive_receive_length" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_directive_receive_length \- Get directive receive length .SH SYNOPSIS diff --git a/doc/man/nvme_get_discovery_args.2 b/doc/man/nvme_get_discovery_args.2 index ca7a25b..4575aa4 100644 --- a/doc/man/nvme_get_discovery_args.2 +++ b/doc/man/nvme_get_discovery_args.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_get_discovery_args" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_get_discovery_args" "September 2023" "API Manual" LINUX .SH NAME struct nvme_get_discovery_args \- Arguments for nvmf_get_discovery_wargs() .SH SYNOPSIS diff --git a/doc/man/nvme_get_feature_length.2 b/doc/man/nvme_get_feature_length.2 index ffe518e..cd3d2e8 100644 --- a/doc/man/nvme_get_feature_length.2 +++ b/doc/man/nvme_get_feature_length.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_feature_length" 9 "nvme_get_feature_length" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_feature_length" 9 "nvme_get_feature_length" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_feature_length \- Retreive the command payload length for a specific feature identifier .SH SYNOPSIS diff --git a/doc/man/nvme_get_feature_length2.2 b/doc/man/nvme_get_feature_length2.2 index eb1d7f4..266bc75 100644 --- a/doc/man/nvme_get_feature_length2.2 +++ b/doc/man/nvme_get_feature_length2.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_feature_length2" 9 "nvme_get_feature_length2" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_feature_length2" 9 "nvme_get_feature_length2" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_feature_length2 \- Retreive the command payload length for a specific feature identifier .SH SYNOPSIS diff --git a/doc/man/nvme_get_features.2 b/doc/man/nvme_get_features.2 index 4e336d1..d680d86 100644 --- a/doc/man/nvme_get_features.2 +++ b/doc/man/nvme_get_features.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features" 9 "nvme_get_features" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features" 9 "nvme_get_features" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features \- Retrieve a feature attribute .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_arbitration.2 b/doc/man/nvme_get_features_arbitration.2 index 627e7f5..01f8087 100644 --- a/doc/man/nvme_get_features_arbitration.2 +++ b/doc/man/nvme_get_features_arbitration.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_arbitration" 9 "nvme_get_features_arbitration" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_arbitration" 9 "nvme_get_features_arbitration" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_arbitration \- Get arbitration feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_async_event.2 b/doc/man/nvme_get_features_async_event.2 index 01f9b78..fdefd91 100644 --- a/doc/man/nvme_get_features_async_event.2 +++ b/doc/man/nvme_get_features_async_event.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_async_event" 9 "nvme_get_features_async_event" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_async_event" 9 "nvme_get_features_async_event" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_async_event \- Get asynchronous event feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_auto_pst.2 b/doc/man/nvme_get_features_auto_pst.2 index 38d2115..128ebe1 100644 --- a/doc/man/nvme_get_features_auto_pst.2 +++ b/doc/man/nvme_get_features_auto_pst.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_auto_pst" 9 "nvme_get_features_auto_pst" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_auto_pst" 9 "nvme_get_features_auto_pst" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_auto_pst \- Get autonomous power state feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_data.2 b/doc/man/nvme_get_features_data.2 index 7c69998..8489025 100644 --- a/doc/man/nvme_get_features_data.2 +++ b/doc/man/nvme_get_features_data.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_data" 9 "nvme_get_features_data" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_data" 9 "nvme_get_features_data" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_data \- Helper function for @nvme_get_features() .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_endurance_event_cfg.2 b/doc/man/nvme_get_features_endurance_event_cfg.2 index 765dfb4..c57c2d8 100644 --- a/doc/man/nvme_get_features_endurance_event_cfg.2 +++ b/doc/man/nvme_get_features_endurance_event_cfg.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_endurance_event_cfg" 9 "nvme_get_features_endurance_event_cfg" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_endurance_event_cfg" 9 "nvme_get_features_endurance_event_cfg" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_endurance_event_cfg \- Get endurance event config feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_err_recovery.2 b/doc/man/nvme_get_features_err_recovery.2 index 8bf2508..01d8150 100644 --- a/doc/man/nvme_get_features_err_recovery.2 +++ b/doc/man/nvme_get_features_err_recovery.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_err_recovery" 9 "nvme_get_features_err_recovery" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_err_recovery" 9 "nvme_get_features_err_recovery" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_err_recovery \- Get error recovery feature .SH SYNOPSIS @@ -13,6 +13,10 @@ File descriptor of nvme device 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 "DESCRIPTION" + +Deprecated: doesn't support specifying a NSID. +Use \fBnvme_get_features_err_recovery2\fP instead. .SH "RETURN" The nvme command status if a response was received (see \fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_get_features_err_recovery2.2 b/doc/man/nvme_get_features_err_recovery2.2 new file mode 100644 index 0000000..0c95f7e --- /dev/null +++ b/doc/man/nvme_get_features_err_recovery2.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_features_err_recovery2" 9 "nvme_get_features_err_recovery2" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_get_features_err_recovery2 \- Get error recovery feature +.SH SYNOPSIS +.B "int" nvme_get_features_err_recovery2 +.BI "(int fd " "," +.BI "enum nvme_get_features_sel sel " "," +.BI "__u32 nsid " "," +.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 "nsid" 12 +Namespace ID +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received (see +\fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_get_features_hctm.2 b/doc/man/nvme_get_features_hctm.2 index 0b8a66f..f3cd219 100644 --- a/doc/man/nvme_get_features_hctm.2 +++ b/doc/man/nvme_get_features_hctm.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_hctm" 9 "nvme_get_features_hctm" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_hctm" 9 "nvme_get_features_hctm" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_hctm \- Get thermal management feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_host_behavior.2 b/doc/man/nvme_get_features_host_behavior.2 index 1268f24..216a51e 100644 --- a/doc/man/nvme_get_features_host_behavior.2 +++ b/doc/man/nvme_get_features_host_behavior.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_host_behavior" 9 "nvme_get_features_host_behavior" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_host_behavior" 9 "nvme_get_features_host_behavior" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_host_behavior \- Get host behavior feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_host_id.2 b/doc/man/nvme_get_features_host_id.2 index 98b1e53..498de0a 100644 --- a/doc/man/nvme_get_features_host_id.2 +++ b/doc/man/nvme_get_features_host_id.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_host_id" 9 "nvme_get_features_host_id" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_host_id" 9 "nvme_get_features_host_id" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_host_id \- Get host id feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_host_mem_buf.2 b/doc/man/nvme_get_features_host_mem_buf.2 index 0c07f14..ea5c22d 100644 --- a/doc/man/nvme_get_features_host_mem_buf.2 +++ b/doc/man/nvme_get_features_host_mem_buf.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_host_mem_buf" 9 "nvme_get_features_host_mem_buf" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_host_mem_buf" 9 "nvme_get_features_host_mem_buf" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_host_mem_buf \- Get host memory buffer feature .SH SYNOPSIS @@ -13,6 +13,10 @@ File descriptor of nvme device 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 "DESCRIPTION" + +Deprecated: doesn't fetch the Host Memory Buffer Attributes data structure. +Use \fBnvme_get_features_host_mem_buf2\fP instead. .SH "RETURN" The nvme command status if a response was received (see \fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_get_features_host_mem_buf2.2 b/doc/man/nvme_get_features_host_mem_buf2.2 new file mode 100644 index 0000000..0eb69e8 --- /dev/null +++ b/doc/man/nvme_get_features_host_mem_buf2.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_features_host_mem_buf2" 9 "nvme_get_features_host_mem_buf2" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_get_features_host_mem_buf2 \- Get host memory buffer feature +.SH SYNOPSIS +.B "int" nvme_get_features_host_mem_buf2 +.BI "(int fd " "," +.BI "enum nvme_get_features_sel sel " "," +.BI "struct nvme_host_mem_buf_attrs *attrs " "," +.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 "attrs" 12 +Buffer for returned Host Memory Buffer Attributes +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received (see +\fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_get_features_iocs_profile.2 b/doc/man/nvme_get_features_iocs_profile.2 index 525be94..e9aa1bc 100644 --- a/doc/man/nvme_get_features_iocs_profile.2 +++ b/doc/man/nvme_get_features_iocs_profile.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_iocs_profile" 9 "nvme_get_features_iocs_profile" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_iocs_profile" 9 "nvme_get_features_iocs_profile" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_iocs_profile \- Get IOCS profile feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_irq_coalesce.2 b/doc/man/nvme_get_features_irq_coalesce.2 index c5e9ba6..eacb415 100644 --- a/doc/man/nvme_get_features_irq_coalesce.2 +++ b/doc/man/nvme_get_features_irq_coalesce.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_irq_coalesce" 9 "nvme_get_features_irq_coalesce" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_irq_coalesce" 9 "nvme_get_features_irq_coalesce" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_irq_coalesce \- Get IRQ coalesce feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_irq_config.2 b/doc/man/nvme_get_features_irq_config.2 index dd10ae8..7714499 100644 --- a/doc/man/nvme_get_features_irq_config.2 +++ b/doc/man/nvme_get_features_irq_config.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_irq_config" 9 "nvme_get_features_irq_config" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_irq_config" 9 "nvme_get_features_irq_config" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_irq_config \- Get IRQ config feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_kato.2 b/doc/man/nvme_get_features_kato.2 index 63c7552..15a5c8c 100644 --- a/doc/man/nvme_get_features_kato.2 +++ b/doc/man/nvme_get_features_kato.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_kato" 9 "nvme_get_features_kato" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_kato" 9 "nvme_get_features_kato" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_kato \- Get keep alive timeout feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_lba_range.2 b/doc/man/nvme_get_features_lba_range.2 index 3ef9561..836705f 100644 --- a/doc/man/nvme_get_features_lba_range.2 +++ b/doc/man/nvme_get_features_lba_range.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_lba_range" 9 "nvme_get_features_lba_range" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_lba_range" 9 "nvme_get_features_lba_range" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_lba_range \- Get LBA range feature .SH SYNOPSIS @@ -16,6 +16,10 @@ Select which type of attribute to return, see \fIenum nvme_get_features_sel\fP User address of feature data, if applicable .IP "result" 12 The command completion result from CQE dword0 +.SH "DESCRIPTION" + +Deprecated: doesn't support specifying a NSID. +Use \fBnvme_get_features_lba_range2\fP instead. .SH "RETURN" The nvme command status if a response was received (see \fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_get_features_lba_range2.2 b/doc/man/nvme_get_features_lba_range2.2 new file mode 100644 index 0000000..a26e3f6 --- /dev/null +++ b/doc/man/nvme_get_features_lba_range2.2 @@ -0,0 +1,24 @@ +.TH "nvme_get_features_lba_range2" 9 "nvme_get_features_lba_range2" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_get_features_lba_range2 \- Get LBA range feature +.SH SYNOPSIS +.B "int" nvme_get_features_lba_range2 +.BI "(int fd " "," +.BI "enum nvme_get_features_sel sel " "," +.BI "__u32 nsid " "," +.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 "nsid" 12 +Namespace ID +.IP "data" 12 +Buffer to receive LBA Range Type data structure +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received (see +\fIenum nvme_status_field\fP) 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 index 5bd6cc0..27bde5a 100644 --- a/doc/man/nvme_get_features_lba_sts_interval.2 +++ b/doc/man/nvme_get_features_lba_sts_interval.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_lba_sts_interval" 9 "nvme_get_features_lba_sts_interval" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_lba_sts_interval" 9 "nvme_get_features_lba_sts_interval" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_lba_sts_interval \- Get LBA status information feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_nopsc.2 b/doc/man/nvme_get_features_nopsc.2 index 59bcbba..0c3e9b6 100644 --- a/doc/man/nvme_get_features_nopsc.2 +++ b/doc/man/nvme_get_features_nopsc.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_nopsc" 9 "nvme_get_features_nopsc" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_nopsc" 9 "nvme_get_features_nopsc" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_nopsc \- Get non-operational power state feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_num_queues.2 b/doc/man/nvme_get_features_num_queues.2 index b5775b7..bf640ff 100644 --- a/doc/man/nvme_get_features_num_queues.2 +++ b/doc/man/nvme_get_features_num_queues.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_num_queues" 9 "nvme_get_features_num_queues" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_num_queues" 9 "nvme_get_features_num_queues" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_num_queues \- Get number of queues feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_plm_config.2 b/doc/man/nvme_get_features_plm_config.2 index ccb53d2..2ecca68 100644 --- a/doc/man/nvme_get_features_plm_config.2 +++ b/doc/man/nvme_get_features_plm_config.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_plm_config" 9 "nvme_get_features_plm_config" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_plm_config" 9 "nvme_get_features_plm_config" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_plm_config \- Get predictable latency feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_plm_window.2 b/doc/man/nvme_get_features_plm_window.2 index 5a15532..ee98349 100644 --- a/doc/man/nvme_get_features_plm_window.2 +++ b/doc/man/nvme_get_features_plm_window.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_plm_window" 9 "nvme_get_features_plm_window" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_plm_window" 9 "nvme_get_features_plm_window" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_plm_window \- Get window select feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_power_mgmt.2 b/doc/man/nvme_get_features_power_mgmt.2 index cbd1434..58fc4b3 100644 --- a/doc/man/nvme_get_features_power_mgmt.2 +++ b/doc/man/nvme_get_features_power_mgmt.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_power_mgmt" 9 "nvme_get_features_power_mgmt" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_power_mgmt" 9 "nvme_get_features_power_mgmt" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_power_mgmt \- Get power management feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_resv_mask.2 b/doc/man/nvme_get_features_resv_mask.2 index f9d4d5d..e398fff 100644 --- a/doc/man/nvme_get_features_resv_mask.2 +++ b/doc/man/nvme_get_features_resv_mask.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_resv_mask" 9 "nvme_get_features_resv_mask" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_resv_mask" 9 "nvme_get_features_resv_mask" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_resv_mask \- Get reservation mask feature .SH SYNOPSIS @@ -13,6 +13,10 @@ File descriptor of nvme device 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 "DESCRIPTION" + +Deprecated: doesn't support specifying a NSID. +Use \fBnvme_get_features_resv_mask2\fP instead. .SH "RETURN" The nvme command status if a response was received (see \fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_get_features_resv_mask2.2 b/doc/man/nvme_get_features_resv_mask2.2 new file mode 100644 index 0000000..eae9d82 --- /dev/null +++ b/doc/man/nvme_get_features_resv_mask2.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_features_resv_mask2" 9 "nvme_get_features_resv_mask2" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_get_features_resv_mask2 \- Get reservation mask feature +.SH SYNOPSIS +.B "int" nvme_get_features_resv_mask2 +.BI "(int fd " "," +.BI "enum nvme_get_features_sel sel " "," +.BI "__u32 nsid " "," +.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 "nsid" 12 +Namespace ID +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received (see +\fIenum nvme_status_field\fP) 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 index 3fb53ff..c0dd50b 100644 --- a/doc/man/nvme_get_features_resv_persist.2 +++ b/doc/man/nvme_get_features_resv_persist.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_resv_persist" 9 "nvme_get_features_resv_persist" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_resv_persist" 9 "nvme_get_features_resv_persist" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_resv_persist \- Get reservation persist feature .SH SYNOPSIS @@ -13,6 +13,10 @@ File descriptor of nvme device 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 "DESCRIPTION" + +Deprecated: doesn't support specifying a NSID. +Use \fBnvme_get_features_resv_persist2\fP instead. .SH "RETURN" The nvme command status if a response was received (see \fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_get_features_resv_persist2.2 b/doc/man/nvme_get_features_resv_persist2.2 new file mode 100644 index 0000000..62e2207 --- /dev/null +++ b/doc/man/nvme_get_features_resv_persist2.2 @@ -0,0 +1,21 @@ +.TH "nvme_get_features_resv_persist2" 9 "nvme_get_features_resv_persist2" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_get_features_resv_persist2 \- Get reservation persist feature +.SH SYNOPSIS +.B "int" nvme_get_features_resv_persist2 +.BI "(int fd " "," +.BI "enum nvme_get_features_sel sel " "," +.BI "__u32 nsid " "," +.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 "nsid" 12 +Namespace ID +.IP "result" 12 +The command completion result from CQE dword0 +.SH "RETURN" +The nvme command status if a response was received (see +\fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_get_features_rrl.2 b/doc/man/nvme_get_features_rrl.2 index 2241ce6..6f3a187 100644 --- a/doc/man/nvme_get_features_rrl.2 +++ b/doc/man/nvme_get_features_rrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_rrl" 9 "nvme_get_features_rrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_rrl" 9 "nvme_get_features_rrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_rrl \- Get read recovery level feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_sanitize.2 b/doc/man/nvme_get_features_sanitize.2 index ded28cc..0e95f8d 100644 --- a/doc/man/nvme_get_features_sanitize.2 +++ b/doc/man/nvme_get_features_sanitize.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_sanitize" 9 "nvme_get_features_sanitize" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_sanitize" 9 "nvme_get_features_sanitize" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_sanitize \- Get sanitize feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_sel.2 b/doc/man/nvme_get_features_sel.2 index 10ffefb..962edb4 100644 --- a/doc/man/nvme_get_features_sel.2 +++ b/doc/man/nvme_get_features_sel.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_get_features_sel" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_get_features_sel" "September 2023" "API Manual" LINUX .SH NAME enum nvme_get_features_sel \- Get Features - Select .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_simple.2 b/doc/man/nvme_get_features_simple.2 index fab3cf6..8c58dce 100644 --- a/doc/man/nvme_get_features_simple.2 +++ b/doc/man/nvme_get_features_simple.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_simple" 9 "nvme_get_features_simple" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_simple" 9 "nvme_get_features_simple" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_simple \- Helper function for @nvme_get_features() .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_sw_progress.2 b/doc/man/nvme_get_features_sw_progress.2 index c33482a..d16e489 100644 --- a/doc/man/nvme_get_features_sw_progress.2 +++ b/doc/man/nvme_get_features_sw_progress.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_sw_progress" 9 "nvme_get_features_sw_progress" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_sw_progress" 9 "nvme_get_features_sw_progress" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_sw_progress \- Get software progress feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_temp_thresh.2 b/doc/man/nvme_get_features_temp_thresh.2 index 2d6ca44..bd6025f 100644 --- a/doc/man/nvme_get_features_temp_thresh.2 +++ b/doc/man/nvme_get_features_temp_thresh.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_temp_thresh" 9 "nvme_get_features_temp_thresh" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_temp_thresh" 9 "nvme_get_features_temp_thresh" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_temp_thresh \- Get temperature threshold feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_timestamp.2 b/doc/man/nvme_get_features_timestamp.2 index fc8ef10..5c81e7c 100644 --- a/doc/man/nvme_get_features_timestamp.2 +++ b/doc/man/nvme_get_features_timestamp.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_timestamp" 9 "nvme_get_features_timestamp" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_timestamp" 9 "nvme_get_features_timestamp" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_timestamp \- Get timestamp feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_volatile_wc.2 b/doc/man/nvme_get_features_volatile_wc.2 index f951648..e1b4abc 100644 --- a/doc/man/nvme_get_features_volatile_wc.2 +++ b/doc/man/nvme_get_features_volatile_wc.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_volatile_wc" 9 "nvme_get_features_volatile_wc" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_volatile_wc" 9 "nvme_get_features_volatile_wc" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_volatile_wc \- Get volatile write cache feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_write_atomic.2 b/doc/man/nvme_get_features_write_atomic.2 index d540755..d6c62eb 100644 --- a/doc/man/nvme_get_features_write_atomic.2 +++ b/doc/man/nvme_get_features_write_atomic.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_write_atomic" 9 "nvme_get_features_write_atomic" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_write_atomic" 9 "nvme_get_features_write_atomic" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_write_atomic \- Get write atomic feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_features_write_protect.2 b/doc/man/nvme_get_features_write_protect.2 index f1a2d4e..aa7e91c 100644 --- a/doc/man/nvme_get_features_write_protect.2 +++ b/doc/man/nvme_get_features_write_protect.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_features_write_protect" 9 "nvme_get_features_write_protect" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_features_write_protect" 9 "nvme_get_features_write_protect" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_features_write_protect \- Get write protect feature .SH SYNOPSIS diff --git a/doc/man/nvme_get_host_telemetry.2 b/doc/man/nvme_get_host_telemetry.2 index b2f90b0..df4f4c2 100644 --- a/doc/man/nvme_get_host_telemetry.2 +++ b/doc/man/nvme_get_host_telemetry.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_host_telemetry" 9 "nvme_get_host_telemetry" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_host_telemetry" 9 "nvme_get_host_telemetry" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_host_telemetry \- Get host telemetry log .SH SYNOPSIS diff --git a/doc/man/nvme_get_lba_status.2 b/doc/man/nvme_get_lba_status.2 index 7a929d1..67a3eb5 100644 --- a/doc/man/nvme_get_lba_status.2 +++ b/doc/man/nvme_get_lba_status.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_lba_status" 9 "nvme_get_lba_status" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_lba_status" 9 "nvme_get_lba_status" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_lba_status \- Retrieve information on possibly unrecoverable LBAs .SH SYNOPSIS diff --git a/doc/man/nvme_get_lba_status_log.2 b/doc/man/nvme_get_lba_status_log.2 index 8bc8071..b496b44 100644 --- a/doc/man/nvme_get_lba_status_log.2 +++ b/doc/man/nvme_get_lba_status_log.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_lba_status_log" 9 "nvme_get_lba_status_log" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_lba_status_log" 9 "nvme_get_lba_status_log" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_lba_status_log \- Retrieve the LBA Status log page .SH SYNOPSIS diff --git a/doc/man/nvme_get_log.2 b/doc/man/nvme_get_log.2 index 5803bc5..432d7cf 100644 --- a/doc/man/nvme_get_log.2 +++ b/doc/man/nvme_get_log.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log" 9 "nvme_get_log" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log" 9 "nvme_get_log" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log \- NVMe Admin Get Log command .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_ana.2 b/doc/man/nvme_get_log_ana.2 index 54ee397..fd7e95f 100644 --- a/doc/man/nvme_get_log_ana.2 +++ b/doc/man/nvme_get_log_ana.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_ana" 9 "nvme_get_log_ana" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_ana" 9 "nvme_get_log_ana" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_ana \- Retrieve Asymmetric Namespace Access log page .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_ana_groups.2 b/doc/man/nvme_get_log_ana_groups.2 index a7c805d..4c3ab5b 100644 --- a/doc/man/nvme_get_log_ana_groups.2 +++ b/doc/man/nvme_get_log_ana_groups.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_ana_groups" 9 "nvme_get_log_ana_groups" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_ana_groups" 9 "nvme_get_log_ana_groups" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_ana_groups \- Retrieve Asymmetric Namespace Access groups only log page .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_boot_partition.2 b/doc/man/nvme_get_log_boot_partition.2 index 94f2b4c..57e5787 100644 --- a/doc/man/nvme_get_log_boot_partition.2 +++ b/doc/man/nvme_get_log_boot_partition.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_boot_partition" 9 "nvme_get_log_boot_partition" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_boot_partition" 9 "nvme_get_log_boot_partition" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_boot_partition \- Retrieve Boot Partition .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_changed_ns_list.2 b/doc/man/nvme_get_log_changed_ns_list.2 index 0605818..9dc582a 100644 --- a/doc/man/nvme_get_log_changed_ns_list.2 +++ b/doc/man/nvme_get_log_changed_ns_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_changed_ns_list" 9 "nvme_get_log_changed_ns_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_changed_ns_list" 9 "nvme_get_log_changed_ns_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_changed_ns_list \- Retrieve namespace changed list .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_cmd_effects.2 b/doc/man/nvme_get_log_cmd_effects.2 index d826f3e..d28df54 100644 --- a/doc/man/nvme_get_log_cmd_effects.2 +++ b/doc/man/nvme_get_log_cmd_effects.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_cmd_effects" 9 "nvme_get_log_cmd_effects" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_cmd_effects" 9 "nvme_get_log_cmd_effects" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_cmd_effects \- Retrieve nvme command effects log .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_create_telemetry_host.2 b/doc/man/nvme_get_log_create_telemetry_host.2 index ca23c83..a5427a1 100644 --- a/doc/man/nvme_get_log_create_telemetry_host.2 +++ b/doc/man/nvme_get_log_create_telemetry_host.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_create_telemetry_host" 9 "nvme_get_log_create_telemetry_host" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_create_telemetry_host" 9 "nvme_get_log_create_telemetry_host" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_create_telemetry_host \- Create host telemetry log .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_device_self_test.2 b/doc/man/nvme_get_log_device_self_test.2 index 84a1625..b35b32c 100644 --- a/doc/man/nvme_get_log_device_self_test.2 +++ b/doc/man/nvme_get_log_device_self_test.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_device_self_test" 9 "nvme_get_log_device_self_test" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_device_self_test" 9 "nvme_get_log_device_self_test" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_device_self_test \- Retrieve the device self test log .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_discovery.2 b/doc/man/nvme_get_log_discovery.2 index e490786..35b618f 100644 --- a/doc/man/nvme_get_log_discovery.2 +++ b/doc/man/nvme_get_log_discovery.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_discovery" 9 "nvme_get_log_discovery" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_discovery" 9 "nvme_get_log_discovery" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_discovery \- Retrieve Discovery log page .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_endurance_group.2 b/doc/man/nvme_get_log_endurance_group.2 index 9f1abe0..c5f7b0e 100644 --- a/doc/man/nvme_get_log_endurance_group.2 +++ b/doc/man/nvme_get_log_endurance_group.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_endurance_group" 9 "nvme_get_log_endurance_group" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_endurance_group" 9 "nvme_get_log_endurance_group" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_endurance_group \- Get Endurance Group log .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_endurance_grp_evt.2 b/doc/man/nvme_get_log_endurance_grp_evt.2 index 241cc0d..b1222fa 100644 --- a/doc/man/nvme_get_log_endurance_grp_evt.2 +++ b/doc/man/nvme_get_log_endurance_grp_evt.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_endurance_grp_evt" 9 "nvme_get_log_endurance_grp_evt" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_endurance_grp_evt" 9 "nvme_get_log_endurance_grp_evt" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_endurance_grp_evt \- Retrieve Rotational Media Information .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_error.2 b/doc/man/nvme_get_log_error.2 index 5943dfc..23a72b6 100644 --- a/doc/man/nvme_get_log_error.2 +++ b/doc/man/nvme_get_log_error.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_error" 9 "nvme_get_log_error" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_error" 9 "nvme_get_log_error" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_error \- Retrieve nvme error log .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_fdp_configurations.2 b/doc/man/nvme_get_log_fdp_configurations.2 index 9468abb..b593f88 100644 --- a/doc/man/nvme_get_log_fdp_configurations.2 +++ b/doc/man/nvme_get_log_fdp_configurations.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_fdp_configurations" 9 "nvme_get_log_fdp_configurations" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_fdp_configurations" 9 "nvme_get_log_fdp_configurations" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_fdp_configurations \- Get list of Flexible Data Placement configurations .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_fdp_events.2 b/doc/man/nvme_get_log_fdp_events.2 index 8936ed6..8a0c873 100644 --- a/doc/man/nvme_get_log_fdp_events.2 +++ b/doc/man/nvme_get_log_fdp_events.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_fdp_events" 9 "nvme_get_log_fdp_events" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_fdp_events" 9 "nvme_get_log_fdp_events" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_fdp_events \- Get Flexible Data Placement events .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_fdp_stats.2 b/doc/man/nvme_get_log_fdp_stats.2 index 24c4cab..b4fb249 100644 --- a/doc/man/nvme_get_log_fdp_stats.2 +++ b/doc/man/nvme_get_log_fdp_stats.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_fdp_stats" 9 "nvme_get_log_fdp_stats" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_fdp_stats" 9 "nvme_get_log_fdp_stats" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_fdp_stats \- Get Flexible Data Placement statistics .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_fid_supported_effects.2 b/doc/man/nvme_get_log_fid_supported_effects.2 index 45e3ac5..70feb30 100644 --- a/doc/man/nvme_get_log_fid_supported_effects.2 +++ b/doc/man/nvme_get_log_fid_supported_effects.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_fid_supported_effects" 9 "nvme_get_log_fid_supported_effects" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_fid_supported_effects" 9 "nvme_get_log_fid_supported_effects" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_fid_supported_effects \- Retrieve Feature Identifiers Supported and Effects .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_fw_slot.2 b/doc/man/nvme_get_log_fw_slot.2 index 8271510..ac48953 100644 --- a/doc/man/nvme_get_log_fw_slot.2 +++ b/doc/man/nvme_get_log_fw_slot.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_fw_slot" 9 "nvme_get_log_fw_slot" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_fw_slot" 9 "nvme_get_log_fw_slot" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_fw_slot \- Retrieves the controller firmware log .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_lba_status.2 b/doc/man/nvme_get_log_lba_status.2 index 2b64d70..f1553bd 100644 --- a/doc/man/nvme_get_log_lba_status.2 +++ b/doc/man/nvme_get_log_lba_status.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_lba_status" 9 "nvme_get_log_lba_status" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_lba_status" 9 "nvme_get_log_lba_status" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_lba_status \- Retrieve LBA Status .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_media_unit_stat.2 b/doc/man/nvme_get_log_media_unit_stat.2 index 8fec753..e0f145b 100644 --- a/doc/man/nvme_get_log_media_unit_stat.2 +++ b/doc/man/nvme_get_log_media_unit_stat.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_media_unit_stat" 9 "nvme_get_log_media_unit_stat" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_media_unit_stat" 9 "nvme_get_log_media_unit_stat" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_media_unit_stat \- Retrieve Media Unit Status .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_mi_cmd_supported_effects.2 b/doc/man/nvme_get_log_mi_cmd_supported_effects.2 index f5d8f55..28d69c4 100644 --- a/doc/man/nvme_get_log_mi_cmd_supported_effects.2 +++ b/doc/man/nvme_get_log_mi_cmd_supported_effects.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_mi_cmd_supported_effects" 9 "nvme_get_log_mi_cmd_supported_effects" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_mi_cmd_supported_effects" 9 "nvme_get_log_mi_cmd_supported_effects" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_mi_cmd_supported_effects \- displays the MI Commands Supported by the controller .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_page.2 b/doc/man/nvme_get_log_page.2 index 4a8b85d..90e7170 100644 --- a/doc/man/nvme_get_log_page.2 +++ b/doc/man/nvme_get_log_page.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_page" 9 "nvme_get_log_page" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_page" 9 "nvme_get_log_page" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_page \- Get log page data .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_persistent_event.2 b/doc/man/nvme_get_log_persistent_event.2 index 2ad5e5e..ea2cb84 100644 --- a/doc/man/nvme_get_log_persistent_event.2 +++ b/doc/man/nvme_get_log_persistent_event.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_persistent_event" 9 "nvme_get_log_persistent_event" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_persistent_event" 9 "nvme_get_log_persistent_event" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_persistent_event \- Retrieve Persistent Event Log .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_phy_rx_eom.2 b/doc/man/nvme_get_log_phy_rx_eom.2 new file mode 100644 index 0000000..aa87a68 --- /dev/null +++ b/doc/man/nvme_get_log_phy_rx_eom.2 @@ -0,0 +1,25 @@ +.TH "nvme_get_log_phy_rx_eom" 9 "nvme_get_log_phy_rx_eom" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_get_log_phy_rx_eom \- Retrieve Physical Interface Receiver Eye Opening Measurement Log +.SH SYNOPSIS +.B "int" nvme_get_log_phy_rx_eom +.BI "(int fd " "," +.BI "__u8 lsp " "," +.BI "__u16 controller " "," +.BI "__u32 len " "," +.BI "struct nvme_phy_rx_eom_log *log " ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "lsp" 12 +Log specific, controls action and measurement quality +.IP "controller" 12 +Target controller ID +.IP "len" 12 +The allocated size, minimum +struct nvme_phy_rx_eom_log +.IP "log" 12 +User address to store the log page +.SH "RETURN" +The nvme command status if a response was received (see +\fIenum nvme_status_field\fP) or -1 with errno set otherwise diff --git a/doc/man/nvme_get_log_predictable_lat_event.2 b/doc/man/nvme_get_log_predictable_lat_event.2 index edfeaf1..f74785f 100644 --- a/doc/man/nvme_get_log_predictable_lat_event.2 +++ b/doc/man/nvme_get_log_predictable_lat_event.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_predictable_lat_event" 9 "nvme_get_log_predictable_lat_event" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_predictable_lat_event" 9 "nvme_get_log_predictable_lat_event" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_predictable_lat_event \- Retrieve Predictable Latency Event Aggregate Log Page .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_predictable_lat_nvmset.2 b/doc/man/nvme_get_log_predictable_lat_nvmset.2 index 4a6763d..c950689 100644 --- a/doc/man/nvme_get_log_predictable_lat_nvmset.2 +++ b/doc/man/nvme_get_log_predictable_lat_nvmset.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_predictable_lat_nvmset" 9 "nvme_get_log_predictable_lat_nvmset" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_predictable_lat_nvmset" 9 "nvme_get_log_predictable_lat_nvmset" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_predictable_lat_nvmset \- Predictable Latency Per NVM Set .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_reclaim_unit_handle_usage.2 b/doc/man/nvme_get_log_reclaim_unit_handle_usage.2 index 008085b..d08a4a8 100644 --- a/doc/man/nvme_get_log_reclaim_unit_handle_usage.2 +++ b/doc/man/nvme_get_log_reclaim_unit_handle_usage.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_reclaim_unit_handle_usage" 9 "nvme_get_log_reclaim_unit_handle_usage" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_reclaim_unit_handle_usage" 9 "nvme_get_log_reclaim_unit_handle_usage" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_reclaim_unit_handle_usage \- Get reclaim unit handle usage .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_reservation.2 b/doc/man/nvme_get_log_reservation.2 index abd304e..73f19cb 100644 --- a/doc/man/nvme_get_log_reservation.2 +++ b/doc/man/nvme_get_log_reservation.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_reservation" 9 "nvme_get_log_reservation" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_reservation" 9 "nvme_get_log_reservation" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_reservation \- Retrieve Reservation Notification .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_sanitize.2 b/doc/man/nvme_get_log_sanitize.2 index b498f14..4d569e4 100644 --- a/doc/man/nvme_get_log_sanitize.2 +++ b/doc/man/nvme_get_log_sanitize.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_sanitize" 9 "nvme_get_log_sanitize" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_sanitize" 9 "nvme_get_log_sanitize" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_sanitize \- Retrieve Sanitize Status .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_smart.2 b/doc/man/nvme_get_log_smart.2 index 1476351..bb25c64 100644 --- a/doc/man/nvme_get_log_smart.2 +++ b/doc/man/nvme_get_log_smart.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_smart" 9 "nvme_get_log_smart" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_smart" 9 "nvme_get_log_smart" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_smart \- Retrieve nvme smart log .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_support_cap_config_list.2 b/doc/man/nvme_get_log_support_cap_config_list.2 index a8aeb41..4e1c3ce 100644 --- a/doc/man/nvme_get_log_support_cap_config_list.2 +++ b/doc/man/nvme_get_log_support_cap_config_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_support_cap_config_list" 9 "nvme_get_log_support_cap_config_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_support_cap_config_list" 9 "nvme_get_log_support_cap_config_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_support_cap_config_list \- Retrieve Supported Capacity Configuration List .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_supported_log_pages.2 b/doc/man/nvme_get_log_supported_log_pages.2 index 8ee0e81..8feb327 100644 --- a/doc/man/nvme_get_log_supported_log_pages.2 +++ b/doc/man/nvme_get_log_supported_log_pages.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_supported_log_pages" 9 "nvme_get_log_supported_log_pages" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_supported_log_pages" 9 "nvme_get_log_supported_log_pages" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_supported_log_pages \- Retrieve nmve supported log pages .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_telemetry_ctrl.2 b/doc/man/nvme_get_log_telemetry_ctrl.2 index abb8c2f..15f0bc3 100644 --- a/doc/man/nvme_get_log_telemetry_ctrl.2 +++ b/doc/man/nvme_get_log_telemetry_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_telemetry_ctrl" 9 "nvme_get_log_telemetry_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_telemetry_ctrl" 9 "nvme_get_log_telemetry_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_telemetry_ctrl \- Get Telemetry Controller-Initiated log page .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_telemetry_host.2 b/doc/man/nvme_get_log_telemetry_host.2 index 4857624..2ee3718 100644 --- a/doc/man/nvme_get_log_telemetry_host.2 +++ b/doc/man/nvme_get_log_telemetry_host.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_telemetry_host" 9 "nvme_get_log_telemetry_host" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_telemetry_host" 9 "nvme_get_log_telemetry_host" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_telemetry_host \- Get Telemetry Host-Initiated log page .SH SYNOPSIS diff --git a/doc/man/nvme_get_log_zns_changed_zones.2 b/doc/man/nvme_get_log_zns_changed_zones.2 index 46fb4f4..b4d7ef4 100644 --- a/doc/man/nvme_get_log_zns_changed_zones.2 +++ b/doc/man/nvme_get_log_zns_changed_zones.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_log_zns_changed_zones" 9 "nvme_get_log_zns_changed_zones" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_log_zns_changed_zones" 9 "nvme_get_log_zns_changed_zones" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_log_zns_changed_zones \- Retrieve list of zones that have changed .SH SYNOPSIS diff --git a/doc/man/nvme_get_logical_block_size.2 b/doc/man/nvme_get_logical_block_size.2 index 0fe0984..bfd3516 100644 --- a/doc/man/nvme_get_logical_block_size.2 +++ b/doc/man/nvme_get_logical_block_size.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_logical_block_size" 9 "nvme_get_logical_block_size" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_logical_block_size" 9 "nvme_get_logical_block_size" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_logical_block_size \- Retrieve block size .SH SYNOPSIS diff --git a/doc/man/nvme_get_new_host_telemetry.2 b/doc/man/nvme_get_new_host_telemetry.2 index e6f0954..7654548 100644 --- a/doc/man/nvme_get_new_host_telemetry.2 +++ b/doc/man/nvme_get_new_host_telemetry.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_new_host_telemetry" 9 "nvme_get_new_host_telemetry" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_new_host_telemetry" 9 "nvme_get_new_host_telemetry" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_new_host_telemetry \- Get new host telemetry log .SH SYNOPSIS diff --git a/doc/man/nvme_get_ns_attr.2 b/doc/man/nvme_get_ns_attr.2 index 62898ff..792914e 100644 --- a/doc/man/nvme_get_ns_attr.2 +++ b/doc/man/nvme_get_ns_attr.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_ns_attr" 9 "nvme_get_ns_attr" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_ns_attr" 9 "nvme_get_ns_attr" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_ns_attr \- Read namespace sysfs attribute .SH SYNOPSIS diff --git a/doc/man/nvme_get_nsid.2 b/doc/man/nvme_get_nsid.2 index d1656f5..8c2e822 100644 --- a/doc/man/nvme_get_nsid.2 +++ b/doc/man/nvme_get_nsid.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_nsid" 9 "nvme_get_nsid" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_nsid" 9 "nvme_get_nsid" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_nsid \- Retrieve the NSID from a namespace file descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_get_path_attr.2 b/doc/man/nvme_get_path_attr.2 index 921b339..00f483b 100644 --- a/doc/man/nvme_get_path_attr.2 +++ b/doc/man/nvme_get_path_attr.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_path_attr" 9 "nvme_get_path_attr" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_path_attr" 9 "nvme_get_path_attr" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_path_attr \- Read path sysfs attribute .SH SYNOPSIS diff --git a/doc/man/nvme_get_property.2 b/doc/man/nvme_get_property.2 index d88155c..d789d1c 100644 --- a/doc/man/nvme_get_property.2 +++ b/doc/man/nvme_get_property.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_property" 9 "nvme_get_property" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_property" 9 "nvme_get_property" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_property \- Get a controller property .SH SYNOPSIS diff --git a/doc/man/nvme_get_subsys_attr.2 b/doc/man/nvme_get_subsys_attr.2 index 5b8db80..55d758a 100644 --- a/doc/man/nvme_get_subsys_attr.2 +++ b/doc/man/nvme_get_subsys_attr.2 @@ -1,4 +1,4 @@ -.TH "nvme_get_subsys_attr" 9 "nvme_get_subsys_attr" "June 2023" "libnvme API manual" LINUX +.TH "nvme_get_subsys_attr" 9 "nvme_get_subsys_attr" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_get_subsys_attr \- Read subsystem sysfs attribute .SH SYNOPSIS diff --git a/doc/man/nvme_get_telemetry_log.2 b/doc/man/nvme_get_telemetry_log.2 new file mode 100644 index 0000000..1c2871b --- /dev/null +++ b/doc/man/nvme_get_telemetry_log.2 @@ -0,0 +1,36 @@ +.TH "nvme_get_telemetry_log" 9 "nvme_get_telemetry_log" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_get_telemetry_log \- Get specified telemetry log +.SH SYNOPSIS +.B "int" nvme_get_telemetry_log +.BI "(int fd " "," +.BI "bool create " "," +.BI "bool ctrl " "," +.BI "bool rae " "," +.BI "size_t max_data_tx " "," +.BI "enum nvme_telemetry_da da " "," +.BI "struct nvme_telemetry_log **log " "," +.BI "size_t *size " ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "create" 12 +Generate new host initated telemetry capture +.IP "ctrl" 12 +Get controller Initiated log +.IP "rae" 12 +Retain asynchronous events +.IP "max_data_tx" 12 +Set the max data transfer size to be used retrieving telemetry. +.IP "da" 12 +Log page data area, valid values: \fIenum nvme_telemetry_da\fP. +.IP "log" 12 +On success, set to the value of the allocated and retrieved log. +.IP "size" 12 +Ptr to the telemetry log size, so it can be returned +.SH "DESCRIPTION" +The total size allocated can be calculated as: +(nvme_telemetry_log da size + 1) * NVME_LOG_TELEM_BLOCK_SIZE. +.SH "RETURN" +The nvme command status if a response was received (see +\fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_get_telemetry_max.2 b/doc/man/nvme_get_telemetry_max.2 new file mode 100644 index 0000000..6ddc882 --- /dev/null +++ b/doc/man/nvme_get_telemetry_max.2 @@ -0,0 +1,18 @@ +.TH "nvme_get_telemetry_max" 9 "nvme_get_telemetry_max" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_get_telemetry_max \- Get telemetry limits +.SH SYNOPSIS +.B "int" nvme_get_telemetry_max +.BI "(int fd " "," +.BI "enum nvme_telemetry_da *da " "," +.BI "size_t *max_data_tx " ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "da" 12 +On success return max supported data area +.IP "max_data_tx" 12 +On success set to max transfer chunk supported by the controller +.SH "RETURN" +The nvme command status if a response was received (see +\fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_hmac_alg.2 b/doc/man/nvme_hmac_alg.2 index 19d4a6d..9e02cc6 100644 --- a/doc/man/nvme_hmac_alg.2 +++ b/doc/man/nvme_hmac_alg.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_hmac_alg" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_hmac_alg" "September 2023" "API Manual" LINUX .SH NAME enum nvme_hmac_alg \- HMAC algorithm .SH SYNOPSIS diff --git a/doc/man/nvme_host_behavior_support.2 b/doc/man/nvme_host_behavior_support.2 index a883d01..f156365 100644 --- a/doc/man/nvme_host_behavior_support.2 +++ b/doc/man/nvme_host_behavior_support.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_host_behavior_support" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_host_behavior_support" "September 2023" "API Manual" LINUX .SH NAME enum nvme_host_behavior_support \- Enable Advanced Command .SH SYNOPSIS diff --git a/doc/man/nvme_host_get_dhchap_key.2 b/doc/man/nvme_host_get_dhchap_key.2 index 8b428bc..0256658 100644 --- a/doc/man/nvme_host_get_dhchap_key.2 +++ b/doc/man/nvme_host_get_dhchap_key.2 @@ -1,4 +1,4 @@ -.TH "nvme_host_get_dhchap_key" 9 "nvme_host_get_dhchap_key" "June 2023" "libnvme API manual" LINUX +.TH "nvme_host_get_dhchap_key" 9 "nvme_host_get_dhchap_key" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_host_get_dhchap_key \- Return host key .SH SYNOPSIS diff --git a/doc/man/nvme_host_get_hostid.2 b/doc/man/nvme_host_get_hostid.2 index 0c6f6dd..506bcce 100644 --- a/doc/man/nvme_host_get_hostid.2 +++ b/doc/man/nvme_host_get_hostid.2 @@ -1,4 +1,4 @@ -.TH "nvme_host_get_hostid" 9 "nvme_host_get_hostid" "June 2023" "libnvme API manual" LINUX +.TH "nvme_host_get_hostid" 9 "nvme_host_get_hostid" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_host_get_hostid \- Host ID of an nvme_host_t object .SH SYNOPSIS diff --git a/doc/man/nvme_host_get_hostnqn.2 b/doc/man/nvme_host_get_hostnqn.2 index 93b6a91..32388f2 100644 --- a/doc/man/nvme_host_get_hostnqn.2 +++ b/doc/man/nvme_host_get_hostnqn.2 @@ -1,4 +1,4 @@ -.TH "nvme_host_get_hostnqn" 9 "nvme_host_get_hostnqn" "June 2023" "libnvme API manual" LINUX +.TH "nvme_host_get_hostnqn" 9 "nvme_host_get_hostnqn" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_host_get_hostnqn \- Host NQN of an nvme_host_t object .SH SYNOPSIS diff --git a/doc/man/nvme_host_get_hostsymname.2 b/doc/man/nvme_host_get_hostsymname.2 index 399eca9..8e6f6b8 100644 --- a/doc/man/nvme_host_get_hostsymname.2 +++ b/doc/man/nvme_host_get_hostsymname.2 @@ -1,4 +1,4 @@ -.TH "nvme_host_get_hostsymname" 9 "nvme_host_get_hostsymname" "June 2023" "libnvme API manual" LINUX +.TH "nvme_host_get_hostsymname" 9 "nvme_host_get_hostsymname" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_host_get_hostsymname \- Get the host's symbolic name .SH SYNOPSIS diff --git a/doc/man/nvme_host_get_root.2 b/doc/man/nvme_host_get_root.2 index 35102a7..fd271bd 100644 --- a/doc/man/nvme_host_get_root.2 +++ b/doc/man/nvme_host_get_root.2 @@ -1,4 +1,4 @@ -.TH "nvme_host_get_root" 9 "nvme_host_get_root" "June 2023" "libnvme API manual" LINUX +.TH "nvme_host_get_root" 9 "nvme_host_get_root" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_host_get_root \- Returns nvme_root_t object .SH SYNOPSIS diff --git a/doc/man/nvme_host_is_pdc_enabled.2 b/doc/man/nvme_host_is_pdc_enabled.2 index f76f290..dd380a9 100644 --- a/doc/man/nvme_host_is_pdc_enabled.2 +++ b/doc/man/nvme_host_is_pdc_enabled.2 @@ -1,4 +1,4 @@ -.TH "nvme_host_is_pdc_enabled" 9 "nvme_host_is_pdc_enabled" "June 2023" "libnvme API manual" LINUX +.TH "nvme_host_is_pdc_enabled" 9 "nvme_host_is_pdc_enabled" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_host_is_pdc_enabled \- Is Persistenct Discovery Controller enabled .SH SYNOPSIS diff --git a/doc/man/nvme_host_mem_buf_attrs.2 b/doc/man/nvme_host_mem_buf_attrs.2 index 624d189..361028d 100644 --- a/doc/man/nvme_host_mem_buf_attrs.2 +++ b/doc/man/nvme_host_mem_buf_attrs.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_host_mem_buf_attrs" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_host_mem_buf_attrs" "September 2023" "API Manual" LINUX .SH NAME struct nvme_host_mem_buf_attrs \- Host Memory Buffer - Attributes Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_host_metadata.2 b/doc/man/nvme_host_metadata.2 index f7b7d9e..049359a 100644 --- a/doc/man/nvme_host_metadata.2 +++ b/doc/man/nvme_host_metadata.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_host_metadata" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_host_metadata" "September 2023" "API Manual" LINUX .SH NAME struct nvme_host_metadata \- Host Metadata Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_host_release_fds.2 b/doc/man/nvme_host_release_fds.2 new file mode 100644 index 0000000..a5cfcd0 --- /dev/null +++ b/doc/man/nvme_host_release_fds.2 @@ -0,0 +1,13 @@ +.TH "nvme_host_release_fds" 9 "nvme_host_release_fds" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_host_release_fds \- Close all opened file descriptors under host +.SH SYNOPSIS +.B "void" nvme_host_release_fds +.BI "(struct nvme_host *h " ");" +.SH ARGUMENTS +.IP "h" 12 +nvme_host_t object +.SH "DESCRIPTION" +Controller and Namespace objects cache the file descriptors +of opened nvme devices. This API can be used to close and +clear all cached fds under this host. diff --git a/doc/man/nvme_host_set_dhchap_key.2 b/doc/man/nvme_host_set_dhchap_key.2 index c453841..2fee1fc 100644 --- a/doc/man/nvme_host_set_dhchap_key.2 +++ b/doc/man/nvme_host_set_dhchap_key.2 @@ -1,4 +1,4 @@ -.TH "nvme_host_set_dhchap_key" 9 "nvme_host_set_dhchap_key" "June 2023" "libnvme API manual" LINUX +.TH "nvme_host_set_dhchap_key" 9 "nvme_host_set_dhchap_key" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_host_set_dhchap_key \- set host key .SH SYNOPSIS diff --git a/doc/man/nvme_host_set_hostsymname.2 b/doc/man/nvme_host_set_hostsymname.2 index 01bdd94..21b92c6 100644 --- a/doc/man/nvme_host_set_hostsymname.2 +++ b/doc/man/nvme_host_set_hostsymname.2 @@ -1,4 +1,4 @@ -.TH "nvme_host_set_hostsymname" 9 "nvme_host_set_hostsymname" "June 2023" "libnvme API manual" LINUX +.TH "nvme_host_set_hostsymname" 9 "nvme_host_set_hostsymname" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_host_set_hostsymname \- Set the host's symbolic name .SH SYNOPSIS diff --git a/doc/man/nvme_host_set_pdc_enabled.2 b/doc/man/nvme_host_set_pdc_enabled.2 index ed512be..b378883 100644 --- a/doc/man/nvme_host_set_pdc_enabled.2 +++ b/doc/man/nvme_host_set_pdc_enabled.2 @@ -1,4 +1,4 @@ -.TH "nvme_host_set_pdc_enabled" 9 "nvme_host_set_pdc_enabled" "June 2023" "libnvme API manual" LINUX +.TH "nvme_host_set_pdc_enabled" 9 "nvme_host_set_pdc_enabled" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_host_set_pdc_enabled \- Set Persistent Discovery Controller flag .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl.2 b/doc/man/nvme_id_ctrl.2 index 664ebd3..04b4c90 100644 --- a/doc/man/nvme_id_ctrl.2 +++ b/doc/man/nvme_id_ctrl.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_ctrl" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_ctrl" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_ctrl \- Identify Controller data structure .SH SYNOPSIS @@ -168,7 +168,9 @@ struct nvme_id_ctrl { .br .BI " __le32 maxcna;" .br -.BI " __u8 rsvd564[204];" +.BI " __le32 oaqd;" +.br +.BI " __u8 rsvd568[200];" .br .BI " char subnqn[NVME_NQN_LENGTH];" .br @@ -469,7 +471,11 @@ controller in the Domain. Maximum I/O Controller Namespace Attachments indicates the maximum number of namespaces that are allowed to be attached to this I/O controller. -.IP "rsvd564" 12 +.IP "oaqd" 12 +Optimal Aggregated Queue Depth indicates the recommended maximum +total number of outstanding I/O commands across all I/O queues +on the controller for optimal operation. +.IP "rsvd568" 12 Reserved .IP "subnqn" 12 NVM Subsystem NVMe Qualified Name, UTF-8 null terminated string diff --git a/doc/man/nvme_id_ctrl_anacap.2 b/doc/man/nvme_id_ctrl_anacap.2 index abe0dc8..cdad1f5 100644 --- a/doc/man/nvme_id_ctrl_anacap.2 +++ b/doc/man/nvme_id_ctrl_anacap.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_anacap" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_anacap" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_anacap \- This field indicates the capabilities associated with Asymmetric Namespace Access Reporting. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_apsta.2 b/doc/man/nvme_id_ctrl_apsta.2 index 342e66a..3ee6e1a 100644 --- a/doc/man/nvme_id_ctrl_apsta.2 +++ b/doc/man/nvme_id_ctrl_apsta.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_apsta" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_apsta" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_apsta \- Flags indicating the attributes of the autonomous power state transition feature. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_avscc.2 b/doc/man/nvme_id_ctrl_avscc.2 index b5995fc..36a19a7 100644 --- a/doc/man/nvme_id_ctrl_avscc.2 +++ b/doc/man/nvme_id_ctrl_avscc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_avscc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_avscc" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_avscc \- Flags indicating the configuration settings for Admin Vendor Specific command handling. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_cmic.2 b/doc/man/nvme_id_ctrl_cmic.2 index 6ec3467..fff47c9 100644 --- a/doc/man/nvme_id_ctrl_cmic.2 +++ b/doc/man/nvme_id_ctrl_cmic.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_cmic" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_cmic" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_cmic \- Controller Multipath IO and Namespace Sharing Capabilities of the controller and NVM subsystem. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_cntrltype.2 b/doc/man/nvme_id_ctrl_cntrltype.2 index 8f3898c..c99b156 100644 --- a/doc/man/nvme_id_ctrl_cntrltype.2 +++ b/doc/man/nvme_id_ctrl_cntrltype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_cntrltype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_cntrltype" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_cntrltype \- Controller types .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_cqes.2 b/doc/man/nvme_id_ctrl_cqes.2 index af5ec84..a7ba09b 100644 --- a/doc/man/nvme_id_ctrl_cqes.2 +++ b/doc/man/nvme_id_ctrl_cqes.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_cqes" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_cqes" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_cqes \- Defines the required and maximum Completion Queue entry size when using the NVM Command Set. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_ctratt.2 b/doc/man/nvme_id_ctrl_ctratt.2 index 92590f9..6bfdc8b 100644 --- a/doc/man/nvme_id_ctrl_ctratt.2 +++ b/doc/man/nvme_id_ctrl_ctratt.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_ctratt" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_ctratt" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_ctratt \- Controller attributes .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_dctype.2 b/doc/man/nvme_id_ctrl_dctype.2 index edd5eb4..c3471fe 100644 --- a/doc/man/nvme_id_ctrl_dctype.2 +++ b/doc/man/nvme_id_ctrl_dctype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_dctype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_dctype" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_dctype \- Discovery Controller types .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_dsto.2 b/doc/man/nvme_id_ctrl_dsto.2 index d179317..260e94c 100644 --- a/doc/man/nvme_id_ctrl_dsto.2 +++ b/doc/man/nvme_id_ctrl_dsto.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_dsto" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_dsto" "September 2023" "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 diff --git a/doc/man/nvme_id_ctrl_fcatt.2 b/doc/man/nvme_id_ctrl_fcatt.2 index 9a610e5..1765ea8 100644 --- a/doc/man/nvme_id_ctrl_fcatt.2 +++ b/doc/man/nvme_id_ctrl_fcatt.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_fcatt" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_fcatt" "September 2023" "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 diff --git a/doc/man/nvme_id_ctrl_fna.2 b/doc/man/nvme_id_ctrl_fna.2 index 4dab325..6ce858a 100644 --- a/doc/man/nvme_id_ctrl_fna.2 +++ b/doc/man/nvme_id_ctrl_fna.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_fna" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_fna" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_fna \- This field indicates attributes for the Format NVM command. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_frmw.2 b/doc/man/nvme_id_ctrl_frmw.2 index f4dad4d..124a13f 100644 --- a/doc/man/nvme_id_ctrl_frmw.2 +++ b/doc/man/nvme_id_ctrl_frmw.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_frmw" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_frmw" "September 2023" "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 diff --git a/doc/man/nvme_id_ctrl_fuses.2 b/doc/man/nvme_id_ctrl_fuses.2 index e34fa04..d36a8b9 100644 --- a/doc/man/nvme_id_ctrl_fuses.2 +++ b/doc/man/nvme_id_ctrl_fuses.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_fuses" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_fuses" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_fuses \- This field indicates the fused operations that the controller supports. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_hctm.2 b/doc/man/nvme_id_ctrl_hctm.2 index c4e549f..6588903 100644 --- a/doc/man/nvme_id_ctrl_hctm.2 +++ b/doc/man/nvme_id_ctrl_hctm.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_hctm" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_hctm" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_hctm \- Flags indicate the attributes of the host controlled thermal management feature .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_lpa.2 b/doc/man/nvme_id_ctrl_lpa.2 index 5c6cc4b..0790acc 100644 --- a/doc/man/nvme_id_ctrl_lpa.2 +++ b/doc/man/nvme_id_ctrl_lpa.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_lpa" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_lpa" "September 2023" "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 diff --git a/doc/man/nvme_id_ctrl_mec.2 b/doc/man/nvme_id_ctrl_mec.2 index 68875bb..7729857 100644 --- a/doc/man/nvme_id_ctrl_mec.2 +++ b/doc/man/nvme_id_ctrl_mec.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_mec" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_mec" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_mec \- Flags indicating the capabilities of the Management Endpoint in the Controller, &struct nvme_id_ctrl.mec. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_nvm.2 b/doc/man/nvme_id_ctrl_nvm.2 index 2611957..9c9eb99 100644 --- a/doc/man/nvme_id_ctrl_nvm.2 +++ b/doc/man/nvme_id_ctrl_nvm.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_ctrl_nvm" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_ctrl_nvm" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_ctrl_nvm \- I/O Command Set Specific Identify Controller data structure .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_nvmsr.2 b/doc/man/nvme_id_ctrl_nvmsr.2 index 2effe80..851d776 100644 --- a/doc/man/nvme_id_ctrl_nvmsr.2 +++ b/doc/man/nvme_id_ctrl_nvmsr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_nvmsr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_nvmsr" "September 2023" "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 diff --git a/doc/man/nvme_id_ctrl_nvscc.2 b/doc/man/nvme_id_ctrl_nvscc.2 index 0b3a3f6..2f3652c 100644 --- a/doc/man/nvme_id_ctrl_nvscc.2 +++ b/doc/man/nvme_id_ctrl_nvscc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_nvscc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_nvscc" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_nvscc \- This field indicates the configuration settings for NVM Vendor Specific command handling. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_nwpc.2 b/doc/man/nvme_id_ctrl_nwpc.2 index 012f34b..2ea248e 100644 --- a/doc/man/nvme_id_ctrl_nwpc.2 +++ b/doc/man/nvme_id_ctrl_nwpc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_nwpc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_nwpc" "September 2023" "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 diff --git a/doc/man/nvme_id_ctrl_oacs.2 b/doc/man/nvme_id_ctrl_oacs.2 index a151fb2..8372a7a 100644 --- a/doc/man/nvme_id_ctrl_oacs.2 +++ b/doc/man/nvme_id_ctrl_oacs.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_oacs" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_oacs" "September 2023" "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 diff --git a/doc/man/nvme_id_ctrl_oaes.2 b/doc/man/nvme_id_ctrl_oaes.2 index dff5e29..6892486 100644 --- a/doc/man/nvme_id_ctrl_oaes.2 +++ b/doc/man/nvme_id_ctrl_oaes.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_oaes" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_oaes" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_oaes \- Optional Asynchronous Events Supported .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_ofcs.2 b/doc/man/nvme_id_ctrl_ofcs.2 index b83606e..2d83cc3 100644 --- a/doc/man/nvme_id_ctrl_ofcs.2 +++ b/doc/man/nvme_id_ctrl_ofcs.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_ofcs" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_ofcs" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_ofcs \- Indicate whether the controller supports optional fabric commands. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_oncs.2 b/doc/man/nvme_id_ctrl_oncs.2 index d51e63f..0d9c295 100644 --- a/doc/man/nvme_id_ctrl_oncs.2 +++ b/doc/man/nvme_id_ctrl_oncs.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_oncs" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_oncs" "September 2023" "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 diff --git a/doc/man/nvme_id_ctrl_rpmbs.2 b/doc/man/nvme_id_ctrl_rpmbs.2 index 169c457..5d84e3f 100644 --- a/doc/man/nvme_id_ctrl_rpmbs.2 +++ b/doc/man/nvme_id_ctrl_rpmbs.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_rpmbs" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_rpmbs" "September 2023" "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 diff --git a/doc/man/nvme_id_ctrl_sanicap.2 b/doc/man/nvme_id_ctrl_sanicap.2 index 7f09750..76aa56e 100644 --- a/doc/man/nvme_id_ctrl_sanicap.2 +++ b/doc/man/nvme_id_ctrl_sanicap.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_sanicap" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_sanicap" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_sanicap \- Indicates attributes for sanitize operations. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_sgls.2 b/doc/man/nvme_id_ctrl_sgls.2 index 444234a..5f432c6 100644 --- a/doc/man/nvme_id_ctrl_sgls.2 +++ b/doc/man/nvme_id_ctrl_sgls.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_sgls" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_sgls" "September 2023" "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 diff --git a/doc/man/nvme_id_ctrl_sqes.2 b/doc/man/nvme_id_ctrl_sqes.2 index 1fae8db..e74e16e 100644 --- a/doc/man/nvme_id_ctrl_sqes.2 +++ b/doc/man/nvme_id_ctrl_sqes.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_sqes" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_sqes" "September 2023" "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 diff --git a/doc/man/nvme_id_ctrl_vwc.2 b/doc/man/nvme_id_ctrl_vwc.2 index caf1f64..bdc1357 100644 --- a/doc/man/nvme_id_ctrl_vwc.2 +++ b/doc/man/nvme_id_ctrl_vwc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_vwc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_vwc" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ctrl_vwc \- Volatile write cache .SH SYNOPSIS diff --git a/doc/man/nvme_id_ctrl_vwci.2 b/doc/man/nvme_id_ctrl_vwci.2 index 0e9d8b1..e7f8ce3 100644 --- a/doc/man/nvme_id_ctrl_vwci.2 +++ b/doc/man/nvme_id_ctrl_vwci.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ctrl_vwci" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ctrl_vwci" "September 2023" "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 diff --git a/doc/man/nvme_id_directives.2 b/doc/man/nvme_id_directives.2 index ccbd468..f474b48 100644 --- a/doc/man/nvme_id_directives.2 +++ b/doc/man/nvme_id_directives.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_directives" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_directives" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_directives \- Identify Directive - Return Parameters Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_id_domain_attr.2 b/doc/man/nvme_id_domain_attr.2 index a3b55c0..d77c6a0 100644 --- a/doc/man/nvme_id_domain_attr.2 +++ b/doc/man/nvme_id_domain_attr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_domain_attr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_domain_attr" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_domain_attr \- Domain Attributes Entry .SH SYNOPSIS diff --git a/doc/man/nvme_id_domain_list.2 b/doc/man/nvme_id_domain_list.2 index cb9c2f9..58efbfc 100644 --- a/doc/man/nvme_id_domain_list.2 +++ b/doc/man/nvme_id_domain_list.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_domain_list" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_domain_list" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_domain_list \- Domain List .SH SYNOPSIS diff --git a/doc/man/nvme_id_endurance_group_list.2 b/doc/man/nvme_id_endurance_group_list.2 index 2285100..847b157 100644 --- a/doc/man/nvme_id_endurance_group_list.2 +++ b/doc/man/nvme_id_endurance_group_list.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_endurance_group_list" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_endurance_group_list" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_endurance_group_list \- Endurance Group List .SH SYNOPSIS diff --git a/doc/man/nvme_id_independent_id_ns.2 b/doc/man/nvme_id_independent_id_ns.2 index cc01f38..5a16efe 100644 --- a/doc/man/nvme_id_independent_id_ns.2 +++ b/doc/man/nvme_id_independent_id_ns.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_independent_id_ns" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_independent_id_ns" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_independent_id_ns \- Identify - I/O Command Set Independent Identify Namespace Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_id_iocs.2 b/doc/man/nvme_id_iocs.2 index 68d056a..aeaaeda 100644 --- a/doc/man/nvme_id_iocs.2 +++ b/doc/man/nvme_id_iocs.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_iocs" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_iocs" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_iocs \- NVMe Identify IO Command Set data structure .SH SYNOPSIS diff --git a/doc/man/nvme_id_ns.2 b/doc/man/nvme_id_ns.2 index 82d68d5..62e292b 100644 --- a/doc/man/nvme_id_ns.2 +++ b/doc/man/nvme_id_ns.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_ns" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_ns" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_ns \- Identify Namespace data structure .SH SYNOPSIS diff --git a/doc/man/nvme_id_ns_attr.2 b/doc/man/nvme_id_ns_attr.2 index 6401c8e..4b57f92 100644 --- a/doc/man/nvme_id_ns_attr.2 +++ b/doc/man/nvme_id_ns_attr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ns_attr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ns_attr" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ns_attr \- Specifies attributes of the namespace. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ns_dlfeat.2 b/doc/man/nvme_id_ns_dlfeat.2 index 93ff84c..d758b86 100644 --- a/doc/man/nvme_id_ns_dlfeat.2 +++ b/doc/man/nvme_id_ns_dlfeat.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ns_dlfeat" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ns_dlfeat" "September 2023" "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 diff --git a/doc/man/nvme_id_ns_dpc.2 b/doc/man/nvme_id_ns_dpc.2 index f9ec8f9..b0c8616 100644 --- a/doc/man/nvme_id_ns_dpc.2 +++ b/doc/man/nvme_id_ns_dpc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ns_dpc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ns_dpc" "September 2023" "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 diff --git a/doc/man/nvme_id_ns_dps.2 b/doc/man/nvme_id_ns_dps.2 index 11c20ac..9f6ec13 100644 --- a/doc/man/nvme_id_ns_dps.2 +++ b/doc/man/nvme_id_ns_dps.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ns_dps" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ns_dps" "September 2023" "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 diff --git a/doc/man/nvme_id_ns_flbas.2 b/doc/man/nvme_id_ns_flbas.2 index cc40af0..64503f8 100644 --- a/doc/man/nvme_id_ns_flbas.2 +++ b/doc/man/nvme_id_ns_flbas.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ns_flbas" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ns_flbas" "September 2023" "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 diff --git a/doc/man/nvme_id_ns_granularity_desc.2 b/doc/man/nvme_id_ns_granularity_desc.2 index 7e94e5d..7949309 100644 --- a/doc/man/nvme_id_ns_granularity_desc.2 +++ b/doc/man/nvme_id_ns_granularity_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_ns_granularity_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_ns_granularity_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_ns_granularity_desc \- Namespace Granularity Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_id_ns_granularity_list.2 b/doc/man/nvme_id_ns_granularity_list.2 index 7dfe503..e6ad00c 100644 --- a/doc/man/nvme_id_ns_granularity_list.2 +++ b/doc/man/nvme_id_ns_granularity_list.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_ns_granularity_list" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_ns_granularity_list" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_ns_granularity_list \- Namespace Granularity List .SH SYNOPSIS diff --git a/doc/man/nvme_id_ns_mc.2 b/doc/man/nvme_id_ns_mc.2 index 859d8d6..c2d51f4 100644 --- a/doc/man/nvme_id_ns_mc.2 +++ b/doc/man/nvme_id_ns_mc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ns_mc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ns_mc" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ns_mc \- This field indicates the capabilities for metadata. .SH SYNOPSIS diff --git a/doc/man/nvme_id_ns_nmic.2 b/doc/man/nvme_id_ns_nmic.2 index 1ef4a83..3a102c7 100644 --- a/doc/man/nvme_id_ns_nmic.2 +++ b/doc/man/nvme_id_ns_nmic.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ns_nmic" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ns_nmic" "September 2023" "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 diff --git a/doc/man/nvme_id_ns_rescap.2 b/doc/man/nvme_id_ns_rescap.2 index 77f5ee8..c29f25d 100644 --- a/doc/man/nvme_id_ns_rescap.2 +++ b/doc/man/nvme_id_ns_rescap.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_ns_rescap" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_ns_rescap" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_ns_rescap \- This field indicates the reservation capabilities of the namespace. .SH SYNOPSIS diff --git a/doc/man/nvme_id_nsfeat.2 b/doc/man/nvme_id_nsfeat.2 index 7d8a3a2..dd50297 100644 --- a/doc/man/nvme_id_nsfeat.2 +++ b/doc/man/nvme_id_nsfeat.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_nsfeat" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_nsfeat" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_nsfeat \- This field defines features of the namespace. .SH SYNOPSIS diff --git a/doc/man/nvme_id_nvmset_list.2 b/doc/man/nvme_id_nvmset_list.2 index 6a9f281..0d173be 100644 --- a/doc/man/nvme_id_nvmset_list.2 +++ b/doc/man/nvme_id_nvmset_list.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_nvmset_list" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_nvmset_list" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_nvmset_list \- NVM set list .SH SYNOPSIS diff --git a/doc/man/nvme_id_psd.2 b/doc/man/nvme_id_psd.2 index 7b23b4b..f4620e1 100644 --- a/doc/man/nvme_id_psd.2 +++ b/doc/man/nvme_id_psd.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_psd" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_psd" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_psd \- Power Management data structure .SH SYNOPSIS diff --git a/doc/man/nvme_id_uuid.2 b/doc/man/nvme_id_uuid.2 index 80ffdf6..66b1949 100644 --- a/doc/man/nvme_id_uuid.2 +++ b/doc/man/nvme_id_uuid.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_id_uuid" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_id_uuid" "September 2023" "API Manual" LINUX .SH NAME enum nvme_id_uuid \- Identifier Association .SH SYNOPSIS diff --git a/doc/man/nvme_id_uuid_list.2 b/doc/man/nvme_id_uuid_list.2 index 0983c18..f407c00 100644 --- a/doc/man/nvme_id_uuid_list.2 +++ b/doc/man/nvme_id_uuid_list.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_uuid_list" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_uuid_list" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_uuid_list \- UUID list .SH SYNOPSIS diff --git a/doc/man/nvme_id_uuid_list_entry.2 b/doc/man/nvme_id_uuid_list_entry.2 index 5debce4..8cc5eb1 100644 --- a/doc/man/nvme_id_uuid_list_entry.2 +++ b/doc/man/nvme_id_uuid_list_entry.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_id_uuid_list_entry" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_id_uuid_list_entry" "September 2023" "API Manual" LINUX .SH NAME struct nvme_id_uuid_list_entry \- UUID List Entry .SH SYNOPSIS diff --git a/doc/man/nvme_identify.2 b/doc/man/nvme_identify.2 index c3a4645..5b8ed8b 100644 --- a/doc/man/nvme_identify.2 +++ b/doc/man/nvme_identify.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify" 9 "nvme_identify" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify" 9 "nvme_identify" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify \- Send the NVMe Identify command .SH SYNOPSIS diff --git a/doc/man/nvme_identify_active_ns_list.2 b/doc/man/nvme_identify_active_ns_list.2 index d04827d..2a53392 100644 --- a/doc/man/nvme_identify_active_ns_list.2 +++ b/doc/man/nvme_identify_active_ns_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_active_ns_list" 9 "nvme_identify_active_ns_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_active_ns_list" 9 "nvme_identify_active_ns_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_active_ns_list \- Retrieves active namespaces id list .SH SYNOPSIS diff --git a/doc/man/nvme_identify_active_ns_list_csi.2 b/doc/man/nvme_identify_active_ns_list_csi.2 index 39c859d..cf39292 100644 --- a/doc/man/nvme_identify_active_ns_list_csi.2 +++ b/doc/man/nvme_identify_active_ns_list_csi.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_active_ns_list_csi" 9 "nvme_identify_active_ns_list_csi" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_active_ns_list_csi" 9 "nvme_identify_active_ns_list_csi" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_active_ns_list_csi \- Active namespace ID list associated with a specified I/O command set .SH SYNOPSIS diff --git a/doc/man/nvme_identify_allocated_ns.2 b/doc/man/nvme_identify_allocated_ns.2 index 7fe2ce7..b6b4771 100644 --- a/doc/man/nvme_identify_allocated_ns.2 +++ b/doc/man/nvme_identify_allocated_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_allocated_ns" 9 "nvme_identify_allocated_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_allocated_ns" 9 "nvme_identify_allocated_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_allocated_ns \- Same as nvme_identify_ns, but only for allocated namespaces .SH SYNOPSIS diff --git a/doc/man/nvme_identify_allocated_ns_list.2 b/doc/man/nvme_identify_allocated_ns_list.2 index 7540578..73da3ba 100644 --- a/doc/man/nvme_identify_allocated_ns_list.2 +++ b/doc/man/nvme_identify_allocated_ns_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_allocated_ns_list" 9 "nvme_identify_allocated_ns_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_allocated_ns_list" 9 "nvme_identify_allocated_ns_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_allocated_ns_list \- Retrieves allocated namespace id list .SH SYNOPSIS diff --git a/doc/man/nvme_identify_allocated_ns_list_csi.2 b/doc/man/nvme_identify_allocated_ns_list_csi.2 index 3f936f6..8637c7c 100644 --- a/doc/man/nvme_identify_allocated_ns_list_csi.2 +++ b/doc/man/nvme_identify_allocated_ns_list_csi.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_allocated_ns_list_csi" 9 "nvme_identify_allocated_ns_list_csi" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_allocated_ns_list_csi" 9 "nvme_identify_allocated_ns_list_csi" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_allocated_ns_list_csi \- Allocated namespace ID list associated with a specified I/O command set .SH SYNOPSIS diff --git a/doc/man/nvme_identify_cns.2 b/doc/man/nvme_identify_cns.2 index 7f2b02c..77e86bc 100644 --- a/doc/man/nvme_identify_cns.2 +++ b/doc/man/nvme_identify_cns.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_identify_cns" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_identify_cns" "September 2023" "API Manual" LINUX .SH NAME enum nvme_identify_cns \- Identify - CNS Values .SH SYNOPSIS diff --git a/doc/man/nvme_identify_ctrl.2 b/doc/man/nvme_identify_ctrl.2 index f1541f0..0e6c2bf 100644 --- a/doc/man/nvme_identify_ctrl.2 +++ b/doc/man/nvme_identify_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_ctrl" 9 "nvme_identify_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_ctrl" 9 "nvme_identify_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_ctrl \- Retrieves nvme identify controller .SH SYNOPSIS diff --git a/doc/man/nvme_identify_ctrl_csi.2 b/doc/man/nvme_identify_ctrl_csi.2 index c501497..ac834b6 100644 --- a/doc/man/nvme_identify_ctrl_csi.2 +++ b/doc/man/nvme_identify_ctrl_csi.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_ctrl_csi" 9 "nvme_identify_ctrl_csi" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_ctrl_csi" 9 "nvme_identify_ctrl_csi" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_ctrl_csi \- I/O command set specific Identify Controller data .SH SYNOPSIS diff --git a/doc/man/nvme_identify_ctrl_list.2 b/doc/man/nvme_identify_ctrl_list.2 index 16907a6..014d815 100644 --- a/doc/man/nvme_identify_ctrl_list.2 +++ b/doc/man/nvme_identify_ctrl_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_ctrl_list" 9 "nvme_identify_ctrl_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_ctrl_list" 9 "nvme_identify_ctrl_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_ctrl_list \- Retrieves identify controller list .SH SYNOPSIS diff --git a/doc/man/nvme_identify_domain_list.2 b/doc/man/nvme_identify_domain_list.2 index c6eaa03..e8d6f64 100644 --- a/doc/man/nvme_identify_domain_list.2 +++ b/doc/man/nvme_identify_domain_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_domain_list" 9 "nvme_identify_domain_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_domain_list" 9 "nvme_identify_domain_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_domain_list \- Domain list data .SH SYNOPSIS diff --git a/doc/man/nvme_identify_endurance_group_list.2 b/doc/man/nvme_identify_endurance_group_list.2 index 575b477..da5d7dd 100644 --- a/doc/man/nvme_identify_endurance_group_list.2 +++ b/doc/man/nvme_identify_endurance_group_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_endurance_group_list" 9 "nvme_identify_endurance_group_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_endurance_group_list" 9 "nvme_identify_endurance_group_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_endurance_group_list \- Endurance group list data .SH SYNOPSIS diff --git a/doc/man/nvme_identify_independent_identify_ns.2 b/doc/man/nvme_identify_independent_identify_ns.2 index 0863437..8724066 100644 --- a/doc/man/nvme_identify_independent_identify_ns.2 +++ b/doc/man/nvme_identify_independent_identify_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_independent_identify_ns" 9 "nvme_identify_independent_identify_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_independent_identify_ns" 9 "nvme_identify_independent_identify_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_independent_identify_ns \- I/O command set independent Identify namespace data .SH SYNOPSIS diff --git a/doc/man/nvme_identify_iocs.2 b/doc/man/nvme_identify_iocs.2 index 57db606..1684dc2 100644 --- a/doc/man/nvme_identify_iocs.2 +++ b/doc/man/nvme_identify_iocs.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_iocs" 9 "nvme_identify_iocs" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_iocs" 9 "nvme_identify_iocs" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_iocs \- I/O command set data structure .SH SYNOPSIS diff --git a/doc/man/nvme_identify_iocs_ns_csi_user_data_format.2 b/doc/man/nvme_identify_iocs_ns_csi_user_data_format.2 index b1a4caa..a185ab3 100644 --- a/doc/man/nvme_identify_iocs_ns_csi_user_data_format.2 +++ b/doc/man/nvme_identify_iocs_ns_csi_user_data_format.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_iocs_ns_csi_user_data_format" 9 "nvme_identify_iocs_ns_csi_user_data_format" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_iocs_ns_csi_user_data_format" 9 "nvme_identify_iocs_ns_csi_user_data_format" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_iocs_ns_csi_user_data_format \- Identify I/O command set namespace data structure .SH SYNOPSIS diff --git a/doc/man/nvme_identify_ns.2 b/doc/man/nvme_identify_ns.2 index c1c12de..500c1e0 100644 --- a/doc/man/nvme_identify_ns.2 +++ b/doc/man/nvme_identify_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_ns" 9 "nvme_identify_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_ns" 9 "nvme_identify_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_ns \- Retrieves nvme identify namespace .SH SYNOPSIS diff --git a/doc/man/nvme_identify_ns_csi.2 b/doc/man/nvme_identify_ns_csi.2 index ad4e743..8b114a4 100644 --- a/doc/man/nvme_identify_ns_csi.2 +++ b/doc/man/nvme_identify_ns_csi.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_ns_csi" 9 "nvme_identify_ns_csi" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_ns_csi" 9 "nvme_identify_ns_csi" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_ns_csi \- I/O command set specific identify namespace data .SH SYNOPSIS diff --git a/doc/man/nvme_identify_ns_csi_user_data_format.2 b/doc/man/nvme_identify_ns_csi_user_data_format.2 index 2368d39..bab8432 100644 --- a/doc/man/nvme_identify_ns_csi_user_data_format.2 +++ b/doc/man/nvme_identify_ns_csi_user_data_format.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_ns_csi_user_data_format" 9 "nvme_identify_ns_csi_user_data_format" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_ns_csi_user_data_format" 9 "nvme_identify_ns_csi_user_data_format" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_ns_csi_user_data_format \- Identify namespace user data format .SH SYNOPSIS diff --git a/doc/man/nvme_identify_ns_descs.2 b/doc/man/nvme_identify_ns_descs.2 index 7c68564..5c5118c 100644 --- a/doc/man/nvme_identify_ns_descs.2 +++ b/doc/man/nvme_identify_ns_descs.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_ns_descs" 9 "nvme_identify_ns_descs" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_ns_descs" 9 "nvme_identify_ns_descs" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_ns_descs \- Retrieves namespace descriptor list .SH SYNOPSIS diff --git a/doc/man/nvme_identify_ns_granularity.2 b/doc/man/nvme_identify_ns_granularity.2 index eecd5ac..f0ad7f3 100644 --- a/doc/man/nvme_identify_ns_granularity.2 +++ b/doc/man/nvme_identify_ns_granularity.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_ns_granularity" 9 "nvme_identify_ns_granularity" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_ns_granularity" 9 "nvme_identify_ns_granularity" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_ns_granularity \- Retrieves namespace granularity identification .SH SYNOPSIS diff --git a/doc/man/nvme_identify_nsid_ctrl_list.2 b/doc/man/nvme_identify_nsid_ctrl_list.2 index eb6492b..230c831 100644 --- a/doc/man/nvme_identify_nsid_ctrl_list.2 +++ b/doc/man/nvme_identify_nsid_ctrl_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_nsid_ctrl_list" 9 "nvme_identify_nsid_ctrl_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_nsid_ctrl_list" 9 "nvme_identify_nsid_ctrl_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_nsid_ctrl_list \- Retrieves controller list attached to an nsid .SH SYNOPSIS diff --git a/doc/man/nvme_identify_nvmset_list.2 b/doc/man/nvme_identify_nvmset_list.2 index f8e90c5..7fd5015 100644 --- a/doc/man/nvme_identify_nvmset_list.2 +++ b/doc/man/nvme_identify_nvmset_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_nvmset_list" 9 "nvme_identify_nvmset_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_nvmset_list" 9 "nvme_identify_nvmset_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_nvmset_list \- Retrieves NVM Set List .SH SYNOPSIS diff --git a/doc/man/nvme_identify_primary_ctrl.2 b/doc/man/nvme_identify_primary_ctrl.2 index 7be8839..cc192a2 100644 --- a/doc/man/nvme_identify_primary_ctrl.2 +++ b/doc/man/nvme_identify_primary_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_primary_ctrl" 9 "nvme_identify_primary_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_primary_ctrl" 9 "nvme_identify_primary_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_primary_ctrl \- Retrieve NVMe Primary Controller identification .SH SYNOPSIS diff --git a/doc/man/nvme_identify_secondary_ctrl_list.2 b/doc/man/nvme_identify_secondary_ctrl_list.2 index 2778705..00b2af8 100644 --- a/doc/man/nvme_identify_secondary_ctrl_list.2 +++ b/doc/man/nvme_identify_secondary_ctrl_list.2 @@ -1,17 +1,14 @@ -.TH "nvme_identify_secondary_ctrl_list" 9 "nvme_identify_secondary_ctrl_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_secondary_ctrl_list" 9 "nvme_identify_secondary_ctrl_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_secondary_ctrl_list \- Retrieves secondary controller list .SH SYNOPSIS .B "int" nvme_identify_secondary_ctrl_list .BI "(int fd " "," -.BI "__u32 nsid " "," .BI "__u16 cntid " "," .BI "struct nvme_secondary_ctrl_list *sc_list " ");" .SH ARGUMENTS .IP "fd" 12 File descriptor of nvme device -.IP "nsid" 12 -Namespace identifier .IP "cntid" 12 Return controllers starting at this identifier .IP "sc_list" 12 diff --git a/doc/man/nvme_identify_uuid.2 b/doc/man/nvme_identify_uuid.2 index e150845..523b4b9 100644 --- a/doc/man/nvme_identify_uuid.2 +++ b/doc/man/nvme_identify_uuid.2 @@ -1,4 +1,4 @@ -.TH "nvme_identify_uuid" 9 "nvme_identify_uuid" "June 2023" "libnvme API manual" LINUX +.TH "nvme_identify_uuid" 9 "nvme_identify_uuid" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_identify_uuid \- Retrieves device's UUIDs .SH SYNOPSIS diff --git a/doc/man/nvme_init_copy_range.2 b/doc/man/nvme_init_copy_range.2 index f47e1f5..015128b 100644 --- a/doc/man/nvme_init_copy_range.2 +++ b/doc/man/nvme_init_copy_range.2 @@ -1,4 +1,4 @@ -.TH "nvme_init_copy_range" 9 "nvme_init_copy_range" "June 2023" "libnvme API manual" LINUX +.TH "nvme_init_copy_range" 9 "nvme_init_copy_range" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_init_copy_range \- Constructs a copy range structure .SH SYNOPSIS diff --git a/doc/man/nvme_init_copy_range_f1.2 b/doc/man/nvme_init_copy_range_f1.2 index 5a981ce..3046b51 100644 --- a/doc/man/nvme_init_copy_range_f1.2 +++ b/doc/man/nvme_init_copy_range_f1.2 @@ -1,4 +1,4 @@ -.TH "nvme_init_copy_range_f1" 9 "nvme_init_copy_range_f1" "June 2023" "libnvme API manual" LINUX +.TH "nvme_init_copy_range_f1" 9 "nvme_init_copy_range_f1" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_init_copy_range_f1 \- Constructs a copy range f1 structure .SH SYNOPSIS diff --git a/doc/man/nvme_init_ctrl.2 b/doc/man/nvme_init_ctrl.2 index 44739a9..2510c4b 100644 --- a/doc/man/nvme_init_ctrl.2 +++ b/doc/man/nvme_init_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_init_ctrl" 9 "nvme_init_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_init_ctrl" 9 "nvme_init_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_init_ctrl \- Initialize nvme_ctrl_t object for an existing controller. .SH SYNOPSIS diff --git a/doc/man/nvme_init_ctrl_list.2 b/doc/man/nvme_init_ctrl_list.2 index 5ba6df6..34a5627 100644 --- a/doc/man/nvme_init_ctrl_list.2 +++ b/doc/man/nvme_init_ctrl_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_init_ctrl_list" 9 "nvme_init_ctrl_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_init_ctrl_list" 9 "nvme_init_ctrl_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_init_ctrl_list \- Initialize an nvme_ctrl_list structure from an array. .SH SYNOPSIS diff --git a/doc/man/nvme_init_dsm_range.2 b/doc/man/nvme_init_dsm_range.2 index b6cf225..5d90d02 100644 --- a/doc/man/nvme_init_dsm_range.2 +++ b/doc/man/nvme_init_dsm_range.2 @@ -1,4 +1,4 @@ -.TH "nvme_init_dsm_range" 9 "nvme_init_dsm_range" "June 2023" "libnvme API manual" LINUX +.TH "nvme_init_dsm_range" 9 "nvme_init_dsm_range" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_init_dsm_range \- Constructs a data set range structure .SH SYNOPSIS diff --git a/doc/man/nvme_init_logging.2 b/doc/man/nvme_init_logging.2 index d47c379..4a045a4 100644 --- a/doc/man/nvme_init_logging.2 +++ b/doc/man/nvme_init_logging.2 @@ -1,4 +1,4 @@ -.TH "nvme_init_logging" 9 "nvme_init_logging" "June 2023" "libnvme API manual" LINUX +.TH "nvme_init_logging" 9 "nvme_init_logging" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_init_logging \- Initialize logging .SH SYNOPSIS diff --git a/doc/man/nvme_insert_tls_key.2 b/doc/man/nvme_insert_tls_key.2 index f0614bf..aa0448d 100644 --- a/doc/man/nvme_insert_tls_key.2 +++ b/doc/man/nvme_insert_tls_key.2 @@ -1,4 +1,4 @@ -.TH "nvme_insert_tls_key" 9 "nvme_insert_tls_key" "June 2023" "libnvme API manual" LINUX +.TH "nvme_insert_tls_key" 9 "nvme_insert_tls_key" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_insert_tls_key \- Derive and insert TLS key .SH SYNOPSIS diff --git a/doc/man/nvme_io.2 b/doc/man/nvme_io.2 index b4f2ca6..b2530ed 100644 --- a/doc/man/nvme_io.2 +++ b/doc/man/nvme_io.2 @@ -1,4 +1,4 @@ -.TH "nvme_io" 9 "nvme_io" "June 2023" "libnvme API manual" LINUX +.TH "nvme_io" 9 "nvme_io" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_io \- Submit an nvme user I/O command .SH SYNOPSIS diff --git a/doc/man/nvme_io_control_flags.2 b/doc/man/nvme_io_control_flags.2 index 04beddc..667ae7d 100644 --- a/doc/man/nvme_io_control_flags.2 +++ b/doc/man/nvme_io_control_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_io_control_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_io_control_flags" "September 2023" "API Manual" LINUX .SH NAME enum nvme_io_control_flags \- I/O control flags .SH SYNOPSIS diff --git a/doc/man/nvme_io_dsm_flags.2 b/doc/man/nvme_io_dsm_flags.2 index 575faa4..c8b52d7 100644 --- a/doc/man/nvme_io_dsm_flags.2 +++ b/doc/man/nvme_io_dsm_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_io_dsm_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_io_dsm_flags" "September 2023" "API Manual" LINUX .SH NAME enum nvme_io_dsm_flags \- Dataset Management flags .SH SYNOPSIS diff --git a/doc/man/nvme_io_mgmt_recv.2 b/doc/man/nvme_io_mgmt_recv.2 index 00ab695..5147327 100644 --- a/doc/man/nvme_io_mgmt_recv.2 +++ b/doc/man/nvme_io_mgmt_recv.2 @@ -1,4 +1,4 @@ -.TH "nvme_io_mgmt_recv" 9 "nvme_io_mgmt_recv" "June 2023" "libnvme API manual" LINUX +.TH "nvme_io_mgmt_recv" 9 "nvme_io_mgmt_recv" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_io_mgmt_recv \- I/O Management Receive command .SH SYNOPSIS diff --git a/doc/man/nvme_io_mgmt_recv_mo.2 b/doc/man/nvme_io_mgmt_recv_mo.2 index 07bb97b..bf313a0 100644 --- a/doc/man/nvme_io_mgmt_recv_mo.2 +++ b/doc/man/nvme_io_mgmt_recv_mo.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_io_mgmt_recv_mo" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_io_mgmt_recv_mo" "September 2023" "API Manual" LINUX .SH NAME enum nvme_io_mgmt_recv_mo \- I/O Management Receive - Management Operation .SH SYNOPSIS diff --git a/doc/man/nvme_io_mgmt_send.2 b/doc/man/nvme_io_mgmt_send.2 index a1e1727..d7d8c42 100644 --- a/doc/man/nvme_io_mgmt_send.2 +++ b/doc/man/nvme_io_mgmt_send.2 @@ -1,4 +1,4 @@ -.TH "nvme_io_mgmt_send" 9 "nvme_io_mgmt_send" "June 2023" "libnvme API manual" LINUX +.TH "nvme_io_mgmt_send" 9 "nvme_io_mgmt_send" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_io_mgmt_send \- I/O Management Send command .SH SYNOPSIS diff --git a/doc/man/nvme_io_mgmt_send_mo.2 b/doc/man/nvme_io_mgmt_send_mo.2 index df588ca..f88afc0 100644 --- a/doc/man/nvme_io_mgmt_send_mo.2 +++ b/doc/man/nvme_io_mgmt_send_mo.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_io_mgmt_send_mo" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_io_mgmt_send_mo" "September 2023" "API Manual" LINUX .SH NAME enum nvme_io_mgmt_send_mo \- I/O Management Send - Management Operation .SH SYNOPSIS diff --git a/doc/man/nvme_io_opcode.2 b/doc/man/nvme_io_opcode.2 index 3c4a995..c020257 100644 --- a/doc/man/nvme_io_opcode.2 +++ b/doc/man/nvme_io_opcode.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_io_opcode" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_io_opcode" "September 2023" "API Manual" LINUX .SH NAME enum nvme_io_opcode \- Opcodes for I/O Commands .SH SYNOPSIS diff --git a/doc/man/nvme_io_passthru.2 b/doc/man/nvme_io_passthru.2 index 7f9ab81..186f7c9 100644 --- a/doc/man/nvme_io_passthru.2 +++ b/doc/man/nvme_io_passthru.2 @@ -1,4 +1,4 @@ -.TH "nvme_io_passthru" 9 "nvme_io_passthru" "June 2023" "libnvme API manual" LINUX +.TH "nvme_io_passthru" 9 "nvme_io_passthru" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_io_passthru \- Submit an nvme io passthrough command .SH SYNOPSIS diff --git a/doc/man/nvme_io_passthru64.2 b/doc/man/nvme_io_passthru64.2 index 970c238..fd35e75 100644 --- a/doc/man/nvme_io_passthru64.2 +++ b/doc/man/nvme_io_passthru64.2 @@ -1,4 +1,4 @@ -.TH "nvme_io_passthru64" 9 "nvme_io_passthru64" "June 2023" "libnvme API manual" LINUX +.TH "nvme_io_passthru64" 9 "nvme_io_passthru64" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_io_passthru64 \- Submit an nvme io passthrough command .SH SYNOPSIS diff --git a/doc/man/nvme_is_64bit_reg.2 b/doc/man/nvme_is_64bit_reg.2 index 426274d..12d5b99 100644 --- a/doc/man/nvme_is_64bit_reg.2 +++ b/doc/man/nvme_is_64bit_reg.2 @@ -1,4 +1,4 @@ -.TH "nvme_is_64bit_reg" 9 "nvme_is_64bit_reg" "June 2023" "libnvme API manual" LINUX +.TH "nvme_is_64bit_reg" 9 "nvme_is_64bit_reg" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_is_64bit_reg \- Checks if offset of the controller register is a know 64bit value. .SH SYNOPSIS diff --git a/doc/man/nvme_lba_range_type.2 b/doc/man/nvme_lba_range_type.2 index 7a00145..7f002c5 100644 --- a/doc/man/nvme_lba_range_type.2 +++ b/doc/man/nvme_lba_range_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_lba_range_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_lba_range_type" "September 2023" "API Manual" LINUX .SH NAME struct nvme_lba_range_type \- LBA Range Type .SH SYNOPSIS diff --git a/doc/man/nvme_lba_range_type_entry.2 b/doc/man/nvme_lba_range_type_entry.2 index 6c8c883..32db9f7 100644 --- a/doc/man/nvme_lba_range_type_entry.2 +++ b/doc/man/nvme_lba_range_type_entry.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_lba_range_type_entry" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_lba_range_type_entry" "September 2023" "API Manual" LINUX .SH NAME struct nvme_lba_range_type_entry \- LBA Range Type - Data Structure Entry .SH SYNOPSIS diff --git a/doc/man/nvme_lba_rd.2 b/doc/man/nvme_lba_rd.2 index 3d75ee6..586c916 100644 --- a/doc/man/nvme_lba_rd.2 +++ b/doc/man/nvme_lba_rd.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_lba_rd" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_lba_rd" "September 2023" "API Manual" LINUX .SH NAME struct nvme_lba_rd \- LBA Range Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_lba_status.2 b/doc/man/nvme_lba_status.2 index ca60c7b..95ecadc 100644 --- a/doc/man/nvme_lba_status.2 +++ b/doc/man/nvme_lba_status.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_lba_status" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_lba_status" "September 2023" "API Manual" LINUX .SH NAME struct nvme_lba_status \- LBA Status Descriptor List .SH SYNOPSIS diff --git a/doc/man/nvme_lba_status_atype.2 b/doc/man/nvme_lba_status_atype.2 index 7d55382..6ab7814 100644 --- a/doc/man/nvme_lba_status_atype.2 +++ b/doc/man/nvme_lba_status_atype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_lba_status_atype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_lba_status_atype" "September 2023" "API Manual" LINUX .SH NAME enum nvme_lba_status_atype \- Potentially Unrecoverable LBAs .SH SYNOPSIS diff --git a/doc/man/nvme_lba_status_desc.2 b/doc/man/nvme_lba_status_desc.2 index 2457296..2ec502e 100644 --- a/doc/man/nvme_lba_status_desc.2 +++ b/doc/man/nvme_lba_status_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_lba_status_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_lba_status_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_lba_status_desc \- LBA Status Descriptor Entry .SH SYNOPSIS diff --git a/doc/man/nvme_lba_status_log.2 b/doc/man/nvme_lba_status_log.2 index 7c3339f..a6a6a61 100644 --- a/doc/man/nvme_lba_status_log.2 +++ b/doc/man/nvme_lba_status_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_lba_status_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_lba_status_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_lba_status_log \- LBA Status Information Log .SH SYNOPSIS diff --git a/doc/man/nvme_lbaf.2 b/doc/man/nvme_lbaf.2 index 620df2e..0a44099 100644 --- a/doc/man/nvme_lbaf.2 +++ b/doc/man/nvme_lbaf.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_lbaf" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_lbaf" "September 2023" "API Manual" LINUX .SH NAME struct nvme_lbaf \- LBA Format Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_lbaf_rp.2 b/doc/man/nvme_lbaf_rp.2 index 942c269..2c697bd 100644 --- a/doc/man/nvme_lbaf_rp.2 +++ b/doc/man/nvme_lbaf_rp.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_lbaf_rp" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_lbaf_rp" "September 2023" "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 diff --git a/doc/man/nvme_lbart.2 b/doc/man/nvme_lbart.2 index 1c6f66f..bfc15e6 100644 --- a/doc/man/nvme_lbart.2 +++ b/doc/man/nvme_lbart.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_lbart" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_lbart" "September 2023" "API Manual" LINUX .SH NAME enum nvme_lbart \- LBA Range Type - Data Structure Entry .SH SYNOPSIS diff --git a/doc/man/nvme_lbas_ns_element.2 b/doc/man/nvme_lbas_ns_element.2 index 6efab64..1127312 100644 --- a/doc/man/nvme_lbas_ns_element.2 +++ b/doc/man/nvme_lbas_ns_element.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_lbas_ns_element" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_lbas_ns_element" "September 2023" "API Manual" LINUX .SH NAME struct nvme_lbas_ns_element \- LBA Status Log Namespace Element .SH SYNOPSIS diff --git a/doc/man/nvme_lockdown.2 b/doc/man/nvme_lockdown.2 index 6a101a5..19e531b 100644 --- a/doc/man/nvme_lockdown.2 +++ b/doc/man/nvme_lockdown.2 @@ -1,4 +1,4 @@ -.TH "nvme_lockdown" 9 "nvme_lockdown" "June 2023" "libnvme API manual" LINUX +.TH "nvme_lockdown" 9 "nvme_lockdown" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_lockdown \- Issue lockdown command .SH SYNOPSIS diff --git a/doc/man/nvme_log_ana_lsp.2 b/doc/man/nvme_log_ana_lsp.2 index 9ccb3ef..3a68e7f 100644 --- a/doc/man/nvme_log_ana_lsp.2 +++ b/doc/man/nvme_log_ana_lsp.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_log_ana_lsp" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_log_ana_lsp" "September 2023" "API Manual" LINUX .SH NAME enum nvme_log_ana_lsp \- Asymmetric Namespace Access - Return Groups Only .SH SYNOPSIS diff --git a/doc/man/nvme_log_phy_rx_eom_action.2 b/doc/man/nvme_log_phy_rx_eom_action.2 new file mode 100644 index 0000000..55f5817 --- /dev/null +++ b/doc/man/nvme_log_phy_rx_eom_action.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 9 "enum nvme_log_phy_rx_eom_action" "September 2023" "API Manual" LINUX +.SH NAME +enum nvme_log_phy_rx_eom_action \- Physical Interface Receiver Eye Opening Measurement Action +.SH SYNOPSIS +enum nvme_log_phy_rx_eom_action { +.br +.BI " NVME_LOG_PHY_RX_EOM_READ" +, +.br +.br +.BI " NVME_LOG_PHY_RX_EOM_START_READ" +, +.br +.br +.BI " NVME_LOG_PHY_RX_EOM_ABORT_CLEAR" + +}; +.SH Constants +.IP "NVME_LOG_PHY_RX_EOM_READ" 12 +Read Log Data +.IP "NVME_LOG_PHY_RX_EOM_START_READ" 12 +Start Measurement and Read Log Data +.IP "NVME_LOG_PHY_RX_EOM_ABORT_CLEAR" 12 +Abort Measurement and Clear Log Data diff --git a/doc/man/nvme_log_phy_rx_eom_quality.2 b/doc/man/nvme_log_phy_rx_eom_quality.2 new file mode 100644 index 0000000..96774e8 --- /dev/null +++ b/doc/man/nvme_log_phy_rx_eom_quality.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 9 "enum nvme_log_phy_rx_eom_quality" "September 2023" "API Manual" LINUX +.SH NAME +enum nvme_log_phy_rx_eom_quality \- Physical Interface Receiver Eye Opening Measurement Quality +.SH SYNOPSIS +enum nvme_log_phy_rx_eom_quality { +.br +.BI " NVME_LOG_PHY_RX_EOM_GOOD" +, +.br +.br +.BI " NVME_LOG_PHY_RX_EOM_BETTER" +, +.br +.br +.BI " NVME_LOG_PHY_RX_EOM_BEST" + +}; +.SH Constants +.IP "NVME_LOG_PHY_RX_EOM_GOOD" 12 +<= Better Quality +.IP "NVME_LOG_PHY_RX_EOM_BETTER" 12 +<= Best Quality, >= Good Quality +.IP "NVME_LOG_PHY_RX_EOM_BEST" 12 +>= Better Quality diff --git a/doc/man/nvme_lookup_ctrl.2 b/doc/man/nvme_lookup_ctrl.2 index 410cf85..32ca459 100644 --- a/doc/man/nvme_lookup_ctrl.2 +++ b/doc/man/nvme_lookup_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_lookup_ctrl" 9 "nvme_lookup_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_lookup_ctrl" 9 "nvme_lookup_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_lookup_ctrl \- Lookup nvme_ctrl_t object .SH SYNOPSIS diff --git a/doc/man/nvme_lookup_host.2 b/doc/man/nvme_lookup_host.2 index ca85e6d..d8a46ae 100644 --- a/doc/man/nvme_lookup_host.2 +++ b/doc/man/nvme_lookup_host.2 @@ -1,4 +1,4 @@ -.TH "nvme_lookup_host" 9 "nvme_lookup_host" "June 2023" "libnvme API manual" LINUX +.TH "nvme_lookup_host" 9 "nvme_lookup_host" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_lookup_host \- Lookup nvme_host_t object .SH SYNOPSIS diff --git a/doc/man/nvme_lookup_key.2 b/doc/man/nvme_lookup_key.2 index e6d3665..2ff23aa 100644 --- a/doc/man/nvme_lookup_key.2 +++ b/doc/man/nvme_lookup_key.2 @@ -1,4 +1,4 @@ -.TH "nvme_lookup_key" 9 "nvme_lookup_key" "June 2023" "libnvme API manual" LINUX +.TH "nvme_lookup_key" 9 "nvme_lookup_key" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_lookup_key \- Lookup key serial number .SH SYNOPSIS diff --git a/doc/man/nvme_lookup_keyring.2 b/doc/man/nvme_lookup_keyring.2 index e2be918..7755151 100644 --- a/doc/man/nvme_lookup_keyring.2 +++ b/doc/man/nvme_lookup_keyring.2 @@ -1,4 +1,4 @@ -.TH "nvme_lookup_keyring" 9 "nvme_lookup_keyring" "June 2023" "libnvme API manual" LINUX +.TH "nvme_lookup_keyring" 9 "nvme_lookup_keyring" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_lookup_keyring \- Lookup keyring serial number .SH SYNOPSIS diff --git a/doc/man/nvme_lookup_subsystem.2 b/doc/man/nvme_lookup_subsystem.2 index a782a1e..f4cc95f 100644 --- a/doc/man/nvme_lookup_subsystem.2 +++ b/doc/man/nvme_lookup_subsystem.2 @@ -1,4 +1,4 @@ -.TH "nvme_lookup_subsystem" 9 "nvme_lookup_subsystem" "June 2023" "libnvme API manual" LINUX +.TH "nvme_lookup_subsystem" 9 "nvme_lookup_subsystem" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_lookup_subsystem \- Lookup nvme_subsystem_t object .SH SYNOPSIS diff --git a/doc/man/nvme_media_unit_config_desc.2 b/doc/man/nvme_media_unit_config_desc.2 index 79b0a6d..f61397d 100644 --- a/doc/man/nvme_media_unit_config_desc.2 +++ b/doc/man/nvme_media_unit_config_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_media_unit_config_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_media_unit_config_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_media_unit_config_desc \- Media Unit Configuration Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_media_unit_stat_desc.2 b/doc/man/nvme_media_unit_stat_desc.2 index d95df72..7206270 100644 --- a/doc/man/nvme_media_unit_stat_desc.2 +++ b/doc/man/nvme_media_unit_stat_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_media_unit_stat_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_media_unit_stat_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_media_unit_stat_desc \- Media Unit Status Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_media_unit_stat_log.2 b/doc/man/nvme_media_unit_stat_log.2 index 8493bff..a285f7d 100644 --- a/doc/man/nvme_media_unit_stat_log.2 +++ b/doc/man/nvme_media_unit_stat_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_media_unit_stat_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_media_unit_stat_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_media_unit_stat_log \- Media Unit Status .SH SYNOPSIS diff --git a/doc/man/nvme_metadata_element_desc.2 b/doc/man/nvme_metadata_element_desc.2 index 098b235..938cec9 100644 --- a/doc/man/nvme_metadata_element_desc.2 +++ b/doc/man/nvme_metadata_element_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_metadata_element_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_metadata_element_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_metadata_element_desc \- Metadata Element Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_admin_passthru.2 b/doc/man/nvme_mi_admin_admin_passthru.2 index e72e6f7..4916679 100644 --- a/doc/man/nvme_mi_admin_admin_passthru.2 +++ b/doc/man/nvme_mi_admin_admin_passthru.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_admin_passthru" 9 "nvme_mi_admin_admin_passthru" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_admin_passthru" 9 "nvme_mi_admin_admin_passthru" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_admin_passthru \- Submit an nvme admin passthrough command .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_format_nvm.2 b/doc/man/nvme_mi_admin_format_nvm.2 index b3862b1..4962fe9 100644 --- a/doc/man/nvme_mi_admin_format_nvm.2 +++ b/doc/man/nvme_mi_admin_format_nvm.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_format_nvm" 9 "nvme_mi_admin_format_nvm" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_format_nvm" 9 "nvme_mi_admin_format_nvm" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_format_nvm \- Format NVMe namespace .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_fw_commit.2 b/doc/man/nvme_mi_admin_fw_commit.2 index 30b536d..65033cc 100644 --- a/doc/man/nvme_mi_admin_fw_commit.2 +++ b/doc/man/nvme_mi_admin_fw_commit.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_fw_commit" 9 "nvme_mi_admin_fw_commit" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_fw_commit" 9 "nvme_mi_admin_fw_commit" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_fw_commit \- Commit firmware using the specified action .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_fw_download.2 b/doc/man/nvme_mi_admin_fw_download.2 index 2a87321..10b7aff 100644 --- a/doc/man/nvme_mi_admin_fw_download.2 +++ b/doc/man/nvme_mi_admin_fw_download.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_fw_download" 9 "nvme_mi_admin_fw_download" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_fw_download" 9 "nvme_mi_admin_fw_download" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_fw_download \- Download part or all of a firmware image to the controller .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_features_data.2 b/doc/man/nvme_mi_admin_get_features_data.2 index 7edf756..125873e 100644 --- a/doc/man/nvme_mi_admin_get_features_data.2 +++ b/doc/man/nvme_mi_admin_get_features_data.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_features_data" 9 "nvme_mi_admin_get_features_data" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_features_data" 9 "nvme_mi_admin_get_features_data" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_features_data \- Helper function for &nvme_mi_admin_get_features() .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log.2 b/doc/man/nvme_mi_admin_get_log.2 index 4b28da3..ca71147 100644 --- a/doc/man/nvme_mi_admin_get_log.2 +++ b/doc/man/nvme_mi_admin_get_log.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log" 9 "nvme_mi_admin_get_log" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log" 9 "nvme_mi_admin_get_log" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log \- Retrieve log page data from controller .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_ana.2 b/doc/man/nvme_mi_admin_get_log_ana.2 index 9f8739a..fde4b74 100644 --- a/doc/man/nvme_mi_admin_get_log_ana.2 +++ b/doc/man/nvme_mi_admin_get_log_ana.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_ana" 9 "nvme_mi_admin_get_log_ana" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_ana" 9 "nvme_mi_admin_get_log_ana" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_ana \- Retrieve Asymmetric Namespace Access log page .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_ana_groups.2 b/doc/man/nvme_mi_admin_get_log_ana_groups.2 index 820794b..72efdc4 100644 --- a/doc/man/nvme_mi_admin_get_log_ana_groups.2 +++ b/doc/man/nvme_mi_admin_get_log_ana_groups.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_ana_groups" 9 "nvme_mi_admin_get_log_ana_groups" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_ana_groups" 9 "nvme_mi_admin_get_log_ana_groups" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_ana_groups \- Retrieve Asymmetric Namespace Access groups only log page .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_boot_partition.2 b/doc/man/nvme_mi_admin_get_log_boot_partition.2 index 4fa7cf0..7997535 100644 --- a/doc/man/nvme_mi_admin_get_log_boot_partition.2 +++ b/doc/man/nvme_mi_admin_get_log_boot_partition.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_boot_partition" 9 "nvme_mi_admin_get_log_boot_partition" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_boot_partition" 9 "nvme_mi_admin_get_log_boot_partition" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_boot_partition \- Retrieve Boot Partition .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_changed_ns_list.2 b/doc/man/nvme_mi_admin_get_log_changed_ns_list.2 index c4b9073..3d8da40 100644 --- a/doc/man/nvme_mi_admin_get_log_changed_ns_list.2 +++ b/doc/man/nvme_mi_admin_get_log_changed_ns_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_changed_ns_list" 9 "nvme_mi_admin_get_log_changed_ns_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_changed_ns_list" 9 "nvme_mi_admin_get_log_changed_ns_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_changed_ns_list \- Retrieve namespace changed list .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_cmd_effects.2 b/doc/man/nvme_mi_admin_get_log_cmd_effects.2 index dd575e4..da20354 100644 --- a/doc/man/nvme_mi_admin_get_log_cmd_effects.2 +++ b/doc/man/nvme_mi_admin_get_log_cmd_effects.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_cmd_effects" 9 "nvme_mi_admin_get_log_cmd_effects" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_cmd_effects" 9 "nvme_mi_admin_get_log_cmd_effects" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_cmd_effects \- Retrieve nvme command effects log .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_create_telemetry_host.2 b/doc/man/nvme_mi_admin_get_log_create_telemetry_host.2 index 12cc91e..820601d 100644 --- a/doc/man/nvme_mi_admin_get_log_create_telemetry_host.2 +++ b/doc/man/nvme_mi_admin_get_log_create_telemetry_host.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_create_telemetry_host" 9 "nvme_mi_admin_get_log_create_telemetry_host" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_create_telemetry_host" 9 "nvme_mi_admin_get_log_create_telemetry_host" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_create_telemetry_host \- Create host telemetry log .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_device_self_test.2 b/doc/man/nvme_mi_admin_get_log_device_self_test.2 index 794bd6b..d7babe8 100644 --- a/doc/man/nvme_mi_admin_get_log_device_self_test.2 +++ b/doc/man/nvme_mi_admin_get_log_device_self_test.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_device_self_test" 9 "nvme_mi_admin_get_log_device_self_test" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_device_self_test" 9 "nvme_mi_admin_get_log_device_self_test" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_device_self_test \- Retrieve the device self test log .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_discovery.2 b/doc/man/nvme_mi_admin_get_log_discovery.2 index c8033e3..4621eae 100644 --- a/doc/man/nvme_mi_admin_get_log_discovery.2 +++ b/doc/man/nvme_mi_admin_get_log_discovery.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_discovery" 9 "nvme_mi_admin_get_log_discovery" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_discovery" 9 "nvme_mi_admin_get_log_discovery" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_discovery \- Retrieve Discovery log page .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_endurance_group.2 b/doc/man/nvme_mi_admin_get_log_endurance_group.2 index d3355d3..5ede46f 100644 --- a/doc/man/nvme_mi_admin_get_log_endurance_group.2 +++ b/doc/man/nvme_mi_admin_get_log_endurance_group.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_endurance_group" 9 "nvme_mi_admin_get_log_endurance_group" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_endurance_group" 9 "nvme_mi_admin_get_log_endurance_group" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_endurance_group \- Get Endurance Group log .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_endurance_grp_evt.2 b/doc/man/nvme_mi_admin_get_log_endurance_grp_evt.2 index ea1bacc..2086ee8 100644 --- a/doc/man/nvme_mi_admin_get_log_endurance_grp_evt.2 +++ b/doc/man/nvme_mi_admin_get_log_endurance_grp_evt.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_endurance_grp_evt" 9 "nvme_mi_admin_get_log_endurance_grp_evt" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_endurance_grp_evt" 9 "nvme_mi_admin_get_log_endurance_grp_evt" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_endurance_grp_evt \- Retrieve Rotational Media Information .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_error.2 b/doc/man/nvme_mi_admin_get_log_error.2 index 427e836..1d79c1d 100644 --- a/doc/man/nvme_mi_admin_get_log_error.2 +++ b/doc/man/nvme_mi_admin_get_log_error.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_error" 9 "nvme_mi_admin_get_log_error" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_error" 9 "nvme_mi_admin_get_log_error" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_error \- Retrieve nvme error log .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_fid_supported_effects.2 b/doc/man/nvme_mi_admin_get_log_fid_supported_effects.2 index d6a85b2..a8a4b48 100644 --- a/doc/man/nvme_mi_admin_get_log_fid_supported_effects.2 +++ b/doc/man/nvme_mi_admin_get_log_fid_supported_effects.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_fid_supported_effects" 9 "nvme_mi_admin_get_log_fid_supported_effects" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_fid_supported_effects" 9 "nvme_mi_admin_get_log_fid_supported_effects" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_fid_supported_effects \- Retrieve Feature Identifiers Supported and Effects .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_fw_slot.2 b/doc/man/nvme_mi_admin_get_log_fw_slot.2 index 87b3b9d..fce5622 100644 --- a/doc/man/nvme_mi_admin_get_log_fw_slot.2 +++ b/doc/man/nvme_mi_admin_get_log_fw_slot.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_fw_slot" 9 "nvme_mi_admin_get_log_fw_slot" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_fw_slot" 9 "nvme_mi_admin_get_log_fw_slot" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_fw_slot \- Retrieves the controller firmware log .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_lba_status.2 b/doc/man/nvme_mi_admin_get_log_lba_status.2 index 3849dee..1bf177d 100644 --- a/doc/man/nvme_mi_admin_get_log_lba_status.2 +++ b/doc/man/nvme_mi_admin_get_log_lba_status.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_lba_status" 9 "nvme_mi_admin_get_log_lba_status" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_lba_status" 9 "nvme_mi_admin_get_log_lba_status" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_lba_status \- Retrieve LBA Status .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_media_unit_stat.2 b/doc/man/nvme_mi_admin_get_log_media_unit_stat.2 index c01e486..3d7e11a 100644 --- a/doc/man/nvme_mi_admin_get_log_media_unit_stat.2 +++ b/doc/man/nvme_mi_admin_get_log_media_unit_stat.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_media_unit_stat" 9 "nvme_mi_admin_get_log_media_unit_stat" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_media_unit_stat" 9 "nvme_mi_admin_get_log_media_unit_stat" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_media_unit_stat \- Retrieve Media Unit Status .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_mi_cmd_supported_effects.2 b/doc/man/nvme_mi_admin_get_log_mi_cmd_supported_effects.2 index b9b5123..fd4c2f2 100644 --- a/doc/man/nvme_mi_admin_get_log_mi_cmd_supported_effects.2 +++ b/doc/man/nvme_mi_admin_get_log_mi_cmd_supported_effects.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_mi_cmd_supported_effects" 9 "nvme_mi_admin_get_log_mi_cmd_supported_effects" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_mi_cmd_supported_effects" 9 "nvme_mi_admin_get_log_mi_cmd_supported_effects" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_mi_cmd_supported_effects \- displays the MI Commands Supported by the controller .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_page.2 b/doc/man/nvme_mi_admin_get_log_page.2 index 5388830..49075bd 100644 --- a/doc/man/nvme_mi_admin_get_log_page.2 +++ b/doc/man/nvme_mi_admin_get_log_page.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_page" 9 "nvme_mi_admin_get_log_page" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_page" 9 "nvme_mi_admin_get_log_page" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_page \- Retrieve log page data from controller .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_persistent_event.2 b/doc/man/nvme_mi_admin_get_log_persistent_event.2 index 00b4cb4..92dc2a8 100644 --- a/doc/man/nvme_mi_admin_get_log_persistent_event.2 +++ b/doc/man/nvme_mi_admin_get_log_persistent_event.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_persistent_event" 9 "nvme_mi_admin_get_log_persistent_event" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_persistent_event" 9 "nvme_mi_admin_get_log_persistent_event" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_persistent_event \- Retrieve Persistent Event Log .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_phy_rx_eom.2 b/doc/man/nvme_mi_admin_get_log_phy_rx_eom.2 new file mode 100644 index 0000000..20c0205 --- /dev/null +++ b/doc/man/nvme_mi_admin_get_log_phy_rx_eom.2 @@ -0,0 +1,25 @@ +.TH "nvme_mi_admin_get_log_phy_rx_eom" 9 "nvme_mi_admin_get_log_phy_rx_eom" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_mi_admin_get_log_phy_rx_eom \- Retrieve Physical Interface Receiver Eye Opening Measurement Log +.SH SYNOPSIS +.B "int" nvme_mi_admin_get_log_phy_rx_eom +.BI "(nvme_mi_ctrl_t ctrl " "," +.BI "__u8 lsp " "," +.BI "__u16 controller " "," +.BI "__u32 len " "," +.BI "struct nvme_phy_rx_eom_log *log " ");" +.SH ARGUMENTS +.IP "ctrl" 12 +Controller to query +.IP "lsp" 12 +Log specific, controls action and measurement quality +.IP "controller" 12 +Target controller ID +.IP "len" 12 +The allocated size, minimum +struct nvme_phy_rx_eom_log +.IP "log" 12 +User address to store the log page +.SH "RETURN" +The nvme command status if a response was received (see +\fIenum nvme_status_field\fP) or -1 with errno set otherwise diff --git a/doc/man/nvme_mi_admin_get_log_predictable_lat_event.2 b/doc/man/nvme_mi_admin_get_log_predictable_lat_event.2 index 303d65e..7868b3f 100644 --- a/doc/man/nvme_mi_admin_get_log_predictable_lat_event.2 +++ b/doc/man/nvme_mi_admin_get_log_predictable_lat_event.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_predictable_lat_event" 9 "nvme_mi_admin_get_log_predictable_lat_event" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_predictable_lat_event" 9 "nvme_mi_admin_get_log_predictable_lat_event" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_predictable_lat_event \- Retrieve Predictable Latency Event Aggregate Log Page .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_predictable_lat_nvmset.2 b/doc/man/nvme_mi_admin_get_log_predictable_lat_nvmset.2 index 2b44bef..97db6d0 100644 --- a/doc/man/nvme_mi_admin_get_log_predictable_lat_nvmset.2 +++ b/doc/man/nvme_mi_admin_get_log_predictable_lat_nvmset.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_predictable_lat_nvmset" 9 "nvme_mi_admin_get_log_predictable_lat_nvmset" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_predictable_lat_nvmset" 9 "nvme_mi_admin_get_log_predictable_lat_nvmset" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_predictable_lat_nvmset \- Predictable Latency Per NVM Set .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_reservation.2 b/doc/man/nvme_mi_admin_get_log_reservation.2 index 9b95c32..3192167 100644 --- a/doc/man/nvme_mi_admin_get_log_reservation.2 +++ b/doc/man/nvme_mi_admin_get_log_reservation.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_reservation" 9 "nvme_mi_admin_get_log_reservation" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_reservation" 9 "nvme_mi_admin_get_log_reservation" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_reservation \- Retrieve Reservation Notification .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_sanitize.2 b/doc/man/nvme_mi_admin_get_log_sanitize.2 index 92d0d39..361f2b3 100644 --- a/doc/man/nvme_mi_admin_get_log_sanitize.2 +++ b/doc/man/nvme_mi_admin_get_log_sanitize.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_sanitize" 9 "nvme_mi_admin_get_log_sanitize" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_sanitize" 9 "nvme_mi_admin_get_log_sanitize" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_sanitize \- Retrieve Sanitize Status .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_simple.2 b/doc/man/nvme_mi_admin_get_log_simple.2 index edfbdd3..eb906c3 100644 --- a/doc/man/nvme_mi_admin_get_log_simple.2 +++ b/doc/man/nvme_mi_admin_get_log_simple.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_simple" 9 "nvme_mi_admin_get_log_simple" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_simple" 9 "nvme_mi_admin_get_log_simple" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_simple \- Helper for Get Log Page functions with no NSID or RAE requirements .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_smart.2 b/doc/man/nvme_mi_admin_get_log_smart.2 index 02505d2..06834df 100644 --- a/doc/man/nvme_mi_admin_get_log_smart.2 +++ b/doc/man/nvme_mi_admin_get_log_smart.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_smart" 9 "nvme_mi_admin_get_log_smart" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_smart" 9 "nvme_mi_admin_get_log_smart" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_smart \- Retrieve nvme smart log .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_support_cap_config_list.2 b/doc/man/nvme_mi_admin_get_log_support_cap_config_list.2 index 35b94ae..983cad5 100644 --- a/doc/man/nvme_mi_admin_get_log_support_cap_config_list.2 +++ b/doc/man/nvme_mi_admin_get_log_support_cap_config_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_support_cap_config_list" 9 "nvme_mi_admin_get_log_support_cap_config_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_support_cap_config_list" 9 "nvme_mi_admin_get_log_support_cap_config_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_support_cap_config_list \- Retrieve Supported Capacity Configuration List .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_supported_log_pages.2 b/doc/man/nvme_mi_admin_get_log_supported_log_pages.2 index 4a22e29..148132e 100644 --- a/doc/man/nvme_mi_admin_get_log_supported_log_pages.2 +++ b/doc/man/nvme_mi_admin_get_log_supported_log_pages.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_supported_log_pages" 9 "nvme_mi_admin_get_log_supported_log_pages" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_supported_log_pages" 9 "nvme_mi_admin_get_log_supported_log_pages" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_supported_log_pages \- Retrieve nmve supported log pages .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_telemetry_ctrl.2 b/doc/man/nvme_mi_admin_get_log_telemetry_ctrl.2 index 1482e97..973e535 100644 --- a/doc/man/nvme_mi_admin_get_log_telemetry_ctrl.2 +++ b/doc/man/nvme_mi_admin_get_log_telemetry_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_telemetry_ctrl" 9 "nvme_mi_admin_get_log_telemetry_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_telemetry_ctrl" 9 "nvme_mi_admin_get_log_telemetry_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_telemetry_ctrl \- Get Telemetry Controller-Initiated log page .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_telemetry_host.2 b/doc/man/nvme_mi_admin_get_log_telemetry_host.2 index 3fc91ca..0e7085c 100644 --- a/doc/man/nvme_mi_admin_get_log_telemetry_host.2 +++ b/doc/man/nvme_mi_admin_get_log_telemetry_host.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_telemetry_host" 9 "nvme_mi_admin_get_log_telemetry_host" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_telemetry_host" 9 "nvme_mi_admin_get_log_telemetry_host" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_telemetry_host \- Get Telemetry Host-Initiated log page .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_log_zns_changed_zones.2 b/doc/man/nvme_mi_admin_get_log_zns_changed_zones.2 index 73bc6fa..622f4bd 100644 --- a/doc/man/nvme_mi_admin_get_log_zns_changed_zones.2 +++ b/doc/man/nvme_mi_admin_get_log_zns_changed_zones.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_log_zns_changed_zones" 9 "nvme_mi_admin_get_log_zns_changed_zones" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_log_zns_changed_zones" 9 "nvme_mi_admin_get_log_zns_changed_zones" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_log_zns_changed_zones \- Retrieve list of zones that have changed .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_get_nsid_log.2 b/doc/man/nvme_mi_admin_get_nsid_log.2 index cd2f29d..ef07b1f 100644 --- a/doc/man/nvme_mi_admin_get_nsid_log.2 +++ b/doc/man/nvme_mi_admin_get_nsid_log.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_get_nsid_log" 9 "nvme_mi_admin_get_nsid_log" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_get_nsid_log" 9 "nvme_mi_admin_get_nsid_log" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_get_nsid_log \- Helper for Get Log Page functions .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify.2 b/doc/man/nvme_mi_admin_identify.2 index cde41dc..ca34155 100644 --- a/doc/man/nvme_mi_admin_identify.2 +++ b/doc/man/nvme_mi_admin_identify.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify" 9 "nvme_mi_admin_identify" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify" 9 "nvme_mi_admin_identify" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify \- Perform an Admin identify command. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_active_ns_list.2 b/doc/man/nvme_mi_admin_identify_active_ns_list.2 index 64f034d..b8a50ab 100644 --- a/doc/man/nvme_mi_admin_identify_active_ns_list.2 +++ b/doc/man/nvme_mi_admin_identify_active_ns_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify_active_ns_list" 9 "nvme_mi_admin_identify_active_ns_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_active_ns_list" 9 "nvme_mi_admin_identify_active_ns_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_active_ns_list \- Perform an Admin identify for an active namespace list .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_allocated_ns.2 b/doc/man/nvme_mi_admin_identify_allocated_ns.2 index e76c411..bda75d5 100644 --- a/doc/man/nvme_mi_admin_identify_allocated_ns.2 +++ b/doc/man/nvme_mi_admin_identify_allocated_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify_allocated_ns" 9 "nvme_mi_admin_identify_allocated_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_allocated_ns" 9 "nvme_mi_admin_identify_allocated_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_allocated_ns \- Perform an Admin identify command for an allocated namespace .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_allocated_ns_list.2 b/doc/man/nvme_mi_admin_identify_allocated_ns_list.2 index 2089b6a..f975da0 100644 --- a/doc/man/nvme_mi_admin_identify_allocated_ns_list.2 +++ b/doc/man/nvme_mi_admin_identify_allocated_ns_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify_allocated_ns_list" 9 "nvme_mi_admin_identify_allocated_ns_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_allocated_ns_list" 9 "nvme_mi_admin_identify_allocated_ns_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_allocated_ns_list \- Perform an Admin identify for an allocated namespace list .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_cns_nsid.2 b/doc/man/nvme_mi_admin_identify_cns_nsid.2 index 26dc3f2..10c13ab 100644 --- a/doc/man/nvme_mi_admin_identify_cns_nsid.2 +++ b/doc/man/nvme_mi_admin_identify_cns_nsid.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify_cns_nsid" 9 "nvme_mi_admin_identify_cns_nsid" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_cns_nsid" 9 "nvme_mi_admin_identify_cns_nsid" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_cns_nsid \- Perform an Admin identify command using specific CNS/NSID parameters. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_ctrl.2 b/doc/man/nvme_mi_admin_identify_ctrl.2 index 57f935a..f55e1c8 100644 --- a/doc/man/nvme_mi_admin_identify_ctrl.2 +++ b/doc/man/nvme_mi_admin_identify_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify_ctrl" 9 "nvme_mi_admin_identify_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_ctrl" 9 "nvme_mi_admin_identify_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_ctrl \- Perform an Admin identify for a controller .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_ctrl_list.2 b/doc/man/nvme_mi_admin_identify_ctrl_list.2 index 2eccfa3..96ba1b8 100644 --- a/doc/man/nvme_mi_admin_identify_ctrl_list.2 +++ b/doc/man/nvme_mi_admin_identify_ctrl_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify_ctrl_list" 9 "nvme_mi_admin_identify_ctrl_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_ctrl_list" 9 "nvme_mi_admin_identify_ctrl_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_ctrl_list \- Perform an Admin identify for a controller list. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_ns.2 b/doc/man/nvme_mi_admin_identify_ns.2 index 1b9bc17..7c33386 100644 --- a/doc/man/nvme_mi_admin_identify_ns.2 +++ b/doc/man/nvme_mi_admin_identify_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify_ns" 9 "nvme_mi_admin_identify_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_ns" 9 "nvme_mi_admin_identify_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_ns \- Perform an Admin identify command for a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_ns_descs.2 b/doc/man/nvme_mi_admin_identify_ns_descs.2 index 63928af..289b5f0 100644 --- a/doc/man/nvme_mi_admin_identify_ns_descs.2 +++ b/doc/man/nvme_mi_admin_identify_ns_descs.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify_ns_descs" 9 "nvme_mi_admin_identify_ns_descs" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_ns_descs" 9 "nvme_mi_admin_identify_ns_descs" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_ns_descs \- Perform an Admin identify Namespace Identification Descriptor list command for a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_nsid_ctrl_list.2 b/doc/man/nvme_mi_admin_identify_nsid_ctrl_list.2 index dca8c61..85dffb2 100644 --- a/doc/man/nvme_mi_admin_identify_nsid_ctrl_list.2 +++ b/doc/man/nvme_mi_admin_identify_nsid_ctrl_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify_nsid_ctrl_list" 9 "nvme_mi_admin_identify_nsid_ctrl_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_nsid_ctrl_list" 9 "nvme_mi_admin_identify_nsid_ctrl_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_nsid_ctrl_list \- Perform an Admin identify for a controller list with specific namespace ID .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_partial.2 b/doc/man/nvme_mi_admin_identify_partial.2 index fa640bb..2e5bebc 100644 --- a/doc/man/nvme_mi_admin_identify_partial.2 +++ b/doc/man/nvme_mi_admin_identify_partial.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify_partial" 9 "nvme_mi_admin_identify_partial" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_partial" 9 "nvme_mi_admin_identify_partial" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_partial \- Perform an Admin identify command, and retrieve partial response data. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_primary_ctrl.2 b/doc/man/nvme_mi_admin_identify_primary_ctrl.2 index a44437b..3daf487 100644 --- a/doc/man/nvme_mi_admin_identify_primary_ctrl.2 +++ b/doc/man/nvme_mi_admin_identify_primary_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_identify_primary_ctrl" 9 "nvme_mi_admin_identify_primary_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_primary_ctrl" 9 "nvme_mi_admin_identify_primary_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_primary_ctrl \- Perform an Admin identify for primary controller capabilities data structure. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_identify_secondary_ctrl_list.2 b/doc/man/nvme_mi_admin_identify_secondary_ctrl_list.2 index 1ae7f4f..230d7e9 100644 --- a/doc/man/nvme_mi_admin_identify_secondary_ctrl_list.2 +++ b/doc/man/nvme_mi_admin_identify_secondary_ctrl_list.2 @@ -1,17 +1,14 @@ -.TH "nvme_mi_admin_identify_secondary_ctrl_list" 9 "nvme_mi_admin_identify_secondary_ctrl_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_identify_secondary_ctrl_list" 9 "nvme_mi_admin_identify_secondary_ctrl_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_identify_secondary_ctrl_list \- Perform an Admin identify for a secondary controller list. .SH SYNOPSIS .B "int" nvme_mi_admin_identify_secondary_ctrl_list .BI "(nvme_mi_ctrl_t ctrl " "," -.BI "__u32 nsid " "," .BI "__u16 cntid " "," .BI "struct nvme_secondary_ctrl_list *list " ");" .SH ARGUMENTS .IP "ctrl" 12 Controller to process identify command -.IP "nsid" 12 -Namespace ID to specify list start .IP "cntid" 12 Controller ID to specify list start .IP "list" 12 diff --git a/doc/man/nvme_mi_admin_ns_attach.2 b/doc/man/nvme_mi_admin_ns_attach.2 index a522d86..6cc14c0 100644 --- a/doc/man/nvme_mi_admin_ns_attach.2 +++ b/doc/man/nvme_mi_admin_ns_attach.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_ns_attach" 9 "nvme_mi_admin_ns_attach" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_ns_attach" 9 "nvme_mi_admin_ns_attach" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_ns_attach \- Attach or detach namespace to controller(s) .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_ns_attach_ctrls.2 b/doc/man/nvme_mi_admin_ns_attach_ctrls.2 index 1a16039..618ddc6 100644 --- a/doc/man/nvme_mi_admin_ns_attach_ctrls.2 +++ b/doc/man/nvme_mi_admin_ns_attach_ctrls.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_ns_attach_ctrls" 9 "nvme_mi_admin_ns_attach_ctrls" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_ns_attach_ctrls" 9 "nvme_mi_admin_ns_attach_ctrls" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_ns_attach_ctrls \- Attach namespace to controllers .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_ns_detach_ctrls.2 b/doc/man/nvme_mi_admin_ns_detach_ctrls.2 index 9d84979..28c9e5b 100644 --- a/doc/man/nvme_mi_admin_ns_detach_ctrls.2 +++ b/doc/man/nvme_mi_admin_ns_detach_ctrls.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_ns_detach_ctrls" 9 "nvme_mi_admin_ns_detach_ctrls" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_ns_detach_ctrls" 9 "nvme_mi_admin_ns_detach_ctrls" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_ns_detach_ctrls \- Detach namespace from controllers .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_req_hdr.2 b/doc/man/nvme_mi_admin_req_hdr.2 index ccc482b..d23bb1e 100644 --- a/doc/man/nvme_mi_admin_req_hdr.2 +++ b/doc/man/nvme_mi_admin_req_hdr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_admin_req_hdr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_admin_req_hdr" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_admin_req_hdr \- Admin command request header. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_resp_hdr.2 b/doc/man/nvme_mi_admin_resp_hdr.2 index 4309c4a..84baec4 100644 --- a/doc/man/nvme_mi_admin_resp_hdr.2 +++ b/doc/man/nvme_mi_admin_resp_hdr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_admin_resp_hdr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_admin_resp_hdr" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_admin_resp_hdr \- Admin command response header. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_sanitize_nvm.2 b/doc/man/nvme_mi_admin_sanitize_nvm.2 index c213d19..a5f6f02 100644 --- a/doc/man/nvme_mi_admin_sanitize_nvm.2 +++ b/doc/man/nvme_mi_admin_sanitize_nvm.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_sanitize_nvm" 9 "nvme_mi_admin_sanitize_nvm" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_sanitize_nvm" 9 "nvme_mi_admin_sanitize_nvm" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_sanitize_nvm \- Start a subsystem Sanitize operation .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_security_recv.2 b/doc/man/nvme_mi_admin_security_recv.2 index 89431f1..3a4341b 100644 --- a/doc/man/nvme_mi_admin_security_recv.2 +++ b/doc/man/nvme_mi_admin_security_recv.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_security_recv" 9 "nvme_mi_admin_security_recv" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_security_recv" 9 "nvme_mi_admin_security_recv" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_security_recv \- Perform a Security Receive command on a controller. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_security_send.2 b/doc/man/nvme_mi_admin_security_send.2 index aa3a34e..e848e5b 100644 --- a/doc/man/nvme_mi_admin_security_send.2 +++ b/doc/man/nvme_mi_admin_security_send.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_security_send" 9 "nvme_mi_admin_security_send" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_security_send" 9 "nvme_mi_admin_security_send" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_security_send \- Perform a Security Send command on a controller. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_admin_xfer.2 b/doc/man/nvme_mi_admin_xfer.2 index 6574c1b..8784ac6 100644 --- a/doc/man/nvme_mi_admin_xfer.2 +++ b/doc/man/nvme_mi_admin_xfer.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_admin_xfer" 9 "nvme_mi_admin_xfer" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_admin_xfer" 9 "nvme_mi_admin_xfer" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_admin_xfer \- Raw admin transfer interface. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_ccs.2 b/doc/man/nvme_mi_ccs.2 index 5fbd342..abdf11d 100644 --- a/doc/man/nvme_mi_ccs.2 +++ b/doc/man/nvme_mi_ccs.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_mi_ccs" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_mi_ccs" "September 2023" "API Manual" LINUX .SH NAME enum nvme_mi_ccs \- Get State Control Primitive Success Response Fields - Control Primitive Specific Response .SH SYNOPSIS diff --git a/doc/man/nvme_mi_close.2 b/doc/man/nvme_mi_close.2 index a30ff6e..0e03eb8 100644 --- a/doc/man/nvme_mi_close.2 +++ b/doc/man/nvme_mi_close.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_close" 9 "nvme_mi_close" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_close" 9 "nvme_mi_close" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_close \- Close an endpoint connection and release resources, including controller objects. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_close_ctrl.2 b/doc/man/nvme_mi_close_ctrl.2 index 296b158..2e6f39f 100644 --- a/doc/man/nvme_mi_close_ctrl.2 +++ b/doc/man/nvme_mi_close_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_close_ctrl" 9 "nvme_mi_close_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_close_ctrl" 9 "nvme_mi_close_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_close_ctrl \- free a controller .SH SYNOPSIS diff --git a/doc/man/nvme_mi_cmd_supported_effects.2 b/doc/man/nvme_mi_cmd_supported_effects.2 index c94c326..b65376d 100644 --- a/doc/man/nvme_mi_cmd_supported_effects.2 +++ b/doc/man/nvme_mi_cmd_supported_effects.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_mi_cmd_supported_effects" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_mi_cmd_supported_effects" "September 2023" "API Manual" LINUX .SH NAME enum nvme_mi_cmd_supported_effects \- MI Command Supported and Effects Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_mi_cmd_supported_effects_log.2 b/doc/man/nvme_mi_cmd_supported_effects_log.2 index e6cd59e..821fbc8 100644 --- a/doc/man/nvme_mi_cmd_supported_effects_log.2 +++ b/doc/man/nvme_mi_cmd_supported_effects_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_cmd_supported_effects_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_cmd_supported_effects_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_cmd_supported_effects_log \- NVMe-MI Commands Supported and Effects Log .SH SYNOPSIS diff --git a/doc/man/nvme_mi_config_id.2 b/doc/man/nvme_mi_config_id.2 index a0c1494..bc10ac0 100644 --- a/doc/man/nvme_mi_config_id.2 +++ b/doc/man/nvme_mi_config_id.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_mi_config_id" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_mi_config_id" "September 2023" "API Manual" LINUX .SH NAME enum nvme_mi_config_id \- NVMe-MI Configuration identifier. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_config_smbus_freq.2 b/doc/man/nvme_mi_config_smbus_freq.2 index 159674e..5766029 100644 --- a/doc/man/nvme_mi_config_smbus_freq.2 +++ b/doc/man/nvme_mi_config_smbus_freq.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_mi_config_smbus_freq" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_mi_config_smbus_freq" "September 2023" "API Manual" LINUX .SH NAME enum nvme_mi_config_smbus_freq \- SMBus/I2C frequency values .SH SYNOPSIS diff --git a/doc/man/nvme_mi_create_root.2 b/doc/man/nvme_mi_create_root.2 index f534272..bd37d50 100644 --- a/doc/man/nvme_mi_create_root.2 +++ b/doc/man/nvme_mi_create_root.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_create_root" 9 "nvme_mi_create_root" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_create_root" 9 "nvme_mi_create_root" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_create_root \- Create top-level MI (root) handle. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_csts.2 b/doc/man/nvme_mi_csts.2 index 491531b..a16d2c9 100644 --- a/doc/man/nvme_mi_csts.2 +++ b/doc/man/nvme_mi_csts.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_mi_csts" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_mi_csts" "September 2023" "API Manual" LINUX .SH NAME enum nvme_mi_csts \- Controller Health Data Structure (CHDS) - Controller Status (CSTS) .SH SYNOPSIS diff --git a/doc/man/nvme_mi_ctrl_health_status.2 b/doc/man/nvme_mi_ctrl_health_status.2 index 1876dcc..9ff7842 100644 --- a/doc/man/nvme_mi_ctrl_health_status.2 +++ b/doc/man/nvme_mi_ctrl_health_status.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_ctrl_health_status" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_ctrl_health_status" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_ctrl_health_status \- Controller Health Data Structure (CHDS) .SH SYNOPSIS diff --git a/doc/man/nvme_mi_ctrl_id.2 b/doc/man/nvme_mi_ctrl_id.2 index 2207e92..2736286 100644 --- a/doc/man/nvme_mi_ctrl_id.2 +++ b/doc/man/nvme_mi_ctrl_id.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_ctrl_id" 9 "nvme_mi_ctrl_id" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_ctrl_id" 9 "nvme_mi_ctrl_id" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_ctrl_id \- get the ID of a controller .SH SYNOPSIS diff --git a/doc/man/nvme_mi_cwarn.2 b/doc/man/nvme_mi_cwarn.2 index 5bbf73e..0b0dbd7 100644 --- a/doc/man/nvme_mi_cwarn.2 +++ b/doc/man/nvme_mi_cwarn.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_mi_cwarn" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_mi_cwarn" "September 2023" "API Manual" LINUX .SH NAME enum nvme_mi_cwarn \- Controller Health Data Structure (CHDS) - Critical Warning (CWARN) .SH SYNOPSIS diff --git a/doc/man/nvme_mi_dtyp.2 b/doc/man/nvme_mi_dtyp.2 index 3e70e9a..0d725d5 100644 --- a/doc/man/nvme_mi_dtyp.2 +++ b/doc/man/nvme_mi_dtyp.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_mi_dtyp" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_mi_dtyp" "September 2023" "API Manual" LINUX .SH NAME enum nvme_mi_dtyp \- Data Structure Type field. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_elem.2 b/doc/man/nvme_mi_elem.2 index 533ffb3..75309d4 100644 --- a/doc/man/nvme_mi_elem.2 +++ b/doc/man/nvme_mi_elem.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_mi_elem" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_mi_elem" "September 2023" "API Manual" LINUX .SH NAME enum nvme_mi_elem \- Element Descriptor Types .SH SYNOPSIS diff --git a/doc/man/nvme_mi_free_root.2 b/doc/man/nvme_mi_free_root.2 index 742278d..355b41d 100644 --- a/doc/man/nvme_mi_free_root.2 +++ b/doc/man/nvme_mi_free_root.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_free_root" 9 "nvme_mi_free_root" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_free_root" 9 "nvme_mi_free_root" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_free_root \- Free root object. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_init_ctrl.2 b/doc/man/nvme_mi_init_ctrl.2 index bacee80..11ae0b5 100644 --- a/doc/man/nvme_mi_init_ctrl.2 +++ b/doc/man/nvme_mi_init_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_init_ctrl" 9 "nvme_mi_init_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_init_ctrl" 9 "nvme_mi_init_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_init_ctrl \- initialise a NVMe controller. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_message_type.2 b/doc/man/nvme_mi_message_type.2 index a7294af..e36da6a 100644 --- a/doc/man/nvme_mi_message_type.2 +++ b/doc/man/nvme_mi_message_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_mi_message_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_mi_message_type" "September 2023" "API Manual" LINUX .SH NAME enum nvme_mi_message_type \- NVMe-MI message type field. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_mi_opcode.2 b/doc/man/nvme_mi_mi_opcode.2 index 3565a55..55e341d 100644 --- a/doc/man/nvme_mi_mi_opcode.2 +++ b/doc/man/nvme_mi_mi_opcode.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_mi_mi_opcode" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_mi_mi_opcode" "September 2023" "API Manual" LINUX .SH NAME enum nvme_mi_mi_opcode \- Operation code for supported NVMe-MI commands. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_mi_read_mi_data_ctrl.2 b/doc/man/nvme_mi_mi_read_mi_data_ctrl.2 index f528989..fab4485 100644 --- a/doc/man/nvme_mi_mi_read_mi_data_ctrl.2 +++ b/doc/man/nvme_mi_mi_read_mi_data_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_mi_read_mi_data_ctrl" 9 "nvme_mi_mi_read_mi_data_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_mi_read_mi_data_ctrl" 9 "nvme_mi_mi_read_mi_data_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_mi_read_mi_data_ctrl \- Perform a Read MI Data Structure command, retrieving controller information .SH SYNOPSIS diff --git a/doc/man/nvme_mi_mi_read_mi_data_ctrl_list.2 b/doc/man/nvme_mi_mi_read_mi_data_ctrl_list.2 index 0953b33..a3e5cce 100644 --- a/doc/man/nvme_mi_mi_read_mi_data_ctrl_list.2 +++ b/doc/man/nvme_mi_mi_read_mi_data_ctrl_list.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_mi_read_mi_data_ctrl_list" 9 "nvme_mi_mi_read_mi_data_ctrl_list" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_mi_read_mi_data_ctrl_list" 9 "nvme_mi_mi_read_mi_data_ctrl_list" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_mi_read_mi_data_ctrl_list \- Perform a Read MI Data Structure command, retrieving the list of attached controllers. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_mi_read_mi_data_port.2 b/doc/man/nvme_mi_mi_read_mi_data_port.2 index 8a04102..6c87f68 100644 --- a/doc/man/nvme_mi_mi_read_mi_data_port.2 +++ b/doc/man/nvme_mi_mi_read_mi_data_port.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_mi_read_mi_data_port" 9 "nvme_mi_mi_read_mi_data_port" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_mi_read_mi_data_port" 9 "nvme_mi_mi_read_mi_data_port" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_mi_read_mi_data_port \- Perform a Read MI Data Structure command, retrieving port data. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_mi_read_mi_data_subsys.2 b/doc/man/nvme_mi_mi_read_mi_data_subsys.2 index 00578e9..d87b8eb 100644 --- a/doc/man/nvme_mi_mi_read_mi_data_subsys.2 +++ b/doc/man/nvme_mi_mi_read_mi_data_subsys.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_mi_read_mi_data_subsys" 9 "nvme_mi_mi_read_mi_data_subsys" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_mi_read_mi_data_subsys" 9 "nvme_mi_mi_read_mi_data_subsys" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_mi_read_mi_data_subsys \- Perform a Read MI Data Structure command, retrieving subsystem data. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_mi_req_hdr.2 b/doc/man/nvme_mi_mi_req_hdr.2 index 9475c41..fb1ac98 100644 --- a/doc/man/nvme_mi_mi_req_hdr.2 +++ b/doc/man/nvme_mi_mi_req_hdr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_mi_req_hdr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_mi_req_hdr" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_mi_req_hdr \- MI request message header. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_mi_resp_hdr.2 b/doc/man/nvme_mi_mi_resp_hdr.2 index 47ac73b..2bd1dc8 100644 --- a/doc/man/nvme_mi_mi_resp_hdr.2 +++ b/doc/man/nvme_mi_mi_resp_hdr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_mi_resp_hdr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_mi_resp_hdr" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_mi_resp_hdr \- MI response message header. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_mi_subsystem_health_status_poll.2 b/doc/man/nvme_mi_mi_subsystem_health_status_poll.2 index b601a97..9baca38 100644 --- a/doc/man/nvme_mi_mi_subsystem_health_status_poll.2 +++ b/doc/man/nvme_mi_mi_subsystem_health_status_poll.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_mi_subsystem_health_status_poll" 9 "nvme_mi_mi_subsystem_health_status_poll" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_mi_subsystem_health_status_poll" 9 "nvme_mi_mi_subsystem_health_status_poll" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_mi_subsystem_health_status_poll \- Read the Subsystem Health Data Structure from the NVM subsystem .SH SYNOPSIS diff --git a/doc/man/nvme_mi_msg_hdr.2 b/doc/man/nvme_mi_msg_hdr.2 index bad5afe..fdc94d1 100644 --- a/doc/man/nvme_mi_msg_hdr.2 +++ b/doc/man/nvme_mi_msg_hdr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_msg_hdr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_msg_hdr" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_msg_hdr \- General MI message header. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_msg_resp.2 b/doc/man/nvme_mi_msg_resp.2 index c51ea53..f8fd055 100644 --- a/doc/man/nvme_mi_msg_resp.2 +++ b/doc/man/nvme_mi_msg_resp.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_msg_resp" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_msg_resp" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_msg_resp \- Generic response type. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_nvm_ss_health_status.2 b/doc/man/nvme_mi_nvm_ss_health_status.2 index f66e82e..9d7601f 100644 --- a/doc/man/nvme_mi_nvm_ss_health_status.2 +++ b/doc/man/nvme_mi_nvm_ss_health_status.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_nvm_ss_health_status" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_nvm_ss_health_status" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_nvm_ss_health_status \- Subsystem Management Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_mi_open_mctp.2 b/doc/man/nvme_mi_open_mctp.2 index ceff350..0db1892 100644 --- a/doc/man/nvme_mi_open_mctp.2 +++ b/doc/man/nvme_mi_open_mctp.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_open_mctp" 9 "nvme_mi_open_mctp" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_open_mctp" 9 "nvme_mi_open_mctp" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_open_mctp \- Create an endpoint using a MCTP connection. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_osc.2 b/doc/man/nvme_mi_osc.2 index 3217aa1..f5b6af7 100644 --- a/doc/man/nvme_mi_osc.2 +++ b/doc/man/nvme_mi_osc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_osc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_osc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_osc \- Optionally Supported Command Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_mi_port_pcie.2 b/doc/man/nvme_mi_port_pcie.2 index 76e4463..8808663 100644 --- a/doc/man/nvme_mi_port_pcie.2 +++ b/doc/man/nvme_mi_port_pcie.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_port_pcie" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_port_pcie" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_port_pcie \- PCIe Port Specific Data .SH SYNOPSIS diff --git a/doc/man/nvme_mi_port_smb.2 b/doc/man/nvme_mi_port_smb.2 index ef7c6c9..10751c5 100644 --- a/doc/man/nvme_mi_port_smb.2 +++ b/doc/man/nvme_mi_port_smb.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_port_smb" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_port_smb" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_port_smb \- SMBus Port Specific Data .SH SYNOPSIS diff --git a/doc/man/nvme_mi_read_ctrl_info.2 b/doc/man/nvme_mi_read_ctrl_info.2 index 2b8d5e4..52529aa 100644 --- a/doc/man/nvme_mi_read_ctrl_info.2 +++ b/doc/man/nvme_mi_read_ctrl_info.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_read_ctrl_info" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_read_ctrl_info" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_read_ctrl_info \- Controller Information Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_mi_read_nvm_ss_info.2 b/doc/man/nvme_mi_read_nvm_ss_info.2 index 2fcd925..1fec4da 100644 --- a/doc/man/nvme_mi_read_nvm_ss_info.2 +++ b/doc/man/nvme_mi_read_nvm_ss_info.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_read_nvm_ss_info" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_read_nvm_ss_info" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_read_nvm_ss_info \- NVM Subsystem Information Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_mi_read_port_info.2 b/doc/man/nvme_mi_read_port_info.2 index b14e8ac..c91f334 100644 --- a/doc/man/nvme_mi_read_port_info.2 +++ b/doc/man/nvme_mi_read_port_info.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_read_port_info" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_read_port_info" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_read_port_info \- Port Information Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_mi_read_sc_list.2 b/doc/man/nvme_mi_read_sc_list.2 index 5f3f6b2..6178b30 100644 --- a/doc/man/nvme_mi_read_sc_list.2 +++ b/doc/man/nvme_mi_read_sc_list.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_read_sc_list" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_read_sc_list" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_read_sc_list \- Management Endpoint Buffer Supported Command List Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_mi_resp_status.2 b/doc/man/nvme_mi_resp_status.2 index 253d114..3bec293 100644 --- a/doc/man/nvme_mi_resp_status.2 +++ b/doc/man/nvme_mi_resp_status.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_mi_resp_status" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_mi_resp_status" "September 2023" "API Manual" LINUX .SH NAME enum nvme_mi_resp_status \- values for the response status field .SH SYNOPSIS diff --git a/doc/man/nvme_mi_set_probe_enabled.2 b/doc/man/nvme_mi_set_probe_enabled.2 index 05ce08a..ef071e7 100644 --- a/doc/man/nvme_mi_set_probe_enabled.2 +++ b/doc/man/nvme_mi_set_probe_enabled.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_set_probe_enabled" 9 "nvme_mi_set_probe_enabled" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_set_probe_enabled" 9 "nvme_mi_set_probe_enabled" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_set_probe_enabled \- enable/disable the probe for new endpoints .SH SYNOPSIS diff --git a/doc/man/nvme_mi_status_to_string.2 b/doc/man/nvme_mi_status_to_string.2 index cb494ce..f1dfdeb 100644 --- a/doc/man/nvme_mi_status_to_string.2 +++ b/doc/man/nvme_mi_status_to_string.2 @@ -1,4 +1,4 @@ -.TH "nvme_mi_status_to_string" 9 "nvme_mi_status_to_string" "June 2023" "libnvme API manual" LINUX +.TH "nvme_mi_status_to_string" 9 "nvme_mi_status_to_string" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_mi_status_to_string \- return a string representation of the MI status. .SH SYNOPSIS diff --git a/doc/man/nvme_mi_vpd_hdr.2 b/doc/man/nvme_mi_vpd_hdr.2 index d0ba148..fd3abb3 100644 --- a/doc/man/nvme_mi_vpd_hdr.2 +++ b/doc/man/nvme_mi_vpd_hdr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_vpd_hdr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_vpd_hdr" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_vpd_hdr \- Vital Product Data Common Header .SH SYNOPSIS diff --git a/doc/man/nvme_mi_vpd_mr_common.2 b/doc/man/nvme_mi_vpd_mr_common.2 index 2d8ab54..bc683f2 100644 --- a/doc/man/nvme_mi_vpd_mr_common.2 +++ b/doc/man/nvme_mi_vpd_mr_common.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_vpd_mr_common" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_vpd_mr_common" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_vpd_mr_common \- NVMe MultiRecord Area .SH SYNOPSIS diff --git a/doc/man/nvme_mi_vpd_mra.2 b/doc/man/nvme_mi_vpd_mra.2 index 1533262..7039438 100644 --- a/doc/man/nvme_mi_vpd_mra.2 +++ b/doc/man/nvme_mi_vpd_mra.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_vpd_mra" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_vpd_mra" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_vpd_mra \- NVMe MultiRecord Area .SH SYNOPSIS diff --git a/doc/man/nvme_mi_vpd_ppmra.2 b/doc/man/nvme_mi_vpd_ppmra.2 index 37e0966..17c8a45 100644 --- a/doc/man/nvme_mi_vpd_ppmra.2 +++ b/doc/man/nvme_mi_vpd_ppmra.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_vpd_ppmra" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_vpd_ppmra" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_vpd_ppmra \- NVMe PCIe Port MultiRecord Area .SH SYNOPSIS diff --git a/doc/man/nvme_mi_vpd_telem.2 b/doc/man/nvme_mi_vpd_telem.2 index b73e9f3..1b50c35 100644 --- a/doc/man/nvme_mi_vpd_telem.2 +++ b/doc/man/nvme_mi_vpd_telem.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_vpd_telem" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_vpd_telem" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_vpd_telem \- Vital Product Data Element Descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_mi_vpd_tra.2 b/doc/man/nvme_mi_vpd_tra.2 index c7fbff2..0a51143 100644 --- a/doc/man/nvme_mi_vpd_tra.2 +++ b/doc/man/nvme_mi_vpd_tra.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_mi_vpd_tra" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_mi_vpd_tra" "September 2023" "API Manual" LINUX .SH NAME struct nvme_mi_vpd_tra \- Vital Product Data Topology MultiRecord .SH SYNOPSIS diff --git a/doc/man/nvme_namespace_attach_ctrls.2 b/doc/man/nvme_namespace_attach_ctrls.2 index 40be8fc..08c5d8c 100644 --- a/doc/man/nvme_namespace_attach_ctrls.2 +++ b/doc/man/nvme_namespace_attach_ctrls.2 @@ -1,4 +1,4 @@ -.TH "nvme_namespace_attach_ctrls" 9 "nvme_namespace_attach_ctrls" "June 2023" "libnvme API manual" LINUX +.TH "nvme_namespace_attach_ctrls" 9 "nvme_namespace_attach_ctrls" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_namespace_attach_ctrls \- Attach namespace to controller(s) .SH SYNOPSIS diff --git a/doc/man/nvme_namespace_detach_ctrls.2 b/doc/man/nvme_namespace_detach_ctrls.2 index fdaf0d7..17f4e83 100644 --- a/doc/man/nvme_namespace_detach_ctrls.2 +++ b/doc/man/nvme_namespace_detach_ctrls.2 @@ -1,4 +1,4 @@ -.TH "nvme_namespace_detach_ctrls" 9 "nvme_namespace_detach_ctrls" "June 2023" "libnvme API manual" LINUX +.TH "nvme_namespace_detach_ctrls" 9 "nvme_namespace_detach_ctrls" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_namespace_detach_ctrls \- Detach namespace from controller(s) .SH SYNOPSIS diff --git a/doc/man/nvme_namespace_filter.2 b/doc/man/nvme_namespace_filter.2 index 41dbc2b..c36b446 100644 --- a/doc/man/nvme_namespace_filter.2 +++ b/doc/man/nvme_namespace_filter.2 @@ -1,4 +1,4 @@ -.TH "nvme_namespace_filter" 9 "nvme_namespace_filter" "June 2023" "libnvme API manual" LINUX +.TH "nvme_namespace_filter" 9 "nvme_namespace_filter" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_namespace_filter \- Filter for namespaces .SH SYNOPSIS diff --git a/doc/man/nvme_namespace_first_path.2 b/doc/man/nvme_namespace_first_path.2 index b3fbd61..cea27b6 100644 --- a/doc/man/nvme_namespace_first_path.2 +++ b/doc/man/nvme_namespace_first_path.2 @@ -1,4 +1,4 @@ -.TH "nvme_namespace_first_path" 9 "nvme_namespace_first_path" "June 2023" "libnvme API manual" LINUX +.TH "nvme_namespace_first_path" 9 "nvme_namespace_first_path" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_namespace_first_path \- Start path iterator .SH SYNOPSIS diff --git a/doc/man/nvme_namespace_for_each_path.2 b/doc/man/nvme_namespace_for_each_path.2 index 6094a21..6a398d4 100644 --- a/doc/man/nvme_namespace_for_each_path.2 +++ b/doc/man/nvme_namespace_for_each_path.2 @@ -1,4 +1,4 @@ -.TH "nvme_namespace_for_each_path" 9 "nvme_namespace_for_each_path" "June 2023" "libnvme API manual" LINUX +.TH "nvme_namespace_for_each_path" 9 "nvme_namespace_for_each_path" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_namespace_for_each_path \- Traverse paths .SH SYNOPSIS diff --git a/doc/man/nvme_namespace_for_each_path_safe.2 b/doc/man/nvme_namespace_for_each_path_safe.2 index f75bea9..4ffe27a 100644 --- a/doc/man/nvme_namespace_for_each_path_safe.2 +++ b/doc/man/nvme_namespace_for_each_path_safe.2 @@ -1,4 +1,4 @@ -.TH "nvme_namespace_for_each_path_safe" 9 "nvme_namespace_for_each_path_safe" "June 2023" "libnvme API manual" LINUX +.TH "nvme_namespace_for_each_path_safe" 9 "nvme_namespace_for_each_path_safe" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_namespace_for_each_path_safe \- Traverse paths .SH SYNOPSIS diff --git a/doc/man/nvme_namespace_next_path.2 b/doc/man/nvme_namespace_next_path.2 index 7e5f843..2d9e70d 100644 --- a/doc/man/nvme_namespace_next_path.2 +++ b/doc/man/nvme_namespace_next_path.2 @@ -1,4 +1,4 @@ -.TH "nvme_namespace_next_path" 9 "nvme_namespace_next_path" "June 2023" "libnvme API manual" LINUX +.TH "nvme_namespace_next_path" 9 "nvme_namespace_next_path" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_namespace_next_path \- Next path iterator .SH SYNOPSIS diff --git a/doc/man/nvme_nbft_free.2 b/doc/man/nvme_nbft_free.2 index 53c921e..9c938cd 100644 --- a/doc/man/nvme_nbft_free.2 +++ b/doc/man/nvme_nbft_free.2 @@ -1,4 +1,4 @@ -.TH "nvme_nbft_free" 9 "nvme_nbft_free" "June 2023" "libnvme API manual" LINUX +.TH "nvme_nbft_free" 9 "nvme_nbft_free" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_nbft_free \- Free the struct nbft_info and its contents .SH SYNOPSIS diff --git a/doc/man/nvme_nbft_read.2 b/doc/man/nvme_nbft_read.2 index 0c8534a..cbf7c95 100644 --- a/doc/man/nvme_nbft_read.2 +++ b/doc/man/nvme_nbft_read.2 @@ -1,4 +1,4 @@ -.TH "nvme_nbft_read" 9 "nvme_nbft_read" "June 2023" "libnvme API manual" LINUX +.TH "nvme_nbft_read" 9 "nvme_nbft_read" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_nbft_read \- Read and parse contents of an ACPI NBFT table .SH SYNOPSIS diff --git a/doc/man/nvme_nd_ns_fpi.2 b/doc/man/nvme_nd_ns_fpi.2 index eaafcfa..e510316 100644 --- a/doc/man/nvme_nd_ns_fpi.2 +++ b/doc/man/nvme_nd_ns_fpi.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_nd_ns_fpi" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_nd_ns_fpi" "September 2023" "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 diff --git a/doc/man/nvme_next_host.2 b/doc/man/nvme_next_host.2 index 4964e70..d38d163 100644 --- a/doc/man/nvme_next_host.2 +++ b/doc/man/nvme_next_host.2 @@ -1,4 +1,4 @@ -.TH "nvme_next_host" 9 "nvme_next_host" "June 2023" "libnvme API manual" LINUX +.TH "nvme_next_host" 9 "nvme_next_host" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_next_host \- Next host iterator .SH SYNOPSIS diff --git a/doc/man/nvme_next_subsystem.2 b/doc/man/nvme_next_subsystem.2 index 08fa802..1489b5f 100644 --- a/doc/man/nvme_next_subsystem.2 +++ b/doc/man/nvme_next_subsystem.2 @@ -1,4 +1,4 @@ -.TH "nvme_next_subsystem" 9 "nvme_next_subsystem" "June 2023" "libnvme API manual" LINUX +.TH "nvme_next_subsystem" 9 "nvme_next_subsystem" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_next_subsystem \- Next subsystem iterator .SH SYNOPSIS diff --git a/doc/man/nvme_ns_attach.2 b/doc/man/nvme_ns_attach.2 index d435197..f0bcbf1 100644 --- a/doc/man/nvme_ns_attach.2 +++ b/doc/man/nvme_ns_attach.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_attach" 9 "nvme_ns_attach" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_attach" 9 "nvme_ns_attach" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_attach \- Attach or detach namespace to controller(s) .SH SYNOPSIS diff --git a/doc/man/nvme_ns_attach_ctrls.2 b/doc/man/nvme_ns_attach_ctrls.2 index 98f6c55..f554131 100644 --- a/doc/man/nvme_ns_attach_ctrls.2 +++ b/doc/man/nvme_ns_attach_ctrls.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_attach_ctrls" 9 "nvme_ns_attach_ctrls" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_attach_ctrls" 9 "nvme_ns_attach_ctrls" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_attach_ctrls \- Attach namespace to controllers .SH SYNOPSIS diff --git a/doc/man/nvme_ns_attach_sel.2 b/doc/man/nvme_ns_attach_sel.2 index 6ed3541..64c5040 100644 --- a/doc/man/nvme_ns_attach_sel.2 +++ b/doc/man/nvme_ns_attach_sel.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ns_attach_sel" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ns_attach_sel" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ns_attach_sel \- Namespace Attachment - Select .SH SYNOPSIS diff --git a/doc/man/nvme_ns_compare.2 b/doc/man/nvme_ns_compare.2 index 89ffdc8..59e3c71 100644 --- a/doc/man/nvme_ns_compare.2 +++ b/doc/man/nvme_ns_compare.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_compare" 9 "nvme_ns_compare" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_compare" 9 "nvme_ns_compare" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_compare \- Compare data on a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_detach_ctrls.2 b/doc/man/nvme_ns_detach_ctrls.2 index b1d5313..b68dd88 100644 --- a/doc/man/nvme_ns_detach_ctrls.2 +++ b/doc/man/nvme_ns_detach_ctrls.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_detach_ctrls" 9 "nvme_ns_detach_ctrls" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_detach_ctrls" 9 "nvme_ns_detach_ctrls" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_detach_ctrls \- Detach namespace from controllers .SH SYNOPSIS diff --git a/doc/man/nvme_ns_flush.2 b/doc/man/nvme_ns_flush.2 index c19f1ee..ce2a067 100644 --- a/doc/man/nvme_ns_flush.2 +++ b/doc/man/nvme_ns_flush.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_flush" 9 "nvme_ns_flush" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_flush" 9 "nvme_ns_flush" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_flush \- Flush data to a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_csi.2 b/doc/man/nvme_ns_get_csi.2 index 5a8e279..5400772 100644 --- a/doc/man/nvme_ns_get_csi.2 +++ b/doc/man/nvme_ns_get_csi.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_csi" 9 "nvme_ns_get_csi" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_csi" 9 "nvme_ns_get_csi" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_csi \- Command set identifier of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_ctrl.2 b/doc/man/nvme_ns_get_ctrl.2 index af12b9c..fcf80e0 100644 --- a/doc/man/nvme_ns_get_ctrl.2 +++ b/doc/man/nvme_ns_get_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_ctrl" 9 "nvme_ns_get_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_ctrl" 9 "nvme_ns_get_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_ctrl \- &nvme_ctrl_t of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_eui64.2 b/doc/man/nvme_ns_get_eui64.2 index 29129f7..d5f3a61 100644 --- a/doc/man/nvme_ns_get_eui64.2 +++ b/doc/man/nvme_ns_get_eui64.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_eui64" 9 "nvme_ns_get_eui64" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_eui64" 9 "nvme_ns_get_eui64" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_eui64 \- 64-bit eui of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_fd.2 b/doc/man/nvme_ns_get_fd.2 index c58e71e..322e4b1 100644 --- a/doc/man/nvme_ns_get_fd.2 +++ b/doc/man/nvme_ns_get_fd.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_fd" 9 "nvme_ns_get_fd" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_fd" 9 "nvme_ns_get_fd" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_fd \- Get associated file descriptor .SH SYNOPSIS @@ -7,5 +7,12 @@ nvme_ns_get_fd \- Get associated file descriptor .SH ARGUMENTS .IP "n" 12 Namespace instance +.SH "DESCRIPTION" +libnvme will \fBopen\fP the file (if not already opened) and keep +an internal copy of the file descriptor. Following calls to +this API retrieve the internal cached copy of the file +descriptor. The file will remain opened and the fd will +remain cached until the ns object is deleted or +\fBnvme_ns_release_fd\fP is called. .SH "RETURN" File descriptor associated with \fIn\fP or -1 diff --git a/doc/man/nvme_ns_get_firmware.2 b/doc/man/nvme_ns_get_firmware.2 index 82cd548..c396c2c 100644 --- a/doc/man/nvme_ns_get_firmware.2 +++ b/doc/man/nvme_ns_get_firmware.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_firmware" 9 "nvme_ns_get_firmware" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_firmware" 9 "nvme_ns_get_firmware" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_firmware \- Firmware string of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_generic_name.2 b/doc/man/nvme_ns_get_generic_name.2 index 3bfc4f7..a41e725 100644 --- a/doc/man/nvme_ns_get_generic_name.2 +++ b/doc/man/nvme_ns_get_generic_name.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_generic_name" 9 "nvme_ns_get_generic_name" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_generic_name" 9 "nvme_ns_get_generic_name" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_generic_name \- Returns name of generic namespace chardev. .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_lba_count.2 b/doc/man/nvme_ns_get_lba_count.2 index 41394b5..43cf7d7 100644 --- a/doc/man/nvme_ns_get_lba_count.2 +++ b/doc/man/nvme_ns_get_lba_count.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_lba_count" 9 "nvme_ns_get_lba_count" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_lba_count" 9 "nvme_ns_get_lba_count" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_lba_count \- LBA count of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_lba_size.2 b/doc/man/nvme_ns_get_lba_size.2 index 3c97f48..407b07d 100644 --- a/doc/man/nvme_ns_get_lba_size.2 +++ b/doc/man/nvme_ns_get_lba_size.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_lba_size" 9 "nvme_ns_get_lba_size" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_lba_size" 9 "nvme_ns_get_lba_size" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_lba_size \- LBA size of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_lba_util.2 b/doc/man/nvme_ns_get_lba_util.2 index 01199ac..f0909de 100644 --- a/doc/man/nvme_ns_get_lba_util.2 +++ b/doc/man/nvme_ns_get_lba_util.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_lba_util" 9 "nvme_ns_get_lba_util" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_lba_util" 9 "nvme_ns_get_lba_util" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_lba_util \- LBA utilization of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_meta_size.2 b/doc/man/nvme_ns_get_meta_size.2 index c348c7e..a37d77f 100644 --- a/doc/man/nvme_ns_get_meta_size.2 +++ b/doc/man/nvme_ns_get_meta_size.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_meta_size" 9 "nvme_ns_get_meta_size" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_meta_size" 9 "nvme_ns_get_meta_size" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_meta_size \- Metadata size of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_model.2 b/doc/man/nvme_ns_get_model.2 index 67ac637..401046f 100644 --- a/doc/man/nvme_ns_get_model.2 +++ b/doc/man/nvme_ns_get_model.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_model" 9 "nvme_ns_get_model" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_model" 9 "nvme_ns_get_model" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_model \- Model of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_name.2 b/doc/man/nvme_ns_get_name.2 index 31662ad..11c7b93 100644 --- a/doc/man/nvme_ns_get_name.2 +++ b/doc/man/nvme_ns_get_name.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_name" 9 "nvme_ns_get_name" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_name" 9 "nvme_ns_get_name" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_name \- sysfs name of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_nguid.2 b/doc/man/nvme_ns_get_nguid.2 index adef802..221a3ae 100644 --- a/doc/man/nvme_ns_get_nguid.2 +++ b/doc/man/nvme_ns_get_nguid.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_nguid" 9 "nvme_ns_get_nguid" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_nguid" 9 "nvme_ns_get_nguid" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_nguid \- 128-bit nguid of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_nsid.2 b/doc/man/nvme_ns_get_nsid.2 index e5312c9..d181480 100644 --- a/doc/man/nvme_ns_get_nsid.2 +++ b/doc/man/nvme_ns_get_nsid.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_nsid" 9 "nvme_ns_get_nsid" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_nsid" 9 "nvme_ns_get_nsid" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_nsid \- NSID of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_serial.2 b/doc/man/nvme_ns_get_serial.2 index 3c081ff..3bd0723 100644 --- a/doc/man/nvme_ns_get_serial.2 +++ b/doc/man/nvme_ns_get_serial.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_serial" 9 "nvme_ns_get_serial" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_serial" 9 "nvme_ns_get_serial" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_serial \- Serial number of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_subsystem.2 b/doc/man/nvme_ns_get_subsystem.2 index 05b5afb..fc69ff4 100644 --- a/doc/man/nvme_ns_get_subsystem.2 +++ b/doc/man/nvme_ns_get_subsystem.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_subsystem" 9 "nvme_ns_get_subsystem" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_subsystem" 9 "nvme_ns_get_subsystem" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_subsystem \- &nvme_subsystem_t of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_sysfs_dir.2 b/doc/man/nvme_ns_get_sysfs_dir.2 index a04f4c9..0442225 100644 --- a/doc/man/nvme_ns_get_sysfs_dir.2 +++ b/doc/man/nvme_ns_get_sysfs_dir.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_sysfs_dir" 9 "nvme_ns_get_sysfs_dir" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_sysfs_dir" 9 "nvme_ns_get_sysfs_dir" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_sysfs_dir \- sysfs directory of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_get_uuid.2 b/doc/man/nvme_ns_get_uuid.2 index d268c54..d18fbc4 100644 --- a/doc/man/nvme_ns_get_uuid.2 +++ b/doc/man/nvme_ns_get_uuid.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_get_uuid" 9 "nvme_ns_get_uuid" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_get_uuid" 9 "nvme_ns_get_uuid" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_get_uuid \- UUID of a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_id_desc.2 b/doc/man/nvme_ns_id_desc.2 index 80415ab..d1bb4ae 100644 --- a/doc/man/nvme_ns_id_desc.2 +++ b/doc/man/nvme_ns_id_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_ns_id_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_ns_id_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_ns_id_desc \- Namespace identifier type descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_ns_id_desc_nidt.2 b/doc/man/nvme_ns_id_desc_nidt.2 index 1ae314d..23dd231 100644 --- a/doc/man/nvme_ns_id_desc_nidt.2 +++ b/doc/man/nvme_ns_id_desc_nidt.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ns_id_desc_nidt" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ns_id_desc_nidt" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ns_id_desc_nidt \- Known namespace identifier types .SH SYNOPSIS diff --git a/doc/man/nvme_ns_identify.2 b/doc/man/nvme_ns_identify.2 index ca44156..bd6768e 100644 --- a/doc/man/nvme_ns_identify.2 +++ b/doc/man/nvme_ns_identify.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_identify" 9 "nvme_ns_identify" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_identify" 9 "nvme_ns_identify" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_identify \- Issue an 'identify namespace' command .SH SYNOPSIS diff --git a/doc/man/nvme_ns_identify_descs.2 b/doc/man/nvme_ns_identify_descs.2 index 64ee0da..ecbf03c 100644 --- a/doc/man/nvme_ns_identify_descs.2 +++ b/doc/man/nvme_ns_identify_descs.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_identify_descs" 9 "nvme_ns_identify_descs" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_identify_descs" 9 "nvme_ns_identify_descs" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_identify_descs \- Issue an 'identify descriptors' command .SH SYNOPSIS diff --git a/doc/man/nvme_ns_list.2 b/doc/man/nvme_ns_list.2 index 6bffd4b..df28045 100644 --- a/doc/man/nvme_ns_list.2 +++ b/doc/man/nvme_ns_list.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_ns_list" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_ns_list" "September 2023" "API Manual" LINUX .SH NAME struct nvme_ns_list \- Namespace List .SH SYNOPSIS diff --git a/doc/man/nvme_ns_metadata_type.2 b/doc/man/nvme_ns_metadata_type.2 index ef90a67..5d1b8a6 100644 --- a/doc/man/nvme_ns_metadata_type.2 +++ b/doc/man/nvme_ns_metadata_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ns_metadata_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ns_metadata_type" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ns_metadata_type \- Namespace Metadata Element Types .SH SYNOPSIS diff --git a/doc/man/nvme_ns_mgmt.2 b/doc/man/nvme_ns_mgmt.2 index e7bdfd9..d2b051e 100644 --- a/doc/man/nvme_ns_mgmt.2 +++ b/doc/man/nvme_ns_mgmt.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_mgmt" 9 "nvme_ns_mgmt" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_mgmt" 9 "nvme_ns_mgmt" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_mgmt \- Issue a Namespace management command .SH SYNOPSIS diff --git a/doc/man/nvme_ns_mgmt_create.2 b/doc/man/nvme_ns_mgmt_create.2 index 057f60b..ef77df6 100644 --- a/doc/man/nvme_ns_mgmt_create.2 +++ b/doc/man/nvme_ns_mgmt_create.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_mgmt_create" 9 "nvme_ns_mgmt_create" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_mgmt_create" 9 "nvme_ns_mgmt_create" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_mgmt_create \- Create a non attached namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_mgmt_delete.2 b/doc/man/nvme_ns_mgmt_delete.2 index 83970ae..599c5a8 100644 --- a/doc/man/nvme_ns_mgmt_delete.2 +++ b/doc/man/nvme_ns_mgmt_delete.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_mgmt_delete" 9 "nvme_ns_mgmt_delete" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_mgmt_delete" 9 "nvme_ns_mgmt_delete" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_mgmt_delete \- Delete a non attached namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_mgmt_host_sw_specified.2 b/doc/man/nvme_ns_mgmt_host_sw_specified.2 index 46c9f9c..46fe768 100644 --- a/doc/man/nvme_ns_mgmt_host_sw_specified.2 +++ b/doc/man/nvme_ns_mgmt_host_sw_specified.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_ns_mgmt_host_sw_specified" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_ns_mgmt_host_sw_specified" "September 2023" "API Manual" LINUX .SH NAME struct nvme_ns_mgmt_host_sw_specified \- Namespace management Host Software Specified Fields. .SH SYNOPSIS diff --git a/doc/man/nvme_ns_mgmt_sel.2 b/doc/man/nvme_ns_mgmt_sel.2 index 68eb862..8fe2211 100644 --- a/doc/man/nvme_ns_mgmt_sel.2 +++ b/doc/man/nvme_ns_mgmt_sel.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ns_mgmt_sel" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ns_mgmt_sel" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ns_mgmt_sel \- Namespace Management - Select .SH SYNOPSIS diff --git a/doc/man/nvme_ns_read.2 b/doc/man/nvme_ns_read.2 index c2697d7..2c9c416 100644 --- a/doc/man/nvme_ns_read.2 +++ b/doc/man/nvme_ns_read.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_read" 9 "nvme_ns_read" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_read" 9 "nvme_ns_read" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_read \- Read from a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_release_fd.2 b/doc/man/nvme_ns_release_fd.2 new file mode 100644 index 0000000..2958ec3 --- /dev/null +++ b/doc/man/nvme_ns_release_fd.2 @@ -0,0 +1,9 @@ +.TH "nvme_ns_release_fd" 9 "nvme_ns_release_fd" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_ns_release_fd \- Close fd and clear fd from ns object +.SH SYNOPSIS +.B "void" nvme_ns_release_fd +.BI "(nvme_ns_t n " ");" +.SH ARGUMENTS +.IP "n" 12 +Namespace instance diff --git a/doc/man/nvme_ns_rescan.2 b/doc/man/nvme_ns_rescan.2 index 3f88875..ee51c25 100644 --- a/doc/man/nvme_ns_rescan.2 +++ b/doc/man/nvme_ns_rescan.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_rescan" 9 "nvme_ns_rescan" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_rescan" 9 "nvme_ns_rescan" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_rescan \- Initiate a controller rescan .SH SYNOPSIS diff --git a/doc/man/nvme_ns_verify.2 b/doc/man/nvme_ns_verify.2 index 0b3ff46..4ab4cd0 100644 --- a/doc/man/nvme_ns_verify.2 +++ b/doc/man/nvme_ns_verify.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_verify" 9 "nvme_ns_verify" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_verify" 9 "nvme_ns_verify" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_verify \- Verify data on a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_write.2 b/doc/man/nvme_ns_write.2 index 290c0c6..951560c 100644 --- a/doc/man/nvme_ns_write.2 +++ b/doc/man/nvme_ns_write.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_write" 9 "nvme_ns_write" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_write" 9 "nvme_ns_write" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_write \- Write to a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_ns_write_protect_cfg.2 b/doc/man/nvme_ns_write_protect_cfg.2 index 96f0fa9..6d1af69 100644 --- a/doc/man/nvme_ns_write_protect_cfg.2 +++ b/doc/man/nvme_ns_write_protect_cfg.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_ns_write_protect_cfg" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_ns_write_protect_cfg" "September 2023" "API Manual" LINUX .SH NAME enum nvme_ns_write_protect_cfg \- Write Protection - Write Protection State .SH SYNOPSIS diff --git a/doc/man/nvme_ns_write_uncorrectable.2 b/doc/man/nvme_ns_write_uncorrectable.2 index ff3cedf..12550fa 100644 --- a/doc/man/nvme_ns_write_uncorrectable.2 +++ b/doc/man/nvme_ns_write_uncorrectable.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_write_uncorrectable" 9 "nvme_ns_write_uncorrectable" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_write_uncorrectable" 9 "nvme_ns_write_uncorrectable" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_write_uncorrectable \- Issus a 'write uncorrectable' command .SH SYNOPSIS diff --git a/doc/man/nvme_ns_write_zeros.2 b/doc/man/nvme_ns_write_zeros.2 index 4469c6c..40c94ba 100644 --- a/doc/man/nvme_ns_write_zeros.2 +++ b/doc/man/nvme_ns_write_zeros.2 @@ -1,4 +1,4 @@ -.TH "nvme_ns_write_zeros" 9 "nvme_ns_write_zeros" "June 2023" "libnvme API manual" LINUX +.TH "nvme_ns_write_zeros" 9 "nvme_ns_write_zeros" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_ns_write_zeros \- Write zeros to a namespace .SH SYNOPSIS diff --git a/doc/man/nvme_nss_hw_err_event.2 b/doc/man/nvme_nss_hw_err_event.2 index b34dff9..2792945 100644 --- a/doc/man/nvme_nss_hw_err_event.2 +++ b/doc/man/nvme_nss_hw_err_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_nss_hw_err_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_nss_hw_err_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_nss_hw_err_event \- NVM Subsystem Hardware Error Event .SH SYNOPSIS diff --git a/doc/man/nvme_nvm_id_ns.2 b/doc/man/nvme_nvm_id_ns.2 index 5ee4066..08e46d9 100644 --- a/doc/man/nvme_nvm_id_ns.2 +++ b/doc/man/nvme_nvm_id_ns.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_nvm_id_ns" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_nvm_id_ns" "September 2023" "API Manual" LINUX .SH NAME struct nvme_nvm_id_ns \- NVME Command Set I/O Command Set Specific Identify Namespace Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_nvm_id_ns_elbaf.2 b/doc/man/nvme_nvm_id_ns_elbaf.2 index 56bc5ea..87caffc 100644 --- a/doc/man/nvme_nvm_id_ns_elbaf.2 +++ b/doc/man/nvme_nvm_id_ns_elbaf.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_nvm_id_ns_elbaf" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_nvm_id_ns_elbaf" "September 2023" "API Manual" LINUX .SH NAME enum nvme_nvm_id_ns_elbaf \- This field indicates the extended LBA format .SH SYNOPSIS diff --git a/doc/man/nvme_nvm_identify_ctrl.2 b/doc/man/nvme_nvm_identify_ctrl.2 index b6aa4d4..789431e 100644 --- a/doc/man/nvme_nvm_identify_ctrl.2 +++ b/doc/man/nvme_nvm_identify_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_nvm_identify_ctrl" 9 "nvme_nvm_identify_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_nvm_identify_ctrl" 9 "nvme_nvm_identify_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_nvm_identify_ctrl \- Identify controller data .SH SYNOPSIS diff --git a/doc/man/nvme_nvmeset_pl_status.2 b/doc/man/nvme_nvmeset_pl_status.2 index ffe0737..5c0afc8 100644 --- a/doc/man/nvme_nvmeset_pl_status.2 +++ b/doc/man/nvme_nvmeset_pl_status.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_nvmeset_pl_status" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_nvmeset_pl_status" "September 2023" "API Manual" LINUX .SH NAME enum nvme_nvmeset_pl_status \- Predictable Latency Per NVM Set Log - Status .SH SYNOPSIS diff --git a/doc/man/nvme_nvmset_attr.2 b/doc/man/nvme_nvmset_attr.2 index be4b38d..c35ef02 100644 --- a/doc/man/nvme_nvmset_attr.2 +++ b/doc/man/nvme_nvmset_attr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_nvmset_attr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_nvmset_attr" "September 2023" "API Manual" LINUX .SH NAME struct nvme_nvmset_attr \- NVM Set Attributes Entry .SH SYNOPSIS diff --git a/doc/man/nvme_nvmset_pl_events.2 b/doc/man/nvme_nvmset_pl_events.2 index 5099602..8194633 100644 --- a/doc/man/nvme_nvmset_pl_events.2 +++ b/doc/man/nvme_nvmset_pl_events.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_nvmset_pl_events" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_nvmset_pl_events" "September 2023" "API Manual" LINUX .SH NAME enum nvme_nvmset_pl_events \- Predictable Latency Per NVM Set Log - Event Type .SH SYNOPSIS diff --git a/doc/man/nvme_nvmset_predictable_lat_log.2 b/doc/man/nvme_nvmset_predictable_lat_log.2 index 582999d..8c56158 100644 --- a/doc/man/nvme_nvmset_predictable_lat_log.2 +++ b/doc/man/nvme_nvmset_predictable_lat_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_nvmset_predictable_lat_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_nvmset_predictable_lat_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_nvmset_predictable_lat_log \- Predictable Latency Mode - Deterministic Threshold Configuration Data .SH SYNOPSIS diff --git a/doc/man/nvme_open.2 b/doc/man/nvme_open.2 index 628afa4..b681d7b 100644 --- a/doc/man/nvme_open.2 +++ b/doc/man/nvme_open.2 @@ -1,4 +1,4 @@ -.TH "nvme_open" 9 "nvme_open" "June 2023" "libnvme API manual" LINUX +.TH "nvme_open" 9 "nvme_open" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_open \- Open an nvme controller or namespace device .SH SYNOPSIS diff --git a/doc/man/nvme_passthru_cmd.2 b/doc/man/nvme_passthru_cmd.2 index 81ccb2b..ee7ba9c 100644 --- a/doc/man/nvme_passthru_cmd.2 +++ b/doc/man/nvme_passthru_cmd.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_passthru_cmd" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_passthru_cmd" "September 2023" "API Manual" LINUX .SH NAME struct nvme_passthru_cmd \- nvme passthrough command structure .SH SYNOPSIS diff --git a/doc/man/nvme_passthru_cmd64.2 b/doc/man/nvme_passthru_cmd64.2 index d34cb92..97e86f7 100644 --- a/doc/man/nvme_passthru_cmd64.2 +++ b/doc/man/nvme_passthru_cmd64.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_passthru_cmd64" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_passthru_cmd64" "September 2023" "API Manual" LINUX .SH NAME struct nvme_passthru_cmd64 \- 64-bit nvme passthrough command structure .SH SYNOPSIS diff --git a/doc/man/nvme_path_get_ana_state.2 b/doc/man/nvme_path_get_ana_state.2 index d00d4b4..634c672 100644 --- a/doc/man/nvme_path_get_ana_state.2 +++ b/doc/man/nvme_path_get_ana_state.2 @@ -1,4 +1,4 @@ -.TH "nvme_path_get_ana_state" 9 "nvme_path_get_ana_state" "June 2023" "libnvme API manual" LINUX +.TH "nvme_path_get_ana_state" 9 "nvme_path_get_ana_state" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_path_get_ana_state \- ANA state of an nvme_path_t object .SH SYNOPSIS diff --git a/doc/man/nvme_path_get_ctrl.2 b/doc/man/nvme_path_get_ctrl.2 index da682c7..7bb79ac 100644 --- a/doc/man/nvme_path_get_ctrl.2 +++ b/doc/man/nvme_path_get_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_path_get_ctrl" 9 "nvme_path_get_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_path_get_ctrl" 9 "nvme_path_get_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_path_get_ctrl \- Parent controller of an nvme_path_t object .SH SYNOPSIS diff --git a/doc/man/nvme_path_get_name.2 b/doc/man/nvme_path_get_name.2 index b99892c..ca9e282 100644 --- a/doc/man/nvme_path_get_name.2 +++ b/doc/man/nvme_path_get_name.2 @@ -1,4 +1,4 @@ -.TH "nvme_path_get_name" 9 "nvme_path_get_name" "June 2023" "libnvme API manual" LINUX +.TH "nvme_path_get_name" 9 "nvme_path_get_name" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_path_get_name \- sysfs name of an &nvme_path_t object .SH SYNOPSIS diff --git a/doc/man/nvme_path_get_ns.2 b/doc/man/nvme_path_get_ns.2 index 9680b6c..29d7fb4 100644 --- a/doc/man/nvme_path_get_ns.2 +++ b/doc/man/nvme_path_get_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_path_get_ns" 9 "nvme_path_get_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_path_get_ns" 9 "nvme_path_get_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_path_get_ns \- Parent namespace of an nvme_path_t object .SH SYNOPSIS diff --git a/doc/man/nvme_path_get_sysfs_dir.2 b/doc/man/nvme_path_get_sysfs_dir.2 index ae262b9..0d19f3f 100644 --- a/doc/man/nvme_path_get_sysfs_dir.2 +++ b/doc/man/nvme_path_get_sysfs_dir.2 @@ -1,4 +1,4 @@ -.TH "nvme_path_get_sysfs_dir" 9 "nvme_path_get_sysfs_dir" "June 2023" "libnvme API manual" LINUX +.TH "nvme_path_get_sysfs_dir" 9 "nvme_path_get_sysfs_dir" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_path_get_sysfs_dir \- sysfs directory of an nvme_path_t object .SH SYNOPSIS diff --git a/doc/man/nvme_paths_filter.2 b/doc/man/nvme_paths_filter.2 index 69f25bc..518d41d 100644 --- a/doc/man/nvme_paths_filter.2 +++ b/doc/man/nvme_paths_filter.2 @@ -1,4 +1,4 @@ -.TH "nvme_paths_filter" 9 "nvme_paths_filter" "June 2023" "libnvme API manual" LINUX +.TH "nvme_paths_filter" 9 "nvme_paths_filter" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_paths_filter \- Filter for paths .SH SYNOPSIS diff --git a/doc/man/nvme_persistent_event_entry.2 b/doc/man/nvme_persistent_event_entry.2 index 1fb0bd1..f6f193b 100644 --- a/doc/man/nvme_persistent_event_entry.2 +++ b/doc/man/nvme_persistent_event_entry.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_persistent_event_entry" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_persistent_event_entry" "September 2023" "API Manual" LINUX .SH NAME struct nvme_persistent_event_entry \- Persistent Event .SH SYNOPSIS diff --git a/doc/man/nvme_persistent_event_log.2 b/doc/man/nvme_persistent_event_log.2 index e5c042b..5ae1832 100644 --- a/doc/man/nvme_persistent_event_log.2 +++ b/doc/man/nvme_persistent_event_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_persistent_event_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_persistent_event_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_persistent_event_log \- Persistent Event Log .SH SYNOPSIS diff --git a/doc/man/nvme_persistent_event_types.2 b/doc/man/nvme_persistent_event_types.2 index 67be426..b43786f 100644 --- a/doc/man/nvme_persistent_event_types.2 +++ b/doc/man/nvme_persistent_event_types.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_persistent_event_types" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_persistent_event_types" "September 2023" "API Manual" LINUX .SH NAME enum nvme_persistent_event_types \- Persistent event log events .SH SYNOPSIS diff --git a/doc/man/nvme_pevent_log_action.2 b/doc/man/nvme_pevent_log_action.2 index c84d51c..3769447 100644 --- a/doc/man/nvme_pevent_log_action.2 +++ b/doc/man/nvme_pevent_log_action.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_pevent_log_action" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_pevent_log_action" "September 2023" "API Manual" LINUX .SH NAME enum nvme_pevent_log_action \- Persistent Event Log - Action .SH SYNOPSIS diff --git a/doc/man/nvme_phy_rx_eom_log.2 b/doc/man/nvme_phy_rx_eom_log.2 new file mode 100644 index 0000000..c68f2c7 --- /dev/null +++ b/doc/man/nvme_phy_rx_eom_log.2 @@ -0,0 +1,99 @@ +.TH "libnvme" 9 "struct nvme_phy_rx_eom_log" "September 2023" "API Manual" LINUX +.SH NAME +struct nvme_phy_rx_eom_log \- Physical Interface Receiver Eye Opening Measurement Log +.SH SYNOPSIS +struct nvme_phy_rx_eom_log { +.br +.BI " __u8 lid;" +.br +.BI " __u8 eomip;" +.br +.BI " __le16 hsize;" +.br +.BI " __le32 rsize;" +.br +.BI " __u8 eomdgn;" +.br +.BI " __u8 lr;" +.br +.BI " __u8 odp;" +.br +.BI " __u8 lanes;" +.br +.BI " __u8 epl;" +.br +.BI " __u8 lspfc;" +.br +.BI " __u8 li;" +.br +.BI " __u8 rsvd15[3];" +.br +.BI " __le16 lsic;" +.br +.BI " __le32 dsize;" +.br +.BI " __le16 nd;" +.br +.BI " __le16 maxtb;" +.br +.BI " __le16 maxlr;" +.br +.BI " __le16 etgood;" +.br +.BI " __le16 etbetter;" +.br +.BI " __le16 etbest;" +.br +.BI " __u8 rsvd36[28];" +.br +.BI " struct nvme_eom_lane_desc descs[];" +.br +.BI " +}; +.br + +.SH Members +.IP "lid" 12 +Log Identifier +.IP "eomip" 12 +EOM In Progress +.IP "hsize" 12 +Header Size +.IP "rsize" 12 +Result Size +.IP "eomdgn" 12 +EOM Data Generation Number +.IP "lr" 12 +Log Revision +.IP "odp" 12 +Optional Data Present +.IP "lanes" 12 +Number of lanes configured for this port +.IP "epl" 12 +Eyes Per Lane +.IP "lspfc" 12 +Log Specific Parameter Field Copy +.IP "li" 12 +Link Information +.IP "rsvd15" 12 +Reserved +.IP "lsic" 12 +Log Specific Identifier Copy +.IP "dsize" 12 +Descriptor Size +.IP "nd" 12 +Number of Descriptors +.IP "maxtb" 12 +Maximum Top Bottom +.IP "maxlr" 12 +Maximum Left Right +.IP "etgood" 12 +Estimated Time for Good Quality +.IP "etbetter" 12 +Estimated Time for Better Quality +.IP "etbest" 12 +Estimated Time for Best Quality +.IP "rsvd36" 12 +Reserved +.IP "descs" 12 +EOM Lane Descriptors diff --git a/doc/man/nvme_phy_rx_eom_progress.2 b/doc/man/nvme_phy_rx_eom_progress.2 new file mode 100644 index 0000000..4e4b2fb --- /dev/null +++ b/doc/man/nvme_phy_rx_eom_progress.2 @@ -0,0 +1,24 @@ +.TH "libnvme" 9 "enum nvme_phy_rx_eom_progress" "September 2023" "API Manual" LINUX +.SH NAME +enum nvme_phy_rx_eom_progress \- EOM In Progress Values +.SH SYNOPSIS +enum nvme_phy_rx_eom_progress { +.br +.BI " NVME_PHY_RX_EOM_NOT_STARTED" +, +.br +.br +.BI " NVME_PHY_RX_EOM_IN_PROGRESS" +, +.br +.br +.BI " NVME_PHY_RX_EOM_COMPLETED" + +}; +.SH Constants +.IP "NVME_PHY_RX_EOM_NOT_STARTED" 12 +EOM Not Started +.IP "NVME_PHY_RX_EOM_IN_PROGRESS" 12 +EOM In Progress +.IP "NVME_PHY_RX_EOM_COMPLETED" 12 +EOM Completed diff --git a/doc/man/nvme_plm_config.2 b/doc/man/nvme_plm_config.2 index c0886fd..8731b9b 100644 --- a/doc/man/nvme_plm_config.2 +++ b/doc/man/nvme_plm_config.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_plm_config" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_plm_config" "September 2023" "API Manual" LINUX .SH NAME struct nvme_plm_config \- Predictable Latency Mode - Deterministic Threshold Configuration Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_pmr_size.2 b/doc/man/nvme_pmr_size.2 index bf6aad9..5cbab51 100644 --- a/doc/man/nvme_pmr_size.2 +++ b/doc/man/nvme_pmr_size.2 @@ -1,4 +1,4 @@ -.TH "nvme_pmr_size" 9 "nvme_pmr_size" "June 2023" "libnvme API manual" LINUX +.TH "nvme_pmr_size" 9 "nvme_pmr_size" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_pmr_size \- Calculate size of persistent memory region elasticity buffer .SH SYNOPSIS diff --git a/doc/man/nvme_pmr_throughput.2 b/doc/man/nvme_pmr_throughput.2 index d0df4d6..e557726 100644 --- a/doc/man/nvme_pmr_throughput.2 +++ b/doc/man/nvme_pmr_throughput.2 @@ -1,4 +1,4 @@ -.TH "nvme_pmr_throughput" 9 "nvme_pmr_throughput" "June 2023" "libnvme API manual" LINUX +.TH "nvme_pmr_throughput" 9 "nvme_pmr_throughput" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_pmr_throughput \- Calculate throughput of persistent memory buffer .SH SYNOPSIS diff --git a/doc/man/nvme_power_on_reset_info_list.2 b/doc/man/nvme_power_on_reset_info_list.2 index 834b032..7d8b721 100644 --- a/doc/man/nvme_power_on_reset_info_list.2 +++ b/doc/man/nvme_power_on_reset_info_list.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_power_on_reset_info_list" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_power_on_reset_info_list" "September 2023" "API Manual" LINUX .SH NAME struct nvme_power_on_reset_info_list \- Controller Reset Information .SH SYNOPSIS diff --git a/doc/man/nvme_primary_ctrl_cap.2 b/doc/man/nvme_primary_ctrl_cap.2 index 9ab721b..37c4820 100644 --- a/doc/man/nvme_primary_ctrl_cap.2 +++ b/doc/man/nvme_primary_ctrl_cap.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_primary_ctrl_cap" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_primary_ctrl_cap" "September 2023" "API Manual" LINUX .SH NAME struct nvme_primary_ctrl_cap \- Identify - Controller Capabilities Structure .SH SYNOPSIS diff --git a/doc/man/nvme_psd_flags.2 b/doc/man/nvme_psd_flags.2 index b7d24c4..bb4491d 100644 --- a/doc/man/nvme_psd_flags.2 +++ b/doc/man/nvme_psd_flags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_psd_flags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_psd_flags" "September 2023" "API Manual" LINUX .SH NAME enum nvme_psd_flags \- Possible flag values in nvme power state descriptor .SH SYNOPSIS diff --git a/doc/man/nvme_psd_power_scale.2 b/doc/man/nvme_psd_power_scale.2 index 27d28aa..2608f81 100644 --- a/doc/man/nvme_psd_power_scale.2 +++ b/doc/man/nvme_psd_power_scale.2 @@ -1,4 +1,4 @@ -.TH "nvme_psd_power_scale" 9 "nvme_psd_power_scale" "June 2023" "libnvme API manual" LINUX +.TH "nvme_psd_power_scale" 9 "nvme_psd_power_scale" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_psd_power_scale \- power scale occupies the upper 3 bits .SH SYNOPSIS diff --git a/doc/man/nvme_psd_ps.2 b/doc/man/nvme_psd_ps.2 index 2f9d3f3..8de5356 100644 --- a/doc/man/nvme_psd_ps.2 +++ b/doc/man/nvme_psd_ps.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_psd_ps" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_psd_ps" "September 2023" "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. .SH SYNOPSIS diff --git a/doc/man/nvme_psd_workload.2 b/doc/man/nvme_psd_workload.2 index dddb9d3..a8609f5 100644 --- a/doc/man/nvme_psd_workload.2 +++ b/doc/man/nvme_psd_workload.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_psd_workload" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_psd_workload" "September 2023" "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 diff --git a/doc/man/nvme_read.2 b/doc/man/nvme_read.2 index ec2f3ec..c8ae060 100644 --- a/doc/man/nvme_read.2 +++ b/doc/man/nvme_read.2 @@ -1,4 +1,4 @@ -.TH "nvme_read" 9 "nvme_read" "June 2023" "libnvme API manual" LINUX +.TH "nvme_read" 9 "nvme_read" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_read \- Submit an nvme user read command .SH SYNOPSIS diff --git a/doc/man/nvme_read_config.2 b/doc/man/nvme_read_config.2 index 75200ef..994f7f4 100644 --- a/doc/man/nvme_read_config.2 +++ b/doc/man/nvme_read_config.2 @@ -1,4 +1,4 @@ -.TH "nvme_read_config" 9 "nvme_read_config" "June 2023" "libnvme API manual" LINUX +.TH "nvme_read_config" 9 "nvme_read_config" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_read_config \- Read NVMe JSON configuration file .SH SYNOPSIS diff --git a/doc/man/nvme_refresh_topology.2 b/doc/man/nvme_refresh_topology.2 index d14cf6a..1fb48a0 100644 --- a/doc/man/nvme_refresh_topology.2 +++ b/doc/man/nvme_refresh_topology.2 @@ -1,4 +1,4 @@ -.TH "nvme_refresh_topology" 9 "nvme_refresh_topology" "June 2023" "libnvme API manual" LINUX +.TH "nvme_refresh_topology" 9 "nvme_refresh_topology" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_refresh_topology \- Refresh nvme_root_t object contents .SH SYNOPSIS diff --git a/doc/man/nvme_register_offsets.2 b/doc/man/nvme_register_offsets.2 index 605d67d..3afaec0 100644 --- a/doc/man/nvme_register_offsets.2 +++ b/doc/man/nvme_register_offsets.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_register_offsets" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_register_offsets" "September 2023" "API Manual" LINUX .SH NAME enum nvme_register_offsets \- controller registers for all transports. This is the layout of BAR0/1 for PCIe, and properties for fabrics. .SH SYNOPSIS diff --git a/doc/man/nvme_registered_ctrl.2 b/doc/man/nvme_registered_ctrl.2 index bf10ec0..a68fc4b 100644 --- a/doc/man/nvme_registered_ctrl.2 +++ b/doc/man/nvme_registered_ctrl.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_registered_ctrl" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_registered_ctrl" "September 2023" "API Manual" LINUX .SH NAME struct nvme_registered_ctrl \- Registered Controller Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_registered_ctrl_ext.2 b/doc/man/nvme_registered_ctrl_ext.2 index 351d011..618a8bb 100644 --- a/doc/man/nvme_registered_ctrl_ext.2 +++ b/doc/man/nvme_registered_ctrl_ext.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_registered_ctrl_ext" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_registered_ctrl_ext" "September 2023" "API Manual" LINUX .SH NAME struct nvme_registered_ctrl_ext \- Registered Controller Extended Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_rescan_ctrl.2 b/doc/man/nvme_rescan_ctrl.2 index e634ed5..fc8a472 100644 --- a/doc/man/nvme_rescan_ctrl.2 +++ b/doc/man/nvme_rescan_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_rescan_ctrl" 9 "nvme_rescan_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_rescan_ctrl" 9 "nvme_rescan_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_rescan_ctrl \- Rescan an existing controller .SH SYNOPSIS diff --git a/doc/man/nvme_resv_acquire.2 b/doc/man/nvme_resv_acquire.2 index 7453c59..bfe6b72 100644 --- a/doc/man/nvme_resv_acquire.2 +++ b/doc/man/nvme_resv_acquire.2 @@ -1,4 +1,4 @@ -.TH "nvme_resv_acquire" 9 "nvme_resv_acquire" "June 2023" "libnvme API manual" LINUX +.TH "nvme_resv_acquire" 9 "nvme_resv_acquire" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_resv_acquire \- Send an nvme reservation acquire .SH SYNOPSIS diff --git a/doc/man/nvme_resv_cptpl.2 b/doc/man/nvme_resv_cptpl.2 index 09da5c7..f0c2cff 100644 --- a/doc/man/nvme_resv_cptpl.2 +++ b/doc/man/nvme_resv_cptpl.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_resv_cptpl" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_resv_cptpl" "September 2023" "API Manual" LINUX .SH NAME enum nvme_resv_cptpl \- Reservation Register - Change Persist Through Power Loss State .SH SYNOPSIS diff --git a/doc/man/nvme_resv_notification_log.2 b/doc/man/nvme_resv_notification_log.2 index 78d7770..96988a3 100644 --- a/doc/man/nvme_resv_notification_log.2 +++ b/doc/man/nvme_resv_notification_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_resv_notification_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_resv_notification_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_resv_notification_log \- Reservation Notification Log .SH SYNOPSIS diff --git a/doc/man/nvme_resv_notify_rnlpt.2 b/doc/man/nvme_resv_notify_rnlpt.2 index 218f7fd..7910194 100644 --- a/doc/man/nvme_resv_notify_rnlpt.2 +++ b/doc/man/nvme_resv_notify_rnlpt.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_resv_notify_rnlpt" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_resv_notify_rnlpt" "September 2023" "API Manual" LINUX .SH NAME enum nvme_resv_notify_rnlpt \- Reservation Notification Log - Reservation Notification Log Page Type .SH SYNOPSIS diff --git a/doc/man/nvme_resv_racqa.2 b/doc/man/nvme_resv_racqa.2 index 462849d..2cc2348 100644 --- a/doc/man/nvme_resv_racqa.2 +++ b/doc/man/nvme_resv_racqa.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_resv_racqa" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_resv_racqa" "September 2023" "API Manual" LINUX .SH NAME enum nvme_resv_racqa \- Reservation Acquire - Reservation Acquire Action .SH SYNOPSIS diff --git a/doc/man/nvme_resv_register.2 b/doc/man/nvme_resv_register.2 index b9a9c62..b0db02c 100644 --- a/doc/man/nvme_resv_register.2 +++ b/doc/man/nvme_resv_register.2 @@ -1,4 +1,4 @@ -.TH "nvme_resv_register" 9 "nvme_resv_register" "June 2023" "libnvme API manual" LINUX +.TH "nvme_resv_register" 9 "nvme_resv_register" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_resv_register \- Send an nvme reservation register .SH SYNOPSIS diff --git a/doc/man/nvme_resv_release.2 b/doc/man/nvme_resv_release.2 index 6c5a711..8cb6e5d 100644 --- a/doc/man/nvme_resv_release.2 +++ b/doc/man/nvme_resv_release.2 @@ -1,4 +1,4 @@ -.TH "nvme_resv_release" 9 "nvme_resv_release" "June 2023" "libnvme API manual" LINUX +.TH "nvme_resv_release" 9 "nvme_resv_release" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_resv_release \- Send an nvme reservation release .SH SYNOPSIS diff --git a/doc/man/nvme_resv_report.2 b/doc/man/nvme_resv_report.2 index 9053502..7f8e742 100644 --- a/doc/man/nvme_resv_report.2 +++ b/doc/man/nvme_resv_report.2 @@ -1,4 +1,4 @@ -.TH "nvme_resv_report" 9 "nvme_resv_report" "June 2023" "libnvme API manual" LINUX +.TH "nvme_resv_report" 9 "nvme_resv_report" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_resv_report \- Send an nvme reservation report .SH SYNOPSIS diff --git a/doc/man/nvme_resv_rrega.2 b/doc/man/nvme_resv_rrega.2 index 0d994c7..d6cd8ef 100644 --- a/doc/man/nvme_resv_rrega.2 +++ b/doc/man/nvme_resv_rrega.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_resv_rrega" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_resv_rrega" "September 2023" "API Manual" LINUX .SH NAME enum nvme_resv_rrega \- Reservation Register - Reservation Register Action .SH SYNOPSIS diff --git a/doc/man/nvme_resv_rrela.2 b/doc/man/nvme_resv_rrela.2 index 1163c2b..b51d035 100644 --- a/doc/man/nvme_resv_rrela.2 +++ b/doc/man/nvme_resv_rrela.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_resv_rrela" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_resv_rrela" "September 2023" "API Manual" LINUX .SH NAME enum nvme_resv_rrela \- Reservation Release - Reservation Release Action .SH SYNOPSIS diff --git a/doc/man/nvme_resv_rtype.2 b/doc/man/nvme_resv_rtype.2 index 53d1bd7..9c5c5f6 100644 --- a/doc/man/nvme_resv_rtype.2 +++ b/doc/man/nvme_resv_rtype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_resv_rtype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_resv_rtype" "September 2023" "API Manual" LINUX .SH NAME enum nvme_resv_rtype \- Reservation Type Encoding .SH SYNOPSIS diff --git a/doc/man/nvme_resv_status.2 b/doc/man/nvme_resv_status.2 index e61190a..4eacf34 100644 --- a/doc/man/nvme_resv_status.2 +++ b/doc/man/nvme_resv_status.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_resv_status" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_resv_status" "September 2023" "API Manual" LINUX .SH NAME struct nvme_resv_status \- Reservation Status Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_sanitize_compln_event.2 b/doc/man/nvme_sanitize_compln_event.2 index cee384b..980ed46 100644 --- a/doc/man/nvme_sanitize_compln_event.2 +++ b/doc/man/nvme_sanitize_compln_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_sanitize_compln_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_sanitize_compln_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_sanitize_compln_event \- Sanitize Completion Event Data .SH SYNOPSIS diff --git a/doc/man/nvme_sanitize_log_page.2 b/doc/man/nvme_sanitize_log_page.2 index 1f5bf66..9814692 100644 --- a/doc/man/nvme_sanitize_log_page.2 +++ b/doc/man/nvme_sanitize_log_page.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_sanitize_log_page" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_sanitize_log_page" "September 2023" "API Manual" LINUX .SH NAME struct nvme_sanitize_log_page \- Sanitize Status (Log Identifier 81h) .SH SYNOPSIS diff --git a/doc/man/nvme_sanitize_nvm.2 b/doc/man/nvme_sanitize_nvm.2 index 359856a..4de58d6 100644 --- a/doc/man/nvme_sanitize_nvm.2 +++ b/doc/man/nvme_sanitize_nvm.2 @@ -1,4 +1,4 @@ -.TH "nvme_sanitize_nvm" 9 "nvme_sanitize_nvm" "June 2023" "libnvme API manual" LINUX +.TH "nvme_sanitize_nvm" 9 "nvme_sanitize_nvm" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_sanitize_nvm \- Start a sanitize operation .SH SYNOPSIS diff --git a/doc/man/nvme_sanitize_sanact.2 b/doc/man/nvme_sanitize_sanact.2 index 9a37206..3c79096 100644 --- a/doc/man/nvme_sanitize_sanact.2 +++ b/doc/man/nvme_sanitize_sanact.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_sanitize_sanact" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_sanitize_sanact" "September 2023" "API Manual" LINUX .SH NAME enum nvme_sanitize_sanact \- Sanitize Action .SH SYNOPSIS diff --git a/doc/man/nvme_sanitize_sstat.2 b/doc/man/nvme_sanitize_sstat.2 index 15eb25e..0b8c06c 100644 --- a/doc/man/nvme_sanitize_sstat.2 +++ b/doc/man/nvme_sanitize_sstat.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_sanitize_sstat" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_sanitize_sstat" "September 2023" "API Manual" LINUX .SH NAME enum nvme_sanitize_sstat \- Sanitize Status (SSTAT) .SH SYNOPSIS diff --git a/doc/man/nvme_sanitize_start_event.2 b/doc/man/nvme_sanitize_start_event.2 index e80dbcf..82424b8 100644 --- a/doc/man/nvme_sanitize_start_event.2 +++ b/doc/man/nvme_sanitize_start_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_sanitize_start_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_sanitize_start_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_sanitize_start_event \- Sanitize Start Event Data .SH SYNOPSIS diff --git a/doc/man/nvme_scan.2 b/doc/man/nvme_scan.2 index 0d51726..6e494bd 100644 --- a/doc/man/nvme_scan.2 +++ b/doc/man/nvme_scan.2 @@ -1,4 +1,4 @@ -.TH "nvme_scan" 9 "nvme_scan" "June 2023" "libnvme API manual" LINUX +.TH "nvme_scan" 9 "nvme_scan" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_scan \- Scan NVMe topology .SH SYNOPSIS diff --git a/doc/man/nvme_scan_ctrl.2 b/doc/man/nvme_scan_ctrl.2 index b3c4363..768e765 100644 --- a/doc/man/nvme_scan_ctrl.2 +++ b/doc/man/nvme_scan_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_scan_ctrl" 9 "nvme_scan_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_scan_ctrl" 9 "nvme_scan_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_scan_ctrl \- Scan on a controller .SH SYNOPSIS diff --git a/doc/man/nvme_scan_ctrl_namespace_paths.2 b/doc/man/nvme_scan_ctrl_namespace_paths.2 index 950c429..77f262f 100644 --- a/doc/man/nvme_scan_ctrl_namespace_paths.2 +++ b/doc/man/nvme_scan_ctrl_namespace_paths.2 @@ -1,4 +1,4 @@ -.TH "nvme_scan_ctrl_namespace_paths" 9 "nvme_scan_ctrl_namespace_paths" "June 2023" "libnvme API manual" LINUX +.TH "nvme_scan_ctrl_namespace_paths" 9 "nvme_scan_ctrl_namespace_paths" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_scan_ctrl_namespace_paths \- Scan for namespace paths in a controller .SH SYNOPSIS diff --git a/doc/man/nvme_scan_ctrl_namespaces.2 b/doc/man/nvme_scan_ctrl_namespaces.2 index ea73d72..beeb01f 100644 --- a/doc/man/nvme_scan_ctrl_namespaces.2 +++ b/doc/man/nvme_scan_ctrl_namespaces.2 @@ -1,4 +1,4 @@ -.TH "nvme_scan_ctrl_namespaces" 9 "nvme_scan_ctrl_namespaces" "June 2023" "libnvme API manual" LINUX +.TH "nvme_scan_ctrl_namespaces" 9 "nvme_scan_ctrl_namespaces" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_scan_ctrl_namespaces \- Scan for namespaces in a controller .SH SYNOPSIS diff --git a/doc/man/nvme_scan_ctrls.2 b/doc/man/nvme_scan_ctrls.2 index 43bc789..1005435 100644 --- a/doc/man/nvme_scan_ctrls.2 +++ b/doc/man/nvme_scan_ctrls.2 @@ -1,4 +1,4 @@ -.TH "nvme_scan_ctrls" 9 "nvme_scan_ctrls" "June 2023" "libnvme API manual" LINUX +.TH "nvme_scan_ctrls" 9 "nvme_scan_ctrls" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_scan_ctrls \- Scan for controllers .SH SYNOPSIS diff --git a/doc/man/nvme_scan_namespace.2 b/doc/man/nvme_scan_namespace.2 index b5ca690..6ff2a8f 100644 --- a/doc/man/nvme_scan_namespace.2 +++ b/doc/man/nvme_scan_namespace.2 @@ -1,4 +1,4 @@ -.TH "nvme_scan_namespace" 9 "nvme_scan_namespace" "June 2023" "libnvme API manual" LINUX +.TH "nvme_scan_namespace" 9 "nvme_scan_namespace" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_scan_namespace \- scan namespace based on sysfs name .SH SYNOPSIS diff --git a/doc/man/nvme_scan_subsystem_namespaces.2 b/doc/man/nvme_scan_subsystem_namespaces.2 index ad74f8a..a8c8c3a 100644 --- a/doc/man/nvme_scan_subsystem_namespaces.2 +++ b/doc/man/nvme_scan_subsystem_namespaces.2 @@ -1,4 +1,4 @@ -.TH "nvme_scan_subsystem_namespaces" 9 "nvme_scan_subsystem_namespaces" "June 2023" "libnvme API manual" LINUX +.TH "nvme_scan_subsystem_namespaces" 9 "nvme_scan_subsystem_namespaces" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_scan_subsystem_namespaces \- Scan for namespaces in a subsystem .SH SYNOPSIS diff --git a/doc/man/nvme_scan_subsystems.2 b/doc/man/nvme_scan_subsystems.2 index 794caf8..c3680f8 100644 --- a/doc/man/nvme_scan_subsystems.2 +++ b/doc/man/nvme_scan_subsystems.2 @@ -1,4 +1,4 @@ -.TH "nvme_scan_subsystems" 9 "nvme_scan_subsystems" "June 2023" "libnvme API manual" LINUX +.TH "nvme_scan_subsystems" 9 "nvme_scan_subsystems" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_scan_subsystems \- Scan for subsystems .SH SYNOPSIS diff --git a/doc/man/nvme_scan_topology.2 b/doc/man/nvme_scan_topology.2 index 4cd6bf7..3255435 100644 --- a/doc/man/nvme_scan_topology.2 +++ b/doc/man/nvme_scan_topology.2 @@ -1,4 +1,4 @@ -.TH "nvme_scan_topology" 9 "nvme_scan_topology" "June 2023" "libnvme API manual" LINUX +.TH "nvme_scan_topology" 9 "nvme_scan_topology" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_scan_topology \- Scan NVMe topology and apply filter .SH SYNOPSIS diff --git a/doc/man/nvme_secondary_ctrl.2 b/doc/man/nvme_secondary_ctrl.2 index 91516a4..6fda9b2 100644 --- a/doc/man/nvme_secondary_ctrl.2 +++ b/doc/man/nvme_secondary_ctrl.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_secondary_ctrl" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_secondary_ctrl" "September 2023" "API Manual" LINUX .SH NAME struct nvme_secondary_ctrl \- Secondary Controller Entry .SH SYNOPSIS diff --git a/doc/man/nvme_secondary_ctrl_list.2 b/doc/man/nvme_secondary_ctrl_list.2 index 1a67f7a..856220d 100644 --- a/doc/man/nvme_secondary_ctrl_list.2 +++ b/doc/man/nvme_secondary_ctrl_list.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_secondary_ctrl_list" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_secondary_ctrl_list" "September 2023" "API Manual" LINUX .SH NAME struct nvme_secondary_ctrl_list \- Secondary Controller List .SH SYNOPSIS diff --git a/doc/man/nvme_security_receive.2 b/doc/man/nvme_security_receive.2 index cbbb0af..0fcf13d 100644 --- a/doc/man/nvme_security_receive.2 +++ b/doc/man/nvme_security_receive.2 @@ -1,4 +1,4 @@ -.TH "nvme_security_receive" 9 "nvme_security_receive" "June 2023" "libnvme API manual" LINUX +.TH "nvme_security_receive" 9 "nvme_security_receive" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_security_receive \- Security Receive command .SH SYNOPSIS diff --git a/doc/man/nvme_security_send.2 b/doc/man/nvme_security_send.2 index dc889d6..14f76e5 100644 --- a/doc/man/nvme_security_send.2 +++ b/doc/man/nvme_security_send.2 @@ -1,4 +1,4 @@ -.TH "nvme_security_send" 9 "nvme_security_send" "June 2023" "libnvme API manual" LINUX +.TH "nvme_security_send" 9 "nvme_security_send" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_security_send \- Security Send command .SH SYNOPSIS diff --git a/doc/man/nvme_self_test_log.2 b/doc/man/nvme_self_test_log.2 index 2117bb5..74c153a 100644 --- a/doc/man/nvme_self_test_log.2 +++ b/doc/man/nvme_self_test_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_self_test_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_self_test_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_self_test_log \- Device Self-test (Log Identifier 06h) .SH SYNOPSIS diff --git a/doc/man/nvme_set_feature_event.2 b/doc/man/nvme_set_feature_event.2 index 56e950f..821240c 100644 --- a/doc/man/nvme_set_feature_event.2 +++ b/doc/man/nvme_set_feature_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_set_feature_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_set_feature_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_set_feature_event \- Set Feature Event Data .SH SYNOPSIS diff --git a/doc/man/nvme_set_features.2 b/doc/man/nvme_set_features.2 index f7d4afc..38561d6 100644 --- a/doc/man/nvme_set_features.2 +++ b/doc/man/nvme_set_features.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features" 9 "nvme_set_features" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features" 9 "nvme_set_features" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features \- Set a feature attribute .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_arbitration.2 b/doc/man/nvme_set_features_arbitration.2 index 6b0d504..73c59df 100644 --- a/doc/man/nvme_set_features_arbitration.2 +++ b/doc/man/nvme_set_features_arbitration.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_arbitration" 9 "nvme_set_features_arbitration" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_arbitration" 9 "nvme_set_features_arbitration" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_arbitration \- Set arbitration features .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_async_event.2 b/doc/man/nvme_set_features_async_event.2 index b9e365b..03d115c 100644 --- a/doc/man/nvme_set_features_async_event.2 +++ b/doc/man/nvme_set_features_async_event.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_async_event" 9 "nvme_set_features_async_event" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_async_event" 9 "nvme_set_features_async_event" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_async_event \- Set asynchronous event feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_auto_pst.2 b/doc/man/nvme_set_features_auto_pst.2 index d983f6b..df8d20a 100644 --- a/doc/man/nvme_set_features_auto_pst.2 +++ b/doc/man/nvme_set_features_auto_pst.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_auto_pst" 9 "nvme_set_features_auto_pst" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_auto_pst" 9 "nvme_set_features_auto_pst" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_auto_pst \- Set autonomous power state feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_data.2 b/doc/man/nvme_set_features_data.2 index 6723d92..b717e5d 100644 --- a/doc/man/nvme_set_features_data.2 +++ b/doc/man/nvme_set_features_data.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_data" 9 "nvme_set_features_data" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_data" 9 "nvme_set_features_data" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_data \- Helper function for @nvme_set_features() .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_endurance_evt_cfg.2 b/doc/man/nvme_set_features_endurance_evt_cfg.2 index d2e319a..ad91f67 100644 --- a/doc/man/nvme_set_features_endurance_evt_cfg.2 +++ b/doc/man/nvme_set_features_endurance_evt_cfg.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_endurance_evt_cfg" 9 "nvme_set_features_endurance_evt_cfg" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_endurance_evt_cfg" 9 "nvme_set_features_endurance_evt_cfg" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_endurance_evt_cfg \- Set endurance event config feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_err_recovery.2 b/doc/man/nvme_set_features_err_recovery.2 index 2cac43a..72b01c1 100644 --- a/doc/man/nvme_set_features_err_recovery.2 +++ b/doc/man/nvme_set_features_err_recovery.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_err_recovery" 9 "nvme_set_features_err_recovery" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_err_recovery" 9 "nvme_set_features_err_recovery" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_err_recovery \- Set error recovery feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_hctm.2 b/doc/man/nvme_set_features_hctm.2 index 310a987..a4087fe 100644 --- a/doc/man/nvme_set_features_hctm.2 +++ b/doc/man/nvme_set_features_hctm.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_hctm" 9 "nvme_set_features_hctm" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_hctm" 9 "nvme_set_features_hctm" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_hctm \- Set thermal management feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_host_behavior.2 b/doc/man/nvme_set_features_host_behavior.2 index 995905b..fb2dc29 100644 --- a/doc/man/nvme_set_features_host_behavior.2 +++ b/doc/man/nvme_set_features_host_behavior.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_host_behavior" 9 "nvme_set_features_host_behavior" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_host_behavior" 9 "nvme_set_features_host_behavior" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_host_behavior \- Set host behavior feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_host_id.2 b/doc/man/nvme_set_features_host_id.2 index f548497..a43d663 100644 --- a/doc/man/nvme_set_features_host_id.2 +++ b/doc/man/nvme_set_features_host_id.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_host_id" 9 "nvme_set_features_host_id" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_host_id" 9 "nvme_set_features_host_id" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_host_id \- Set enable extended host identifiers feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_iocs_profile.2 b/doc/man/nvme_set_features_iocs_profile.2 new file mode 100644 index 0000000..a8a4dac --- /dev/null +++ b/doc/man/nvme_set_features_iocs_profile.2 @@ -0,0 +1,18 @@ +.TH "nvme_set_features_iocs_profile" 9 "nvme_set_features_iocs_profile" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_set_features_iocs_profile \- Set I/O command set profile feature +.SH SYNOPSIS +.B "int" nvme_set_features_iocs_profile +.BI "(int fd " "," +.BI "__u16 iocsi " "," +.BI "bool save " ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "iocsi" 12 +I/O Command Set Combination Index +.IP "save" 12 +Save value across power states +.SH "RETURN" +The nvme command status if a response was received (see +\fIenum nvme_status_field\fP) 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 index 89a57dc..512a74d 100644 --- a/doc/man/nvme_set_features_irq_coalesce.2 +++ b/doc/man/nvme_set_features_irq_coalesce.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_irq_coalesce" 9 "nvme_set_features_irq_coalesce" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_irq_coalesce" 9 "nvme_set_features_irq_coalesce" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_irq_coalesce \- Set IRQ coalesce feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_irq_config.2 b/doc/man/nvme_set_features_irq_config.2 index 80c2e17..568f1ab 100644 --- a/doc/man/nvme_set_features_irq_config.2 +++ b/doc/man/nvme_set_features_irq_config.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_irq_config" 9 "nvme_set_features_irq_config" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_irq_config" 9 "nvme_set_features_irq_config" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_irq_config \- Set IRQ config feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_lba_range.2 b/doc/man/nvme_set_features_lba_range.2 index 133afe2..ecc2b07 100644 --- a/doc/man/nvme_set_features_lba_range.2 +++ b/doc/man/nvme_set_features_lba_range.2 @@ -1,11 +1,11 @@ -.TH "nvme_set_features_lba_range" 9 "nvme_set_features_lba_range" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_lba_range" 9 "nvme_set_features_lba_range" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_lba_range \- Set LBA range feature .SH SYNOPSIS .B "int" nvme_set_features_lba_range .BI "(int fd " "," .BI "__u32 nsid " "," -.BI "__u32 nr_ranges " "," +.BI "__u8 nr_ranges " "," .BI "bool save " "," .BI "struct nvme_lba_range_type *data " "," .BI "__u32 *result " ");" diff --git a/doc/man/nvme_set_features_lba_sts_interval.2 b/doc/man/nvme_set_features_lba_sts_interval.2 index 4f1d1d6..08cdf2b 100644 --- a/doc/man/nvme_set_features_lba_sts_interval.2 +++ b/doc/man/nvme_set_features_lba_sts_interval.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_lba_sts_interval" 9 "nvme_set_features_lba_sts_interval" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_lba_sts_interval" 9 "nvme_set_features_lba_sts_interval" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_lba_sts_interval \- Set LBA status information feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_nopsc.2 b/doc/man/nvme_set_features_nopsc.2 index 58d642c..5c8708d 100644 --- a/doc/man/nvme_set_features_nopsc.2 +++ b/doc/man/nvme_set_features_nopsc.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_nopsc" 9 "nvme_set_features_nopsc" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_nopsc" 9 "nvme_set_features_nopsc" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_nopsc \- Set non-operational power state feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_plm_config.2 b/doc/man/nvme_set_features_plm_config.2 index 637c071..4ebff31 100644 --- a/doc/man/nvme_set_features_plm_config.2 +++ b/doc/man/nvme_set_features_plm_config.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_plm_config" 9 "nvme_set_features_plm_config" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_plm_config" 9 "nvme_set_features_plm_config" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_plm_config \- Set predictable latency feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_plm_window.2 b/doc/man/nvme_set_features_plm_window.2 index 64cc02c..5584349 100644 --- a/doc/man/nvme_set_features_plm_window.2 +++ b/doc/man/nvme_set_features_plm_window.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_plm_window" 9 "nvme_set_features_plm_window" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_plm_window" 9 "nvme_set_features_plm_window" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_plm_window \- Set window select feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_power_mgmt.2 b/doc/man/nvme_set_features_power_mgmt.2 index 51d6671..1532c00 100644 --- a/doc/man/nvme_set_features_power_mgmt.2 +++ b/doc/man/nvme_set_features_power_mgmt.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_power_mgmt" 9 "nvme_set_features_power_mgmt" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_power_mgmt" 9 "nvme_set_features_power_mgmt" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_power_mgmt \- Set power management feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_resv_mask.2 b/doc/man/nvme_set_features_resv_mask.2 index 395a42e..5b9d22c 100644 --- a/doc/man/nvme_set_features_resv_mask.2 +++ b/doc/man/nvme_set_features_resv_mask.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_resv_mask" 9 "nvme_set_features_resv_mask" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_resv_mask" 9 "nvme_set_features_resv_mask" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_resv_mask \- Set reservation notification mask feature .SH SYNOPSIS @@ -16,6 +16,10 @@ Reservation Notification Mask Field Save value across power states .IP "result" 12 The command completion result from CQE dword0 +.SH "DESCRIPTION" + +Deprecated: doesn't support specifying a NSID. +Use \fBnvme_set_features_resv_mask2\fP instead. .SH "RETURN" The nvme command status if a response was received (see \fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_set_features_resv_mask2.2 b/doc/man/nvme_set_features_resv_mask2.2 new file mode 100644 index 0000000..86f64df --- /dev/null +++ b/doc/man/nvme_set_features_resv_mask2.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_resv_mask2" 9 "nvme_set_features_resv_mask2" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_set_features_resv_mask2 \- Set reservation notification mask feature +.SH SYNOPSIS +.B "int" nvme_set_features_resv_mask2 +.BI "(int fd " "," +.BI "__u32 nsid " "," +.BI "__u32 mask " "," +.BI "bool save " "," +.BI "__u32 *result " ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "mask" 12 +Reservation Notification Mask Field +.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 (see +\fIenum nvme_status_field\fP) 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 index d83f670..da77983 100644 --- a/doc/man/nvme_set_features_resv_persist.2 +++ b/doc/man/nvme_set_features_resv_persist.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_resv_persist" 9 "nvme_set_features_resv_persist" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_resv_persist" 9 "nvme_set_features_resv_persist" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_resv_persist \- Set persist through power loss feature .SH SYNOPSIS @@ -16,6 +16,10 @@ Persist Through Power Loss Save value across power states .IP "result" 12 The command completion result from CQE dword0 +.SH "DESCRIPTION" + +Deprecated: doesn't support specifying a NSID. +Use \fBnvme_set_features_resv_persist2\fP instead. .SH "RETURN" The nvme command status if a response was received (see \fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_set_features_resv_persist2.2 b/doc/man/nvme_set_features_resv_persist2.2 new file mode 100644 index 0000000..9d60deb --- /dev/null +++ b/doc/man/nvme_set_features_resv_persist2.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_resv_persist2" 9 "nvme_set_features_resv_persist2" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_set_features_resv_persist2 \- Set persist through power loss feature +.SH SYNOPSIS +.B "int" nvme_set_features_resv_persist2 +.BI "(int fd " "," +.BI "__u32 nsid " "," +.BI "bool ptpl " "," +.BI "bool save " "," +.BI "__u32 *result " ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "ptpl" 12 +Persist Through Power Loss +.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 (see +\fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_set_features_rrl.2 b/doc/man/nvme_set_features_rrl.2 index 736e272..6432cee 100644 --- a/doc/man/nvme_set_features_rrl.2 +++ b/doc/man/nvme_set_features_rrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_rrl" 9 "nvme_set_features_rrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_rrl" 9 "nvme_set_features_rrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_rrl \- Set read recovery level feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_sanitize.2 b/doc/man/nvme_set_features_sanitize.2 index 7904355..bf57b6b 100644 --- a/doc/man/nvme_set_features_sanitize.2 +++ b/doc/man/nvme_set_features_sanitize.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_sanitize" 9 "nvme_set_features_sanitize" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_sanitize" 9 "nvme_set_features_sanitize" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_sanitize \- Set sanitize feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_simple.2 b/doc/man/nvme_set_features_simple.2 index 288272c..3628e56 100644 --- a/doc/man/nvme_set_features_simple.2 +++ b/doc/man/nvme_set_features_simple.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_simple" 9 "nvme_set_features_simple" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_simple" 9 "nvme_set_features_simple" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_simple \- Helper function for @nvme_set_features() .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_sw_progress.2 b/doc/man/nvme_set_features_sw_progress.2 index 8ce8ece..33a5a73 100644 --- a/doc/man/nvme_set_features_sw_progress.2 +++ b/doc/man/nvme_set_features_sw_progress.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_sw_progress" 9 "nvme_set_features_sw_progress" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_sw_progress" 9 "nvme_set_features_sw_progress" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_sw_progress \- Set pre-boot software load count feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_temp_thresh.2 b/doc/man/nvme_set_features_temp_thresh.2 index c91b1af..9d3079d 100644 --- a/doc/man/nvme_set_features_temp_thresh.2 +++ b/doc/man/nvme_set_features_temp_thresh.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_temp_thresh" 9 "nvme_set_features_temp_thresh" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_temp_thresh" 9 "nvme_set_features_temp_thresh" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_temp_thresh \- Set temperature threshold feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_timestamp.2 b/doc/man/nvme_set_features_timestamp.2 index 33b06bc..ef35534 100644 --- a/doc/man/nvme_set_features_timestamp.2 +++ b/doc/man/nvme_set_features_timestamp.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_timestamp" 9 "nvme_set_features_timestamp" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_timestamp" 9 "nvme_set_features_timestamp" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_timestamp \- Set timestamp feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_volatile_wc.2 b/doc/man/nvme_set_features_volatile_wc.2 index 415f3f1..5c637cd 100644 --- a/doc/man/nvme_set_features_volatile_wc.2 +++ b/doc/man/nvme_set_features_volatile_wc.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_volatile_wc" 9 "nvme_set_features_volatile_wc" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_volatile_wc" 9 "nvme_set_features_volatile_wc" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_volatile_wc \- Set volatile write cache feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_write_atomic.2 b/doc/man/nvme_set_features_write_atomic.2 index 4f9f691..26db4fb 100644 --- a/doc/man/nvme_set_features_write_atomic.2 +++ b/doc/man/nvme_set_features_write_atomic.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_write_atomic" 9 "nvme_set_features_write_atomic" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_write_atomic" 9 "nvme_set_features_write_atomic" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_write_atomic \- Set write atomic feature .SH SYNOPSIS diff --git a/doc/man/nvme_set_features_write_protect.2 b/doc/man/nvme_set_features_write_protect.2 index aff3417..58509f3 100644 --- a/doc/man/nvme_set_features_write_protect.2 +++ b/doc/man/nvme_set_features_write_protect.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_features_write_protect" 9 "nvme_set_features_write_protect" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_features_write_protect" 9 "nvme_set_features_write_protect" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_features_write_protect \- Set write protect feature .SH SYNOPSIS @@ -16,6 +16,10 @@ Write Protection State Save value across power states .IP "result" 12 The command completion result from CQE dword0 +.SH "DESCRIPTION" + +Deprecated: doesn't support specifying a NSID. +Use \fBnvme_set_features_write_protect2\fP instead. .SH "RETURN" The nvme command status if a response was received (see \fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_set_features_write_protect2.2 b/doc/man/nvme_set_features_write_protect2.2 new file mode 100644 index 0000000..c74caf0 --- /dev/null +++ b/doc/man/nvme_set_features_write_protect2.2 @@ -0,0 +1,24 @@ +.TH "nvme_set_features_write_protect2" 9 "nvme_set_features_write_protect2" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_set_features_write_protect2 \- Set write protect feature +.SH SYNOPSIS +.B "int" nvme_set_features_write_protect2 +.BI "(int fd " "," +.BI "__u32 nsid " "," +.BI "enum nvme_feat_nswpcfg_state state " "," +.BI "bool save " "," +.BI "__u32 *result " ");" +.SH ARGUMENTS +.IP "fd" 12 +File descriptor of nvme device +.IP "nsid" 12 +Namespace ID +.IP "state" 12 +Write Protection State +.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 (see +\fIenum nvme_status_field\fP) or -1 with errno set otherwise. diff --git a/doc/man/nvme_set_keyring.2 b/doc/man/nvme_set_keyring.2 index a2f0ca7..e81a742 100644 --- a/doc/man/nvme_set_keyring.2 +++ b/doc/man/nvme_set_keyring.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_keyring" 9 "nvme_set_keyring" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_keyring" 9 "nvme_set_keyring" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_keyring \- Link keyring for lookup .SH SYNOPSIS diff --git a/doc/man/nvme_set_property.2 b/doc/man/nvme_set_property.2 index febbbed..be4de8a 100644 --- a/doc/man/nvme_set_property.2 +++ b/doc/man/nvme_set_property.2 @@ -1,4 +1,4 @@ -.TH "nvme_set_property" 9 "nvme_set_property" "June 2023" "libnvme API manual" LINUX +.TH "nvme_set_property" 9 "nvme_set_property" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_set_property \- Set controller property .SH SYNOPSIS diff --git a/doc/man/nvme_set_root.2 b/doc/man/nvme_set_root.2 new file mode 100644 index 0000000..401c1c0 --- /dev/null +++ b/doc/man/nvme_set_root.2 @@ -0,0 +1,16 @@ +.TH "nvme_set_root" 9 "nvme_set_root" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_set_root \- Set nvme_root_t context +.SH SYNOPSIS +.B "void" nvme_set_root +.BI "(nvme_root_t r " ");" +.SH ARGUMENTS +.IP "r" 12 +nvme_root_t context +.SH "DESCRIPTION" +In order to be able to log from code paths where no root object is passed in +via the arguments use the the default one which can be set via this call. +When creating a new root object with \fInvme_create_root\fP the global root object +will be set as well. This means the global root object is always pointing to +the latest created root object. Note the first \fInvme_free_tree\fP call will reset +the global root object. diff --git a/doc/man/nvme_smart_crit.2 b/doc/man/nvme_smart_crit.2 index f4a034f..7a0ac2b 100644 --- a/doc/man/nvme_smart_crit.2 +++ b/doc/man/nvme_smart_crit.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_smart_crit" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_smart_crit" "September 2023" "API Manual" LINUX .SH NAME enum nvme_smart_crit \- Critical Warning .SH SYNOPSIS diff --git a/doc/man/nvme_smart_egcw.2 b/doc/man/nvme_smart_egcw.2 index f3399c1..b4c30b9 100644 --- a/doc/man/nvme_smart_egcw.2 +++ b/doc/man/nvme_smart_egcw.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_smart_egcw" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_smart_egcw" "September 2023" "API Manual" LINUX .SH NAME enum nvme_smart_egcw \- Endurance Group Critical Warning Summary .SH SYNOPSIS diff --git a/doc/man/nvme_smart_log.2 b/doc/man/nvme_smart_log.2 index b2a80ee..0cd6895 100644 --- a/doc/man/nvme_smart_log.2 +++ b/doc/man/nvme_smart_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_smart_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_smart_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_smart_log \- SMART / Health Information Log (Log Identifier 02h) .SH SYNOPSIS diff --git a/doc/man/nvme_st_code.2 b/doc/man/nvme_st_code.2 index bac55dc..e986b55 100644 --- a/doc/man/nvme_st_code.2 +++ b/doc/man/nvme_st_code.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_st_code" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_st_code" "September 2023" "API Manual" LINUX .SH NAME enum nvme_st_code \- Self-test Code value .SH SYNOPSIS diff --git a/doc/man/nvme_st_curr_op.2 b/doc/man/nvme_st_curr_op.2 index 3c10880..fcaaea2 100644 --- a/doc/man/nvme_st_curr_op.2 +++ b/doc/man/nvme_st_curr_op.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_st_curr_op" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_st_curr_op" "September 2023" "API Manual" LINUX .SH NAME enum nvme_st_curr_op \- Current Device Self-Test Operation .SH SYNOPSIS diff --git a/doc/man/nvme_st_result.2 b/doc/man/nvme_st_result.2 index e787d09..dd31738 100644 --- a/doc/man/nvme_st_result.2 +++ b/doc/man/nvme_st_result.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_st_result" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_st_result" "September 2023" "API Manual" LINUX .SH NAME struct nvme_st_result \- Self-test Result .SH SYNOPSIS diff --git a/doc/man/nvme_st_valid_diag_info.2 b/doc/man/nvme_st_valid_diag_info.2 index 174aaa3..d9035d2 100644 --- a/doc/man/nvme_st_valid_diag_info.2 +++ b/doc/man/nvme_st_valid_diag_info.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_st_valid_diag_info" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_st_valid_diag_info" "September 2023" "API Manual" LINUX .SH NAME enum nvme_st_valid_diag_info \- Valid Diagnostic Information .SH SYNOPSIS diff --git a/doc/man/nvme_status_code.2 b/doc/man/nvme_status_code.2 index 08d3ada..80f7ac5 100644 --- a/doc/man/nvme_status_code.2 +++ b/doc/man/nvme_status_code.2 @@ -1,4 +1,4 @@ -.TH "nvme_status_code" 9 "nvme_status_code" "June 2023" "libnvme API manual" LINUX +.TH "nvme_status_code" 9 "nvme_status_code" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_status_code \- Returns the NVMe Status Code .SH SYNOPSIS diff --git a/doc/man/nvme_status_code_type.2 b/doc/man/nvme_status_code_type.2 index 29a3631..4dd9479 100644 --- a/doc/man/nvme_status_code_type.2 +++ b/doc/man/nvme_status_code_type.2 @@ -1,4 +1,4 @@ -.TH "nvme_status_code_type" 9 "nvme_status_code_type" "June 2023" "libnvme API manual" LINUX +.TH "nvme_status_code_type" 9 "nvme_status_code_type" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_status_code_type \- Returns the NVMe Status Code Type .SH SYNOPSIS diff --git a/doc/man/nvme_status_equals.2 b/doc/man/nvme_status_equals.2 index e46df00..59928cb 100644 --- a/doc/man/nvme_status_equals.2 +++ b/doc/man/nvme_status_equals.2 @@ -1,4 +1,4 @@ -.TH "nvme_status_equals" 9 "nvme_status_equals" "June 2023" "libnvme API manual" LINUX +.TH "nvme_status_equals" 9 "nvme_status_equals" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_status_equals \- helper to check a status against a type and value .SH SYNOPSIS diff --git a/doc/man/nvme_status_field.2 b/doc/man/nvme_status_field.2 index 4f6d3ae..6f2aeec 100644 --- a/doc/man/nvme_status_field.2 +++ b/doc/man/nvme_status_field.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_status_field" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_status_field" "September 2023" "API Manual" LINUX .SH NAME enum nvme_status_field \- Defines all parts of the nvme status field: status code, status code type, and additional flags. .SH SYNOPSIS diff --git a/doc/man/nvme_status_get_type.2 b/doc/man/nvme_status_get_type.2 index ded575d..2df2d5a 100644 --- a/doc/man/nvme_status_get_type.2 +++ b/doc/man/nvme_status_get_type.2 @@ -1,4 +1,4 @@ -.TH "nvme_status_get_type" 9 "nvme_status_get_type" "June 2023" "libnvme API manual" LINUX +.TH "nvme_status_get_type" 9 "nvme_status_get_type" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_status_get_type \- extract the type from a nvme_* return value .SH SYNOPSIS diff --git a/doc/man/nvme_status_get_value.2 b/doc/man/nvme_status_get_value.2 index db09890..5e88a64 100644 --- a/doc/man/nvme_status_get_value.2 +++ b/doc/man/nvme_status_get_value.2 @@ -1,4 +1,4 @@ -.TH "nvme_status_get_value" 9 "nvme_status_get_value" "June 2023" "libnvme API manual" LINUX +.TH "nvme_status_get_value" 9 "nvme_status_get_value" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_status_get_value \- extract the status value from a nvme_* return value .SH SYNOPSIS diff --git a/doc/man/nvme_status_result.2 b/doc/man/nvme_status_result.2 index 55170ba..f5d2f06 100644 --- a/doc/man/nvme_status_result.2 +++ b/doc/man/nvme_status_result.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_status_result" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_status_result" "September 2023" "API Manual" LINUX .SH NAME enum nvme_status_result \- Result of the device self-test operation .SH SYNOPSIS diff --git a/doc/man/nvme_status_to_errno.2 b/doc/man/nvme_status_to_errno.2 index e1f4c7c..95eea7f 100644 --- a/doc/man/nvme_status_to_errno.2 +++ b/doc/man/nvme_status_to_errno.2 @@ -1,4 +1,4 @@ -.TH "nvme_status_to_errno" 9 "nvme_status_to_errno" "June 2023" "libnvme API manual" LINUX +.TH "nvme_status_to_errno" 9 "nvme_status_to_errno" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_status_to_errno \- Converts nvme return status to errno .SH SYNOPSIS diff --git a/doc/man/nvme_status_to_string.2 b/doc/man/nvme_status_to_string.2 index f6d33da..a96097a 100644 --- a/doc/man/nvme_status_to_string.2 +++ b/doc/man/nvme_status_to_string.2 @@ -1,4 +1,4 @@ -.TH "nvme_status_to_string" 9 "nvme_status_to_string" "June 2023" "libnvme API manual" LINUX +.TH "nvme_status_to_string" 9 "nvme_status_to_string" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_status_to_string \- Returns string describing nvme return status. .SH SYNOPSIS diff --git a/doc/man/nvme_status_type.2 b/doc/man/nvme_status_type.2 index fa128ab..eda75de 100644 --- a/doc/man/nvme_status_type.2 +++ b/doc/man/nvme_status_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_status_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_status_type" "September 2023" "API Manual" LINUX .SH NAME enum nvme_status_type \- type encoding for NVMe return values, when represented as an int. .SH SYNOPSIS diff --git a/doc/man/nvme_streams_directive_params.2 b/doc/man/nvme_streams_directive_params.2 index 624ed47..6f70cf1 100644 --- a/doc/man/nvme_streams_directive_params.2 +++ b/doc/man/nvme_streams_directive_params.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_streams_directive_params" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_streams_directive_params" "September 2023" "API Manual" LINUX .SH NAME struct nvme_streams_directive_params \- Streams Directive - Return Parameters Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_streams_directive_status.2 b/doc/man/nvme_streams_directive_status.2 index 4a4bbe0..b7a1eaa 100644 --- a/doc/man/nvme_streams_directive_status.2 +++ b/doc/man/nvme_streams_directive_status.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_streams_directive_status" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_streams_directive_status" "September 2023" "API Manual" LINUX .SH NAME struct nvme_streams_directive_status \- Streams Directive - Get Status Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_submit_admin_passthru.2 b/doc/man/nvme_submit_admin_passthru.2 index b726665..eb0c297 100644 --- a/doc/man/nvme_submit_admin_passthru.2 +++ b/doc/man/nvme_submit_admin_passthru.2 @@ -1,4 +1,4 @@ -.TH "nvme_submit_admin_passthru" 9 "nvme_submit_admin_passthru" "June 2023" "libnvme API manual" LINUX +.TH "nvme_submit_admin_passthru" 9 "nvme_submit_admin_passthru" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_submit_admin_passthru \- Submit an nvme passthrough admin command .SH SYNOPSIS diff --git a/doc/man/nvme_submit_admin_passthru64.2 b/doc/man/nvme_submit_admin_passthru64.2 index 531e1a4..fb43726 100644 --- a/doc/man/nvme_submit_admin_passthru64.2 +++ b/doc/man/nvme_submit_admin_passthru64.2 @@ -1,4 +1,4 @@ -.TH "nvme_submit_admin_passthru64" 9 "nvme_submit_admin_passthru64" "June 2023" "libnvme API manual" LINUX +.TH "nvme_submit_admin_passthru64" 9 "nvme_submit_admin_passthru64" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_submit_admin_passthru64 \- Submit a 64-bit nvme passthrough admin command .SH SYNOPSIS diff --git a/doc/man/nvme_submit_io_passthru.2 b/doc/man/nvme_submit_io_passthru.2 index 4e00f8d..6058afc 100644 --- a/doc/man/nvme_submit_io_passthru.2 +++ b/doc/man/nvme_submit_io_passthru.2 @@ -1,4 +1,4 @@ -.TH "nvme_submit_io_passthru" 9 "nvme_submit_io_passthru" "June 2023" "libnvme API manual" LINUX +.TH "nvme_submit_io_passthru" 9 "nvme_submit_io_passthru" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_submit_io_passthru \- Submit an nvme passthrough command .SH SYNOPSIS diff --git a/doc/man/nvme_submit_io_passthru64.2 b/doc/man/nvme_submit_io_passthru64.2 index bc0bebf..0b2b82a 100644 --- a/doc/man/nvme_submit_io_passthru64.2 +++ b/doc/man/nvme_submit_io_passthru64.2 @@ -1,4 +1,4 @@ -.TH "nvme_submit_io_passthru64" 9 "nvme_submit_io_passthru64" "June 2023" "libnvme API manual" LINUX +.TH "nvme_submit_io_passthru64" 9 "nvme_submit_io_passthru64" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_submit_io_passthru64 \- Submit a 64-bit nvme passthrough command .SH SYNOPSIS diff --git a/doc/man/nvme_subsys_filter.2 b/doc/man/nvme_subsys_filter.2 index 98cde4f..d248b1f 100644 --- a/doc/man/nvme_subsys_filter.2 +++ b/doc/man/nvme_subsys_filter.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsys_filter" 9 "nvme_subsys_filter" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsys_filter" 9 "nvme_subsys_filter" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsys_filter \- Filter for subsystems .SH SYNOPSIS diff --git a/doc/man/nvme_subsys_type.2 b/doc/man/nvme_subsys_type.2 index 1b149c7..242edc2 100644 --- a/doc/man/nvme_subsys_type.2 +++ b/doc/man/nvme_subsys_type.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_subsys_type" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_subsys_type" "September 2023" "API Manual" LINUX .SH NAME enum nvme_subsys_type \- Type of the NVM subsystem. .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_first_ctrl.2 b/doc/man/nvme_subsystem_first_ctrl.2 index 0e026fc..43564d3 100644 --- a/doc/man/nvme_subsystem_first_ctrl.2 +++ b/doc/man/nvme_subsystem_first_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_first_ctrl" 9 "nvme_subsystem_first_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_first_ctrl" 9 "nvme_subsystem_first_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_first_ctrl \- First ctrl iterator .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_first_ns.2 b/doc/man/nvme_subsystem_first_ns.2 index 06b2005..0d74198 100644 --- a/doc/man/nvme_subsystem_first_ns.2 +++ b/doc/man/nvme_subsystem_first_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_first_ns" 9 "nvme_subsystem_first_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_first_ns" 9 "nvme_subsystem_first_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_first_ns \- Start namespace iterator .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_for_each_ctrl.2 b/doc/man/nvme_subsystem_for_each_ctrl.2 index 0747ce4..8cd5b4d 100644 --- a/doc/man/nvme_subsystem_for_each_ctrl.2 +++ b/doc/man/nvme_subsystem_for_each_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_for_each_ctrl" 9 "nvme_subsystem_for_each_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_for_each_ctrl" 9 "nvme_subsystem_for_each_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_for_each_ctrl \- Traverse controllers .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_for_each_ctrl_safe.2 b/doc/man/nvme_subsystem_for_each_ctrl_safe.2 index d8babcf..a3b684f 100644 --- a/doc/man/nvme_subsystem_for_each_ctrl_safe.2 +++ b/doc/man/nvme_subsystem_for_each_ctrl_safe.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_for_each_ctrl_safe" 9 "nvme_subsystem_for_each_ctrl_safe" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_for_each_ctrl_safe" 9 "nvme_subsystem_for_each_ctrl_safe" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_for_each_ctrl_safe \- Traverse controllers .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_for_each_ns.2 b/doc/man/nvme_subsystem_for_each_ns.2 index 3f40473..afae2d0 100644 --- a/doc/man/nvme_subsystem_for_each_ns.2 +++ b/doc/man/nvme_subsystem_for_each_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_for_each_ns" 9 "nvme_subsystem_for_each_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_for_each_ns" 9 "nvme_subsystem_for_each_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_for_each_ns \- Traverse namespaces .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_for_each_ns_safe.2 b/doc/man/nvme_subsystem_for_each_ns_safe.2 index 9892225..49ddb3a 100644 --- a/doc/man/nvme_subsystem_for_each_ns_safe.2 +++ b/doc/man/nvme_subsystem_for_each_ns_safe.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_for_each_ns_safe" 9 "nvme_subsystem_for_each_ns_safe" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_for_each_ns_safe" 9 "nvme_subsystem_for_each_ns_safe" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_for_each_ns_safe \- Traverse namespaces .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_get_application.2 b/doc/man/nvme_subsystem_get_application.2 index e94ccf7..30aa8f2 100644 --- a/doc/man/nvme_subsystem_get_application.2 +++ b/doc/man/nvme_subsystem_get_application.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_get_application" 9 "nvme_subsystem_get_application" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_get_application" 9 "nvme_subsystem_get_application" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_get_application \- Return the application string .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_get_host.2 b/doc/man/nvme_subsystem_get_host.2 index e52a4ab..282654a 100644 --- a/doc/man/nvme_subsystem_get_host.2 +++ b/doc/man/nvme_subsystem_get_host.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_get_host" 9 "nvme_subsystem_get_host" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_get_host" 9 "nvme_subsystem_get_host" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_get_host \- Returns nvme_host_t object .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_get_iopolicy.2 b/doc/man/nvme_subsystem_get_iopolicy.2 new file mode 100644 index 0000000..5d30078 --- /dev/null +++ b/doc/man/nvme_subsystem_get_iopolicy.2 @@ -0,0 +1,11 @@ +.TH "nvme_subsystem_get_iopolicy" 9 "nvme_subsystem_get_iopolicy" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_subsystem_get_iopolicy \- Return the IO policy of subsytem +.SH SYNOPSIS +.B "const char *" nvme_subsystem_get_iopolicy +.BI "(nvme_subsystem_t s " ");" +.SH ARGUMENTS +.IP "s" 12 +nvme_subsystem_t object +.SH "RETURN" +IO policy used by current subsystem diff --git a/doc/man/nvme_subsystem_get_name.2 b/doc/man/nvme_subsystem_get_name.2 index 4430362..793e613 100644 --- a/doc/man/nvme_subsystem_get_name.2 +++ b/doc/man/nvme_subsystem_get_name.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_get_name" 9 "nvme_subsystem_get_name" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_get_name" 9 "nvme_subsystem_get_name" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_get_name \- sysfs name of an nvme_subsystem_t object .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_get_nqn.2 b/doc/man/nvme_subsystem_get_nqn.2 index 7d64aa3..48acd3d 100644 --- a/doc/man/nvme_subsystem_get_nqn.2 +++ b/doc/man/nvme_subsystem_get_nqn.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_get_nqn" 9 "nvme_subsystem_get_nqn" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_get_nqn" 9 "nvme_subsystem_get_nqn" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_get_nqn \- Retrieve NQN from subsystem .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_get_sysfs_dir.2 b/doc/man/nvme_subsystem_get_sysfs_dir.2 index b780f37..0fc4abd 100644 --- a/doc/man/nvme_subsystem_get_sysfs_dir.2 +++ b/doc/man/nvme_subsystem_get_sysfs_dir.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_get_sysfs_dir" 9 "nvme_subsystem_get_sysfs_dir" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_get_sysfs_dir" 9 "nvme_subsystem_get_sysfs_dir" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_get_sysfs_dir \- sysfs directory of an nvme_subsystem_t object .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_get_type.2 b/doc/man/nvme_subsystem_get_type.2 index ef2e4e2..588f2b4 100644 --- a/doc/man/nvme_subsystem_get_type.2 +++ b/doc/man/nvme_subsystem_get_type.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_get_type" 9 "nvme_subsystem_get_type" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_get_type" 9 "nvme_subsystem_get_type" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_get_type \- Returns the type of a subsystem .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_lookup_namespace.2 b/doc/man/nvme_subsystem_lookup_namespace.2 index ca88701..5408537 100644 --- a/doc/man/nvme_subsystem_lookup_namespace.2 +++ b/doc/man/nvme_subsystem_lookup_namespace.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_lookup_namespace" 9 "nvme_subsystem_lookup_namespace" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_lookup_namespace" 9 "nvme_subsystem_lookup_namespace" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_lookup_namespace \- lookup namespace by NSID .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_next_ctrl.2 b/doc/man/nvme_subsystem_next_ctrl.2 index 3df44c6..3c2f9b3 100644 --- a/doc/man/nvme_subsystem_next_ctrl.2 +++ b/doc/man/nvme_subsystem_next_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_next_ctrl" 9 "nvme_subsystem_next_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_next_ctrl" 9 "nvme_subsystem_next_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_next_ctrl \- Next ctrl iterator .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_next_ns.2 b/doc/man/nvme_subsystem_next_ns.2 index e14c98c..e097997 100644 --- a/doc/man/nvme_subsystem_next_ns.2 +++ b/doc/man/nvme_subsystem_next_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_next_ns" 9 "nvme_subsystem_next_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_next_ns" 9 "nvme_subsystem_next_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_next_ns \- Next namespace iterator .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_release_fds.2 b/doc/man/nvme_subsystem_release_fds.2 new file mode 100644 index 0000000..8aa873e --- /dev/null +++ b/doc/man/nvme_subsystem_release_fds.2 @@ -0,0 +1,13 @@ +.TH "nvme_subsystem_release_fds" 9 "nvme_subsystem_release_fds" "September 2023" "libnvme API manual" LINUX +.SH NAME +nvme_subsystem_release_fds \- Close all opened fds under subsystem +.SH SYNOPSIS +.B "void" nvme_subsystem_release_fds +.BI "(struct nvme_subsystem *s " ");" +.SH ARGUMENTS +.IP "s" 12 +nvme_subsystem_t object +.SH "DESCRIPTION" +Controller and Namespace objects cache the file descriptors +of opened nvme devices. This API can be used to close and +clear all cached fds under this subsystem. diff --git a/doc/man/nvme_subsystem_reset.2 b/doc/man/nvme_subsystem_reset.2 index e2d1a5c..5ef5f41 100644 --- a/doc/man/nvme_subsystem_reset.2 +++ b/doc/man/nvme_subsystem_reset.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_reset" 9 "nvme_subsystem_reset" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_reset" 9 "nvme_subsystem_reset" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_reset \- Initiate a subsystem reset .SH SYNOPSIS diff --git a/doc/man/nvme_subsystem_set_application.2 b/doc/man/nvme_subsystem_set_application.2 index ab3ad8f..4d468c8 100644 --- a/doc/man/nvme_subsystem_set_application.2 +++ b/doc/man/nvme_subsystem_set_application.2 @@ -1,4 +1,4 @@ -.TH "nvme_subsystem_set_application" 9 "nvme_subsystem_set_application" "June 2023" "libnvme API manual" LINUX +.TH "nvme_subsystem_set_application" 9 "nvme_subsystem_set_application" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_subsystem_set_application \- Set the application string .SH SYNOPSIS diff --git a/doc/man/nvme_supported_cap_config_list_log.2 b/doc/man/nvme_supported_cap_config_list_log.2 index 60d2ac4..5993dc3 100644 --- a/doc/man/nvme_supported_cap_config_list_log.2 +++ b/doc/man/nvme_supported_cap_config_list_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_supported_cap_config_list_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_supported_cap_config_list_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_supported_cap_config_list_log \- Supported Capacity Configuration list log page .SH SYNOPSIS diff --git a/doc/man/nvme_supported_log_pages.2 b/doc/man/nvme_supported_log_pages.2 index 57e0cbd..263b584 100644 --- a/doc/man/nvme_supported_log_pages.2 +++ b/doc/man/nvme_supported_log_pages.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_supported_log_pages" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_supported_log_pages" "September 2023" "API Manual" LINUX .SH NAME struct nvme_supported_log_pages \- Supported Log Pages - Log .SH SYNOPSIS diff --git a/doc/man/nvme_telemetry_da.2 b/doc/man/nvme_telemetry_da.2 index 4096fa7..6ad49c4 100644 --- a/doc/man/nvme_telemetry_da.2 +++ b/doc/man/nvme_telemetry_da.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_telemetry_da" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_telemetry_da" "September 2023" "API Manual" LINUX .SH NAME enum nvme_telemetry_da \- Telemetry Log Data Area .SH SYNOPSIS diff --git a/doc/man/nvme_telemetry_log.2 b/doc/man/nvme_telemetry_log.2 index d2885fb..7ba4238 100644 --- a/doc/man/nvme_telemetry_log.2 +++ b/doc/man/nvme_telemetry_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_telemetry_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_telemetry_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_telemetry_log \- Retrieve internal data specific to the manufacturer. .SH SYNOPSIS diff --git a/doc/man/nvme_thermal_exc_event.2 b/doc/man/nvme_thermal_exc_event.2 index 62f431e..8c07ae3 100644 --- a/doc/man/nvme_thermal_exc_event.2 +++ b/doc/man/nvme_thermal_exc_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_thermal_exc_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_thermal_exc_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_thermal_exc_event \- Thermal Excursion Event Data .SH SYNOPSIS diff --git a/doc/man/nvme_time_stamp_change_event.2 b/doc/man/nvme_time_stamp_change_event.2 index 66c1847..1582a2f 100644 --- a/doc/man/nvme_time_stamp_change_event.2 +++ b/doc/man/nvme_time_stamp_change_event.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_time_stamp_change_event" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_time_stamp_change_event" "September 2023" "API Manual" LINUX .SH NAME struct nvme_time_stamp_change_event \- Timestamp Change Event .SH SYNOPSIS diff --git a/doc/man/nvme_timestamp.2 b/doc/man/nvme_timestamp.2 index 0e828bb..0df53fc 100644 --- a/doc/man/nvme_timestamp.2 +++ b/doc/man/nvme_timestamp.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_timestamp" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_timestamp" "September 2023" "API Manual" LINUX .SH NAME struct nvme_timestamp \- Timestamp - Data Structure for Get Features .SH SYNOPSIS diff --git a/doc/man/nvme_unlink_ctrl.2 b/doc/man/nvme_unlink_ctrl.2 index c778c9c..b5e5ec7 100644 --- a/doc/man/nvme_unlink_ctrl.2 +++ b/doc/man/nvme_unlink_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_unlink_ctrl" 9 "nvme_unlink_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_unlink_ctrl" 9 "nvme_unlink_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_unlink_ctrl \- Unlink controller .SH SYNOPSIS diff --git a/doc/man/nvme_update_config.2 b/doc/man/nvme_update_config.2 index b99ef98..a3e8a88 100644 --- a/doc/man/nvme_update_config.2 +++ b/doc/man/nvme_update_config.2 @@ -1,4 +1,4 @@ -.TH "nvme_update_config" 9 "nvme_update_config" "June 2023" "libnvme API manual" LINUX +.TH "nvme_update_config" 9 "nvme_update_config" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_update_config \- Update JSON configuration .SH SYNOPSIS diff --git a/doc/man/nvme_uring_cmd.2 b/doc/man/nvme_uring_cmd.2 index 1d205a3..2bf0210 100644 --- a/doc/man/nvme_uring_cmd.2 +++ b/doc/man/nvme_uring_cmd.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_uring_cmd" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_uring_cmd" "September 2023" "API Manual" LINUX .SH NAME struct nvme_uring_cmd \- nvme uring command structure .SH SYNOPSIS diff --git a/doc/man/nvme_verify.2 b/doc/man/nvme_verify.2 index d4f7cf7..ebf150d 100644 --- a/doc/man/nvme_verify.2 +++ b/doc/man/nvme_verify.2 @@ -1,4 +1,4 @@ -.TH "nvme_verify" 9 "nvme_verify" "June 2023" "libnvme API manual" LINUX +.TH "nvme_verify" 9 "nvme_verify" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_verify \- Send an nvme verify command .SH SYNOPSIS diff --git a/doc/man/nvme_version.2 b/doc/man/nvme_version.2 index d9fc700..c406a98 100644 --- a/doc/man/nvme_version.2 +++ b/doc/man/nvme_version.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_version" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_version" "September 2023" "API Manual" LINUX .SH NAME enum nvme_version \- Selector for version to be returned by @nvme_get_version .SH SYNOPSIS diff --git a/doc/man/nvme_virt_mgmt_act.2 b/doc/man/nvme_virt_mgmt_act.2 index efa1bfa..d0c5977 100644 --- a/doc/man/nvme_virt_mgmt_act.2 +++ b/doc/man/nvme_virt_mgmt_act.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_virt_mgmt_act" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_virt_mgmt_act" "September 2023" "API Manual" LINUX .SH NAME enum nvme_virt_mgmt_act \- Virtualization Management - Action .SH SYNOPSIS diff --git a/doc/man/nvme_virt_mgmt_rt.2 b/doc/man/nvme_virt_mgmt_rt.2 index 43e3f89..6c37477 100644 --- a/doc/man/nvme_virt_mgmt_rt.2 +++ b/doc/man/nvme_virt_mgmt_rt.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_virt_mgmt_rt" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_virt_mgmt_rt" "September 2023" "API Manual" LINUX .SH NAME enum nvme_virt_mgmt_rt \- Virtualization Management - Resource Type .SH SYNOPSIS diff --git a/doc/man/nvme_virtual_mgmt.2 b/doc/man/nvme_virtual_mgmt.2 index 1431851..320ac58 100644 --- a/doc/man/nvme_virtual_mgmt.2 +++ b/doc/man/nvme_virtual_mgmt.2 @@ -1,4 +1,4 @@ -.TH "nvme_virtual_mgmt" 9 "nvme_virtual_mgmt" "June 2023" "libnvme API manual" LINUX +.TH "nvme_virtual_mgmt" 9 "nvme_virtual_mgmt" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_virtual_mgmt \- Virtualization resource management .SH SYNOPSIS diff --git a/doc/man/nvme_write.2 b/doc/man/nvme_write.2 index 37edcbf..0271831 100644 --- a/doc/man/nvme_write.2 +++ b/doc/man/nvme_write.2 @@ -1,4 +1,4 @@ -.TH "nvme_write" 9 "nvme_write" "June 2023" "libnvme API manual" LINUX +.TH "nvme_write" 9 "nvme_write" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_write \- Submit an nvme user write command .SH SYNOPSIS diff --git a/doc/man/nvme_write_uncorrectable.2 b/doc/man/nvme_write_uncorrectable.2 index b0d838c..3072e1b 100644 --- a/doc/man/nvme_write_uncorrectable.2 +++ b/doc/man/nvme_write_uncorrectable.2 @@ -1,4 +1,4 @@ -.TH "nvme_write_uncorrectable" 9 "nvme_write_uncorrectable" "June 2023" "libnvme API manual" LINUX +.TH "nvme_write_uncorrectable" 9 "nvme_write_uncorrectable" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_write_uncorrectable \- Submit an nvme write uncorrectable command .SH SYNOPSIS diff --git a/doc/man/nvme_write_zeros.2 b/doc/man/nvme_write_zeros.2 index db35d2f..e0beb7a 100644 --- a/doc/man/nvme_write_zeros.2 +++ b/doc/man/nvme_write_zeros.2 @@ -1,4 +1,4 @@ -.TH "nvme_write_zeros" 9 "nvme_write_zeros" "June 2023" "libnvme API manual" LINUX +.TH "nvme_write_zeros" 9 "nvme_write_zeros" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_write_zeros \- Submit an nvme write zeroes command .SH SYNOPSIS diff --git a/doc/man/nvme_zns_append.2 b/doc/man/nvme_zns_append.2 index a818143..aa4e35e 100644 --- a/doc/man/nvme_zns_append.2 +++ b/doc/man/nvme_zns_append.2 @@ -1,4 +1,4 @@ -.TH "nvme_zns_append" 9 "nvme_zns_append" "June 2023" "libnvme API manual" LINUX +.TH "nvme_zns_append" 9 "nvme_zns_append" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_zns_append \- Append data to a zone .SH SYNOPSIS diff --git a/doc/man/nvme_zns_changed_zone_log.2 b/doc/man/nvme_zns_changed_zone_log.2 index bd490e0..a48b0a1 100644 --- a/doc/man/nvme_zns_changed_zone_log.2 +++ b/doc/man/nvme_zns_changed_zone_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_zns_changed_zone_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_zns_changed_zone_log" "September 2023" "API Manual" LINUX .SH NAME struct nvme_zns_changed_zone_log \- ZNS Changed Zone List log .SH SYNOPSIS diff --git a/doc/man/nvme_zns_desc.2 b/doc/man/nvme_zns_desc.2 index d67c4ce..a36eb4a 100644 --- a/doc/man/nvme_zns_desc.2 +++ b/doc/man/nvme_zns_desc.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_zns_desc" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_zns_desc" "September 2023" "API Manual" LINUX .SH NAME struct nvme_zns_desc \- Zone Descriptor Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_zns_id_ctrl.2 b/doc/man/nvme_zns_id_ctrl.2 index 29c920f..f514487 100644 --- a/doc/man/nvme_zns_id_ctrl.2 +++ b/doc/man/nvme_zns_id_ctrl.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_zns_id_ctrl" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_zns_id_ctrl" "September 2023" "API Manual" LINUX .SH NAME struct nvme_zns_id_ctrl \- I/O Command Set Specific Identify Controller Data Structure for the Zoned Namespace Command Set .SH SYNOPSIS diff --git a/doc/man/nvme_zns_id_ns.2 b/doc/man/nvme_zns_id_ns.2 index 4629af3..68e5b72 100644 --- a/doc/man/nvme_zns_id_ns.2 +++ b/doc/man/nvme_zns_id_ns.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_zns_id_ns" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_zns_id_ns" "September 2023" "API Manual" LINUX .SH NAME struct nvme_zns_id_ns \- Zoned Namespace Command Set Specific Identify Namespace Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_zns_identify_ctrl.2 b/doc/man/nvme_zns_identify_ctrl.2 index 81107ce..6d8bbee 100644 --- a/doc/man/nvme_zns_identify_ctrl.2 +++ b/doc/man/nvme_zns_identify_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvme_zns_identify_ctrl" 9 "nvme_zns_identify_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvme_zns_identify_ctrl" 9 "nvme_zns_identify_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_zns_identify_ctrl \- ZNS identify controller data .SH SYNOPSIS diff --git a/doc/man/nvme_zns_identify_ns.2 b/doc/man/nvme_zns_identify_ns.2 index 21207f5..fc018b4 100644 --- a/doc/man/nvme_zns_identify_ns.2 +++ b/doc/man/nvme_zns_identify_ns.2 @@ -1,4 +1,4 @@ -.TH "nvme_zns_identify_ns" 9 "nvme_zns_identify_ns" "June 2023" "libnvme API manual" LINUX +.TH "nvme_zns_identify_ns" 9 "nvme_zns_identify_ns" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_zns_identify_ns \- ZNS identify namespace data .SH SYNOPSIS diff --git a/doc/man/nvme_zns_lbafe.2 b/doc/man/nvme_zns_lbafe.2 index 42fb999..5153f72 100644 --- a/doc/man/nvme_zns_lbafe.2 +++ b/doc/man/nvme_zns_lbafe.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_zns_lbafe" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_zns_lbafe" "September 2023" "API Manual" LINUX .SH NAME struct nvme_zns_lbafe \- LBA Format Extension Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_zns_mgmt_recv.2 b/doc/man/nvme_zns_mgmt_recv.2 index 2b3c995..9c19c25 100644 --- a/doc/man/nvme_zns_mgmt_recv.2 +++ b/doc/man/nvme_zns_mgmt_recv.2 @@ -1,4 +1,4 @@ -.TH "nvme_zns_mgmt_recv" 9 "nvme_zns_mgmt_recv" "June 2023" "libnvme API manual" LINUX +.TH "nvme_zns_mgmt_recv" 9 "nvme_zns_mgmt_recv" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_zns_mgmt_recv \- ZNS management receive command .SH SYNOPSIS diff --git a/doc/man/nvme_zns_mgmt_send.2 b/doc/man/nvme_zns_mgmt_send.2 index 01fe8d7..5c37b7d 100644 --- a/doc/man/nvme_zns_mgmt_send.2 +++ b/doc/man/nvme_zns_mgmt_send.2 @@ -1,4 +1,4 @@ -.TH "nvme_zns_mgmt_send" 9 "nvme_zns_mgmt_send" "June 2023" "libnvme API manual" LINUX +.TH "nvme_zns_mgmt_send" 9 "nvme_zns_mgmt_send" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_zns_mgmt_send \- ZNS management send command .SH SYNOPSIS diff --git a/doc/man/nvme_zns_recv_action.2 b/doc/man/nvme_zns_recv_action.2 index 383b391..70970d1 100644 --- a/doc/man/nvme_zns_recv_action.2 +++ b/doc/man/nvme_zns_recv_action.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_zns_recv_action" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_zns_recv_action" "September 2023" "API Manual" LINUX .SH NAME enum nvme_zns_recv_action \- Zone Management Receive - Zone Receive Action Specific Features .SH SYNOPSIS diff --git a/doc/man/nvme_zns_report_options.2 b/doc/man/nvme_zns_report_options.2 index 1ba5c4c..8bdeac2 100644 --- a/doc/man/nvme_zns_report_options.2 +++ b/doc/man/nvme_zns_report_options.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_zns_report_options" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_zns_report_options" "September 2023" "API Manual" LINUX .SH NAME enum nvme_zns_report_options \- Zone Management Receive - Zone Receive Action Specific Field .SH SYNOPSIS diff --git a/doc/man/nvme_zns_report_zones.2 b/doc/man/nvme_zns_report_zones.2 index 07386af..bdab28e 100644 --- a/doc/man/nvme_zns_report_zones.2 +++ b/doc/man/nvme_zns_report_zones.2 @@ -1,4 +1,4 @@ -.TH "nvme_zns_report_zones" 9 "nvme_zns_report_zones" "June 2023" "libnvme API manual" LINUX +.TH "nvme_zns_report_zones" 9 "nvme_zns_report_zones" "September 2023" "libnvme API manual" LINUX .SH NAME nvme_zns_report_zones \- Return the list of zones .SH SYNOPSIS diff --git a/doc/man/nvme_zns_send_action.2 b/doc/man/nvme_zns_send_action.2 index 3163fb2..0fc7ee9 100644 --- a/doc/man/nvme_zns_send_action.2 +++ b/doc/man/nvme_zns_send_action.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_zns_send_action" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_zns_send_action" "September 2023" "API Manual" LINUX .SH NAME enum nvme_zns_send_action \- Zone Management Send - Zone Send Action .SH SYNOPSIS diff --git a/doc/man/nvme_zns_za.2 b/doc/man/nvme_zns_za.2 index 3f30ab6..dc7a698 100644 --- a/doc/man/nvme_zns_za.2 +++ b/doc/man/nvme_zns_za.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_zns_za" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_zns_za" "September 2023" "API Manual" LINUX .SH NAME enum nvme_zns_za \- Zone Descriptor Data Structure .SH SYNOPSIS diff --git a/doc/man/nvme_zns_zs.2 b/doc/man/nvme_zns_zs.2 index ef586ba..c28c511 100644 --- a/doc/man/nvme_zns_zs.2 +++ b/doc/man/nvme_zns_zs.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_zns_zs" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_zns_zs" "September 2023" "API Manual" LINUX .SH NAME enum nvme_zns_zs \- Zone Descriptor Data Structure - Zone State .SH SYNOPSIS diff --git a/doc/man/nvme_zns_zt.2 b/doc/man/nvme_zns_zt.2 index 36bfa1d..6c7d25a 100644 --- a/doc/man/nvme_zns_zt.2 +++ b/doc/man/nvme_zns_zt.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvme_zns_zt" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvme_zns_zt" "September 2023" "API Manual" LINUX .SH NAME enum nvme_zns_zt \- Zone Descriptor Data Structure - Zone Type .SH SYNOPSIS diff --git a/doc/man/nvme_zone_report.2 b/doc/man/nvme_zone_report.2 index 461f0fe..cbe3270 100644 --- a/doc/man/nvme_zone_report.2 +++ b/doc/man/nvme_zone_report.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvme_zone_report" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvme_zone_report" "September 2023" "API Manual" LINUX .SH NAME struct nvme_zone_report \- Report Zones Data Structure .SH SYNOPSIS diff --git a/doc/man/nvmf_add_ctrl.2 b/doc/man/nvmf_add_ctrl.2 index 2f138b0..d3eeec5 100644 --- a/doc/man/nvmf_add_ctrl.2 +++ b/doc/man/nvmf_add_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvmf_add_ctrl" 9 "nvmf_add_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_add_ctrl" 9 "nvmf_add_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_add_ctrl \- Connect a controller and update topology .SH SYNOPSIS diff --git a/doc/man/nvmf_addr_family.2 b/doc/man/nvmf_addr_family.2 index af220fa..cab76db 100644 --- a/doc/man/nvmf_addr_family.2 +++ b/doc/man/nvmf_addr_family.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_addr_family" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_addr_family" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_addr_family \- Address Family codes for Discovery Log Page entry ADRFAM field .SH SYNOPSIS diff --git a/doc/man/nvmf_adrfam_str.2 b/doc/man/nvmf_adrfam_str.2 index 654e71e..be4f9e2 100644 --- a/doc/man/nvmf_adrfam_str.2 +++ b/doc/man/nvmf_adrfam_str.2 @@ -1,4 +1,4 @@ -.TH "nvmf_adrfam_str" 9 "nvmf_adrfam_str" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_adrfam_str" 9 "nvmf_adrfam_str" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_adrfam_str \- Decode ADRFAM field .SH SYNOPSIS diff --git a/doc/man/nvmf_cms_str.2 b/doc/man/nvmf_cms_str.2 index a7ceccd..3fb824b 100644 --- a/doc/man/nvmf_cms_str.2 +++ b/doc/man/nvmf_cms_str.2 @@ -1,4 +1,4 @@ -.TH "nvmf_cms_str" 9 "nvmf_cms_str" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_cms_str" 9 "nvmf_cms_str" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_cms_str \- Decode RDMA connection management service field .SH SYNOPSIS diff --git a/doc/man/nvmf_connect_data.2 b/doc/man/nvmf_connect_data.2 index eebaf3f..b240fe2 100644 --- a/doc/man/nvmf_connect_data.2 +++ b/doc/man/nvmf_connect_data.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvmf_connect_data" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvmf_connect_data" "September 2023" "API Manual" LINUX .SH NAME struct nvmf_connect_data \- Data payload for the 'connect' command .SH SYNOPSIS diff --git a/doc/man/nvmf_connect_disc_entry.2 b/doc/man/nvmf_connect_disc_entry.2 index ea6d1e4..f39a9d2 100644 --- a/doc/man/nvmf_connect_disc_entry.2 +++ b/doc/man/nvmf_connect_disc_entry.2 @@ -1,4 +1,4 @@ -.TH "nvmf_connect_disc_entry" 9 "nvmf_connect_disc_entry" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_connect_disc_entry" 9 "nvmf_connect_disc_entry" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_connect_disc_entry \- Connect controller based on the discovery log page entry .SH SYNOPSIS diff --git a/doc/man/nvmf_default_config.2 b/doc/man/nvmf_default_config.2 index 17d8853..7709c49 100644 --- a/doc/man/nvmf_default_config.2 +++ b/doc/man/nvmf_default_config.2 @@ -1,4 +1,4 @@ -.TH "nvmf_default_config" 9 "nvmf_default_config" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_default_config" 9 "nvmf_default_config" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_default_config \- Default values for fabrics configuration .SH SYNOPSIS diff --git a/doc/man/nvmf_dim_data.2 b/doc/man/nvmf_dim_data.2 index ec2a122..5f070fe 100644 --- a/doc/man/nvmf_dim_data.2 +++ b/doc/man/nvmf_dim_data.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvmf_dim_data" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvmf_dim_data" "September 2023" "API Manual" LINUX .SH NAME struct nvmf_dim_data \- Discovery Information Management (DIM) - Data .SH SYNOPSIS diff --git a/doc/man/nvmf_dim_entfmt.2 b/doc/man/nvmf_dim_entfmt.2 index 0b1638b..cc2e912 100644 --- a/doc/man/nvmf_dim_entfmt.2 +++ b/doc/man/nvmf_dim_entfmt.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_dim_entfmt" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_dim_entfmt" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_dim_entfmt \- Discovery Information Management Entry Format .SH SYNOPSIS diff --git a/doc/man/nvmf_dim_etype.2 b/doc/man/nvmf_dim_etype.2 index 76f4f15..1628ca4 100644 --- a/doc/man/nvmf_dim_etype.2 +++ b/doc/man/nvmf_dim_etype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_dim_etype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_dim_etype" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_dim_etype \- Discovery Information Management Entity Type .SH SYNOPSIS diff --git a/doc/man/nvmf_dim_tas.2 b/doc/man/nvmf_dim_tas.2 index 153a65c..6ed9ff7 100644 --- a/doc/man/nvmf_dim_tas.2 +++ b/doc/man/nvmf_dim_tas.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_dim_tas" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_dim_tas" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_dim_tas \- Discovery Information Management Task .SH SYNOPSIS diff --git a/doc/man/nvmf_disc_eflags.2 b/doc/man/nvmf_disc_eflags.2 index 282d6f7..757039f 100644 --- a/doc/man/nvmf_disc_eflags.2 +++ b/doc/man/nvmf_disc_eflags.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_disc_eflags" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_disc_eflags" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_disc_eflags \- Discovery Log Page entry flags. .SH SYNOPSIS diff --git a/doc/man/nvmf_disc_log_entry.2 b/doc/man/nvmf_disc_log_entry.2 index f1a0616..b8258ec 100644 --- a/doc/man/nvmf_disc_log_entry.2 +++ b/doc/man/nvmf_disc_log_entry.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvmf_disc_log_entry" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvmf_disc_log_entry" "September 2023" "API Manual" LINUX .SH NAME struct nvmf_disc_log_entry \- Discovery Log Page entry .SH SYNOPSIS diff --git a/doc/man/nvmf_discovery_log.2 b/doc/man/nvmf_discovery_log.2 index 353c831..b71db55 100644 --- a/doc/man/nvmf_discovery_log.2 +++ b/doc/man/nvmf_discovery_log.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvmf_discovery_log" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvmf_discovery_log" "September 2023" "API Manual" LINUX .SH NAME struct nvmf_discovery_log \- Discovery Log Page (Log Identifier 70h) .SH SYNOPSIS diff --git a/doc/man/nvmf_eflags_str.2 b/doc/man/nvmf_eflags_str.2 index 348b206..1582c73 100644 --- a/doc/man/nvmf_eflags_str.2 +++ b/doc/man/nvmf_eflags_str.2 @@ -1,4 +1,4 @@ -.TH "nvmf_eflags_str" 9 "nvmf_eflags_str" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_eflags_str" 9 "nvmf_eflags_str" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_eflags_str \- Decode EFLAGS field .SH SYNOPSIS diff --git a/doc/man/nvmf_exat_len.2 b/doc/man/nvmf_exat_len.2 index 3ab5f4a..c615de0 100644 --- a/doc/man/nvmf_exat_len.2 +++ b/doc/man/nvmf_exat_len.2 @@ -1,4 +1,4 @@ -.TH "nvmf_exat_len" 9 "nvmf_exat_len" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_exat_len" 9 "nvmf_exat_len" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_exat_len \- Return length rounded up by 4 .SH SYNOPSIS diff --git a/doc/man/nvmf_exattype.2 b/doc/man/nvmf_exattype.2 index 55c7c5c..8dee393 100644 --- a/doc/man/nvmf_exattype.2 +++ b/doc/man/nvmf_exattype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_exattype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_exattype" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_exattype \- Extended Attribute Type .SH SYNOPSIS diff --git a/doc/man/nvmf_ext_attr.2 b/doc/man/nvmf_ext_attr.2 index 7281c7b..7d5ae93 100644 --- a/doc/man/nvmf_ext_attr.2 +++ b/doc/man/nvmf_ext_attr.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvmf_ext_attr" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvmf_ext_attr" "September 2023" "API Manual" LINUX .SH NAME struct nvmf_ext_attr \- Extended Attribute (EXAT) .SH SYNOPSIS diff --git a/doc/man/nvmf_ext_die.2 b/doc/man/nvmf_ext_die.2 index be641af..ef9c13b 100644 --- a/doc/man/nvmf_ext_die.2 +++ b/doc/man/nvmf_ext_die.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "struct nvmf_ext_die" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "struct nvmf_ext_die" "September 2023" "API Manual" LINUX .SH NAME struct nvmf_ext_die \- Extended Discovery Information Entry (DIE) .SH SYNOPSIS diff --git a/doc/man/nvmf_get_discovery_log.2 b/doc/man/nvmf_get_discovery_log.2 index 77adfb0..54672c4 100644 --- a/doc/man/nvmf_get_discovery_log.2 +++ b/doc/man/nvmf_get_discovery_log.2 @@ -1,4 +1,4 @@ -.TH "nvmf_get_discovery_log" 9 "nvmf_get_discovery_log" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_get_discovery_log" 9 "nvmf_get_discovery_log" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_get_discovery_log \- Return the discovery log page .SH SYNOPSIS diff --git a/doc/man/nvmf_get_discovery_wargs.2 b/doc/man/nvmf_get_discovery_wargs.2 index ac0cdfb..8377d6f 100644 --- a/doc/man/nvmf_get_discovery_wargs.2 +++ b/doc/man/nvmf_get_discovery_wargs.2 @@ -1,4 +1,4 @@ -.TH "nvmf_get_discovery_wargs" 9 "nvmf_get_discovery_wargs" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_get_discovery_wargs" 9 "nvmf_get_discovery_wargs" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_get_discovery_wargs \- Get the discovery log page with args .SH SYNOPSIS diff --git a/doc/man/nvmf_hostid_from_file.2 b/doc/man/nvmf_hostid_from_file.2 index 33eae9e..7d72616 100644 --- a/doc/man/nvmf_hostid_from_file.2 +++ b/doc/man/nvmf_hostid_from_file.2 @@ -1,4 +1,4 @@ -.TH "nvmf_hostid_from_file" 9 "nvmf_hostid_from_file" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_hostid_from_file" 9 "nvmf_hostid_from_file" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_hostid_from_file \- Reads the host identifier from the config default location .SH SYNOPSIS diff --git a/doc/man/nvmf_hostnqn_from_file.2 b/doc/man/nvmf_hostnqn_from_file.2 index 98e0c40..01011f0 100644 --- a/doc/man/nvmf_hostnqn_from_file.2 +++ b/doc/man/nvmf_hostnqn_from_file.2 @@ -1,4 +1,4 @@ -.TH "nvmf_hostnqn_from_file" 9 "nvmf_hostnqn_from_file" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_hostnqn_from_file" 9 "nvmf_hostnqn_from_file" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_hostnqn_from_file \- Reads the host nvm qualified name from the config default location .SH SYNOPSIS diff --git a/doc/man/nvmf_hostnqn_generate.2 b/doc/man/nvmf_hostnqn_generate.2 index 4b147a0..3389139 100644 --- a/doc/man/nvmf_hostnqn_generate.2 +++ b/doc/man/nvmf_hostnqn_generate.2 @@ -1,4 +1,4 @@ -.TH "nvmf_hostnqn_generate" 9 "nvmf_hostnqn_generate" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_hostnqn_generate" 9 "nvmf_hostnqn_generate" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_hostnqn_generate \- Generate a machine specific host nqn .SH SYNOPSIS diff --git a/doc/man/nvmf_log_discovery_lid_support.2 b/doc/man/nvmf_log_discovery_lid_support.2 index 241b93c..fbf2292 100644 --- a/doc/man/nvmf_log_discovery_lid_support.2 +++ b/doc/man/nvmf_log_discovery_lid_support.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_log_discovery_lid_support" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_log_discovery_lid_support" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_log_discovery_lid_support \- Discovery log specific support .SH SYNOPSIS diff --git a/doc/man/nvmf_log_discovery_lsp.2 b/doc/man/nvmf_log_discovery_lsp.2 index 1d41732..f6f37db 100644 --- a/doc/man/nvmf_log_discovery_lsp.2 +++ b/doc/man/nvmf_log_discovery_lsp.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_log_discovery_lsp" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_log_discovery_lsp" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_log_discovery_lsp \- Discovery log specific field .SH SYNOPSIS diff --git a/doc/man/nvmf_prtype_str.2 b/doc/man/nvmf_prtype_str.2 index 6b0b758..f8e6a9a 100644 --- a/doc/man/nvmf_prtype_str.2 +++ b/doc/man/nvmf_prtype_str.2 @@ -1,4 +1,4 @@ -.TH "nvmf_prtype_str" 9 "nvmf_prtype_str" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_prtype_str" 9 "nvmf_prtype_str" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_prtype_str \- Decode RDMA Provider type field .SH SYNOPSIS diff --git a/doc/man/nvmf_qptype_str.2 b/doc/man/nvmf_qptype_str.2 index 7435ddd..d957779 100644 --- a/doc/man/nvmf_qptype_str.2 +++ b/doc/man/nvmf_qptype_str.2 @@ -1,4 +1,4 @@ -.TH "nvmf_qptype_str" 9 "nvmf_qptype_str" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_qptype_str" 9 "nvmf_qptype_str" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_qptype_str \- Decode RDMA QP Service type field .SH SYNOPSIS diff --git a/doc/man/nvmf_rdma_cms.2 b/doc/man/nvmf_rdma_cms.2 index a2fb1d4..5a4fcd1 100644 --- a/doc/man/nvmf_rdma_cms.2 +++ b/doc/man/nvmf_rdma_cms.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_rdma_cms" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_rdma_cms" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_rdma_cms \- RDMA Connection Management Service Type codes for Discovery Log Page entry TSAS RDMA_CMS field .SH SYNOPSIS diff --git a/doc/man/nvmf_rdma_prtype.2 b/doc/man/nvmf_rdma_prtype.2 index f7a600d..c7ef4c0 100644 --- a/doc/man/nvmf_rdma_prtype.2 +++ b/doc/man/nvmf_rdma_prtype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_rdma_prtype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_rdma_prtype" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_rdma_prtype \- RDMA Provider Type codes for Discovery Log Page entry TSAS RDMA_PRTYPE field .SH SYNOPSIS diff --git a/doc/man/nvmf_rdma_qptype.2 b/doc/man/nvmf_rdma_qptype.2 index 6ee0c27..1ef1e11 100644 --- a/doc/man/nvmf_rdma_qptype.2 +++ b/doc/man/nvmf_rdma_qptype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_rdma_qptype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_rdma_qptype" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_rdma_qptype \- RDMA QP Service Type codes for Discovery Log Page entry TSAS RDMA_QPTYPE field .SH SYNOPSIS diff --git a/doc/man/nvmf_register_ctrl.2 b/doc/man/nvmf_register_ctrl.2 index 66a4da7..69d42ef 100644 --- a/doc/man/nvmf_register_ctrl.2 +++ b/doc/man/nvmf_register_ctrl.2 @@ -1,4 +1,4 @@ -.TH "nvmf_register_ctrl" 9 "nvmf_register_ctrl" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_register_ctrl" 9 "nvmf_register_ctrl" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_register_ctrl \- Perform registration task with a DC .SH SYNOPSIS diff --git a/doc/man/nvmf_sectype_str.2 b/doc/man/nvmf_sectype_str.2 index c5f1bba..551226c 100644 --- a/doc/man/nvmf_sectype_str.2 +++ b/doc/man/nvmf_sectype_str.2 @@ -1,4 +1,4 @@ -.TH "nvmf_sectype_str" 9 "nvmf_sectype_str" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_sectype_str" 9 "nvmf_sectype_str" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_sectype_str \- Decode SECTYPE field .SH SYNOPSIS diff --git a/doc/man/nvmf_subtype_str.2 b/doc/man/nvmf_subtype_str.2 index fb874b8..1c0ac44 100644 --- a/doc/man/nvmf_subtype_str.2 +++ b/doc/man/nvmf_subtype_str.2 @@ -1,4 +1,4 @@ -.TH "nvmf_subtype_str" 9 "nvmf_subtype_str" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_subtype_str" 9 "nvmf_subtype_str" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_subtype_str \- Decode SUBTYPE field .SH SYNOPSIS diff --git a/doc/man/nvmf_tcp_sectype.2 b/doc/man/nvmf_tcp_sectype.2 index 89a98eb..d561e42 100644 --- a/doc/man/nvmf_tcp_sectype.2 +++ b/doc/man/nvmf_tcp_sectype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_tcp_sectype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_tcp_sectype" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_tcp_sectype \- Transport Specific Address Subtype Definition for NVMe/TCP Transport .SH SYNOPSIS diff --git a/doc/man/nvmf_treq.2 b/doc/man/nvmf_treq.2 index f91e7db..499840e 100644 --- a/doc/man/nvmf_treq.2 +++ b/doc/man/nvmf_treq.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_treq" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_treq" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_treq \- Transport Requirements codes for Discovery Log Page entry TREQ field .SH SYNOPSIS diff --git a/doc/man/nvmf_treq_str.2 b/doc/man/nvmf_treq_str.2 index 85f01bc..db5fe43 100644 --- a/doc/man/nvmf_treq_str.2 +++ b/doc/man/nvmf_treq_str.2 @@ -1,4 +1,4 @@ -.TH "nvmf_treq_str" 9 "nvmf_treq_str" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_treq_str" 9 "nvmf_treq_str" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_treq_str \- Decode TREQ field .SH SYNOPSIS diff --git a/doc/man/nvmf_trtype.2 b/doc/man/nvmf_trtype.2 index ebdd63a..c5d8651 100644 --- a/doc/man/nvmf_trtype.2 +++ b/doc/man/nvmf_trtype.2 @@ -1,4 +1,4 @@ -.TH "libnvme" 9 "enum nvmf_trtype" "June 2023" "API Manual" LINUX +.TH "libnvme" 9 "enum nvmf_trtype" "September 2023" "API Manual" LINUX .SH NAME enum nvmf_trtype \- Transport Type codes for Discovery Log Page entry TRTYPE field .SH SYNOPSIS diff --git a/doc/man/nvmf_trtype_str.2 b/doc/man/nvmf_trtype_str.2 index 2149982..dcbe0f9 100644 --- a/doc/man/nvmf_trtype_str.2 +++ b/doc/man/nvmf_trtype_str.2 @@ -1,4 +1,4 @@ -.TH "nvmf_trtype_str" 9 "nvmf_trtype_str" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_trtype_str" 9 "nvmf_trtype_str" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_trtype_str \- Decode TRTYPE field .SH SYNOPSIS diff --git a/doc/man/nvmf_update_config.2 b/doc/man/nvmf_update_config.2 index c57f505..6001dfc 100644 --- a/doc/man/nvmf_update_config.2 +++ b/doc/man/nvmf_update_config.2 @@ -1,4 +1,4 @@ -.TH "nvmf_update_config" 9 "nvmf_update_config" "June 2023" "libnvme API manual" LINUX +.TH "nvmf_update_config" 9 "nvmf_update_config" "September 2023" "libnvme API manual" LINUX .SH NAME nvmf_update_config \- Update fabrics configuration values .SH SYNOPSIS diff --git a/doc/rst/ioctl.rst b/doc/rst/ioctl.rst index a2f3b86..4d8af34 100644 --- a/doc/rst/ioctl.rst +++ b/doc/rst/ioctl.rst @@ -1081,7 +1081,7 @@ The nvme command status if a response was received (see :c:type:`enum nvme_status_field `) or -1 with errno set otherwise. -.. c:function:: int nvme_identify_secondary_ctrl_list (int fd, __u32 nsid, __u16 cntid, struct nvme_secondary_ctrl_list *sc_list) +.. c:function:: int nvme_identify_secondary_ctrl_list (int fd, __u16 cntid, struct nvme_secondary_ctrl_list *sc_list) Retrieves secondary controller list @@ -1090,9 +1090,6 @@ The nvme command status if a response was received (see ``int fd`` File descriptor of nvme device -``__u32 nsid`` - Namespace identifier - ``__u16 cntid`` Return controllers starting at this identifier @@ -2185,6 +2182,34 @@ The nvme command status if a response was received (see :c:type:`enum nvme_status_field `) or -1 with errno set otherwise +.. c:function:: int nvme_get_log_phy_rx_eom (int fd, __u8 lsp, __u16 controller, __u32 len, struct nvme_phy_rx_eom_log *log) + + Retrieve Physical Interface Receiver Eye Opening Measurement Log + +**Parameters** + +``int fd`` + File descriptor of nvme device + +``__u8 lsp`` + Log specific, controls action and measurement quality + +``__u16 controller`` + Target controller ID + +``__u32 len`` + The allocated size, minimum + struct nvme_phy_rx_eom_log + +``struct nvme_phy_rx_eom_log *log`` + User address to store the log page + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise + + .. c:function:: int nvme_get_log_discovery (int fd, bool rae, __u32 offset, __u32 len, void *log) Retrieve Discovery log page @@ -2499,7 +2524,7 @@ The nvme command status if a response was received (see :c:type:`enum nvme_status_field `) 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_set_features_lba_range (int fd, __u32 nsid, __u8 nr_ranges, bool save, struct nvme_lba_range_type *data, __u32 *result) Set LBA range feature @@ -2511,7 +2536,7 @@ The nvme command status if a response was received (see ``__u32 nsid`` Namespace ID -``__u32 nr_ranges`` +``__u8 nr_ranges`` Number of ranges in **data** ``bool save`` @@ -3063,6 +3088,39 @@ The nvme command status if a response was received (see ``__u32 *result`` The command completion result from CQE dword0 +**Description** + + +Deprecated: doesn't support specifying a NSID. +Use nvme_set_features_resv_mask2() instead. + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise. + + +.. c:function:: int nvme_set_features_resv_mask2 (int fd, __u32 nsid, __u32 mask, bool save, __u32 *result) + + Set reservation notification mask feature + +**Parameters** + +``int fd`` + File descriptor of nvme device + +``__u32 nsid`` + Namespace ID + +``__u32 mask`` + Reservation Notification Mask Field + +``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 (see @@ -3087,6 +3145,39 @@ The nvme command status if a response was received (see ``__u32 *result`` The command completion result from CQE dword0 +**Description** + + +Deprecated: doesn't support specifying a NSID. +Use nvme_set_features_resv_persist2() instead. + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise. + + +.. c:function:: int nvme_set_features_resv_persist2 (int fd, __u32 nsid, bool ptpl, bool save, __u32 *result) + + Set persist through power loss feature + +**Parameters** + +``int fd`` + File descriptor of nvme device + +``__u32 nsid`` + Namespace ID + +``bool ptpl`` + Persist Through Power Loss + +``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 (see @@ -3111,6 +3202,60 @@ The nvme command status if a response was received (see ``__u32 *result`` The command completion result from CQE dword0 +**Description** + + +Deprecated: doesn't support specifying a NSID. +Use nvme_set_features_write_protect2() instead. + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise. + + +.. c:function:: int nvme_set_features_write_protect2 (int fd, __u32 nsid, enum nvme_feat_nswpcfg_state state, bool save, __u32 *result) + + Set write protect feature + +**Parameters** + +``int fd`` + File descriptor of nvme device + +``__u32 nsid`` + Namespace ID + +``enum nvme_feat_nswpcfg_state state`` + Write Protection State + +``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 (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise. + + +.. c:function:: int nvme_set_features_iocs_profile (int fd, __u16 iocsi, bool save) + + Set I/O command set profile feature + +**Parameters** + +``int fd`` + File descriptor of nvme device + +``__u16 iocsi`` + I/O Command Set Combination Index + +``bool save`` + Save value across power states + **Return** The nvme command status if a response was received (see @@ -3246,6 +3391,39 @@ The nvme command status if a response was received (see ``__u32 *result`` The command completion result from CQE dword0 +**Description** + + +Deprecated: doesn't support specifying a NSID. +Use nvme_get_features_lba_range2() instead. + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise. + + +.. c:function:: int nvme_get_features_lba_range2 (int fd, enum nvme_get_features_sel sel, __u32 nsid, struct nvme_lba_range_type *data, __u32 *result) + + Get LBA range feature + +**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 nsid`` + Namespace ID + +``struct nvme_lba_range_type *data`` + Buffer to receive LBA Range Type data structure + +``__u32 *result`` + The command completion result from CQE dword0 + **Return** The nvme command status if a response was received (see @@ -3288,6 +3466,36 @@ The nvme command status if a response was received (see ``__u32 *result`` The command completion result from CQE dword0 +**Description** + + +Deprecated: doesn't support specifying a NSID. +Use nvme_get_features_err_recovery2() instead. + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise. + + +.. c:function:: int nvme_get_features_err_recovery2 (int fd, enum nvme_get_features_sel sel, __u32 nsid, __u32 *result) + + Get error recovery feature + +**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 nsid`` + Namespace ID + +``__u32 *result`` + The command completion result from CQE dword0 + **Return** The nvme command status if a response was received (see @@ -3460,6 +3668,36 @@ The nvme command status if a response was received (see ``__u32 *result`` The command completion result from CQE dword0 +**Description** + + +Deprecated: doesn't fetch the Host Memory Buffer Attributes data structure. +Use nvme_get_features_host_mem_buf2() instead. + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise. + + +.. c:function:: int nvme_get_features_host_mem_buf2 (int fd, enum nvme_get_features_sel sel, struct nvme_host_mem_buf_attrs *attrs, __u32 *result) + + Get host memory buffer feature + +**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 ` + +``struct nvme_host_mem_buf_attrs *attrs`` + Buffer for returned Host Memory Buffer Attributes + +``__u32 *result`` + The command completion result from CQE dword0 + **Return** The nvme command status if a response was received (see @@ -3774,6 +4012,36 @@ The nvme command status if a response was received (see ``__u32 *result`` The command completion result from CQE dword0 +**Description** + + +Deprecated: doesn't support specifying a NSID. +Use nvme_get_features_resv_mask2() instead. + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise. + + +.. c:function:: int nvme_get_features_resv_mask2 (int fd, enum nvme_get_features_sel sel, __u32 nsid, __u32 *result) + + Get reservation mask feature + +**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 nsid`` + Namespace ID + +``__u32 *result`` + The command completion result from CQE dword0 + **Return** The nvme command status if a response was received (see @@ -3795,6 +4063,36 @@ The nvme command status if a response was received (see ``__u32 *result`` The command completion result from CQE dword0 +**Description** + + +Deprecated: doesn't support specifying a NSID. +Use nvme_get_features_resv_persist2() instead. + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise. + + +.. c:function:: int nvme_get_features_resv_persist2 (int fd, enum nvme_get_features_sel sel, __u32 nsid, __u32 *result) + + Get reservation persist feature + +**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 nsid`` + Namespace ID + +``__u32 *result`` + The command completion result from CQE dword0 + **Return** The nvme command status if a response was received (see @@ -4903,3 +5201,27 @@ The nvme command status if a response was received (see :c:type:`enum nvme_status_field `) or -1 with errno set otherwise. +.. c:function:: void nvme_set_debug (bool debug) + + Set NVMe command debugging output + +**Parameters** + +``bool debug`` + true to enable or false to disable + + +.. c:function:: bool nvme_get_debug (void) + + Get NVMe command debugging output + +**Parameters** + +``void`` + no arguments + +**Return** + +false if disabled or true if enabled. + + diff --git a/doc/rst/linux.rst b/doc/rst/linux.rst index b437499..1e681d2 100644 --- a/doc/rst/linux.rst +++ b/doc/rst/linux.rst @@ -53,6 +53,68 @@ The nvme command status if a response was received (see Data Area 4 +.. c:function:: int nvme_get_telemetry_max (int fd, enum nvme_telemetry_da *da, size_t *max_data_tx) + + Get telemetry limits + +**Parameters** + +``int fd`` + File descriptor of nvme device + +``enum nvme_telemetry_da *da`` + On success return max supported data area + +``size_t *max_data_tx`` + On success set to max transfer chunk supported by the controller + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise. + + +.. c:function:: int nvme_get_telemetry_log (int fd, bool create, bool ctrl, bool rae, size_t max_data_tx, enum nvme_telemetry_da da, struct nvme_telemetry_log **log, size_t *size) + + Get specified telemetry log + +**Parameters** + +``int fd`` + File descriptor of nvme device + +``bool create`` + Generate new host initated telemetry capture + +``bool ctrl`` + Get controller Initiated log + +``bool rae`` + Retain asynchronous events + +``size_t max_data_tx`` + Set the max data transfer size to be used retrieving telemetry. + +``enum nvme_telemetry_da da`` + Log page data area, valid values: :c:type:`enum nvme_telemetry_da `. + +``struct nvme_telemetry_log **log`` + On success, set to the value of the allocated and retrieved log. + +``size_t *size`` + Ptr to the telemetry log size, so it can be returned + +**Description** + +The total size allocated can be calculated as: + (nvme_telemetry_log da size + 1) * NVME_LOG_TELEM_BLOCK_SIZE. + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise. + + .. c:function:: int nvme_get_ctrl_telemetry (int fd, bool rae, struct nvme_telemetry_log **log, enum nvme_telemetry_da da, size_t *size) Get controller telemetry log diff --git a/doc/rst/log.rst b/doc/rst/log.rst index 45b4689..67911a5 100644 --- a/doc/rst/log.rst +++ b/doc/rst/log.rst @@ -28,3 +28,22 @@ logging functions Sets the default logging variables for the library. +.. c:function:: void nvme_set_root (nvme_root_t r) + + Set nvme_root_t context + +**Parameters** + +``nvme_root_t r`` + nvme_root_t context + +**Description** + +In order to be able to log from code paths where no root object is passed in +via the arguments use the the default one which can be set via this call. +When creating a new root object with **nvme_create_root** the global root object +will be set as well. This means the global root object is always pointing to +the latest created root object. Note the first **nvme_free_tree** call will reset +the global root object. + + diff --git a/doc/rst/mi.rst b/doc/rst/mi.rst index ba0f29a..2aa7438 100644 --- a/doc/rst/mi.rst +++ b/doc/rst/mi.rst @@ -1923,7 +1923,7 @@ See: :c:type:`struct nvme_primary_ctrl_cap ` 0 on success, non-zero on failure -.. c:function:: int nvme_mi_admin_identify_secondary_ctrl_list (nvme_mi_ctrl_t ctrl, __u32 nsid, __u16 cntid, struct nvme_secondary_ctrl_list *list) +.. c:function:: int nvme_mi_admin_identify_secondary_ctrl_list (nvme_mi_ctrl_t ctrl, __u16 cntid, struct nvme_secondary_ctrl_list *list) Perform an Admin identify for a secondary controller list. @@ -1932,9 +1932,6 @@ See: :c:type:`struct nvme_primary_ctrl_cap ` ``nvme_mi_ctrl_t ctrl`` Controller to process identify command -``__u32 nsid`` - Namespace ID to specify list start - ``__u16 cntid`` Controller ID to specify list start @@ -2622,6 +2619,34 @@ The nvme command status if a response was received (see :c:type:`enum nvme_status_field `) or -1 with errno set otherwise. +.. c:function:: int nvme_mi_admin_get_log_phy_rx_eom (nvme_mi_ctrl_t ctrl, __u8 lsp, __u16 controller, __u32 len, struct nvme_phy_rx_eom_log *log) + + Retrieve Physical Interface Receiver Eye Opening Measurement Log + +**Parameters** + +``nvme_mi_ctrl_t ctrl`` + Controller to query + +``__u8 lsp`` + Log specific, controls action and measurement quality + +``__u16 controller`` + Target controller ID + +``__u32 len`` + The allocated size, minimum + struct nvme_phy_rx_eom_log + +``struct nvme_phy_rx_eom_log *log`` + User address to store the log page + +**Return** + +The nvme command status if a response was received (see +:c:type:`enum nvme_status_field `) or -1 with errno set otherwise + + .. c:function:: int nvme_mi_admin_get_log_discovery (nvme_mi_ctrl_t ctrl, bool rae, __u32 offset, __u32 len, void *log) Retrieve Discovery log page diff --git a/doc/rst/tree.rst b/doc/rst/tree.rst index f964ec6..b73ffae 100644 --- a/doc/rst/tree.rst +++ b/doc/rst/tree.rst @@ -53,6 +53,22 @@ Sets the managing application string for **r**. Returns the managing application string for **r** or NULL if not set. +.. c:function:: void nvme_root_release_fds (nvme_root_t r) + + Close all opened file descriptors in the tree + +**Parameters** + +``nvme_root_t r`` + :c:type:`nvme_root_t` object + +**Description** + +Controller and Namespace objects cache the file descriptors +of opened nvme devices. This API can be used to close and +clear all cached fds in the tree. + + .. c:function:: void nvme_free_tree (nvme_root_t r) Free root object @@ -469,6 +485,86 @@ will start at **p** instead of the first controller. Controller instance +.. c:function:: nvme_ctrl_t nvme_ctrl_find (nvme_subsystem_t s, const char *transport, const char *traddr, const char *trsvcid, const char *subsysnqn, const char *host_traddr, const char *host_iface) + + Locate an existing controller + +**Parameters** + +``nvme_subsystem_t s`` + :c:type:`nvme_subsystem_t` object + +``const char *transport`` + Transport name + +``const char *traddr`` + Transport address + +``const char *trsvcid`` + Transport service identifier + +``const char *subsysnqn`` + Subsystem NQN + +``const char *host_traddr`` + Host transport address + +``const char *host_iface`` + Host interface name + +**Description** + +Lookup a controller in **s** based on **transport**, **traddr**, **trsvcid**, +**subsysnqn**, **host_traddr**, and **host_iface**. **transport** must be specified, +other fields may be required depending on the transport. Parameters set +to NULL will be ignored. + +Unlike nvme_lookup_ctrl(), this function does not create a new object if +an existing controller cannot be found. + +**Return** + +Controller instance on success, NULL otherwise. + + +.. c:function:: bool nvme_ctrl_config_match (struct nvme_ctrl *c, const char *transport, const char *traddr, const char *trsvcid, const char *subsysnqn, const char *host_traddr, const char *host_iface) + + Check if ctrl **c** matches config params + +**Parameters** + +``struct nvme_ctrl *c`` + An existing controller instance + +``const char *transport`` + Transport name + +``const char *traddr`` + Transport address + +``const char *trsvcid`` + Transport service identifier + +``const char *subsysnqn`` + Subsystem NQN + +``const char *host_traddr`` + Host transport address + +``const char *host_iface`` + Host interface name + +**Description** + +Check that controller **c** matches parameters: **transport**, **traddr**, +**trsvcid**, **subsysnqn**, **host_traddr**, and **host_iface**. Parameters set +to NULL will be ignored. + +**Return** + +true if there's a match, false otherwise. + + .. c:function:: nvme_ctrl_t nvme_create_ctrl (nvme_root_t r, const char *subsysnqn, const char *transport, const char *traddr, const char *host_traddr, const char *host_iface, const char *trsvcid) Allocate an unconnected NVMe controller @@ -776,11 +872,30 @@ Next :c:type:`nvme_ns_t` object of an **s** iterator ``nvme_ns_t n`` Namespace instance +**Description** + +libnvme will open() the file (if not already opened) and keep +an internal copy of the file descriptor. Following calls to +this API retrieve the internal cached copy of the file +descriptor. The file will remain opened and the fd will +remain cached until the ns object is deleted or +nvme_ns_release_fd() is called. + **Return** File descriptor associated with **n** or -1 +.. c:function:: void nvme_ns_release_fd (nvme_ns_t n) + + Close fd and clear fd from ns object + +**Parameters** + +``nvme_ns_t n`` + Namespace instance + + .. c:function:: int nvme_ns_get_nsid (nvme_ns_t n) NSID of a namespace @@ -1302,11 +1417,30 @@ Parent namespace if present ``nvme_ctrl_t c`` Controller instance +**Description** + +libnvme will open() the file (if not already opened) and keep +an internal copy of the file descriptor. Following calls to +this API retrieve the internal cached copy of the file +descriptor. The file will remain opened and the fd will +remain cached until the controller object is deleted or +nvme_ctrl_release_fd() is called. + **Return** File descriptor associated with **c** or -1 +.. c:function:: void nvme_ctrl_release_fd (nvme_ctrl_t c) + + Close fd and clear fd from controller object + +**Parameters** + +``nvme_ctrl_t c`` + Controller instance + + .. c:function:: const char * nvme_ctrl_get_name (nvme_ctrl_t c) sysfs name of a controller @@ -1350,6 +1484,26 @@ NVMe-over-Fabrics address string of **c** or empty string of no address is present. +.. c:function:: char * nvme_ctrl_get_src_addr (nvme_ctrl_t c, char *src_addr, size_t src_addr_len) + + Extract src_addr from the c->address string + +**Parameters** + +``nvme_ctrl_t c`` + Controller instance + +``char *src_addr`` + Where to copy the src_addr. Size must be at least INET6_ADDRSTRLEN. + +``size_t src_addr_len`` + Length of the buffer **src_addr**. + +**Return** + +Pointer to **src_addr** on success. NULL on failure to extract the src_addr. + + .. c:function:: const char * nvme_ctrl_get_phy_slot (nvme_ctrl_t c) PCI physical slot number of a controller @@ -1395,7 +1549,7 @@ Model string of **c** .. c:function:: const char * nvme_ctrl_get_state (nvme_ctrl_t c) - Running state of an controller + Running state of a controller **Parameters** @@ -1962,6 +2116,20 @@ Managing application string or NULL if not set. Sets the managing application string for **s**. +.. c:function:: const char * nvme_subsystem_get_iopolicy (nvme_subsystem_t s) + + Return the IO policy of subsytem + +**Parameters** + +``nvme_subsystem_t s`` + nvme_subsystem_t object + +**Return** + +IO policy used by current subsystem + + .. c:function:: int nvme_scan_topology (nvme_root_t r, nvme_scan_filter_t f, void *f_args) Scan NVMe topology and apply filter @@ -2015,6 +2183,22 @@ Host NQN of **h** Host ID of **h** +.. c:function:: void nvme_host_release_fds (struct nvme_host *h) + + Close all opened file descriptors under host + +**Parameters** + +``struct nvme_host *h`` + nvme_host_t object + +**Description** + +Controller and Namespace objects cache the file descriptors +of opened nvme devices. This API can be used to close and +clear all cached fds under this host. + + .. c:function:: void nvme_free_host (nvme_host_t h) Free nvme_host_t object @@ -2220,6 +2404,22 @@ String with the contents of **attr** or ``NULL`` in case of an empty value nvme_ns_t of the namespace with id **nsid** in subsystem **s** +.. c:function:: void nvme_subsystem_release_fds (struct nvme_subsystem *s) + + Close all opened fds under subsystem + +**Parameters** + +``struct nvme_subsystem *s`` + nvme_subsystem_t object + +**Description** + +Controller and Namespace objects cache the file descriptors +of opened nvme devices. This API can be used to close and +clear all cached fds under this subsystem. + + .. c:function:: char * nvme_get_path_attr (nvme_path_t p, const char *attr) Read path sysfs attribute diff --git a/doc/rst/types.rst b/doc/rst/types.rst index 3c9725a..80dfef2 100644 --- a/doc/rst/types.rst +++ b/doc/rst/types.rst @@ -607,7 +607,8 @@ power scale value __le32 mnan; __u8 maxdna[16]; __le32 maxcna; - __u8 rsvd564[204]; + __le32 oaqd; + __u8 rsvd568[200]; char subnqn[NVME_NQN_LENGTH]; __u8 rsvd1024[768]; __le32 ioccsz; @@ -976,7 +977,12 @@ power scale value maximum number of namespaces that are allowed to be attached to this I/O controller. -``rsvd564`` +``oaqd`` + Optimal Aggregated Queue Depth indicates the recommended maximum + total number of outstanding I/O commands across all I/O queues + on the controller for optimal operation. + +``rsvd568`` Reserved ``subnqn`` @@ -4196,11 +4202,13 @@ bytes, in size. This log captures the controller’s internal state. struct nvme_endurance_group_log { __u8 critical_warning; - __u8 rsvd1[2]; + __u8 endurance_group_features; + __u8 rsvd2; __u8 avl_spare; __u8 avl_spare_threshold; __u8 percent_used; - __u8 rsvd6[26]; + __le16 domain_identifier; + __u8 rsvd8[24]; __u8 endurance_estimate[16]; __u8 data_units_read[16]; __u8 data_units_written[16]; @@ -4209,7 +4217,9 @@ bytes, in size. This log captures the controller’s internal state. __u8 host_write_cmds[16]; __u8 media_data_integrity_err[16]; __u8 num_err_info_log_entries[16]; - __u8 rsvd160[352]; + __u8 total_end_grp_cap[16]; + __u8 unalloc_end_grp_cap[16]; + __u8 rsvd192[320]; }; **Members** @@ -4217,7 +4227,10 @@ bytes, in size. This log captures the controller’s internal state. ``critical_warning`` Critical Warning -``rsvd1`` +``endurance_group_features`` + Endurance Group Features + +``rsvd2`` Reserved ``avl_spare`` @@ -4229,7 +4242,10 @@ bytes, in size. This log captures the controller’s internal state. ``percent_used`` Percentage Used -``rsvd6`` +``domain_identifier`` + Domain Identifier + +``rsvd8`` Reserved ``endurance_estimate`` @@ -4256,7 +4272,13 @@ bytes, in size. This log captures the controller’s internal state. ``num_err_info_log_entries`` Number of Error Information Log Entries -``rsvd160`` +``total_end_grp_cap`` + Total Endurance Group Capacity + +``unalloc_end_grp_cap`` + Unallocated Endurance Group Capacity + +``rsvd192`` Reserved @@ -5503,6 +5525,213 @@ bytes, in size. This log captures the controller’s internal state. +.. c:struct:: nvme_eom_lane_desc + + EOM Lane Descriptor + +**Definition** + +:: + + struct nvme_eom_lane_desc { + __u8 rsvd0; + __u8 mstatus; + __u8 lane; + __u8 eye; + __le16 top; + __le16 bottom; + __le16 left; + __le16 right; + __le16 nrows; + __le16 ncols; + __le16 edlen; + __u8 rsvd18[14]; + __u8 eye_desc[]; + }; + +**Members** + +``rsvd0`` + Reserved + +``mstatus`` + Measurement Status + +``lane`` + Lane number + +``eye`` + Eye number + +``top`` + Absolute number of rows from center to top edge of eye + +``bottom`` + Absolute number of rows from center to bottom edge of eye + +``left`` + Absolute number of rows from center to left edge of eye + +``right`` + Absolute number of rows from center to right edge of eye + +``nrows`` + Number of Rows + +``ncols`` + Number of Columns + +``edlen`` + Eye Data Length + +``rsvd18`` + Reserved + +``eye_desc`` + Printable Eye, Eye Data, and any Padding + + + + + +.. c:struct:: nvme_phy_rx_eom_log + + Physical Interface Receiver Eye Opening Measurement Log + +**Definition** + +:: + + struct nvme_phy_rx_eom_log { + __u8 lid; + __u8 eomip; + __le16 hsize; + __le32 rsize; + __u8 eomdgn; + __u8 lr; + __u8 odp; + __u8 lanes; + __u8 epl; + __u8 lspfc; + __u8 li; + __u8 rsvd15[3]; + __le16 lsic; + __le32 dsize; + __le16 nd; + __le16 maxtb; + __le16 maxlr; + __le16 etgood; + __le16 etbetter; + __le16 etbest; + __u8 rsvd36[28]; + struct nvme_eom_lane_desc descs[]; + }; + +**Members** + +``lid`` + Log Identifier + +``eomip`` + EOM In Progress + +``hsize`` + Header Size + +``rsize`` + Result Size + +``eomdgn`` + EOM Data Generation Number + +``lr`` + Log Revision + +``odp`` + Optional Data Present + +``lanes`` + Number of lanes configured for this port + +``epl`` + Eyes Per Lane + +``lspfc`` + Log Specific Parameter Field Copy + +``li`` + Link Information + +``rsvd15`` + Reserved + +``lsic`` + Log Specific Identifier Copy + +``dsize`` + Descriptor Size + +``nd`` + Number of Descriptors + +``maxtb`` + Maximum Top Bottom + +``maxlr`` + Maximum Left Right + +``etgood`` + Estimated Time for Good Quality + +``etbetter`` + Estimated Time for Better Quality + +``etbest`` + Estimated Time for Best Quality + +``rsvd36`` + Reserved + +``descs`` + EOM Lane Descriptors + + + + + +.. c:enum:: nvme_eom_optional_data + + EOM Optional Data Present Fields + +**Constants** + +``NVME_EOM_EYE_DATA_PRESENT`` + Eye Data Present + +``NVME_EOM_PRINTABLE_EYE_PRESENT`` + Printable Eye Present + + + + +.. c:enum:: nvme_phy_rx_eom_progress + + EOM In Progress Values + +**Constants** + +``NVME_PHY_RX_EOM_NOT_STARTED`` + EOM Not Started + +``NVME_PHY_RX_EOM_IN_PROGRESS`` + EOM In Progress + +``NVME_PHY_RX_EOM_COMPLETED`` + EOM Completed + + + + .. c:struct:: nvme_media_unit_stat_desc Media Unit Status Descriptor @@ -10508,6 +10737,9 @@ true if **status** is of the specified type and value ``NVME_LOG_LID_BOOT_PARTITION`` Boot Partition +``NVME_LOG_LID_PHY_RX_EOM`` + Physical Interface Receiver Eye Opening Measurement + ``NVME_LOG_LID_FDP_CONFIGS`` FDP Configurations @@ -11219,6 +11451,42 @@ true if **status** is of the specified type and value +.. c:enum:: nvme_log_phy_rx_eom_action + + Physical Interface Receiver Eye Opening Measurement Action + +**Constants** + +``NVME_LOG_PHY_RX_EOM_READ`` + Read Log Data + +``NVME_LOG_PHY_RX_EOM_START_READ`` + Start Measurement and Read Log Data + +``NVME_LOG_PHY_RX_EOM_ABORT_CLEAR`` + Abort Measurement and Clear Log Data + + + + +.. c:enum:: nvme_log_phy_rx_eom_quality + + Physical Interface Receiver Eye Opening Measurement Quality + +**Constants** + +``NVME_LOG_PHY_RX_EOM_GOOD`` + <= Better Quality + +``NVME_LOG_PHY_RX_EOM_BETTER`` + <= Best Quality, >= Good Quality + +``NVME_LOG_PHY_RX_EOM_BEST`` + >= Better Quality + + + + .. c:enum:: nvme_pevent_log_action Persistent Event Log - Action diff --git a/doc/rst/util.rst b/doc/rst/util.rst index 6f7974e..f81b188 100644 --- a/doc/rst/util.rst +++ b/doc/rst/util.rst @@ -598,3 +598,52 @@ Returns error code if generating of random number fails. true if addr1 == addr2. false otherwise. +.. c:function:: const char * nvme_iface_matching_addr (const struct ifaddrs *iface_list, const char *addr) + + Get interface matching **addr** + +**Parameters** + +``const struct ifaddrs *iface_list`` + Interface list returned by getifaddrs() + +``const char *addr`` + Address to match + +**Description** + +Parse the interface list pointed to by **iface_list** looking +for the interface that has **addr** as one of its assigned +addresses. + +**Return** + +The name of the interface that owns **addr** or NULL. + + +.. c:function:: bool nvme_iface_primary_addr_matches (const struct ifaddrs *iface_list, const char *iface, const char *addr) + + Check that interface's primary address matches + +**Parameters** + +``const struct ifaddrs *iface_list`` + Interface list returned by getifaddrs() + +``const char *iface`` + Interface to match + +``const char *addr`` + Address to match + +**Description** + +Parse the interface list pointed to by **iface_list** and looking for +interface **iface**. The get its primary address and check if it matches +**addr**. + +**Return** + +true if a match is found, false otherwise. + + diff --git a/internal/meson.build b/internal/meson.build index fde4cca..cc1e852 100644 --- a/internal/meson.build +++ b/internal/meson.build @@ -19,3 +19,10 @@ internal_incdir = include_directories('.') config_dep = declare_dependency( include_directories : internal_incdir, sources: config_h) + +add_project_arguments( + [ + '-include', '@0@'.format(config_h), + ], + language : 'c', +) diff --git a/meson.build b/meson.build index 77415eb..6fcf1da 100644 --- a/meson.build +++ b/meson.build @@ -8,7 +8,7 @@ project( 'libnvme', ['c'], meson_version: '>= 0.50.0', - version: '1.5', + version: '1.6', license: 'LGPL-2.1-or-later', default_options: [ 'c_std=gnu99', @@ -253,7 +253,6 @@ add_project_arguments( [ '-fomit-frame-pointer', '-D_GNU_SOURCE', - '-include', 'internal/config.h', ], language : 'c', ) diff --git a/scripts/build.sh b/scripts/build.sh index 82d271b..f40a4cf 100755 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -1,4 +1,5 @@ #!/bin/bash +set -e usage() { echo "Usage: build.sh [-b [release|debug]] " @@ -19,6 +20,7 @@ usage() { echo " fallback download all dependencies" echo " and build them as shared libaries" echo " cross use cross toolchain to build" + echo " coverage build coverage report" echo "" echo "configs with muon:" echo " [default] minimal static build" @@ -58,6 +60,8 @@ cd "$(git rev-parse --show-toplevel)" || exit 1 BUILDDIR="$(pwd)/.build-ci" +fn_exists() { declare -F "$1" > /dev/null; } + config_meson_default() { CC="${CC}" "${MESON}" setup \ --werror \ @@ -95,6 +99,16 @@ config_meson_cross() { "${BUILDDIR}" } +config_meson_coverage() { + CC="${CC}" "${MESON}" setup \ + --werror \ + --buildtype="${BUILDTYPE}" \ + --wrap-mode=nofallback \ + -Dlibdbus=enabled \ + -Db_coverage=true \ + "${BUILDDIR}" +} + build_meson() { "${MESON}" compile \ -C "${BUILDDIR}" @@ -105,6 +119,12 @@ test_meson() { -C "${BUILDDIR}" } +test_meson_coverage() { + "${MESON}" test \ + -C "${BUILDDIR}" + ninja -C "${BUILDDIR}" coverage --verbose +} + tools_build_samurai() { mkdir -p "${BUILDDIR}"/build-tools git clone --depth 1 https://github.com/michaelforney/samurai.git \ @@ -178,5 +198,5 @@ if [[ "${BUILDTOOL}" == "muon" ]]; then fi config_"${BUILDTOOL}"_"${CONFIG}" -build_"${BUILDTOOL}" -test_"${BUILDTOOL}" +fn_exists "build_${BUILDTOOL}_${CONFIG}" && "build_${BUILDTOOL}_${CONFIG}" || build_"${BUILDTOOL}" +fn_exists "test_${BUILDTOOL}_${CONFIG}" && "test_${BUILDTOOL}_${CONFIG}" || test_"${BUILDTOOL}" diff --git a/src/libnvme.map b/src/libnvme.map index 82387d4..6bb05b0 100644 --- a/src/libnvme.map +++ b/src/libnvme.map @@ -1,4 +1,29 @@ # SPDX-License-Identifier: LGPL-2.1-or-later +LIBNVME_1_6 { + global: + nvme_ctrl_config_match; + nvme_ctrl_find; + nvme_ctrl_get_src_addr; + nvme_ctrl_release_fd; + nvme_get_debug; + nvme_get_features_err_recovery2; + nvme_get_features_host_mem_buf2; + nvme_get_features_iocs_profile; + nvme_get_features_lba_range2; + nvme_get_features_resv_mask2; + nvme_get_features_resv_persist2; + nvme_host_release_fds; + nvme_ns_release_fd; + nvme_root_release_fds; + nvme_set_debug; + nvme_set_features_iocs_profile; + nvme_set_features_resv_mask2; + nvme_set_features_resv_persist2; + nvme_set_features_write_protect2; + nvme_set_root; + nvme_subsystem_get_iopolicy; + nvme_subsystem_release_fds; +}; LIBNVME_1_5 { global: @@ -25,8 +50,6 @@ LIBNVME_1_3 { global: nvme_ctrl_is_unique_discovery_ctrl; nvme_ctrl_set_unique_discovery_ctrl; - nvme_fdp_reclaim_unit_handle_status; - nvme_fdp_reclaim_unit_handle_update; nvme_io_mgmt_recv; nvme_io_mgmt_send; nvme_host_is_pdc_enabled; @@ -55,19 +78,15 @@ LIBNVME_1_0 { global: nvme_admin_passthru64; nvme_admin_passthru; - nvme_attach_ns; nvme_capacity_mgmt; - nvme_compare; nvme_copy; nvme_create_root; nvme_create_ctrl; - nvme_ctrl_disconnect; nvme_ctrl_first_ns; nvme_ctrl_first_path; nvme_ctrl_get_address; nvme_ctrl_get_config; nvme_ctrl_get_dhchap_key; - nvme_ctrl_get_discovery_ctrl; nvme_ctrl_get_fd; nvme_ctrl_get_firmware; nvme_ctrl_get_host_iface; @@ -98,22 +117,14 @@ LIBNVME_1_0 { nvme_dev_self_test; nvme_dim_send; nvme_directive_recv; - nvme_directive_recv_identify_parameters; - nvme_directive_recv_stream_allocate; - nvme_directive_recv_stream_parameters; - nvme_directive_recv_stream_status; nvme_directive_send; nvme_directive_send_id_endir; - nvme_directive_send_stream_release_identifier; - nvme_directive_send_stream_release_resource; nvme_disconnect_ctrl; nvme_dsm; - nvme_dsm_range; nvme_dump_config; nvme_errno_to_string; nvme_first_host; nvme_first_subsystem; - nvme_flush; nvme_format_nvm; nvme_free_ctrl; nvme_free_host; @@ -163,31 +174,7 @@ LIBNVME_1_0 { nvme_get_host_telemetry; nvme_get_lba_status; nvme_get_log; - nvme_get_log_ana; - nvme_get_log_ana_groups; - nvme_get_log_boot_partition; - nvme_get_log_changed_ns_list; - nvme_get_log_cmd_effects; - nvme_get_log_create_telemetry_host; - nvme_get_log_device_self_test; - nvme_get_log_discovery; - nvme_get_log_endurance_group; - nvme_get_log_endurance_grp_evt; - nvme_get_log_error; - nvme_get_log_fid_supported_effects; - nvme_get_log_fw_slot; - nvme_get_log_lba_status; nvme_get_log_page; - nvme_get_log_persistent_event; - nvme_get_log_predictable_lat_event; - nvme_get_log_predictable_lat_nvmset; - nvme_get_log_reservation; - nvme_get_log_sanitize; - nvme_get_log_smart; - nvme_get_log_supported_log_pages; - nvme_get_log_telemetry_ctrl; - nvme_get_log_telemetry_host; - nvme_get_log_zns_changed_zones; nvme_get_logical_block_size; nvme_get_new_host_telemetry; nvme_get_ns_attr; @@ -196,6 +183,7 @@ LIBNVME_1_0 { nvme_get_property; nvme_get_subsys_attr; nvme_get_telemetry_log; + nvme_get_telemetry_max; nvme_host_get_dhchap_key; nvme_host_get_hostid; nvme_host_get_hostnqn; @@ -204,25 +192,6 @@ LIBNVME_1_0 { nvme_host_set_dhchap_key; nvme_host_set_hostsymname; nvme_identify; - nvme_identify_active_ns_list; - nvme_identify_allocated_ns; - nvme_identify_allocated_ns_list; - nvme_identify_ctrl; - nvme_identify_ctrl_list; - nvme_identify_domain_list; - nvme_identify_endurance_group_list; - nvme_identify_independent_identify_ns; - nvme_identify_ns_csi_user_data_format; - nvme_identify_iocs_ns_csi_user_data_format; - nvme_identify_iocs; - nvme_identify_ns; - nvme_identify_ns_descs; - nvme_identify_ns_granularity; - nvme_identify_nsid_ctrl_list; - nvme_identify_nvmset_list; - nvme_identify_primary_ctrl; - nvme_identify_secondary_ctrl_list; - nvme_identify_uuid; nvme_init_copy_range; nvme_init_ctrl; nvme_init_ctrl_list; @@ -243,10 +212,7 @@ LIBNVME_1_0 { nvme_next_host; nvme_next_subsystem; nvme_ns_attach; - nvme_ns_attach_ctrls; nvme_ns_compare; - nvme_ns_detach_ctrls; - nvme_ns_dettach_ctrls; nvme_ns_flush; nvme_ns_get_csi; nvme_ns_get_ctrl; @@ -259,7 +225,6 @@ LIBNVME_1_0 { nvme_ns_get_lba_util; nvme_ns_get_meta_size; nvme_ns_get_model; - nvme_ns_get_model; nvme_ns_get_name; nvme_ns_get_nguid; nvme_ns_get_nsid; @@ -269,16 +234,12 @@ LIBNVME_1_0 { nvme_ns_get_uuid; nvme_ns_identify; nvme_ns_mgmt; - nvme_ns_mgmt_create; - nvme_ns_mgmt_delete; - nvme_ns_open; nvme_ns_read; nvme_ns_rescan; nvme_ns_verify; nvme_ns_write; nvme_ns_write_uncorrectable; nvme_ns_write_zeros; - nvme_nvm_identify_ctrl; nvme_open; nvme_path_get_ana_state; nvme_path_get_ctrl; @@ -286,7 +247,6 @@ LIBNVME_1_0 { nvme_path_get_ns; nvme_path_get_sysfs_dir; nvme_paths_filter; - nvme_read; nvme_read_config; nvme_refresh_topology; nvme_rescan_ctrl; @@ -294,7 +254,6 @@ LIBNVME_1_0 { nvme_resv_register; nvme_resv_release; nvme_resv_report; - nvme_sanitize; nvme_sanitize_nvm; nvme_scan; nvme_scan_ctrl; @@ -306,9 +265,7 @@ LIBNVME_1_0 { nvme_scan_subsystem_namespaces; nvme_scan_subsystems; nvme_security_receive; - nvme_security_receive; nvme_security_send; - nvme_set_feature; nvme_set_features; nvme_set_features_arbitration; nvme_set_features_async_event; @@ -337,11 +294,8 @@ LIBNVME_1_0 { nvme_set_features_write_atomic; nvme_set_features_write_protect; nvme_set_property; - nvme_setup_ctrl_list; - nvme_setup_id_ns; nvme_status_to_errno; nvme_status_to_string; - nvme_status_type; nvme_submit_admin_passthru64; nvme_submit_admin_passthru; nvme_submit_io_passthru64; @@ -360,18 +314,10 @@ LIBNVME_1_0 { nvme_subsystem_reset; nvme_unlink_ctrl; nvme_update_config; - nvme_verify; nvme_virtual_mgmt; - nvme_write; - nvme_write_uncorrectable; - nvme_write_zeros; nvme_zns_append; - nvme_zns_identify_ctrl; - nvme_zns_identify_ns; - nvme_zns_identify_ns; nvme_zns_mgmt_recv; nvme_zns_mgmt_send; - nvme_zns_report_zones; nvmf_add_ctrl; nvmf_adrfam_str; nvmf_cms_str; diff --git a/src/nvme/fabrics.c b/src/nvme/fabrics.c index f0a06e8..21fb292 100644 --- a/src/nvme/fabrics.c +++ b/src/nvme/fabrics.c @@ -47,7 +47,7 @@ const char *nvmf_dev = "/dev/nvme-fabrics"; /** - * strchomp() - Strip trailing white space + * strchomp() - Strip trailing spaces * @str: String to strip * @max: Maximum length of string */ @@ -55,11 +55,8 @@ static void strchomp(char *str, int max) { int i; - for (i = max - 1; i >= 0; i--) { - if (str[i] != '\0' && str[i] != ' ') - return; - else - str[i] = '\0'; + for (i = max - 1; i >= 0 && str[i] == ' '; i--) { + str[i] = '\0'; } } @@ -357,10 +354,16 @@ static int __add_argument(char **argstr, const char *tok, const char *arg) return 0; } +static int __nvmf_supported_options(nvme_root_t r); +#define nvmf_check_option(r, tok) \ +({ \ + !__nvmf_supported_options(r) && (r)->options->tok; \ +}) + #define add_bool_argument(o, argstr, tok, arg) \ ({ \ int ret; \ - if (r->options->tok) { \ + if (nvmf_check_option(r, tok)) { \ ret = __add_bool_argument(argstr, \ stringify(tok), \ arg); \ @@ -376,7 +379,7 @@ static int __add_argument(char **argstr, const char *tok, const char *arg) #define add_int_argument(o, argstr, tok, arg, allow_zero) \ ({ \ int ret; \ - if (r->options->tok) { \ + if (nvmf_check_option(r, tok)) { \ ret = __add_int_argument(argstr, \ stringify(tok), \ arg, \ @@ -393,7 +396,7 @@ static int __add_argument(char **argstr, const char *tok, const char *arg) #define add_int_or_minus_one_argument(o, argstr, tok, arg) \ ({ \ int ret; \ - if (r->options->tok) { \ + if (nvmf_check_option(r, tok)) { \ ret = __add_int_or_minus_one_argument(argstr, \ stringify(tok), \ arg); \ @@ -409,7 +412,7 @@ static int __add_argument(char **argstr, const char *tok, const char *arg) #define add_argument(r, argstr, tok, arg) \ ({ \ int ret; \ - if (r->options->tok) { \ + if (nvmf_check_option(r, tok)) { \ ret = __add_argument(argstr, \ stringify(tok), \ arg); \ @@ -818,6 +821,28 @@ out_close: return ret; } +static const char *lookup_context(nvme_root_t r, nvme_ctrl_t c) +{ + + nvme_host_t h; + nvme_subsystem_t s; + + nvme_for_each_host(r, h) { + nvme_for_each_subsystem(h, s) { + if (__nvme_lookup_ctrl(s, nvme_ctrl_get_transport(c), + nvme_ctrl_get_traddr(c), + NULL, + NULL, + nvme_ctrl_get_trsvcid(c), + NULL, + NULL)) + return nvme_subsystem_get_application(s); + } + } + + return NULL; +} + int nvmf_add_ctrl(nvme_host_t h, nvme_ctrl_t c, const struct nvme_fabrics_config *cfg) { @@ -839,6 +864,7 @@ int nvmf_add_ctrl(nvme_host_t h, nvme_ctrl_t c, nvme_ctrl_get_host_traddr(c), nvme_ctrl_get_host_iface(c), nvme_ctrl_get_trsvcid(c), + NULL, NULL); if (fc) { const char *key; @@ -862,24 +888,9 @@ int nvmf_add_ctrl(nvme_host_t h, nvme_ctrl_t c, root_app = nvme_root_get_application(h->r); if (root_app) { app = nvme_subsystem_get_application(s); - if (!app && nvme_ctrl_is_discovery_ctrl(c)) { - nvme_subsystem_t s; - nvme_ctrl_t fc; + if (!app && nvme_ctrl_is_discovery_ctrl(c)) + app = lookup_context(h->r, c); - nvme_for_each_subsystem(h, s) { - fc = __nvme_lookup_ctrl(s, nvme_ctrl_get_transport(c), - nvme_ctrl_get_traddr(c), - NULL, - NULL, - nvme_ctrl_get_trsvcid(c), - NULL); - - if (fc) { - app = nvme_subsystem_get_application(s); - break; - } - } - } /* * configuration is managed by an application, * refuse to act on subsystems which either have @@ -907,9 +918,6 @@ int nvmf_add_ctrl(nvme_host_t h, nvme_ctrl_t c, free(traddr); } - ret = __nvmf_supported_options(h->r); - if (ret) - return ret; ret = build_options(h, c, &argstr); if (ret) return ret; @@ -1020,7 +1028,8 @@ nvme_ctrl_t nvmf_connect_disc_entry(nvme_host_t h, return NULL; } - if (e->treq & NVMF_TREQ_DISABLE_SQFLOW) + if (e->treq & NVMF_TREQ_DISABLE_SQFLOW && + nvmf_check_option(h->r, disable_sqflow)) c->cfg.disable_sqflow = true; if (e->trtype == NVMF_TRTYPE_TCP && @@ -1159,30 +1168,10 @@ out_free_log: return NULL; } -static void sanitize_discovery_log_entry(struct nvmf_disc_log_entry *e) +static void sanitize_discovery_log_entry(struct nvmf_disc_log_entry *e) { - switch (e->trtype) { - case NVMF_TRTYPE_RDMA: - case NVMF_TRTYPE_TCP: - switch (e->adrfam) { - case NVMF_ADDR_FAMILY_IP4: - case NVMF_ADDR_FAMILY_IP6: - strchomp(e->traddr, NVMF_TRADDR_SIZE); - strchomp(e->trsvcid, NVMF_TRSVCID_SIZE); - break; - } - break; - case NVMF_TRTYPE_FC: - switch (e->adrfam) { - case NVMF_ADDR_FAMILY_FC: - strchomp(e->traddr, NVMF_TRADDR_SIZE); - break; - } - break; - case NVMF_TRTYPE_LOOP: - strchomp(e->traddr, NVMF_TRADDR_SIZE); - break; - } + strchomp(e->trsvcid, sizeof(e->trsvcid)); + strchomp(e->traddr, sizeof(e->traddr)); } int nvmf_get_discovery_log(nvme_ctrl_t c, struct nvmf_discovery_log **logp, diff --git a/src/nvme/ioctl.c b/src/nvme/ioctl.c index b9710b3..14d186a 100644 --- a/src/nvme/ioctl.c +++ b/src/nvme/ioctl.c @@ -13,9 +13,11 @@ #include #include #include +#include #include #include +#include #include #include @@ -23,6 +25,8 @@ #include "ioctl.h" #include "util.h" +static bool nvme_debug; + static int nvme_verify_chr(int fd) { static struct stat nvme_stat; @@ -86,13 +90,62 @@ static int nvme_submit_passthru64(int fd, unsigned long ioctl_cmd, return err; } +static void nvme_show_command(struct nvme_passthru_cmd *cmd, int err, struct timeval start, + struct timeval end) +{ + printf("opcode : %02x\n", cmd->opcode); + printf("flags : %02x\n", cmd->flags); + printf("rsvd1 : %04x\n", cmd->rsvd1); + printf("nsid : %08x\n", cmd->nsid); + printf("cdw2 : %08x\n", cmd->cdw2); + printf("cdw3 : %08x\n", cmd->cdw3); + printf("data_len : %08x\n", cmd->data_len); + printf("metadata_len : %08x\n", cmd->metadata_len); + printf("addr : %"PRIx64"\n", (uint64_t)(uintptr_t)cmd->addr); + printf("metadata : %"PRIx64"\n", (uint64_t)(uintptr_t)cmd->metadata); + printf("cdw10 : %08x\n", cmd->cdw10); + printf("cdw11 : %08x\n", cmd->cdw11); + printf("cdw12 : %08x\n", cmd->cdw12); + printf("cdw13 : %08x\n", cmd->cdw13); + printf("cdw14 : %08x\n", cmd->cdw14); + printf("cdw15 : %08x\n", cmd->cdw15); + printf("timeout_ms : %08x\n", cmd->timeout_ms); + printf("result : %08x\n", cmd->result); + printf("err : %d\n", err); + printf("latency : %lu us\n", + (end.tv_sec - start.tv_sec) * 1000000 + (end.tv_usec - start.tv_usec)); +} + +void nvme_set_debug(bool debug) +{ + nvme_debug = debug; +} + +bool nvme_get_debug(void) +{ + return nvme_debug; +} + static int nvme_submit_passthru(int fd, unsigned long ioctl_cmd, struct nvme_passthru_cmd *cmd, __u32 *result) { - int err = ioctl(fd, ioctl_cmd, cmd); + struct timeval start; + struct timeval end; + int err; + + if (nvme_get_debug()) + gettimeofday(&start, NULL); + + err = ioctl(fd, ioctl_cmd, cmd); + + if (nvme_get_debug()) { + gettimeofday(&end, NULL); + nvme_show_command(cmd, err, start, end); + } if (err >= 0 && result) *result = cmd->result; + return err; } @@ -532,16 +585,18 @@ int nvme_set_features_power_mgmt(int fd, __u8 ps, __u8 wh, bool save, __u32 *result) { __u32 value = NVME_SET(ps, FEAT_PWRMGMT_PS) | - NVME_SET(wh, FEAT_PWRMGMT_PS); + NVME_SET(wh, FEAT_PWRMGMT_WH); return __nvme_set_features(fd, NVME_FEAT_FID_POWER_MGMT, value, save, result); } -int nvme_set_features_lba_range(int fd, __u32 nsid, __u32 nr_ranges, bool save, +int nvme_set_features_lba_range(int fd, __u32 nsid, __u8 nr_ranges, bool save, struct nvme_lba_range_type *data, __u32 *result) { - return -1; + return nvme_set_features_data( + fd, NVME_FEAT_FID_LBA_RANGE, nsid, nr_ranges - 1, save, + sizeof(*data), data, result); } int nvme_set_features_temp_thresh(int fd, __u16 tmpth, __u8 tmpsel, @@ -562,8 +617,8 @@ int nvme_set_features_err_recovery(int fd, __u32 nsid, __u16 tler, bool dulbe, __u32 value = NVME_SET(tler, FEAT_ERROR_RECOVERY_TLER) | NVME_SET(!!dulbe, FEAT_ERROR_RECOVERY_DULBE); - return __nvme_set_features(fd, NVME_FEAT_FID_ERR_RECOVERY, value, save, - result); + return nvme_set_features_simple( + fd, NVME_FEAT_FID_ERR_RECOVERY, nsid, value, save, result); } int nvme_set_features_volatile_wc(int fd, bool wce, bool save, __u32 *result) @@ -577,8 +632,8 @@ int nvme_set_features_volatile_wc(int fd, bool wce, bool save, __u32 *result) int nvme_set_features_irq_coalesce(int fd, __u8 thr, __u8 time, bool save, __u32 *result) { - __u32 value = NVME_SET(thr, FEAT_IRQC_TIME) | - NVME_SET(time, FEAT_IRQC_THR); + __u32 value = NVME_SET(thr, FEAT_IRQC_THR) | + NVME_SET(time, FEAT_IRQC_TIME); return __nvme_set_features(fd, NVME_FEAT_FID_IRQ_COALESCE, value, save, result); @@ -612,19 +667,31 @@ int nvme_set_features_async_event(int fd, __u32 events, int nvme_set_features_auto_pst(int fd, bool apste, bool save, struct nvme_feat_auto_pst *apst, __u32 *result) { - __u32 value = NVME_SET(!!apste, FEAT_APST_APSTE); + struct nvme_set_features_args args = { + .args_size = sizeof(args), + .fd = fd, + .fid = NVME_FEAT_FID_AUTO_PST, + .nsid = NVME_NSID_NONE, + .cdw11 = NVME_SET(!!apste, FEAT_APST_APSTE), + .save = save, + .uuidx = NVME_UUID_NONE, + .data = apst, + .data_len = sizeof(*apst), + .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, + .result = result, + }; - return __nvme_set_features(fd, NVME_FEAT_FID_AUTO_PST, value, save, - result); + return nvme_set_features(&args); } int nvme_set_features_timestamp(int fd, bool save, __u64 timestamp) { __le64 t = cpu_to_le64(timestamp); - struct nvme_timestamp ts; + struct nvme_timestamp ts = {}; struct nvme_set_features_args args = { .args_size = sizeof(args), .fd = fd, + .fid = NVME_FEAT_FID_TIMESTAMP, .nsid = NVME_NSID_NONE, .cdw11 = 0, .cdw12 = 0, @@ -694,8 +761,8 @@ int nvme_set_features_plm_config(int fd, bool plm, __u16 nvmsetid, bool save, .save = save, .uuidx = NVME_UUID_NONE, .cdw15 = 0, - .data_len = 0, - .data = NULL, + .data_len = sizeof(*data), + .data = data, .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, .result = result, }; @@ -746,7 +813,7 @@ int nvme_set_features_host_behavior(int fd, bool save, .nsid = NVME_NSID_NONE, .cdw11 = 0, .cdw12 = 0, - .save = save, + .save = false, .uuidx = NVME_UUID_NONE, .cdw15 = 0, .data_len = sizeof(*data), @@ -780,7 +847,7 @@ int nvme_set_features_sw_progress(int fd, __u8 pbslc, bool save, result); } -int nvme_set_features_host_id(int fd, bool save, bool exhid, __u8 *hostid) +int nvme_set_features_host_id(int fd, bool exhid, bool save, __u8 *hostid) { __u32 len = exhid ? 16 : 8; __u32 value = !!exhid; @@ -809,20 +876,42 @@ int nvme_set_features_resv_mask(int fd, __u32 mask, bool save, __u32 *result) result); } +int nvme_set_features_resv_mask2(int fd, __u32 nsid, __u32 mask, bool save, + __u32 *result) +{ + return nvme_set_features_simple( + fd, NVME_FEAT_FID_RESV_MASK, nsid, mask, save, result); +} + int nvme_set_features_resv_persist(int fd, bool ptpl, bool save, __u32 *result) { return __nvme_set_features(fd, NVME_FEAT_FID_RESV_PERSIST, !!ptpl, save, result); } +int nvme_set_features_resv_persist2(int fd, __u32 nsid, bool ptpl, bool save, + __u32 *result) +{ + return nvme_set_features_simple( + fd, NVME_FEAT_FID_RESV_PERSIST, nsid, !!ptpl, save, result); +} + int nvme_set_features_write_protect(int fd, enum nvme_feat_nswpcfg_state state, bool save, __u32 *result) { return __nvme_set_features(fd, NVME_FEAT_FID_WRITE_PROTECT, state, - save, result); + false, result); } -int nvme_set_features_iocs_profile(int fd, __u8 iocsi, bool save) +int nvme_set_features_write_protect2(int fd, __u32 nsid, + enum nvme_feat_nswpcfg_state state, + bool save, __u32 *result) +{ + return nvme_set_features_simple( + fd, NVME_FEAT_FID_WRITE_PROTECT, nsid, state, false, result); +} + +int nvme_set_features_iocs_profile(int fd, __u16 iocsi, bool save) { __u32 value = NVME_SET(iocsi, FEAT_IOCSP_IOCSCI); @@ -898,8 +987,28 @@ int nvme_get_features_lba_range(int fd, enum nvme_get_features_sel sel, .sel = sel, .cdw11 = 0, .uuidx = NVME_UUID_NONE, - .data_len = 0, - .data = NULL, + .data_len = sizeof(*data), + .data = data, + .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, + .result = result, + }; + + return nvme_get_features(&args); +} + +int nvme_get_features_lba_range2(int fd, enum nvme_get_features_sel sel, + __u32 nsid, struct nvme_lba_range_type *data, + __u32 *result) +{ + struct nvme_get_features_args args = { + .args_size = sizeof(args), + .fd = fd, + .fid = NVME_FEAT_FID_LBA_RANGE, + .nsid = nsid, + .sel = sel, + .uuidx = NVME_UUID_NONE, + .data = data, + .data_len = sizeof(*data), .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, .result = result, }; @@ -920,6 +1029,24 @@ int nvme_get_features_err_recovery(int fd, enum nvme_get_features_sel sel, result); } +int nvme_get_features_err_recovery2(int fd, enum nvme_get_features_sel sel, + __u32 nsid, __u32 *result) +{ + + struct nvme_get_features_args args = { + .args_size = sizeof(args), + .fd = fd, + .fid = NVME_FEAT_FID_ERR_RECOVERY, + .nsid = nsid, + .sel = sel, + .uuidx = NVME_UUID_NONE, + .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, + .result = result, + }; + + return nvme_get_features(&args); +} + int nvme_get_features_volatile_wc(int fd, enum nvme_get_features_sel sel, __u32 *result) { @@ -945,7 +1072,7 @@ int nvme_get_features_irq_config(int fd, enum nvme_get_features_sel sel, struct nvme_get_features_args args = { .args_size = sizeof(args), .fd = fd, - .fid = NVME_FEAT_FID_LBA_RANGE, + .fid = NVME_FEAT_FID_IRQ_CONFIG, .nsid = NVME_NSID_NONE, .sel = sel, .cdw11 = iv, @@ -978,13 +1105,13 @@ int nvme_get_features_auto_pst(int fd, enum nvme_get_features_sel sel, struct nvme_get_features_args args = { .args_size = sizeof(args), .fd = fd, - .fid = NVME_FEAT_FID_LBA_RANGE, + .fid = NVME_FEAT_FID_AUTO_PST, .nsid = NVME_NSID_NONE, .sel = sel, .cdw11 = 0, .uuidx = NVME_UUID_NONE, - .data_len = 0, - .data = NULL, + .data_len = sizeof(*apst), + .data = apst, .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, .result = result, }; @@ -998,6 +1125,26 @@ int nvme_get_features_host_mem_buf(int fd, enum nvme_get_features_sel sel, return __nvme_get_features(fd, NVME_FEAT_FID_HOST_MEM_BUF, sel, result); } +int nvme_get_features_host_mem_buf2(int fd, enum nvme_get_features_sel sel, + struct nvme_host_mem_buf_attrs *attrs, + __u32 *result) +{ + struct nvme_get_features_args args = { + .args_size = sizeof(args), + .fd = fd, + .fid = NVME_FEAT_FID_HOST_MEM_BUF, + .nsid = NVME_NSID_NONE, + .sel = sel, + .uuidx = NVME_UUID_NONE, + .data = attrs, + .data_len = sizeof(*attrs), + .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, + .result = result, + }; + + return nvme_get_features(&args); +} + int nvme_get_features_timestamp(int fd, enum nvme_get_features_sel sel, struct nvme_timestamp *ts) { @@ -1050,8 +1197,8 @@ int nvme_get_features_plm_config(int fd, enum nvme_get_features_sel sel, .sel = sel, .cdw11 = nvmsetid, .uuidx = NVME_UUID_NONE, - .data_len = 0, - .data = NULL, + .data_len = sizeof(*data), + .data = data, .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, .result = result, }; @@ -1098,8 +1245,8 @@ int nvme_get_features_host_behavior(int fd, enum nvme_get_features_sel sel, .sel = sel, .cdw11 = 0, .uuidx = NVME_UUID_NONE, - .data_len = 0, - .data = NULL, + .data_len = sizeof(*data), + .data = data, .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, .result = result, }; @@ -1122,7 +1269,7 @@ int nvme_get_features_endurance_event_cfg(int fd, enum nvme_get_features_sel sel .fid = NVME_FEAT_FID_ENDURANCE_EVT_CFG, .nsid = NVME_NSID_NONE, .sel = sel, - .cdw11 = 0, + .cdw11 = endgid, .uuidx = NVME_UUID_NONE, .data_len = 0, .data = NULL, @@ -1165,12 +1312,46 @@ int nvme_get_features_resv_mask(int fd, enum nvme_get_features_sel sel, return __nvme_get_features(fd, NVME_FEAT_FID_RESV_MASK, sel, result); } +int nvme_get_features_resv_mask2(int fd, enum nvme_get_features_sel sel, + __u32 nsid, __u32 *result) +{ + struct nvme_get_features_args args = { + .args_size = sizeof(args), + .fd = fd, + .fid = NVME_FEAT_FID_RESV_MASK, + .nsid = nsid, + .sel = sel, + .uuidx = NVME_UUID_NONE, + .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, + .result = result, + }; + + return nvme_get_features(&args); +} + int nvme_get_features_resv_persist(int fd, enum nvme_get_features_sel sel, __u32 *result) { return __nvme_get_features(fd, NVME_FEAT_FID_RESV_PERSIST, sel, result); } +int nvme_get_features_resv_persist2(int fd, enum nvme_get_features_sel sel, + __u32 nsid, __u32 *result) +{ + struct nvme_get_features_args args = { + .args_size = sizeof(args), + .fd = fd, + .fid = NVME_FEAT_FID_RESV_PERSIST, + .nsid = nsid, + .sel = sel, + .uuidx = NVME_UUID_NONE, + .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, + .result = result, + }; + + return nvme_get_features(&args); +} + int nvme_get_features_write_protect(int fd, __u32 nsid, enum nvme_get_features_sel sel, __u32 *result) diff --git a/src/nvme/ioctl.h b/src/nvme/ioctl.h index 4d843bc..3076152 100644 --- a/src/nvme/ioctl.h +++ b/src/nvme/ioctl.h @@ -748,7 +748,6 @@ static inline int nvme_identify_primary_ctrl(int fd, __u16 cntid, /** * nvme_identify_secondary_ctrl_list() - Retrieves secondary controller list * @fd: File descriptor of nvme device - * @nsid: Namespace identifier * @cntid: Return controllers starting at this identifier * @sc_list: User space destination address to transfer the data * @@ -763,7 +762,7 @@ static inline int nvme_identify_primary_ctrl(int fd, __u16 cntid, * Return: The nvme command status if a response was received (see * &enum nvme_status_field) or -1 with errno set otherwise. */ -static inline int nvme_identify_secondary_ctrl_list(int fd, __u32 nsid, +static inline int nvme_identify_secondary_ctrl_list(int fd, __u16 cntid, struct nvme_secondary_ctrl_list *sc_list) { struct nvme_identify_args args = { @@ -774,7 +773,7 @@ static inline int nvme_identify_secondary_ctrl_list(int fd, __u32 nsid, .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, .cns = NVME_IDENTIFY_CNS_SECONDARY_CTRL_LIST, .csi = NVME_CSI_NVM, - .nsid = nsid, + .nsid = NVME_NSID_NONE, .cntid = cntid, .cns_specific_id = NVME_CNSSPECID_NONE, .uuidx = NVME_UUID_NONE, @@ -981,21 +980,8 @@ static inline int nvme_identify_allocated_ns_list_csi(int fd, __u32 nsid, static inline int nvme_identify_independent_identify_ns(int fd, __u32 nsid, struct nvme_id_independent_id_ns *ns) { - struct nvme_identify_args args = { - .result = NULL, - .data = ns, - .args_size = sizeof(args), - .fd = fd, - .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, - .cns = NVME_IDENTIFY_CNS_CSI_INDEPENDENT_ID_NS, - .csi = NVME_CSI_NVM, - .nsid = nsid, - .cntid = NVME_CNTLID_NONE, - .cns_specific_id = NVME_CNSSPECID_NONE, - .uuidx = NVME_UUID_NONE, - }; - - return nvme_identify(&args); + return nvme_identify_cns_nsid( + fd, NVME_IDENTIFY_CNS_CSI_INDEPENDENT_ID_NS, nsid, ns); } /** @@ -1194,20 +1180,8 @@ static inline int nvme_identify_iocs(int fd, __u16 cntlid, static inline int nvme_zns_identify_ns(int fd, __u32 nsid, struct nvme_zns_id_ns *data) { - struct nvme_identify_args args = { - .result = NULL, - .data = data, - .args_size = sizeof(args), - .fd = fd, - .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, - .cns = NVME_IDENTIFY_CNS_CSI_NS, - .csi = NVME_CSI_ZNS, - .nsid = nsid, - .cntid = NVME_CNTLID_NONE, - .cns_specific_id = NVME_CNSSPECID_NONE, - }; - - return nvme_identify(&args); + return nvme_identify_ns_csi( + fd, nsid, NVME_UUID_NONE, NVME_CSI_ZNS, data); } /** @@ -1954,6 +1928,41 @@ static inline int nvme_get_log_boot_partition(int fd, bool rae, return nvme_get_log_page(fd, NVME_LOG_PAGE_PDU_SIZE, &args); } +/** + * nvme_get_log_phy_rx_eom() - Retrieve Physical Interface Receiver Eye Opening Measurement Log + * @fd: File descriptor of nvme device + * @lsp: Log specific, controls action and measurement quality + * @controller: Target controller ID + * @len: The allocated size, minimum + * struct nvme_phy_rx_eom_log + * @log: User address to store the log page + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise + */ +static inline int nvme_get_log_phy_rx_eom(int fd, __u8 lsp, __u16 controller, + __u32 len, struct nvme_phy_rx_eom_log *log) +{ + struct nvme_get_log_args args = { + .lpo = 0, + .result = NULL, + .log = log, + .args_size = sizeof(args), + .fd = fd, + .timeout = NVME_DEFAULT_IOCTL_TIMEOUT, + .lid = NVME_LOG_LID_PHY_RX_EOM, + .len = len, + .nsid = NVME_NSID_NONE, + .csi = NVME_CSI_NVM, + .lsi = controller, + .lsp = lsp, + .uuidx = NVME_UUID_NONE, + .rae = false, + .ot = false, + }; + return nvme_get_log_page(fd, NVME_LOG_PAGE_PDU_SIZE, &args); +} + /** * nvme_get_log_discovery() - Retrieve Discovery log page * @fd: File descriptor of nvme device @@ -2266,7 +2275,7 @@ int nvme_set_features_power_mgmt(int fd, __u8 ps, __u8 wh, bool save, * Return: The nvme command status if a response was received (see * &enum nvme_status_field) or -1 with errno set otherwise. */ -int nvme_set_features_lba_range(int fd, __u32 nsid, __u32 nr_ranges, bool save, +int nvme_set_features_lba_range(int fd, __u32 nsid, __u8 nr_ranges, bool save, struct nvme_lba_range_type *data, __u32 *result); /** @@ -2542,6 +2551,10 @@ int nvme_set_features_host_id(int fd, bool exhid, bool save, __u8 *hostid); /** * nvme_set_features_resv_mask() - Set reservation notification mask feature + * + * Deprecated: doesn't support specifying a NSID. + * Use nvme_set_features_resv_mask2() instead. + * * @fd: File descriptor of nvme device * @mask: Reservation Notification Mask Field * @save: Save value across power states @@ -2550,10 +2563,29 @@ int nvme_set_features_host_id(int fd, bool exhid, bool save, __u8 *hostid); * Return: The nvme command status if a response was received (see * &enum nvme_status_field) or -1 with errno set otherwise. */ -int nvme_set_features_resv_mask(int fd, __u32 mask, bool save, __u32 *result); +int nvme_set_features_resv_mask(int fd, __u32 mask, bool save, __u32 *result) + __attribute__((deprecated)); + +/** + * nvme_set_features_resv_mask2() - Set reservation notification mask feature + * @fd: File descriptor of nvme device + * @nsid: Namespace ID + * @mask: Reservation Notification Mask Field + * @save: Save value across power states + * @result: The command completion result from CQE dword0 + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise. + */ +int nvme_set_features_resv_mask2(int fd, __u32 nsid, __u32 mask, bool save, + __u32 *result); /** * nvme_set_features_resv_persist() - Set persist through power loss feature + * + * Deprecated: doesn't support specifying a NSID. + * Use nvme_set_features_resv_persist2() instead. + * * @fd: File descriptor of nvme device * @ptpl: Persist Through Power Loss * @save: Save value across power states @@ -2562,10 +2594,29 @@ int nvme_set_features_resv_mask(int fd, __u32 mask, bool save, __u32 *result); * Return: The nvme command status if a response was received (see * &enum nvme_status_field) or -1 with errno set otherwise. */ -int nvme_set_features_resv_persist(int fd, bool ptpl, bool save, __u32 *result); +int nvme_set_features_resv_persist(int fd, bool ptpl, bool save, __u32 *result) + __attribute__((deprecated)); + +/** + * nvme_set_features_resv_persist2() - Set persist through power loss feature + * @fd: File descriptor of nvme device + * @nsid: Namespace ID + * @ptpl: Persist Through Power Loss + * @save: Save value across power states + * @result: The command completion result from CQE dword0 + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise. + */ +int nvme_set_features_resv_persist2(int fd, __u32 nsid, bool ptpl, bool save, + __u32 *result); /** * nvme_set_features_write_protect() - Set write protect feature + * + * Deprecated: doesn't support specifying a NSID. + * Use nvme_set_features_write_protect2() instead. + * * @fd: File descriptor of nvme device * @state: Write Protection State * @save: Save value across power states @@ -2575,7 +2626,34 @@ int nvme_set_features_resv_persist(int fd, bool ptpl, bool save, __u32 *result); * &enum nvme_status_field) or -1 with errno set otherwise. */ int nvme_set_features_write_protect(int fd, enum nvme_feat_nswpcfg_state state, - bool save, __u32 *result); + bool save, __u32 *result) + __attribute__((deprecated)); + +/** + * nvme_set_features_write_protect2() - Set write protect feature + * @fd: File descriptor of nvme device + * @nsid: Namespace ID + * @state: Write Protection State + * @save: Save value across power states + * @result: The command completion result from CQE dword0 + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise. + */ +int nvme_set_features_write_protect2(int fd, __u32 nsid, + enum nvme_feat_nswpcfg_state state, + bool save, __u32 *result); + +/** + * nvme_set_features_iocs_profile() - Set I/O command set profile feature + * @fd: File descriptor of nvme device + * @iocsi: I/O Command Set Combination Index + * @save: Save value across power states + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise. + */ +int nvme_set_features_iocs_profile(int fd, __u16 iocsi, bool save); /** * nvme_get_features() - Retrieve a feature attribute @@ -2660,6 +2738,10 @@ int nvme_get_features_power_mgmt(int fd, enum nvme_get_features_sel sel, /** * nvme_get_features_lba_range() - Get LBA range feature + * + * Deprecated: doesn't support specifying a NSID. + * Use nvme_get_features_lba_range2() instead. + * * @fd: File descriptor of nvme device * @sel: Select which type of attribute to return, see &enum nvme_get_features_sel * @data: User address of feature data, if applicable @@ -2670,7 +2752,22 @@ int nvme_get_features_power_mgmt(int fd, enum nvme_get_features_sel sel, */ int nvme_get_features_lba_range(int fd, enum nvme_get_features_sel sel, struct nvme_lba_range_type *data, - __u32 *result); + __u32 *result) __attribute__((deprecated)); + +/** + * nvme_get_features_lba_range2() - Get LBA range feature + * @fd: File descriptor of nvme device + * @sel: Select which type of attribute to return, see &enum nvme_get_features_sel + * @nsid: Namespace ID + * @data: Buffer to receive LBA Range Type data structure + * @result: The command completion result from CQE dword0 + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise. + */ +int nvme_get_features_lba_range2(int fd, enum nvme_get_features_sel sel, + __u32 nsid, struct nvme_lba_range_type *data, + __u32 *result); /** * nvme_get_features_temp_thresh() - Get temperature threshold feature @@ -2686,6 +2783,10 @@ int nvme_get_features_temp_thresh(int fd, enum nvme_get_features_sel sel, /** * nvme_get_features_err_recovery() - Get error recovery feature + * + * Deprecated: doesn't support specifying a NSID. + * Use nvme_get_features_err_recovery2() instead. + * * @fd: File descriptor of nvme device * @sel: Select which type of attribute to return, see &enum nvme_get_features_sel * @result: The command completion result from CQE dword0 @@ -2694,7 +2795,20 @@ int nvme_get_features_temp_thresh(int fd, enum nvme_get_features_sel sel, * &enum nvme_status_field) or -1 with errno set otherwise. */ int nvme_get_features_err_recovery(int fd, enum nvme_get_features_sel sel, - __u32 *result); + __u32 *result) __attribute__((deprecated)); + +/** + * nvme_get_features_err_recovery2() - Get error recovery feature + * @fd: File descriptor of nvme device + * @sel: Select which type of attribute to return, see &enum nvme_get_features_sel + * @nsid: Namespace ID + * @result: The command completion result from CQE dword0 + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise. + */ +int nvme_get_features_err_recovery2(int fd, enum nvme_get_features_sel sel, + __u32 nsid, __u32 *result); /** * nvme_get_features_volatile_wc() - Get volatile write cache feature @@ -2784,6 +2898,10 @@ int nvme_get_features_auto_pst(int fd, enum nvme_get_features_sel sel, /** * nvme_get_features_host_mem_buf() - Get host memory buffer feature + * + * Deprecated: doesn't fetch the Host Memory Buffer Attributes data structure. + * Use nvme_get_features_host_mem_buf2() instead. + * * @fd: File descriptor of nvme device * @sel: Select which type of attribute to return, see &enum nvme_get_features_sel * @result: The command completion result from CQE dword0 @@ -2792,7 +2910,21 @@ int nvme_get_features_auto_pst(int fd, enum nvme_get_features_sel sel, * &enum nvme_status_field) or -1 with errno set otherwise. */ int nvme_get_features_host_mem_buf(int fd, enum nvme_get_features_sel sel, - __u32 *result); + __u32 *result) __attribute__((deprecated)); + +/** + * nvme_get_features_host_mem_buf2() - Get host memory buffer feature + * @fd: File descriptor of nvme device + * @sel: Select which type of attribute to return, see &enum nvme_get_features_sel + * @attrs: Buffer for returned Host Memory Buffer Attributes + * @result: The command completion result from CQE dword0 + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise. + */ +int nvme_get_features_host_mem_buf2(int fd, enum nvme_get_features_sel sel, + struct nvme_host_mem_buf_attrs *attrs, + __u32 *result); /** * nvme_get_features_timestamp() - Get timestamp feature @@ -2957,6 +3089,10 @@ int nvme_get_features_host_id(int fd, enum nvme_get_features_sel sel, /** * nvme_get_features_resv_mask() - Get reservation mask feature + * + * Deprecated: doesn't support specifying a NSID. + * Use nvme_get_features_resv_mask2() instead. + * * @fd: File descriptor of nvme device * @sel: Select which type of attribute to return, see &enum nvme_get_features_sel * @result: The command completion result from CQE dword0 @@ -2965,10 +3101,27 @@ int nvme_get_features_host_id(int fd, enum nvme_get_features_sel sel, * &enum nvme_status_field) or -1 with errno set otherwise. */ int nvme_get_features_resv_mask(int fd, enum nvme_get_features_sel sel, - __u32 *result); + __u32 *result) __attribute__((deprecated)); + +/** + * nvme_get_features_resv_mask2() - Get reservation mask feature + * @fd: File descriptor of nvme device + * @sel: Select which type of attribute to return, see &enum nvme_get_features_sel + * @nsid: Namespace ID + * @result: The command completion result from CQE dword0 + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise. + */ +int nvme_get_features_resv_mask2(int fd, enum nvme_get_features_sel sel, + __u32 nsid, __u32 *result); /** * nvme_get_features_resv_persist() - Get reservation persist feature + * + * Deprecated: doesn't support specifying a NSID. + * Use nvme_get_features_resv_persist2() instead. + * * @fd: File descriptor of nvme device * @sel: Select which type of attribute to return, see &enum nvme_get_features_sel * @result: The command completion result from CQE dword0 @@ -2977,7 +3130,20 @@ int nvme_get_features_resv_mask(int fd, enum nvme_get_features_sel sel, * &enum nvme_status_field) or -1 with errno set otherwise. */ int nvme_get_features_resv_persist(int fd, enum nvme_get_features_sel sel, - __u32 *result); + __u32 *result) __attribute__((deprecated)); + +/** + * nvme_get_features_resv_persist2() - Get reservation persist feature + * @fd: File descriptor of nvme device + * @sel: Select which type of attribute to return, see &enum nvme_get_features_sel + * @nsid: Namespace ID + * @result: The command completion result from CQE dword0 + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise. + */ +int nvme_get_features_resv_persist2(int fd, enum nvme_get_features_sel sel, + __u32 nsid, __u32 *result); /** * nvme_get_features_write_protect() - Get write protect feature @@ -3881,4 +4047,16 @@ int nvme_zns_append(struct nvme_zns_append_args *args); */ int nvme_dim_send(struct nvme_dim_args *args); +/** + * nvme_set_debug - Set NVMe command debugging output + * @debug: true to enable or false to disable + */ +void nvme_set_debug(bool debug); + +/** + * nvme_get_debug - Get NVMe command debugging output + * + * Return: false if disabled or true if enabled. + */ +bool nvme_get_debug(void); #endif /* _LIBNVME_IOCTL_H */ diff --git a/src/nvme/linux.c b/src/nvme/linux.c index c6eedc2..adbc4cd 100644 --- a/src/nvme/linux.c +++ b/src/nvme/linux.c @@ -122,17 +122,44 @@ int nvme_fw_download_seq(int fd, __u32 size, __u32 xfer, __u32 offset, return err; } -static int nvme_get_telemetry_log(int fd, bool create, bool ctrl, bool rae, - struct nvme_telemetry_log **buf, enum nvme_telemetry_da da, - size_t *size) +int nvme_get_telemetry_max(int fd, enum nvme_telemetry_da *da, size_t *data_tx) +{ + struct nvme_id_ctrl id_ctrl; + int err = nvme_identify_ctrl(fd, &id_ctrl); + + if (err) + return err; + + if (data_tx) { + *data_tx = id_ctrl.mdts; + if (id_ctrl.mdts) { + /* assuming CAP.MPSMIN is zero minimum Memory Page Size is at least + * 4096 bytes + */ + *data_tx = (1 << id_ctrl.mdts) * 4096; + } + } + if (da) { + if (id_ctrl.lpa & 0x8) + *da = NVME_TELEMETRY_DA_3; + if (id_ctrl.lpa & 0x40) + *da = NVME_TELEMETRY_DA_4; + + } + return err; +} + +int nvme_get_telemetry_log(int fd, bool create, bool ctrl, bool rae, size_t max_data_tx, + enum nvme_telemetry_da da, struct nvme_telemetry_log **buf, + size_t *size) { static const __u32 xfer = NVME_LOG_TELEM_BLOCK_SIZE; struct nvme_telemetry_log *telem; enum nvme_cmd_get_log_lid lid; - struct nvme_id_ctrl id_ctrl; void *log, *tmp; int err; + size_t dalb; struct nvme_get_log_args args = { .args_size = sizeof(args), .fd = fd, @@ -178,35 +205,31 @@ static int nvme_get_telemetry_log(int fd, bool create, bool ctrl, bool rae, switch (da) { case NVME_TELEMETRY_DA_1: + dalb = le16_to_cpu(telem->dalb1); + break; case NVME_TELEMETRY_DA_2: + dalb = le16_to_cpu(telem->dalb2); + break; case NVME_TELEMETRY_DA_3: /* dalb3 >= dalb2 >= dalb1 */ - *size = (le16_to_cpu(telem->dalb3) + 1) * xfer; + dalb = le16_to_cpu(telem->dalb3); break; case NVME_TELEMETRY_DA_4: - err = nvme_identify_ctrl(fd, &id_ctrl); - if (err) { - perror("identify-ctrl"); - errno = EINVAL; - goto free; - } - - if (id_ctrl.lpa & 0x40) { - *size = (le32_to_cpu(telem->dalb4) + 1) * xfer; - } else { - fprintf(stderr, "Data area 4 unsupported, bit 6 of Log Page Attributes not set\n"); - errno = EINVAL; - err = -1; - goto free; - } + dalb = le32_to_cpu(telem->dalb4); break; default: - fprintf(stderr, "Invalid data area parameter - %d\n", da); errno = EINVAL; err = -1; goto free; } + if (dalb == 0) { + errno = ENOENT; + err = -1; + goto free; + } + + *size = (dalb + 1) * xfer; tmp = realloc(log, *size); if (!tmp) { errno = ENOMEM; @@ -218,7 +241,7 @@ static int nvme_get_telemetry_log(int fd, bool create, bool ctrl, bool rae, args.lid = lid; args.log = log; args.len = *size; - err = nvme_get_log_page(fd, 4096, &args); + err = nvme_get_log_page(fd, max_data_tx, &args); if (!err) { *buf = log; return 0; @@ -228,22 +251,40 @@ free: return err; } + +static int nvme_check_get_telemetry_log(int fd, bool create, bool ctrl, bool rae, + struct nvme_telemetry_log **log, enum nvme_telemetry_da da, + size_t *size) +{ + enum nvme_telemetry_da max_da = 0; + int err = nvme_get_telemetry_max(fd, &max_da, NULL); + + if (err) + return err; + if (da > max_da) { + errno = ENOENT; + return -1; + } + return nvme_get_telemetry_log(fd, create, ctrl, rae, 4096, da, log, size); +} + + int nvme_get_ctrl_telemetry(int fd, bool rae, struct nvme_telemetry_log **log, enum nvme_telemetry_da da, size_t *size) { - return nvme_get_telemetry_log(fd, false, true, rae, log, da, size); + return nvme_check_get_telemetry_log(fd, false, true, rae, log, da, size); } int nvme_get_host_telemetry(int fd, struct nvme_telemetry_log **log, enum nvme_telemetry_da da, size_t *size) { - return nvme_get_telemetry_log(fd, false, false, false, log, da, size); + return nvme_check_get_telemetry_log(fd, false, false, false, log, da, size); } int nvme_get_new_host_telemetry(int fd, struct nvme_telemetry_log **log, enum nvme_telemetry_da da, size_t *size) { - return nvme_get_telemetry_log(fd, true, false, false, log, da, size); + return nvme_check_get_telemetry_log(fd, true, false, false, log, da, size); } int nvme_get_lba_status_log(int fd, bool rae, struct nvme_lba_status_log **log) diff --git a/src/nvme/linux.h b/src/nvme/linux.h index 37ba9d4..be91819 100644 --- a/src/nvme/linux.h +++ b/src/nvme/linux.h @@ -48,6 +48,37 @@ enum nvme_telemetry_da { NVME_TELEMETRY_DA_4 = 4, }; +/** + * nvme_get_telemetry_max() - Get telemetry limits + * @fd: File descriptor of nvme device + * @da: On success return max supported data area + * @max_data_tx: On success set to max transfer chunk supported by the controller + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise. + */ +int nvme_get_telemetry_max(int fd, enum nvme_telemetry_da *da, size_t *max_data_tx); + +/** + * nvme_get_telemetry_log() - Get specified telemetry log + * @fd: File descriptor of nvme device + * @create: Generate new host initated telemetry capture + * @ctrl: Get controller Initiated log + * @rae: Retain asynchronous events + * @max_data_tx: Set the max data transfer size to be used retrieving telemetry. + * @da: Log page data area, valid values: &enum nvme_telemetry_da. + * @log: On success, set to the value of the allocated and retrieved log. + * @size: Ptr to the telemetry log size, so it can be returned + * + * The total size allocated can be calculated as: + * (nvme_telemetry_log da size + 1) * NVME_LOG_TELEM_BLOCK_SIZE. + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise. + */ +int nvme_get_telemetry_log(int fd, bool create, bool ctrl, bool rae, size_t max_data_tx, + enum nvme_telemetry_da da, struct nvme_telemetry_log **log, + size_t *size); /** * nvme_get_ctrl_telemetry() - Get controller telemetry log * @fd: File descriptor of nvme device diff --git a/src/nvme/log.c b/src/nvme/log.c index e4697df..d4cef19 100644 --- a/src/nvme/log.c +++ b/src/nvme/log.c @@ -26,11 +26,13 @@ #define LOG_CLOCK CLOCK_MONOTONIC #endif +static nvme_root_t root; + void __attribute__((format(printf, 4, 5))) __nvme_msg(nvme_root_t r, int lvl, const char *func, const char *format, ...) { - FILE *fp = r ? r->fp : stderr; + FILE *fp = stderr; va_list ap; char pidbuf[16]; char timebuf[32]; @@ -48,6 +50,12 @@ __nvme_msg(nvme_root_t r, int lvl, char *message __cleanup__(cleanup_charp) = NULL; int idx = 0; + if (!r) + r = root; + + if (r) + fp = r->fp; + if (r && lvl > r->log_level) return; @@ -90,3 +98,8 @@ void nvme_init_logging(nvme_root_t r, int lvl, bool log_pid, bool log_tstamp) r->log_pid = log_pid; r->log_timestamp = log_tstamp; } + +void nvme_set_root(nvme_root_t r) +{ + root = r; +} diff --git a/src/nvme/log.h b/src/nvme/log.h index 1cf797a..7c345f6 100644 --- a/src/nvme/log.h +++ b/src/nvme/log.h @@ -35,4 +35,17 @@ */ void nvme_init_logging(nvme_root_t r, int lvl, bool log_pid, bool log_tstamp); +/** + * nvme_set_root() - Set nvme_root_t context + * @r: nvme_root_t context + * + * In order to be able to log from code paths where no root object is passed in + * via the arguments use the the default one which can be set via this call. + * When creating a new root object with @nvme_create_root the global root object + * will be set as well. This means the global root object is always pointing to + * the latest created root object. Note the first @nvme_free_tree call will reset + * the global root object. + */ +void nvme_set_root(nvme_root_t r); + #endif /* _LOG_H */ diff --git a/src/nvme/mi-mctp.c b/src/nvme/mi-mctp.c index 0c5972a..86c4c29 100644 --- a/src/nvme/mi-mctp.c +++ b/src/nvme/mi-mctp.c @@ -82,6 +82,8 @@ struct nvme_mi_transport_mctp { int net; __u8 eid; int sd; + void *resp_buf; + size_t resp_buf_size; }; static int ioctl_tag(int sd, unsigned long req, struct mctp_ioc_tag_ctl *ctl) @@ -175,60 +177,40 @@ struct nvme_mi_msg_resp_mpr { /* Check if this response was a More Processing Required response; if so, * populate the worst-case expected processing time, given in milliseconds. + * + * buf is the incoming message data, including type byte, but excluding + * the MIC which has been extracted into the mic argument already. */ -static bool nvme_mi_mctp_resp_is_mpr(struct nvme_mi_resp *resp, size_t len, +static bool nvme_mi_mctp_resp_is_mpr(void *buf, size_t len, __le32 mic, unsigned int *mpr_time) { - struct nvme_mi_admin_resp_hdr *admin_msg; struct nvme_mi_msg_resp_mpr *msg; - size_t clen; __u32 crc; - /* We need at least the minimal header plus checksum */ - if (len < sizeof(*msg) + sizeof(mic)) + /* We need at least the minimal header */ + if (len < sizeof(*msg)) return false; - msg = (struct nvme_mi_msg_resp_mpr *)resp->hdr; + msg = (struct nvme_mi_msg_resp_mpr *)buf; if (msg->status != NVME_MI_RESP_MPR) return false; - /* Find and verify the MIC from the response, which may not be laid out - * in resp as we expect. We have to preserve resp->hdr_len and - * resp->data_len, as we will need them for the eventual reply message. - * Because of that, we can't use verify_resp_mic here. - * - * If the packet was at the expected response size, then mic will - * be set already; if not, find it within the header/data buffers. - */ - /* Devices may send a MPR response as a full-sized Admin response, * rather than the minimal MI-only header. Allow this, but only if the * type indicates admin, and the allocated response header is the * correct size for an Admin response. */ - if (((msg->hdr.nmp >> 3) & 0xf) == NVME_MI_MT_ADMIN && - len == sizeof(*admin_msg) + sizeof(mic) && - resp->hdr_len == sizeof(*admin_msg)) { - if (resp->data_len) - mic = *(__le32 *)resp->data; - } else if (len == sizeof(*msg) + sizeof(mic)) { - if (resp->hdr_len > sizeof(*msg)) - mic = *(__le32 *)(msg + 1); - else if (resp->data_len) - mic = *(__le32 *)(resp->data); - } else { - return false; - } + if (!(len == sizeof(*msg) || + ((msg->hdr.nmp >> 3 & 0x0f) == NVME_MI_MT_ADMIN && + len == sizeof(struct nvme_mi_admin_resp_hdr)))) + return false; - /* Since our response is just a header, we're guaranteed to have - * all data in resp->hdr. The response may be shorter than the expected - * header though, so clamp to len. + /* Verify the MIC from the response. We're dealing with linear + * header data here, and need to preserve the resp pointer & size + * values, so can't use verify_resp_mic here. */ - len -= sizeof(mic); - clen = len < resp->hdr_len ? len : resp->hdr_len; - - crc = ~nvme_mi_crc32_update(0xffffffff, resp->hdr, clen); + crc = ~nvme_mi_crc32_update(0xffffffff, buf, len); if (le32_to_cpu(mic) != crc) return false; @@ -242,14 +224,14 @@ static int nvme_mi_mctp_submit(struct nvme_mi_ep *ep, struct nvme_mi_req *req, struct nvme_mi_resp *resp) { + ssize_t len, resp_len, resp_hdr_len, resp_data_len; struct nvme_mi_transport_mctp *mctp; - struct iovec req_iov[3], resp_iov[3]; + struct iovec req_iov[3], resp_iov[1]; struct msghdr req_msg, resp_msg; int i, rc, errno_save, timeout; struct sockaddr_mctp addr; struct pollfd pollfds[1]; unsigned int mpr_time; - ssize_t len; __le32 mic; __u8 tag; @@ -306,20 +288,30 @@ static int nvme_mi_mctp_submit(struct nvme_mi_ep *ep, goto out; } - resp_iov[0].iov_base = ((__u8 *)resp->hdr) + 1; - resp_iov[0].iov_len = resp->hdr_len - 1; + resp_len = resp->hdr_len + resp->data_len + sizeof(mic); + if (resp_len > mctp->resp_buf_size) { + void *tmp = realloc(mctp->resp_buf, resp_len); + if (!tmp) { + errno_save = errno; + nvme_msg(ep->root, LOG_ERR, + "Failure allocating response buffer: %m\n"); + errno = errno_save; + rc = -1; + goto out; + } + mctp->resp_buf = tmp; + mctp->resp_buf_size = resp_len; + } - resp_iov[1].iov_base = ((__u8 *)resp->data); - resp_iov[1].iov_len = resp->data_len; - - resp_iov[2].iov_base = &mic; - resp_iov[2].iov_len = sizeof(mic); + /* offset by one: the MCTP message type is excluded from the buffer */ + resp_iov[0].iov_base = mctp->resp_buf + 1; + resp_iov[0].iov_len = resp_len - 1; memset(&resp_msg, 0, sizeof(resp_msg)); resp_msg.msg_name = &addr; resp_msg.msg_namelen = sizeof(addr); resp_msg.msg_iov = resp_iov; - resp_msg.msg_iovlen = 3; + resp_msg.msg_iovlen = 1; pollfds[0].fd = mctp->sd; pollfds[0].events = POLLIN; @@ -333,13 +325,14 @@ retry: nvme_msg(ep->root, LOG_ERR, "Failed polling on MCTP socket: %m"); errno = errno_save; - return -1; + goto out; } if (rc == 0) { nvme_msg(ep->root, LOG_DEBUG, "Timeout on MCTP socket"); errno = ETIMEDOUT; - return -1; + rc = -1; + goto out; } rc = -1; @@ -361,7 +354,7 @@ retry: } /* Re-add the type byte, so we can work on aligned lengths from here */ - resp->hdr->type = MCTP_TYPE_NVME | MCTP_TYPE_MIC; + ((uint8_t *)mctp->resp_buf)[0] = MCTP_TYPE_NVME | MCTP_TYPE_MIC; len += 1; /* The smallest response data is 8 bytes: generic 4-byte message header @@ -375,21 +368,21 @@ retry: goto out; } - /* We can't have header/payload data that isn't a multiple of 4 bytes */ - if (len & 0x3) { - nvme_msg(ep->root, LOG_WARNING, - "Response message has unaligned length (%zd)!\n", - len); - errno = EPROTO; - goto out; - } + /* Start unpacking the linear resp buffer into the split header + data + * + MIC. We check for a MPR response before fully unpacking, as we'll + * need to preserve the resp layout if we need to retry the receive. + */ + + /* MIC is always at the tail */ + memcpy(&mic, mctp->resp_buf + len - sizeof(mic), sizeof(mic)); + len -= 4; /* Check for a More Processing Required response. This is a slight * layering violation, as we're pre-checking the MIC and inspecting * header fields. However, we need to do this in the transport in order * to keep the tag allocated and retry the recvmsg */ - if (nvme_mi_mctp_resp_is_mpr(resp, len, mic, &mpr_time)) { + if (nvme_mi_mctp_resp_is_mpr(mctp->resp_buf, len, mic, &mpr_time)) { nvme_msg(ep->root, LOG_DEBUG, "Received More Processing Required, waiting for response\n"); @@ -406,30 +399,20 @@ retry: goto retry; } - /* If we have a shorter than expected response, we need to find the - * MIC and the correct split between header & data. We know that the - * split is 4-byte aligned, so the MIC will be entirely within one - * of the iovecs. - */ - if (len == resp->hdr_len + resp->data_len + sizeof(mic)) { - /* Common case: expected data length. Header, data and MIC - * are already laid-out correctly. Nothing to do. */ + /* we expect resp->hdr_len bytes, but we may have less */ + resp_hdr_len = resp->hdr_len; + if (resp_hdr_len > len) + resp_hdr_len = len; + memcpy(resp->hdr, mctp->resp_buf, resp_hdr_len); + resp->hdr_len = resp_hdr_len; + len -= resp_hdr_len; - } else if (len < resp->hdr_len + sizeof(mic)) { - /* Response is smaller than the expected header. MIC is - * somewhere in the header buf */ - resp->hdr_len = len - sizeof(mic); - resp->data_len = 0; - memcpy(&mic, ((uint8_t *)resp->hdr) + resp->hdr_len, - sizeof(mic)); - - } else { - /* We have a full header, but data is truncated - possibly - * zero bytes. MIC is somewhere in the data buf */ - resp->data_len = len - resp->hdr_len - sizeof(mic); - memcpy(&mic, ((uint8_t *)resp->data) + resp->data_len, - sizeof(mic)); - } + /* any remaining bytes are the data payload */ + resp_data_len = resp->data_len; + if (resp_data_len > len) + resp_data_len = len; + memcpy(resp->data, mctp->resp_buf + resp_hdr_len, resp_data_len); + resp->data_len = resp_data_len; resp->mic = le32_to_cpu(mic); @@ -450,6 +433,7 @@ static void nvme_mi_mctp_close(struct nvme_mi_ep *ep) mctp = ep->transport_data; close(mctp->sd); + free(mctp->resp_buf); free(ep->transport_data); } @@ -488,15 +472,29 @@ nvme_mi_ep_t nvme_mi_open_mctp(nvme_root_t root, unsigned int netid, __u8 eid) return NULL; mctp = malloc(sizeof(*mctp)); - if (!mctp) - goto err_free_ep; + if (!mctp) { + errno_save = errno; + goto err_close_ep; + } + + memset(mctp, 0, sizeof(*mctp)); + mctp->sd = -1; + + mctp->resp_buf_size = 4096; + mctp->resp_buf = malloc(mctp->resp_buf_size); + if (!mctp->resp_buf) { + errno_save = errno; + goto err_free_mctp; + } mctp->net = netid; mctp->eid = eid; mctp->sd = ops.socket(AF_MCTP, SOCK_DGRAM, 0); - if (mctp->sd < 0) - goto err_free_ep; + if (mctp->sd < 0) { + errno_save = errno; + goto err_free_rspbuf; + } ep->transport = &nvme_mi_transport_mctp; ep->transport_data = mctp; @@ -512,10 +510,14 @@ nvme_mi_ep_t nvme_mi_open_mctp(nvme_root_t root, unsigned int netid, __u8 eid) return ep; -err_free_ep: - errno_save = errno; - nvme_mi_close(ep); +err_free_rspbuf: + free(mctp->resp_buf); +err_free_mctp: free(mctp); +err_close_ep: + /* the ep->transport is not set yet, so this will not call back + * into nvme_mi_mctp_close() */ + nvme_mi_close(ep); errno = errno_save; return NULL; } diff --git a/src/nvme/mi.c b/src/nvme/mi.c index 3799f35..95f5224 100644 --- a/src/nvme/mi.c +++ b/src/nvme/mi.c @@ -413,11 +413,6 @@ int nvme_mi_submit(nvme_mi_ep_t ep, struct nvme_mi_req *req, return -1; } - if (resp->data_len & 0x3) { - errno = EINVAL; - return -1; - } - if (ep->transport->mic_enabled) nvme_mi_calc_req_mic(req); @@ -580,8 +575,10 @@ int nvme_mi_admin_xfer(nvme_mi_ctrl_t ctrl, return -1; } - /* must be aligned */ - if (resp_data_offset & 0x3) { + /* request and response lengths & offset must be aligned */ + if ((req_data_size & 0x3) || + (*resp_data_size & 0x3) || + (resp_data_offset & 0x3)) { errno = EINVAL; return -1; } diff --git a/src/nvme/mi.h b/src/nvme/mi.h index 211cb29..bd26627 100644 --- a/src/nvme/mi.h +++ b/src/nvme/mi.h @@ -1395,7 +1395,6 @@ static inline int nvme_mi_admin_identify_primary_ctrl(nvme_mi_ctrl_t ctrl, * nvme_mi_admin_identify_secondary_ctrl_list() - Perform an Admin identify for * a secondary controller list. * @ctrl: Controller to process identify command - * @nsid: Namespace ID to specify list start * @cntid: Controller ID to specify list start * @list: List data to populate * @@ -1412,7 +1411,6 @@ static inline int nvme_mi_admin_identify_primary_ctrl(nvme_mi_ctrl_t ctrl, * See: &struct nvme_secondary_ctrl_list */ static inline int nvme_mi_admin_identify_secondary_ctrl_list(nvme_mi_ctrl_t ctrl, - __u32 nsid, __u16 cntid, struct nvme_secondary_ctrl_list *list) { @@ -1422,7 +1420,7 @@ static inline int nvme_mi_admin_identify_secondary_ctrl_list(nvme_mi_ctrl_t ctrl .args_size = sizeof(args), .cns = NVME_IDENTIFY_CNS_SECONDARY_CTRL_LIST, .csi = NVME_CSI_NVM, - .nsid = nsid, + .nsid = NVME_NSID_NONE, .cntid = cntid, .cns_specific_id = NVME_CNSSPECID_NONE, .uuidx = NVME_UUID_NONE, @@ -2108,6 +2106,41 @@ static inline int nvme_mi_admin_get_log_boot_partition(nvme_mi_ctrl_t ctrl, return nvme_mi_admin_get_log(ctrl, &args); } +/** + * nvme_mi_admin_get_log_phy_rx_eom() - Retrieve Physical Interface Receiver Eye Opening Measurement Log + * @ctrl: Controller to query + * @lsp: Log specific, controls action and measurement quality + * @controller: Target controller ID + * @len: The allocated size, minimum + * struct nvme_phy_rx_eom_log + * @log: User address to store the log page + * + * Return: The nvme command status if a response was received (see + * &enum nvme_status_field) or -1 with errno set otherwise + */ +static inline int nvme_mi_admin_get_log_phy_rx_eom(nvme_mi_ctrl_t ctrl, + __u8 lsp, __u16 controller, + __u32 len, + struct nvme_phy_rx_eom_log *log) +{ + struct nvme_get_log_args args = { + .lpo = 0, + .result = NULL, + .log = log, + .args_size = sizeof(args), + .lid = NVME_LOG_LID_PHY_RX_EOM, + .len = len, + .nsid = NVME_NSID_NONE, + .csi = NVME_CSI_NVM, + .lsi = controller, + .lsp = lsp, + .uuidx = NVME_UUID_NONE, + .rae = false, + .ot = false, + }; + return nvme_mi_admin_get_log(ctrl, &args); +} + /** * nvme_mi_admin_get_log_discovery() - Retrieve Discovery log page * @ctrl: Controller to query diff --git a/src/nvme/private.h b/src/nvme/private.h index 809b3bb..6fb9784 100644 --- a/src/nvme/private.h +++ b/src/nvme/private.h @@ -106,6 +106,7 @@ struct nvme_subsystem { char *firmware; char *subsystype; char *application; + char *iopolicy; }; struct nvme_host { @@ -179,7 +180,7 @@ int json_dump_tree(nvme_root_t r); nvme_ctrl_t __nvme_lookup_ctrl(nvme_subsystem_t s, const char *transport, const char *traddr, const char *host_traddr, const char *host_iface, const char *trsvcid, - nvme_ctrl_t p); + const char *subsysnqn, nvme_ctrl_t p); #if (LOG_FUNCNAME == 1) #define __nvme_log_func __func__ @@ -197,6 +198,11 @@ __nvme_msg(nvme_root_t r, int lvl, const char *func, const char *format, ...); format, ##__VA_ARGS__); \ } while (0) +#define root_from_ctrl(c) ((c)->s && (c)->s->h ? (c)->s->h->r : NULL) +#define root_from_ns(n) ((n)->s && (n)->s->h ? (n)->s->h->r : \ + (n)->c && (n)->c->s && (n)->c->s->h ? (n)->c->s->h->r : \ + NULL) + /* mi internal headers */ /* internal transport API */ diff --git a/src/nvme/tree.c b/src/nvme/tree.c index a2ac069..00cf96f 100644 --- a/src/nvme/tree.c +++ b/src/nvme/tree.c @@ -15,6 +15,7 @@ #include #include #include +#include #include #include @@ -34,6 +35,31 @@ #include "log.h" #include "private.h" +/** + * struct candidate_args - Used to look for a controller matching these parameters + * @transport: Transport type: loop, fc, rdma, tcp + * @traddr: Transport address (destination address) + * @trsvcid: Transport service ID + * @subsysnqn: Subsystem NQN + * @host_traddr: Host transport address (source address) + * @host_iface: Host interface for connection (tcp only) + * @iface_list: Interface list (tcp only) + * @addreq: Address comparison function (for traddr, host-traddr) + * @well_known_nqn: Set to "true" when @subsysnqn is the well-known NQN + */ +struct candidate_args { + const char *transport; + const char *traddr; + const char *trsvcid; + const char *subsysnqn; + const char *host_traddr; + const char *host_iface; + struct ifaddrs *iface_list; + bool (*addreq)(const char *, const char *); + bool well_known_nqn; +}; +typedef bool (*ctrl_match_t)(struct nvme_ctrl *c, struct candidate_args *candidate); + const char *nvme_slots_sysfs_dir = "/sys/bus/pci/slots"; static struct nvme_host *default_host; @@ -172,6 +198,7 @@ nvme_root_t nvme_create_root(FILE *fp, int log_level) r->fp = fp; list_head_init(&r->hosts); list_head_init(&r->endpoints); + nvme_set_root(r); return r; } @@ -338,9 +365,18 @@ void nvme_free_tree(nvme_root_t r) free(r->config_file); if (r->application) free(r->application); + nvme_set_root(NULL); free(r); } +void nvme_root_release_fds(nvme_root_t r) +{ + struct nvme_host *h, *_h; + + nvme_for_each_host_safe(r, h, _h) + nvme_host_release_fds(h); +} + const char *nvme_subsystem_get_nqn(nvme_subsystem_t s) { return s->subsysnqn; @@ -374,6 +410,11 @@ void nvme_subsystem_set_application(nvme_subsystem_t s, const char *a) s->application = strdup(a); } +const char *nvme_subsystem_get_iopolicy(nvme_subsystem_t s) +{ + return s->iopolicy; +} + nvme_ctrl_t nvme_subsystem_first_ctrl(nvme_subsystem_t s) { return list_top(&s->ctrls, struct nvme_ctrl, entry); @@ -412,7 +453,7 @@ nvme_path_t nvme_namespace_next_path(nvme_ns_t ns, nvme_path_t p) static void __nvme_free_ns(struct nvme_ns *n) { list_del_init(&n->entry); - close(n->fd); + nvme_ns_release_fd(n); free(n->generic_name); free(n->name); free(n->sysfs_dir); @@ -451,9 +492,23 @@ static void __nvme_free_subsystem(struct nvme_subsystem *s) free(s->subsystype); if (s->application) free(s->application); + if (s->iopolicy) + free(s->iopolicy); free(s); } +void nvme_subsystem_release_fds(struct nvme_subsystem *s) +{ + struct nvme_ctrl *c, *_c; + struct nvme_ns *n, *_n; + + nvme_subsystem_for_each_ctrl_safe(s, c, _c) + nvme_ctrl_release_fd(c); + + nvme_subsystem_for_each_ns_safe(s, n, _n) + nvme_ns_release_fd(n); +} + /* * Stub for SWIG */ @@ -524,6 +579,14 @@ static void __nvme_free_host(struct nvme_host *h) free(h); } +void nvme_host_release_fds(struct nvme_host *h) +{ + struct nvme_subsystem *s, *_s; + + nvme_for_each_subsystem_safe(h, s, _s) + nvme_subsystem_release_fds(s); +} + /* Stub for SWIG */ void nvme_free_host(struct nvme_host *h) { @@ -610,10 +673,23 @@ static int nvme_init_subsystem(nvme_subsystem_t s, const char *name) s->sysfs_dir = (char *)path; if (s->h->r->application) s->application = strdup(s->h->r->application); + s->iopolicy = nvme_get_attr(path, "iopolicy"); return 0; } +static bool __nvme_scan_subsystem(struct nvme_root *r, nvme_subsystem_t s, + nvme_scan_filter_t f, void *f_args) +{ + if (f && !f(s, NULL, NULL, f_args)) { + nvme_msg(r, LOG_DEBUG, "filter out subsystem %s\n", s->name); + __nvme_free_subsystem(s); + return false; + } + nvme_subsystem_scan_namespaces(r, s, f, f_args); + return true; +} + static int nvme_scan_subsystem(struct nvme_root *r, const char *name, nvme_scan_filter_t f, void *f_args) { @@ -644,6 +720,10 @@ static int nvme_scan_subsystem(struct nvme_root *r, const char *name, continue; if (strcmp(_s->name, name)) continue; + if (!__nvme_scan_subsystem(r, _s, f, f_args)) { + errno = -EINVAL; + goto out_free; + } s = _s; } } @@ -658,28 +738,26 @@ static int nvme_scan_subsystem(struct nvme_root *r, const char *name, h = nvme_default_host(r); s = nvme_alloc_subsystem(h, name, subsysnqn); if (!s) { - errno = ENOMEM; + ret = -ENOMEM; + goto out_free; + } + if (!__nvme_scan_subsystem(r, s, f, f_args)) { + ret = -EINVAL; + goto out_free; } } else if (strcmp(s->subsysnqn, subsysnqn)) { - nvme_msg(r, LOG_WARNING, "NQN mismatch for subsystem '%s'\n", + nvme_msg(r, LOG_DEBUG, "NQN mismatch for subsystem '%s'\n", name); - s = NULL; - free(subsysnqn); - errno = EINVAL; - return -1; + ret = -EINVAL; } +out_free: free(subsysnqn); - if (!s) + + if (ret) { + errno = -ret; return -1; - - if (f && !f(s, NULL, NULL, f_args)) { - nvme_msg(r, LOG_DEBUG, "filter out subsystem %s\n", name); - __nvme_free_subsystem(s); - return 0; } - nvme_subsystem_scan_namespaces(r, s, f, f_args); - return 0; } @@ -787,18 +865,25 @@ free_path: int nvme_ctrl_get_fd(nvme_ctrl_t c) { - nvme_root_t r = c->s && c->s->h ? c->s->h->r : NULL; - if (c->fd < 0) { c->fd = nvme_open(c->name); if (c->fd < 0) - nvme_msg(r, LOG_ERR, + nvme_msg(root_from_ctrl(c), LOG_ERR, "Failed to open ctrl %s, errno %d\n", c->name, errno); } return c->fd; } +void nvme_ctrl_release_fd(nvme_ctrl_t c) +{ + if (c->fd < 0) + return; + + close(c->fd); + c->fd = -1; +} + nvme_subsystem_t nvme_ctrl_get_subsystem(nvme_ctrl_t c) { return c->s; @@ -824,6 +909,32 @@ const char *nvme_ctrl_get_address(nvme_ctrl_t c) return c->address ? c->address : ""; } +char *nvme_ctrl_get_src_addr(nvme_ctrl_t c, char *src_addr, size_t src_addr_len) +{ + size_t l; + char *p; + + if (!c->address) + return NULL; + + p = strstr(c->address, "src_addr="); + if (!p) + return NULL; + + p += strlen("src_addr="); + l = strcspn(p, ",%"); /* % to eliminate IPv6 scope (if present) */ + if (l >= src_addr_len) { + nvme_msg(root_from_ctrl(c), LOG_ERR, + "Buffer for src_addr is too small (%zu must be > %zu)\n", + src_addr_len, l); + return NULL; + } + + strncpy(src_addr, p, l); + src_addr[l] = '\0'; + return src_addr; +} + const char *nvme_ctrl_get_phy_slot(nvme_ctrl_t c) { return c->phy_slot ? c->phy_slot : ""; @@ -998,10 +1109,7 @@ nvme_path_t nvme_ctrl_next_path(nvme_ctrl_t c, nvme_path_t p) do { if (a) { free(a); (a) = NULL; } } while (0) void nvme_deconfigure_ctrl(nvme_ctrl_t c) { - if (c->fd >= 0) { - close(c->fd); - c->fd = -1; - } + nvme_ctrl_release_fd(c); FREE_CTRL_ATTR(c->name); FREE_CTRL_ATTR(c->sysfs_dir); FREE_CTRL_ATTR(c->firmware); @@ -1140,40 +1248,396 @@ struct nvme_ctrl *nvme_create_ctrl(nvme_root_t r, return c; } +/** + * _tcp_ctrl_match_host_traddr_no_src_addr() - Match host_traddr w/o src_addr + * @c: An existing controller instance + * @candidate: Candidate ctrl we're trying to match with @c. + * + * On kernels prior to 6.1 (i.e. src_addr is not available), try to match + * a candidate controller's host_traddr to that of an existing controller. + * + * This function takes an optimistic approach. In doubt, it will declare a + * match and return true. + * + * Return: true if @c->host_traddr matches @candidate->host_traddr. false otherwise. + */ +static bool _tcp_ctrl_match_host_traddr_no_src_addr(struct nvme_ctrl *c, struct candidate_args *candidate) +{ + if (c->cfg.host_traddr) + return candidate->addreq(candidate->host_traddr, c->cfg.host_traddr); + + /* If c->cfg.host_traddr is NULL, then the controller (c) + * uses the interface's primary address as the source + * address. If c->cfg.host_iface is defined we can + * determine the primary address associated with that + * interface and compare that to the candidate->host_traddr. + */ + if (c->cfg.host_iface) + return nvme_iface_primary_addr_matches(candidate->iface_list, + c->cfg.host_iface, + candidate->host_traddr); + + /* If both c->cfg.host_traddr and c->cfg.host_iface are + * NULL, we don't have enough information to make a + * 100% positive match. Regardless, let's be optimistic + * and assume that we have a match. + */ + nvme_msg(root_from_ctrl(c), LOG_DEBUG, + "Not enough data, but assume %s matches candidate's host_traddr: %s\n", + nvme_ctrl_get_name(c), candidate->host_traddr); + + return true; +} + +/** + * _tcp_ctrl_match_host_iface_no_src_addr() - Match host_iface w/o src_addr + * @c: An existing controller instance + * @candidate: Candidate ctrl we're trying to match with @c. + * + * On kernels prior to 6.1 (i.e. src_addr is not available), try to match + * a candidate controller's host_iface to that of an existing controller. + * + * This function takes an optimistic approach. In doubt, it will declare a + * match and return true. + * + * Return: true if @c->host_iface matches @candidate->host_iface. false otherwise. + */ +static bool _tcp_ctrl_match_host_iface_no_src_addr(struct nvme_ctrl *c, struct candidate_args *candidate) +{ + if (c->cfg.host_iface) + return streq0(candidate->host_iface, c->cfg.host_iface); + + /* If c->cfg.host_traddr is not NULL we can infer the controller's (c) + * interface from it and compare it to the candidate->host_iface. + */ + if (c->cfg.host_traddr) { + const char *c_host_iface; + + c_host_iface = nvme_iface_matching_addr(candidate->iface_list, c->cfg.host_traddr); + return streq0(candidate->host_iface, c_host_iface); + } + + /* If both c->cfg.host_traddr and c->cfg.host_iface are + * NULL, we don't have enough information to make a + * 100% positive match. Regardless, let's be optimistic + * and assume that we have a match. + */ + nvme_msg(root_from_ctrl(c), LOG_DEBUG, + "Not enough data, but assume %s matches candidate's host_iface: %s\n", + nvme_ctrl_get_name(c), candidate->host_iface); + + return true; +} + +/** + * _tcp_opt_params_match_no_src_addr() - Match optional host_traddr/host_iface w/o src_addr + * @c: An existing controller instance + * @candidate: Candidate ctrl we're trying to match with @c. + * + * Before kernel 6.1, the src_addr was not reported by the kernel which makes + * it hard to match a candidate's host_traddr and host_iface to an existing + * controller if that controller was created without specifying the + * host_traddr and/or host_iface. This function tries its best in the absense + * of a src_addr to match @c to @candidate. This may not be 100% accurate. + * Only the src_addr can provide 100% accuracy. + * + * This function takes an optimistic approach. In doubt, it will declare a + * match and return true. + * + * Return: true if @c matches @candidate. false otherwise. + */ +static bool _tcp_opt_params_match_no_src_addr(struct nvme_ctrl *c, struct candidate_args *candidate) +{ + /* Check host_traddr only if candidate is interested */ + if (candidate->host_traddr) { + if (!_tcp_ctrl_match_host_traddr_no_src_addr(c, candidate)) + return false; + } + + /* Check host_iface only if candidate is interested */ + if (candidate->host_iface) { + if (!_tcp_ctrl_match_host_iface_no_src_addr(c, candidate)) + return false; + } + + return true; +} + +/** + * _tcp_opt_params_match() - Match optional host_traddr/host_iface + * @c: An existing controller instance + * @candidate: Candidate ctrl we're trying to match with @c. + * + * The host_traddr and host_iface are optional for TCP. When they are not + * specified, the kernel looks up the destination IP address (traddr) in the + * routing table to determine the best interface for the connection. The + * kernel then retrieves the primary IP address assigned to that interface + * and uses that as the connection’s source address. + * + * An interface’s primary address is the default source address used for + * all connections made on that interface unless host-traddr is used to + * override the default. Kernel-selected interfaces and/or source addresses + * are hidden from user-space applications unless the kernel makes that + * information available through the "src_addr" attribute in the + * sysfs (kernel 6.1 or later). + * + * Sometimes, an application may force the interface by specifying the + * "host-iface" or may force a different source address (instead of the + * primary address) by providing the "host-traddr". + * + * If the candidate specifies the host_traddr and/or host_iface but they + * do not match the existing controller's host_traddr and/or host_iface + * (they could be NULL), we may still be able to find a match by taking + * the existing controller's src_addr into consideration since that + * parameter identifies the actual source address of the connection and + * therefore can be used to infer the interface of the connection. However, + * the src_addr can only be read from the nvme device's sysfs "address" + * attribute starting with kernel 6.1 (or kernels that backported the + * src_addr patch). + * + * For legacy kernels that do not provide the src_addr we must use a + * different algorithm to match the host_traddr and host_iface, but + * it's not 100% accurate. + * + * Return: true if @c matches @candidate. false otherwise. + */ +static bool _tcp_opt_params_match(struct nvme_ctrl *c, struct candidate_args *candidate) +{ + char *src_addr, buffer[INET6_ADDRSTRLEN]; + + /* Check if src_addr is available (kernel 6.1 or later) */ + src_addr = nvme_ctrl_get_src_addr(c, buffer, sizeof(buffer)); + if (!src_addr) + return _tcp_opt_params_match_no_src_addr(c, candidate); + + /* Check host_traddr only if candidate is interested */ + if (candidate->host_traddr && + !candidate->addreq(candidate->host_traddr, src_addr)) + return false; + + /* Check host_iface only if candidate is interested */ + if (candidate->host_iface && + !streq0(candidate->host_iface, + nvme_iface_matching_addr(candidate->iface_list, src_addr))) + return false; + + return true; +} + +/** + * _tcp_match_ctrl() - Check if controller matches candidate (TCP only) + * @c: An existing controller instance + * @candidate: Candidate ctrl we're trying to match with @c. + * + * We want to determine if an existing controller can be re-used + * for the candidate controller we're trying to instantiate. + * + * For TCP, we do not have a match if the candidate's transport, traddr, + * trsvcid are not identical to those of the the existing controller. + * These 3 parameters are mandatory for a match. + * + * The host_traddr and host_iface are optional. When the candidate does + * not specify them (both NULL), we can ignore them. Otherwise, we must + * employ advanced investigation techniques to determine if there's a match. + * + * Return: true if a match is found, false otherwise. + */ +static bool _tcp_match_ctrl(struct nvme_ctrl *c, struct candidate_args *candidate) +{ + if (!streq0(c->transport, candidate->transport)) + return false; + + if (!streq0(c->trsvcid, candidate->trsvcid)) + return false; + + if (!candidate->addreq(c->traddr, candidate->traddr)) + return false; + + if (candidate->well_known_nqn && !nvme_ctrl_is_discovery_ctrl(c)) + return false; + + if (candidate->subsysnqn && !streq0(c->subsysnqn, candidate->subsysnqn)) + return false; + + /* Check host_traddr / host_iface only if candidate is interested */ + if ((candidate->host_iface || candidate->host_traddr) && + !_tcp_opt_params_match(c, candidate)) + return false; + + return true; +} + +/** + * _match_ctrl() - Check if controller matches candidate (non TCP transport) + * @c: An existing controller instance + * @candidate: Candidate ctrl we're trying to match with @c. + * + * We want to determine if an existing controller can be re-used + * for the candidate controller we're trying to instantiate. This function + * is used for all transports except TCP. + * + * Return: true if a match is found, false otherwise. + */ +static bool _match_ctrl(struct nvme_ctrl *c, struct candidate_args *candidate) +{ + if (!streq0(c->transport, candidate->transport)) + return false; + + if (candidate->traddr && c->traddr && + !candidate->addreq(c->traddr, candidate->traddr)) + return false; + + if (candidate->host_traddr && c->cfg.host_traddr && + !candidate->addreq(c->cfg.host_traddr, candidate->host_traddr)) + return false; + + if (candidate->host_iface && c->cfg.host_iface && + !streq0(c->cfg.host_iface, candidate->host_iface)) + return false; + + if (candidate->trsvcid && c->trsvcid && + !streq0(c->trsvcid, candidate->trsvcid)) + return false; + + if (candidate->well_known_nqn && !nvme_ctrl_is_discovery_ctrl(c)) + return false; + + if (candidate->subsysnqn && !streq0(c->subsysnqn, candidate->subsysnqn)) + return false; + + return true; +} +/** + * _candidate_init() - Init candidate and get the matching function + * + * @candidate: Candidate struct to initialize + * @transport: Transport name + * @traddr: Transport address + * @trsvcid: Transport service identifier + * @subsysnqn: Subsystem NQN + * @host_traddr: Host transport address + * @host_iface: Host interface name + * @host_iface: Host interface name + * + * The function _candidate_free() must be called to release resources once + * the candidate object is not longer required. + * + * Return: The matching function to use when comparing an existing + * controller to the candidate controller. + */ +static ctrl_match_t _candidate_init(struct candidate_args *candidate, + const char *transport, + const char *traddr, + const char *trsvcid, + const char *subsysnqn, + const char *host_traddr, + const char *host_iface) +{ + memset(candidate, 0, sizeof(*candidate)); + + candidate->traddr = traddr; + candidate->trsvcid = trsvcid; + candidate->transport = transport; + candidate->subsysnqn = subsysnqn; + candidate->host_iface = host_iface; + candidate->host_traddr = host_traddr; + + if (streq0(subsysnqn, NVME_DISC_SUBSYS_NAME)) { + /* Since TP8013, the NQN of discovery controllers can be the + * well-known NQN (i.e. nqn.2014-08.org.nvmexpress.discovery) or + * a unique NQN. A DC created using the well-known NQN may later + * display a unique NQN when looked up in the sysfs. Therefore, + * ignore (i.e. set to NULL) the well-known NQN when looking for + * a match. + */ + candidate->subsysnqn = NULL; + candidate->well_known_nqn = true; + } + + if (streq0(transport, "tcp")) { + /* For TCP we may need to access the interface map. + * Let's retrieve and cache the map. + */ + if (getifaddrs(&candidate->iface_list) == -1) + candidate->iface_list = NULL; + + candidate->addreq = nvme_ipaddrs_eq; + return _tcp_match_ctrl; + } + + if (streq0(transport, "rdma")) { + candidate->addreq = nvme_ipaddrs_eq; + return _match_ctrl; + } + + /* All other transport types */ + candidate->addreq = streqcase0; + return _match_ctrl; +} + +/** + * _candidate_free() - Release resources allocated by _candidate_init() + * + * @candidate: data to free. + */ +static void _candidate_free(struct candidate_args *candidate) +{ + freeifaddrs(candidate->iface_list); /* This is NULL-safe */ +} + nvme_ctrl_t __nvme_lookup_ctrl(nvme_subsystem_t s, const char *transport, const char *traddr, const char *host_traddr, const char *host_iface, const char *trsvcid, - nvme_ctrl_t p) - + const char *subsysnqn, nvme_ctrl_t p) { - struct nvme_ctrl *c; - bool (*addreq)(const char *, const char *); + struct nvme_ctrl *c, *matching_c = NULL; + struct candidate_args candidate; + ctrl_match_t ctrl_match; - if (!strcmp(transport, "tcp") || !strcmp(transport, "rdma")) - addreq = nvme_ipaddrs_eq; /* IP address compare for TCP/RDMA */ - else - addreq = streqcase0; /* Case-insensitive for FC (n/a for loop) */ + /* Init candidate and get the matching function to use */ + ctrl_match = _candidate_init(&candidate, transport, traddr, trsvcid, + subsysnqn, host_traddr, host_iface); c = p ? nvme_subsystem_next_ctrl(s, p) : nvme_subsystem_first_ctrl(s); for (; c != NULL; c = nvme_subsystem_next_ctrl(s, c)) { - if (!streq0(c->transport, transport)) - continue; - if (traddr && c->traddr && - !addreq(c->traddr, traddr)) - continue; - if (host_traddr && c->cfg.host_traddr && - !addreq(c->cfg.host_traddr, host_traddr)) - continue; - if (host_iface && c->cfg.host_iface && - !streq0(c->cfg.host_iface, host_iface)) - continue; - if (trsvcid && c->trsvcid && - !streq0(c->trsvcid, trsvcid)) - continue; - return c; + if (ctrl_match(c, &candidate)) { + matching_c = c; + break; + } } - return NULL; + _candidate_free(&candidate); + + return matching_c; +} + +bool nvme_ctrl_config_match(struct nvme_ctrl *c, const char *transport, + const char *traddr, const char *trsvcid, + const char *subsysnqn, const char *host_traddr, + const char *host_iface) +{ + bool match; + ctrl_match_t ctrl_match; + struct candidate_args candidate; + + /* Init candidate and get the matching function to use */ + ctrl_match = _candidate_init(&candidate, transport, traddr, trsvcid, + subsysnqn, host_traddr, host_iface); + + match = ctrl_match(c, &candidate); + + _candidate_free(&candidate); + + return match; +} + +nvme_ctrl_t nvme_ctrl_find(nvme_subsystem_t s, const char *transport, + const char *traddr, const char *trsvcid, + const char *subsysnqn, const char *host_traddr, + const char *host_iface) +{ + return __nvme_lookup_ctrl(s, transport, traddr, host_traddr, host_iface, + trsvcid, subsysnqn, NULL/*p*/); } nvme_ctrl_t nvme_lookup_ctrl(nvme_subsystem_t s, const char *transport, @@ -1188,7 +1652,7 @@ nvme_ctrl_t nvme_lookup_ctrl(nvme_subsystem_t s, const char *transport, return NULL; c = __nvme_lookup_ctrl(s, transport, traddr, host_traddr, - host_iface, trsvcid, p); + host_iface, trsvcid, NULL, p); if (c) return c; @@ -1289,9 +1753,12 @@ static char *nvme_ctrl_lookup_phy_slot(nvme_root_t r, const char *address) if (entry->d_type == DT_DIR && strncmp(entry->d_name, ".", 1) != 0 && strncmp(entry->d_name, "..", 2) != 0) { - ret = asprintf(&path, "/sys/bus/pci/slots/%s", entry->d_name); + ret = asprintf(&path, "%s/%s", + nvme_slots_sysfs_dir, entry->d_name); if (ret < 0) { errno = ENOMEM; + free(target_addr); + closedir(slots_dir); return NULL; } addr = nvme_get_attr(path, "address"); @@ -1306,6 +1773,7 @@ static char *nvme_ctrl_lookup_phy_slot(nvme_root_t r, const char *address) } } free(target_addr); + closedir(slots_dir); if (found) return strdup(entry->d_name); return NULL; @@ -1622,9 +2090,26 @@ static int nvme_bytes_to_lba(nvme_ns_t n, off_t offset, size_t count, int nvme_ns_get_fd(nvme_ns_t n) { + if (n->fd < 0) { + n->fd = nvme_open(n->name); + if (n->fd < 0) + nvme_msg(root_from_ns(n), LOG_ERR, + "Failed to open ns %s, errno %d\n", + n->name, errno); + } + return n->fd; } +void nvme_ns_release_fd(nvme_ns_t n) +{ + if (n->fd < 0) + return; + + close(n->fd); + n->fd = -1; +} + nvme_subsystem_t nvme_ns_get_subsystem(nvme_ns_t n) { return n->s; @@ -1959,6 +2444,7 @@ static void nvme_ns_set_generic_name(struct nvme_ns *n, const char *name) static nvme_ns_t nvme_ns_open(const char *name) { struct nvme_ns *n; + int fd; n = calloc(1, sizeof(*n)); if (!n) { @@ -1966,27 +2452,29 @@ static nvme_ns_t nvme_ns_open(const char *name) return NULL; } + n->fd = -1; n->name = strdup(name); - n->fd = nvme_open(n->name); - if (n->fd < 0) + + fd = nvme_ns_get_fd(n); + if (fd < 0) goto free_ns; nvme_ns_set_generic_name(n, name); - if (nvme_get_nsid(n->fd, &n->nsid) < 0) - goto close_fd; + if (nvme_get_nsid(fd, &n->nsid) < 0) + goto free_ns; if (nvme_ns_init(n) != 0) - goto close_fd; + goto free_ns; list_head_init(&n->paths); list_node_init(&n->entry); + nvme_ns_release_fd(n); /* Do not leak fds */ return n; -close_fd: - close(n->fd); free_ns: + nvme_ns_release_fd(n); free(n->generic_name); free(n->name); free(n); diff --git a/src/nvme/tree.h b/src/nvme/tree.h index bcf3636..a30e8eb 100644 --- a/src/nvme/tree.h +++ b/src/nvme/tree.h @@ -15,6 +15,7 @@ #include #include +#include #include "ioctl.h" #include "util.h" @@ -61,6 +62,17 @@ void nvme_root_set_application(nvme_root_t r, const char *a); */ const char *nvme_root_get_application(nvme_root_t r); +/** + * nvme_root_release_fds - Close all opened file descriptors in the tree + * @r: &nvme_root_t object + * + * Controller and Namespace objects cache the file descriptors + * of opened nvme devices. This API can be used to close and + * clear all cached fds in the tree. + * + */ +void nvme_root_release_fds(nvme_root_t r); + /** * nvme_free_tree() - Free root object * @r: &nvme_root_t object @@ -295,6 +307,51 @@ nvme_ctrl_t nvme_lookup_ctrl(nvme_subsystem_t s, const char *transport, const char *host_iface, const char *trsvcid, nvme_ctrl_t p); +/** + * nvme_ctrl_find() - Locate an existing controller + * @s: &nvme_subsystem_t object + * @transport: Transport name + * @traddr: Transport address + * @trsvcid: Transport service identifier + * @subsysnqn: Subsystem NQN + * @host_traddr: Host transport address + * @host_iface: Host interface name + * + * Lookup a controller in @s based on @transport, @traddr, @trsvcid, + * @subsysnqn, @host_traddr, and @host_iface. @transport must be specified, + * other fields may be required depending on the transport. Parameters set + * to NULL will be ignored. + * + * Unlike nvme_lookup_ctrl(), this function does not create a new object if + * an existing controller cannot be found. + * + * Return: Controller instance on success, NULL otherwise. + */ +nvme_ctrl_t nvme_ctrl_find(nvme_subsystem_t s, const char *transport, + const char *traddr, const char *trsvcid, + const char *subsysnqn, const char *host_traddr, + const char *host_iface); + +/** + * nvme_ctrl_config_match() - Check if ctrl @c matches config params + * @c: An existing controller instance + * @transport: Transport name + * @traddr: Transport address + * @trsvcid: Transport service identifier + * @subsysnqn: Subsystem NQN + * @host_traddr: Host transport address + * @host_iface: Host interface name + * + * Check that controller @c matches parameters: @transport, @traddr, + * @trsvcid, @subsysnqn, @host_traddr, and @host_iface. Parameters set + * to NULL will be ignored. + * + * Return: true if there's a match, false otherwise. + */ +bool nvme_ctrl_config_match(struct nvme_ctrl *c, const char *transport, + const char *traddr, const char *trsvcid, + const char *subsysnqn, const char *host_traddr, + const char *host_iface); /** * nvme_create_ctrl() - Allocate an unconnected NVMe controller @@ -484,10 +541,24 @@ nvme_ns_t nvme_subsystem_next_ns(nvme_subsystem_t s, nvme_ns_t n); * nvme_ns_get_fd() - Get associated file descriptor * @n: Namespace instance * + * libnvme will open() the file (if not already opened) and keep + * an internal copy of the file descriptor. Following calls to + * this API retrieve the internal cached copy of the file + * descriptor. The file will remain opened and the fd will + * remain cached until the ns object is deleted or + * nvme_ns_release_fd() is called. + * * Return: File descriptor associated with @n or -1 */ int nvme_ns_get_fd(nvme_ns_t n); +/** + * nvme_ns_release_fd() - Close fd and clear fd from ns object + * @n: Namespace instance + * + */ +void nvme_ns_release_fd(nvme_ns_t n); + /** * nvme_ns_get_nsid() - NSID of a namespace * @n: Namespace instance @@ -772,10 +843,24 @@ nvme_ns_t nvme_path_get_ns(nvme_path_t p); * nvme_ctrl_get_fd() - Get associated file descriptor * @c: Controller instance * + * libnvme will open() the file (if not already opened) and keep + * an internal copy of the file descriptor. Following calls to + * this API retrieve the internal cached copy of the file + * descriptor. The file will remain opened and the fd will + * remain cached until the controller object is deleted or + * nvme_ctrl_release_fd() is called. + * * Return: File descriptor associated with @c or -1 */ int nvme_ctrl_get_fd(nvme_ctrl_t c); +/** + * nvme_ctrl_release_fd() - Close fd and clear fd from controller object + * @c: Controller instance + * + */ +void nvme_ctrl_release_fd(nvme_ctrl_t c); + /** * nvme_ctrl_get_name() - sysfs name of a controller * @c: Controller instance @@ -801,6 +886,16 @@ const char *nvme_ctrl_get_sysfs_dir(nvme_ctrl_t c); */ const char *nvme_ctrl_get_address(nvme_ctrl_t c); +/** + * nvme_ctrl_get_src_addr() - Extract src_addr from the c->address string + * @c: Controller instance + * @src_addr: Where to copy the src_addr. Size must be at least INET6_ADDRSTRLEN. + * @src_addr_len: Length of the buffer @src_addr. + * + * Return: Pointer to @src_addr on success. NULL on failure to extract the src_addr. + */ +char *nvme_ctrl_get_src_addr(nvme_ctrl_t c, char *src_addr, size_t src_addr_len); + /** * nvme_ctrl_get_phy_slot() - PCI physical slot number of a controller * @c: Controller instance @@ -827,7 +922,7 @@ const char *nvme_ctrl_get_firmware(nvme_ctrl_t c); const char *nvme_ctrl_get_model(nvme_ctrl_t c); /** - * nvme_ctrl_get_state() - Running state of an controller + * nvme_ctrl_get_state() - Running state of a controller * @c: Controller instance * * Return: String indicating the running state of @c @@ -1147,6 +1242,14 @@ const char *nvme_subsystem_get_application(nvme_subsystem_t s); */ void nvme_subsystem_set_application(nvme_subsystem_t s, const char *a); +/** + * nvme_subsystem_get_iopolicy() - Return the IO policy of subsytem + * @s: nvme_subsystem_t object + * + * Return: IO policy used by current subsystem + */ +const char *nvme_subsystem_get_iopolicy(nvme_subsystem_t s); + /** * nvme_scan_topology() - Scan NVMe topology and apply filter * @r: nvme_root_t object @@ -1176,6 +1279,16 @@ const char *nvme_host_get_hostnqn(nvme_host_t h); */ const char *nvme_host_get_hostid(nvme_host_t h); +/** + * nvme_host_release_fds() - Close all opened file descriptors under host + * @h: nvme_host_t object + * + * Controller and Namespace objects cache the file descriptors + * of opened nvme devices. This API can be used to close and + * clear all cached fds under this host. + */ +void nvme_host_release_fds(struct nvme_host *h); + /** * nvme_free_host() - Free nvme_host_t object * @h: nvme_host_t object @@ -1292,6 +1405,18 @@ char *nvme_get_ns_attr(nvme_ns_t n, const char *attr); nvme_ns_t nvme_subsystem_lookup_namespace(struct nvme_subsystem *s, __u32 nsid); +/** + * nvme_subsystem_release_fds() - Close all opened fds under subsystem + * @s: nvme_subsystem_t object + * + * Controller and Namespace objects cache the file descriptors + * of opened nvme devices. This API can be used to close and + * clear all cached fds under this subsystem. + * + */ +void nvme_subsystem_release_fds(struct nvme_subsystem *s); + + /** * nvme_get_path_attr() - Read path sysfs attribute * @p: nvme_path_t object diff --git a/src/nvme/types.h b/src/nvme/types.h index 3bf2237..ac6d781 100644 --- a/src/nvme/types.h +++ b/src/nvme/types.h @@ -611,6 +611,19 @@ static const __u64 NVME_PMRMSC_CBA_MASK = 0xfffffffffffffull; #define NVME_PMRMSC_CMSE(pmrmsc) NVME_GET(pmrmsc, PMRMSC_CMSE) #define NVME_PMRMSC_CBA(pmrmsc) NVME_GET(pmrmsc, PMRMSC_CBA) +enum nvme_flbas { + NVME_FLBAS_LOWER_SHIFT = 0, + NVME_FLBAS_META_EXT_SHIFT = 4, + NVME_FLBAS_HIGHER_SHIFT = 5, + NVME_FLBAS_LOWER_MASK = 0xf, + NVME_FLBAS_META_EXT_MASK = 0x1, + NVME_FLBAS_HIGHER_MASK = 0x3, +}; + +#define NVME_FLBAS_LOWER(flbas) NVME_GET(flbas, FLBAS_LOWER) +#define NVME_FLBAS_META_EXT(flbas) NVME_GET(flbas, FLBAS_META_EXT) +#define NVME_FLBAS_HIGHER(flbas) NVME_GET(flbas, FLBAS_HIGHER) + /** * enum nvme_psd_flags - Possible flag values in nvme power state descriptor * @NVME_PSD_FLAGS_MXPS: Indicates the scale for the Maximum Power @@ -930,7 +943,10 @@ struct nvme_id_psd { * @maxcna: Maximum I/O Controller Namespace Attachments indicates the * maximum number of namespaces that are allowed to be attached to * this I/O controller. - * @rsvd564: Reserved + * @oaqd: Optimal Aggregated Queue Depth indicates the recommended maximum + * total number of outstanding I/O commands across all I/O queues + * on the controller for optimal operation. + * @rsvd568: Reserved * @subnqn: NVM Subsystem NVMe Qualified Name, UTF-8 null terminated string * @rsvd1024: Reserved * @ioccsz: I/O Queue Command Capsule Supported Size, defines the maximum @@ -1035,7 +1051,8 @@ struct nvme_id_ctrl { __le32 mnan; __u8 maxdna[16]; __le32 maxcna; - __u8 rsvd564[204]; + __le32 oaqd; + __u8 rsvd568[200]; char subnqn[NVME_NQN_LENGTH]; __u8 rsvd1024[768]; @@ -3075,11 +3092,13 @@ struct nvme_telemetry_log { /** * struct nvme_endurance_group_log - Endurance Group Information Log * @critical_warning: Critical Warning - * @rsvd1: Reserved + * @endurance_group_features: Endurance Group Features + * @rsvd2: Reserved * @avl_spare: Available Spare * @avl_spare_threshold: Available Spare Threshold * @percent_used: Percentage Used - * @rsvd6: Reserved + * @domain_identifier: Domain Identifier + * @rsvd8: Reserved * @endurance_estimate: Endurance Estimate * @data_units_read: Data Units Read * @data_units_written: Data Units Written @@ -3088,15 +3107,19 @@ struct nvme_telemetry_log { * @host_write_cmds: Host Write Commands * @media_data_integrity_err: Media and Data Integrity Errors * @num_err_info_log_entries: Number of Error Information Log Entries - * @rsvd160: Reserved + * @total_end_grp_cap: Total Endurance Group Capacity + * @unalloc_end_grp_cap: Unallocated Endurance Group Capacity + * @rsvd192: Reserved */ struct nvme_endurance_group_log { __u8 critical_warning; - __u8 rsvd1[2]; + __u8 endurance_group_features; + __u8 rsvd2; __u8 avl_spare; __u8 avl_spare_threshold; __u8 percent_used; - __u8 rsvd6[26]; + __le16 domain_identifier; + __u8 rsvd8[24]; __u8 endurance_estimate[16]; __u8 data_units_read[16]; __u8 data_units_written[16]; @@ -3105,7 +3128,9 @@ struct nvme_endurance_group_log { __u8 host_write_cmds[16]; __u8 media_data_integrity_err[16]; __u8 num_err_info_log_entries[16]; - __u8 rsvd160[352]; + __u8 total_end_grp_cap[16]; + __u8 unalloc_end_grp_cap[16]; + __u8 rsvd192[320]; }; /** @@ -3709,6 +3734,110 @@ struct nvme_boot_partition { __u8 boot_partition_data[]; }; +/** + * struct nvme_eom_lane_desc - EOM Lane Descriptor + * @rsvd0: Reserved + * @mstatus: Measurement Status + * @lane: Lane number + * @eye: Eye number + * @top: Absolute number of rows from center to top edge of eye + * @bottom: Absolute number of rows from center to bottom edge of eye + * @left: Absolute number of rows from center to left edge of eye + * @right: Absolute number of rows from center to right edge of eye + * @nrows: Number of Rows + * @ncols: Number of Columns + * @edlen: Eye Data Length + * @rsvd18: Reserved + * @eye_desc: Printable Eye, Eye Data, and any Padding + */ +struct nvme_eom_lane_desc { + __u8 rsvd0; + __u8 mstatus; + __u8 lane; + __u8 eye; + __le16 top; + __le16 bottom; + __le16 left; + __le16 right; + __le16 nrows; + __le16 ncols; + __le16 edlen; + __u8 rsvd18[14]; + __u8 eye_desc[]; +}; + +/** + * struct nvme_phy_rx_eom_log - Physical Interface Receiver Eye Opening Measurement Log + * @lid: Log Identifier + * @eomip: EOM In Progress + * @hsize: Header Size + * @rsize: Result Size + * @eomdgn: EOM Data Generation Number + * @lr: Log Revision + * @odp: Optional Data Present + * @lanes: Number of lanes configured for this port + * @epl: Eyes Per Lane + * @lspfc: Log Specific Parameter Field Copy + * @li: Link Information + * @rsvd15: Reserved + * @lsic: Log Specific Identifier Copy + * @dsize: Descriptor Size + * @nd: Number of Descriptors + * @maxtb: Maximum Top Bottom + * @maxlr: Maximum Left Right + * @etgood: Estimated Time for Good Quality + * @etbetter: Estimated Time for Better Quality + * @etbest: Estimated Time for Best Quality + * @rsvd36: Reserved + * @descs: EOM Lane Descriptors + */ +struct nvme_phy_rx_eom_log { + __u8 lid; + __u8 eomip; + __le16 hsize; + __le32 rsize; + __u8 eomdgn; + __u8 lr; + __u8 odp; + __u8 lanes; + __u8 epl; + __u8 lspfc; + __u8 li; + __u8 rsvd15[3]; + __le16 lsic; + __le32 dsize; + __le16 nd; + __le16 maxtb; + __le16 maxlr; + __le16 etgood; + __le16 etbetter; + __le16 etbest; + __u8 rsvd36[28]; + struct nvme_eom_lane_desc descs[]; +}; + +/** + * enum nvme_eom_optional_data - EOM Optional Data Present Fields + * @NVME_EOM_EYE_DATA_PRESENT: Eye Data Present + * @NVME_EOM_PRINTABLE_EYE_PRESENT: Printable Eye Present + */ +enum nvme_eom_optional_data { + NVME_EOM_EYE_DATA_PRESENT = 1, + NVME_EOM_PRINTABLE_EYE_PRESENT = 1 << 1, +}; + +/** + * enum nvme_phy_rx_eom_progress - EOM In Progress Values + * @NVME_PHY_RX_EOM_NOT_STARTED: EOM Not Started + * @NVME_PHY_RX_EOM_IN_PROGRESS: EOM In Progress + * @NVME_PHY_RX_EOM_COMPLETED: EOM Completed + */ +enum nvme_phy_rx_eom_progress { + NVME_PHY_RX_EOM_NOT_STARTED = 0, + NVME_PHY_RX_EOM_IN_PROGRESS = 1, + NVME_PHY_RX_EOM_COMPLETED = 2, +}; + /** * struct nvme_media_unit_stat_desc - Media Unit Status Descriptor * @muid: Media Unit Identifier @@ -6501,7 +6630,7 @@ static inline __u32 nvme_status_get_type(int status) */ static inline __u32 nvme_status_get_value(int status) { - return status & ~(NVME_STATUS_TYPE_MASK << NVME_STATUS_TYPE_SHIFT); + return status & ~NVME_SET(NVME_STATUS_TYPE_MASK, STATUS_TYPE); } /** @@ -6688,6 +6817,7 @@ enum nvme_identify_cns { * @NVME_LOG_LID_FID_SUPPORTED_EFFECTS: Feature Identifiers Supported and Effects * @NVME_LOG_LID_MI_CMD_SUPPORTED_EFFECTS: NVMe-MI Commands Supported and Effects * @NVME_LOG_LID_BOOT_PARTITION: Boot Partition + * @NVME_LOG_LID_PHY_RX_EOM: Physical Interface Receiver Eye Opening Measurement * @NVME_LOG_LID_FDP_CONFIGS: FDP Configurations * @NVME_LOG_LID_FDP_RUH_USAGE: Reclaim Unit Handle Usage * @NVME_LOG_LID_FDP_STATS: FDP Statistics @@ -6719,6 +6849,7 @@ enum nvme_cmd_get_log_lid { NVME_LOG_LID_FID_SUPPORTED_EFFECTS = 0x12, NVME_LOG_LID_MI_CMD_SUPPORTED_EFFECTS = 0x13, NVME_LOG_LID_BOOT_PARTITION = 0x15, + NVME_LOG_LID_PHY_RX_EOM = 0x19, NVME_LOG_LID_FDP_CONFIGS = 0x20, NVME_LOG_LID_FDP_RUH_USAGE = 0x21, NVME_LOG_LID_FDP_STATS = 0x22, @@ -7012,7 +7143,7 @@ enum nvme_feat { NVME_FEAT_WP_WPS_SHIFT = 0, NVME_FEAT_WP_WPS_MASK = 0x7, NVME_FEAT_IOCSP_IOCSCI_SHIFT = 0, - NVME_FEAT_IOCSP_IOCSCI_MASK = 0xff, + NVME_FEAT_IOCSP_IOCSCI_MASK = 0x1ff, NVME_FEAT_FDP_ENABLED_SHIFT = 0, NVME_FEAT_FDP_ENABLED_MASK = 0x1, NVME_FEAT_FDP_INDEX_SHIFT = 8, @@ -7272,6 +7403,30 @@ enum nvme_log_ana_lsp { NVME_LOG_ANA_LSP_RGO_GROUPS_ONLY = 1, }; +/** + * enum nvme_log_phy_rx_eom_action - Physical Interface Receiver Eye Opening Measurement Action + * @NVME_LOG_PHY_RX_EOM_READ: Read Log Data + * @NVME_LOG_PHY_RX_EOM_START_READ: Start Measurement and Read Log Data + * @NVME_LOG_PHY_RX_EOM_ABORT_CLEAR: Abort Measurement and Clear Log Data + */ +enum nvme_log_phy_rx_eom_action { + NVME_LOG_PHY_RX_EOM_READ = 0, + NVME_LOG_PHY_RX_EOM_START_READ = 1, + NVME_LOG_PHY_RX_EOM_ABORT_CLEAR = 2, +}; + +/** + * enum nvme_log_phy_rx_eom_quality - Physical Interface Receiver Eye Opening Measurement Quality + * @NVME_LOG_PHY_RX_EOM_GOOD: <= Better Quality + * @NVME_LOG_PHY_RX_EOM_BETTER: <= Best Quality, >= Good Quality + * @NVME_LOG_PHY_RX_EOM_BEST: >= Better Quality + */ +enum nvme_log_phy_rx_eom_quality { + NVME_LOG_PHY_RX_EOM_GOOD = 0, + NVME_LOG_PHY_RX_EOM_BETTER = 1, + NVME_LOG_PHY_RX_EOM_BEST = 2, +}; + /** * enum nvme_pevent_log_action - Persistent Event Log - Action * @NVME_PEVENT_LOG_READ: Read Log Data diff --git a/src/nvme/util.c b/src/nvme/util.c index 143cc31..8fe094d 100644 --- a/src/nvme/util.c +++ b/src/nvme/util.c @@ -906,6 +906,46 @@ int nvme_uuid_random(unsigned char uuid[NVME_UUID_LEN]) } #ifdef HAVE_NETDB +static bool _nvme_ipaddrs_eq(struct sockaddr *addr1, struct sockaddr *addr2) +{ + struct sockaddr_in *sockaddr_v4; + struct sockaddr_in6 *sockaddr_v6; + + if (addr1->sa_family == AF_INET && addr2->sa_family == AF_INET) { + struct sockaddr_in *sockaddr1 = (struct sockaddr_in *)addr1; + struct sockaddr_in *sockaddr2 = (struct sockaddr_in *)addr2; + return sockaddr1->sin_addr.s_addr == sockaddr2->sin_addr.s_addr; + } + + if (addr1->sa_family == AF_INET6 && addr2->sa_family == AF_INET6) { + struct sockaddr_in6 *sockaddr1 = (struct sockaddr_in6 *)addr1; + struct sockaddr_in6 *sockaddr2 = (struct sockaddr_in6 *)addr2; + return !memcmp(&sockaddr1->sin6_addr, &sockaddr2->sin6_addr, sizeof(struct in6_addr)); + } + + switch (addr1->sa_family) { + case AF_INET: + sockaddr_v6 = (struct sockaddr_in6 *)addr2; + if (IN6_IS_ADDR_V4MAPPED(&sockaddr_v6->sin6_addr)) { + sockaddr_v4 = (struct sockaddr_in *)addr1; + return sockaddr_v4->sin_addr.s_addr == sockaddr_v6->sin6_addr.s6_addr32[3]; + } + break; + + case AF_INET6: + sockaddr_v6 = (struct sockaddr_in6 *)addr1; + if (IN6_IS_ADDR_V4MAPPED(&sockaddr_v6->sin6_addr)) { + sockaddr_v4 = (struct sockaddr_in *)addr2; + return sockaddr_v4->sin_addr.s_addr == sockaddr_v6->sin6_addr.s6_addr32[3]; + } + break; + + default: ; + } + + return false; +} + bool nvme_ipaddrs_eq(const char *addr1, const char *addr2) { bool result = false; @@ -924,37 +964,7 @@ bool nvme_ipaddrs_eq(const char *addr1, const char *addr2) if (getaddrinfo(addr2, 0, &hint2, &info2) || !info2) goto ipaddrs_eq_fail; - if (info1->ai_family == AF_INET && info2->ai_family == AF_INET) { - struct sockaddr_in *sockaddr1 = (struct sockaddr_in *)(info1->ai_addr); - struct sockaddr_in *sockaddr2 = (struct sockaddr_in *)(info2->ai_addr); - result = sockaddr1->sin_addr.s_addr == sockaddr2->sin_addr.s_addr; - } else if (info1->ai_family == AF_INET6 && info2->ai_family == AF_INET6) { - struct sockaddr_in6 *sockaddr1 = (struct sockaddr_in6 *)(info1->ai_addr); - struct sockaddr_in6 *sockaddr2 = (struct sockaddr_in6 *)(info2->ai_addr); - result = !memcmp(&sockaddr1->sin6_addr, &sockaddr2->sin6_addr, sizeof(struct in6_addr)); - } else { - struct sockaddr_in *sockaddr_v4; - struct sockaddr_in6 *sockaddr_v6; - switch (info1->ai_family) { - case AF_INET: - sockaddr_v6 = (struct sockaddr_in6 *)(info2->ai_addr); - if (IN6_IS_ADDR_V4MAPPED(&sockaddr_v6->sin6_addr)) { - sockaddr_v4 = (struct sockaddr_in *)(info1->ai_addr); - result = sockaddr_v4->sin_addr.s_addr == sockaddr_v6->sin6_addr.s6_addr32[3]; - } - break; - - case AF_INET6: - sockaddr_v6 = (struct sockaddr_in6 *)(info1->ai_addr); - if (IN6_IS_ADDR_V4MAPPED(&sockaddr_v6->sin6_addr)) { - sockaddr_v4 = (struct sockaddr_in *)(info2->ai_addr); - result = sockaddr_v4->sin_addr.s_addr == sockaddr_v6->sin6_addr.s6_addr32[3]; - } - break; - - default: ; - } - } + result = _nvme_ipaddrs_eq(info1->ai_addr, info2->ai_addr); ipaddrs_eq_fail: if (info1) @@ -972,3 +982,79 @@ bool nvme_ipaddrs_eq(const char *addr1, const char *addr2) return false; } #endif /* HAVE_NETDB */ + +#ifdef HAVE_NETDB +const char *nvme_iface_matching_addr(const struct ifaddrs *iface_list, const char *addr) +{ + const struct ifaddrs *iface_it; + struct addrinfo *info = NULL, hint = { .ai_flags = AI_NUMERICHOST, .ai_family = AF_UNSPEC }; + const char *iface_name = NULL; + + if (!iface_list || !addr || getaddrinfo(addr, 0, &hint, &info) || !info) + return NULL; + + /* Walk through the linked list */ + for (iface_it = iface_list; iface_it != NULL; iface_it = iface_it->ifa_next) { + struct sockaddr *ifaddr = iface_it->ifa_addr; + + if (ifaddr && (ifaddr->sa_family == AF_INET || ifaddr->sa_family == AF_INET6) && + _nvme_ipaddrs_eq(info->ai_addr, ifaddr)) { + iface_name = iface_it->ifa_name; + break; + } + } + + freeaddrinfo(info); + + return iface_name; +} + +bool nvme_iface_primary_addr_matches(const struct ifaddrs *iface_list, const char *iface, const char *addr) +{ + const struct ifaddrs *iface_it; + struct addrinfo *info = NULL, hint = { .ai_flags = AI_NUMERICHOST, .ai_family = AF_UNSPEC }; + bool match_found = false; + + if (!iface_list || !addr || getaddrinfo(addr, 0, &hint, &info) || !info) + return false; + + /* Walk through the linked list */ + for (iface_it = iface_list; iface_it != NULL; iface_it = iface_it->ifa_next) { + if (strcmp(iface, iface_it->ifa_name)) + continue; /* Not the interface we're looking for*/ + + /* The interface list is ordered in a way that the primary + * address is listed first. As soon as the parsed address + * matches the family of the address we're looking for, we + * have found the primary address for that family. + */ + if (iface_it->ifa_addr && (iface_it->ifa_addr->sa_family == info->ai_addr->sa_family)) { + match_found = _nvme_ipaddrs_eq(info->ai_addr, iface_it->ifa_addr); + break; + } + } + + freeaddrinfo(info); + + return match_found; +} + +#else /* HAVE_NETDB */ + +const char *nvme_iface_matching_addr(const struct ifaddrs *iface_list, const char *addr) +{ + nvme_msg(NULL, LOG_ERR, "no support for interface lookup; " + "recompile with libnss support.\n"); + + return NULL; +} + +bool nvme_iface_primary_addr_matches(const struct ifaddrs *iface_list, const char *iface, const char *addr) +{ + nvme_msg(NULL, LOG_ERR, "no support for interface lookup; " + "recompile with libnss support.\n"); + + return false; +} + +#endif /* HAVE_NETDB */ diff --git a/src/nvme/util.h b/src/nvme/util.h index 9d6faf3..efdf975 100644 --- a/src/nvme/util.h +++ b/src/nvme/util.h @@ -9,6 +9,8 @@ #ifndef _LIBNVME_UTIL_H #define _LIBNVME_UTIL_H +#include + #include "types.h" /** @@ -447,8 +449,8 @@ static inline void nvme_feature_decode_namespace_write_protect(__u32 value, static inline void nvme_id_ns_flbas_to_lbaf_inuse(__u8 flbas, __u8 *lbaf_inuse) { - *lbaf_inuse = (((flbas & NVME_NS_FLBAS_HIGHER_MASK) >> 1) | - (flbas & NVME_NS_FLBAS_LOWER_MASK)); + *lbaf_inuse = ((NVME_FLBAS_HIGHER(flbas) >> 1) | + NVME_FLBAS_LOWER(flbas)); } struct nvme_root; @@ -639,4 +641,31 @@ int nvme_uuid_random(unsigned char uuid[NVME_UUID_LEN]); */ bool nvme_ipaddrs_eq(const char *addr1, const char *addr2); +/** + * nvme_iface_matching_addr - Get interface matching @addr + * @iface_list: Interface list returned by getifaddrs() + * @addr: Address to match + * + * Parse the interface list pointed to by @iface_list looking + * for the interface that has @addr as one of its assigned + * addresses. + * + * Return: The name of the interface that owns @addr or NULL. + */ +const char *nvme_iface_matching_addr(const struct ifaddrs *iface_list, const char *addr); + +/** + * nvme_iface_primary_addr_matches - Check that interface's primary address matches + * @iface_list: Interface list returned by getifaddrs() + * @iface: Interface to match + * @addr: Address to match + * + * Parse the interface list pointed to by @iface_list and looking for + * interface @iface. The get its primary address and check if it matches + * @addr. + * + * Return: true if a match is found, false otherwise. + */ +bool nvme_iface_primary_addr_matches(const struct ifaddrs *iface_list, const char *iface, const char *addr); + #endif /* _LIBNVME_UTIL_H */ diff --git a/test/ioctl/discovery.c b/test/ioctl/discovery.c new file mode 100644 index 0000000..7e075b8 --- /dev/null +++ b/test/ioctl/discovery.c @@ -0,0 +1,460 @@ +// SPDX-License-Identifier: LGPL-2.1-or-later + +#include + +#include +#include +#include +#include +#include + +#include "../../src/nvme/private.h" +#include "mock.h" +#include "util.h" + +#define TEST_FD 0xFD + +static void arbitrary_ascii_string(size_t max_len, char *str, char *log_str) +{ + size_t len; + size_t i; + + len = arbitrary_range(max_len + 1); + for (i = 0; i < len; i++) { + /* + * ASCII strings shall contain only code values 20h through 7Eh. + * Exclude 20h (space) because it ends the string. + */ + str[i] = log_str[i] = arbitrary_range(0x7E - 0x20) + 0x20 + 1; + } + for (i = len; i < max_len; i++) { + str[i] = '\0'; + log_str[i] = ' '; + } +} + +static void arbitrary_entry(struct nvmf_disc_log_entry *entry, + struct nvmf_disc_log_entry *log_entry) +{ + arbitrary(entry, sizeof(*entry)); + memcpy(log_entry, entry, sizeof(*entry)); + arbitrary_ascii_string( + sizeof(entry->trsvcid), entry->trsvcid, log_entry->trsvcid); + arbitrary_ascii_string( + sizeof(entry->traddr), entry->traddr, log_entry->traddr); +} + +static void arbitrary_entries(size_t len, + struct nvmf_disc_log_entry *entries, + struct nvmf_disc_log_entry *log_entries) +{ + size_t i; + + for (i = 0; i < len; i++) + arbitrary_entry(&entries[i], &log_entries[i]); +} + +static void test_no_entries(nvme_ctrl_t c) +{ + struct nvmf_discovery_log header = {}; + /* No entries to fetch after fetching the header */ + struct mock_cmd mock_admin_cmds[] = { + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header), + .cdw10 = (sizeof(header) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header, + }, + }; + struct nvmf_discovery_log *log = NULL; + + set_mock_admin_cmds(mock_admin_cmds, ARRAY_SIZE(mock_admin_cmds)); + check(nvmf_get_discovery_log(c, &log, 1) == 0, "discovery failed: %m"); + end_mock_cmds(); + cmp(log, &header, sizeof(header), "incorrect header"); + free(log); +} + +static void test_four_entries(nvme_ctrl_t c) +{ + size_t num_entries = 4; + struct nvmf_disc_log_entry entries[num_entries]; + struct nvmf_disc_log_entry log_entries[num_entries]; + struct nvmf_discovery_log header = {.numrec = cpu_to_le64(num_entries)}; + /* + * All 4 entries should be fetched at once + * followed by the header again (to ensure genctr hasn't changed) + */ + struct mock_cmd mock_admin_cmds[] = { + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header), + .cdw10 = (sizeof(header) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(entries), + .cdw10 = (sizeof(entries) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .cdw12 = sizeof(header), /* LPOL */ + .out_data = log_entries, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header), + .cdw10 = (sizeof(header) / 4 - 1) << 16 /* NUMDL */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header, + }, + }; + struct nvmf_discovery_log *log = NULL; + + arbitrary_entries(num_entries, entries, log_entries); + set_mock_admin_cmds(mock_admin_cmds, ARRAY_SIZE(mock_admin_cmds)); + check(nvmf_get_discovery_log(c, &log, 1) == 0, "discovery failed: %m"); + end_mock_cmds(); + cmp(log, &header, sizeof(header), "incorrect header"); + cmp(log->entries, entries, sizeof(entries), "incorrect entries"); + free(log); +} + +static void test_five_entries(nvme_ctrl_t c) +{ + size_t num_entries = 5; + struct nvmf_disc_log_entry entries[num_entries]; + struct nvmf_disc_log_entry log_entries[num_entries]; + size_t first_entries = 4; + size_t first_data_len = first_entries * sizeof(*entries); + size_t second_entries = num_entries - first_entries; + size_t second_data_len = second_entries * sizeof(*entries); + struct nvmf_discovery_log header = {.numrec = cpu_to_le64(num_entries)}; + /* + * The first 4 entries (4 KB) are fetched together, + * followed by last entry separately. + * Finally, the header is fetched again to check genctr. + */ + struct mock_cmd mock_admin_cmds[] = { + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header), + .cdw10 = (sizeof(header) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = first_data_len, + .cdw10 = (first_data_len / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .cdw12 = sizeof(header), /* LPOL */ + .out_data = log_entries, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = second_data_len, + .cdw10 = (second_data_len / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .cdw12 = sizeof(header) + first_data_len, /* LPOL */ + .out_data = log_entries + first_entries, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header), + .cdw10 = (sizeof(header) / 4 - 1) << 16 /* NUMDL */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header, + }, + }; + struct nvmf_discovery_log *log = NULL; + + arbitrary_entries(num_entries, entries, log_entries); + set_mock_admin_cmds(mock_admin_cmds, ARRAY_SIZE(mock_admin_cmds)); + check(nvmf_get_discovery_log(c, &log, 1) == 0, "discovery failed: %m"); + end_mock_cmds(); + cmp(log, &header, sizeof(header), "incorrect header"); + cmp(log->entries, entries, sizeof(entries), "incorrect entries"); + free(log); +} + +static void test_genctr_change(nvme_ctrl_t c) +{ + struct nvmf_disc_log_entry entries1[1]; + struct nvmf_discovery_log header1 = { + .numrec = cpu_to_le64(ARRAY_SIZE(entries1)), + }; + size_t num_entries2 = 2; + struct nvmf_disc_log_entry entries2[num_entries2]; + struct nvmf_disc_log_entry log_entries2[num_entries2]; + struct nvmf_discovery_log header2 = { + .genctr = cpu_to_le64(1), + .numrec = cpu_to_le64(num_entries2), + }; + /* + * genctr changes after the entries are fetched the first time, + * so the log page fetch is retried + */ + struct mock_cmd mock_admin_cmds[] = { + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header1), + .cdw10 = (sizeof(header1) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header1, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(entries1), + .cdw10 = (sizeof(entries1) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* NUMDL */ + .cdw12 = sizeof(header1), /* LPOL */ + .out_data = entries1, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header2), + .cdw10 = (sizeof(header2) / 4 - 1) << 16 /* NUMDL */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header2, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header2), + .cdw10 = (sizeof(header2) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header2, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(entries2), + .cdw10 = (sizeof(entries2) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .cdw12 = sizeof(header2), /* LPOL */ + .out_data = log_entries2, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header2), + .cdw10 = (sizeof(header2) / 4 - 1) << 16 /* NUMDL */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header2, + }, + }; + struct nvmf_discovery_log *log = NULL; + + arbitrary(entries1, sizeof(entries1)); + arbitrary_entries(num_entries2, entries2, log_entries2); + set_mock_admin_cmds(mock_admin_cmds, ARRAY_SIZE(mock_admin_cmds)); + check(nvmf_get_discovery_log(c, &log, 2) == 0, "discovery failed: %m"); + end_mock_cmds(); + cmp(log, &header2, sizeof(header2), "incorrect header"); + cmp(log->entries, entries2, sizeof(entries2), "incorrect entries"); + free(log); +} + +static void test_max_retries(nvme_ctrl_t c) +{ + struct nvmf_disc_log_entry entry; + struct nvmf_discovery_log header1 = {.numrec = cpu_to_le64(1)}; + struct nvmf_discovery_log header2 = { + .genctr = cpu_to_le64(1), + .numrec = cpu_to_le64(1), + }; + struct nvmf_discovery_log header3 = { + .genctr = cpu_to_le64(2), + .numrec = cpu_to_le64(1), + }; + /* genctr changes in both attempts, hitting the max retries (2) */ + struct mock_cmd mock_admin_cmds[] = { + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header1), + .cdw10 = (sizeof(header1) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header1, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(entry), + .cdw10 = (sizeof(entry) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .cdw12 = sizeof(header1), /* LPOL */ + .out_data = &entry, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header2), + .cdw10 = (sizeof(header2) / 4 - 1) << 16 /* NUMDL */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header2, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header2), + .cdw10 = (sizeof(header2) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header2, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(entry), + .cdw10 = (sizeof(entry) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .cdw12 = sizeof(header2), /* LPOL */ + .out_data = &entry, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header3), + .cdw10 = (sizeof(header3) / 4 - 1) << 16 /* NUMDL */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header3, + }, + }; + struct nvmf_discovery_log *log = NULL; + + arbitrary(&entry, sizeof(entry)); + set_mock_admin_cmds(mock_admin_cmds, ARRAY_SIZE(mock_admin_cmds)); + check(nvmf_get_discovery_log(c, &log, 2) == -1, "discovery succeeded"); + end_mock_cmds(); + check(errno == EAGAIN, "discovery failed: %m"); + check(!log, "unexpected log page returned"); +} + +static void test_header_error(nvme_ctrl_t c) +{ + size_t header_size = sizeof(struct nvmf_discovery_log); + /* Stop after an error in fetching the header the first time */ + struct mock_cmd mock_admin_cmds[] = { + { + .opcode = nvme_admin_get_log_page, + .data_len = header_size, + .cdw10 = (header_size / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .err = NVME_SC_INVALID_OPCODE, + }, + }; + struct nvmf_discovery_log *log = NULL; + + set_mock_admin_cmds(mock_admin_cmds, ARRAY_SIZE(mock_admin_cmds)); + check(nvmf_get_discovery_log(c, &log, 1) == -1, "discovery succeeded"); + end_mock_cmds(); + check(!log, "unexpected log page returned"); +} + +static void test_entries_error(nvme_ctrl_t c) +{ + struct nvmf_discovery_log header = {.numrec = cpu_to_le64(1)}; + size_t entry_size = sizeof(struct nvmf_disc_log_entry); + /* Stop after an error in fetching the entries */ + struct mock_cmd mock_admin_cmds[] = { + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header), + .cdw10 = (sizeof(header) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = entry_size, + .cdw10 = (entry_size / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .cdw12 = sizeof(header), /* LPOL */ + .err = -EIO, + }, + }; + struct nvmf_discovery_log *log = NULL; + + set_mock_admin_cmds(mock_admin_cmds, ARRAY_SIZE(mock_admin_cmds)); + check(nvmf_get_discovery_log(c, &log, 1) == -1, "discovery succeeded"); + end_mock_cmds(); + check(errno == EIO, "discovery failed: %m"); + check(!log, "unexpected log page returned"); +} + +static void test_genctr_error(nvme_ctrl_t c) +{ + struct nvmf_disc_log_entry entry; + struct nvmf_discovery_log header = {.numrec = cpu_to_le64(1)}; + /* Stop after an error in refetching the header */ + struct mock_cmd mock_admin_cmds[] = { + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header), + .cdw10 = (sizeof(header) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .out_data = &header, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(entry), + .cdw10 = (sizeof(entry) / 4 - 1) << 16 /* NUMDL */ + | 1 << 15 /* RAE */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .cdw12 = sizeof(header), /* LPOL */ + .out_data = &entry, + }, + { + .opcode = nvme_admin_get_log_page, + .data_len = sizeof(header), + .cdw10 = (sizeof(header) / 4 - 1) << 16 /* NUMDL */ + | NVME_LOG_LID_DISCOVER, /* LID */ + .err = NVME_SC_INTERNAL, + }, + }; + struct nvmf_discovery_log *log = NULL; + + arbitrary(&entry, sizeof(entry)); + set_mock_admin_cmds(mock_admin_cmds, ARRAY_SIZE(mock_admin_cmds)); + check(nvmf_get_discovery_log(c, &log, 1) == -1, "discovery succeeded"); + end_mock_cmds(); + check(!log, "unexpected log page returned"); +} + +static void run_test(const char *test_name, void (*test_fn)(nvme_ctrl_t)) +{ + struct nvme_ctrl c = {.fd = TEST_FD}; + + printf("Running test %s...", test_name); + fflush(stdout); + check(asprintf(&c.name, "%s_ctrl", test_name) >= 0, "asprintf() failed"); + test_fn(&c); + free(c.name); + puts(" OK"); +} + +#define RUN_TEST(name) run_test(#name, test_ ## name) + +int main(void) +{ + set_mock_fd(TEST_FD); + RUN_TEST(no_entries); + RUN_TEST(four_entries); + RUN_TEST(five_entries); + RUN_TEST(genctr_change); + RUN_TEST(max_retries); + RUN_TEST(header_error); + RUN_TEST(entries_error); + RUN_TEST(genctr_error); +} diff --git a/test/ioctl/features.c b/test/ioctl/features.c new file mode 100644 index 0000000..6cdd43c --- /dev/null +++ b/test/ioctl/features.c @@ -0,0 +1,1604 @@ +// SPDX-License-Identifier: LGPL-2.1-or-later + +#include + +#include +#include + +#include "mock.h" +#include "util.h" + +#define TEST_FD 0xFD +#define TEST_TIMEOUT 1234 +#define TEST_NSID 0x89ABCDEF +#define TEST_CDW11 0x11111111 +#define TEST_CDW12 0x12121212 +#define TEST_CDW13 0x13131313 +#define TEST_CDW15 0x15151515 +#define TEST_UUIDX 0b1001110 +#define TEST_FID 0xFE +#define TEST_RESULT 0x12345678 +#define TEST_SEL NVME_GET_FEATURES_SEL_SAVED +#define TEST_SC NVME_SC_INVALID_FIELD + +static void test_set_features(void) +{ + uint32_t result = 0; + uint8_t data[256]; + struct nvme_set_features_args args = { + .result = &result, + .data = data, + .args_size = sizeof(args), + .fd = TEST_FD, + .timeout = TEST_TIMEOUT, + .nsid = TEST_NSID, + .cdw11 = TEST_CDW11, + .cdw12 = TEST_CDW12, + .cdw13 = TEST_CDW13, + .cdw15 = TEST_CDW15, + .data_len = sizeof(data), + .save = true, + .uuidx = TEST_UUIDX, + .fid = TEST_FID, + }; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .nsid = TEST_NSID, + .in_data = data, + .data_len = sizeof(data), + .cdw10 = 1 << 31 /* SAVE */ + | TEST_FID, + .cdw11 = TEST_CDW11, + .cdw12 = TEST_CDW12, + .cdw13 = TEST_CDW13, + .cdw14 = TEST_UUIDX, + .cdw15 = TEST_CDW15, + .timeout_ms = TEST_TIMEOUT, + .result = TEST_RESULT, + }; + int err; + + arbitrary(data, sizeof(data)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features(&args); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_features(void) +{ + uint32_t result = 0; + uint8_t data[256], get_data[sizeof(data)] = {}; + struct nvme_get_features_args args = { + .result = &result, + .data = get_data, + .args_size = sizeof(args), + .fd = TEST_FD, + .timeout = TEST_TIMEOUT, + .nsid = TEST_NSID, + .sel = TEST_SEL, + .cdw11 = TEST_CDW11, + .data_len = sizeof(data), + .fid = TEST_FID, + .uuidx = TEST_UUIDX, + }; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .nsid = TEST_NSID, + .data_len = sizeof(data), + .cdw10 = TEST_SEL << 8 | TEST_FID, + .cdw11 = TEST_CDW11, + .cdw14 = TEST_UUIDX, + .timeout_ms = TEST_TIMEOUT, + .out_data = data, + .result = TEST_RESULT, + }; + int err; + + arbitrary(data, sizeof(data)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features(&args); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); + cmp(get_data, data, sizeof(data), "incorrect data"); +} + +static void test_set_features_data(void) +{ + uint8_t data[128]; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .nsid = TEST_NSID, + .in_data = data, + .data_len = sizeof(data), + .cdw10 = TEST_FID, + .cdw11 = TEST_CDW11, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + arbitrary(data, sizeof(data)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_data( + TEST_FD, TEST_FID, TEST_NSID, TEST_CDW11, false, + sizeof(data), data, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_features_data(void) +{ + uint8_t data[128], get_data[sizeof(data)] = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .nsid = TEST_NSID, + .data_len = sizeof(data), + .cdw10 = NVME_GET_FEATURES_SEL_CURRENT << 8 | TEST_FID, + .out_data = data, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + arbitrary(data, sizeof(data)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_data( + TEST_FD, TEST_FID, TEST_NSID, sizeof(data), get_data, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); + cmp(get_data, data, sizeof(data), "incorrect data"); +} + +static void test_set_features_simple(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .nsid = TEST_NSID, + .cdw10 = 1 << 31 /* SAVE */ + | TEST_FID, + .cdw11 = TEST_CDW11, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_simple( + TEST_FD, TEST_FID, TEST_NSID, TEST_CDW11, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_features_simple(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .nsid = TEST_NSID, + .cdw10 = NVME_GET_FEATURES_SEL_CURRENT << 8 | TEST_FID, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_simple(TEST_FD, TEST_FID, TEST_NSID, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_arbitration(void) +{ + uint8_t HPW = 0xAA, MPW = 0xBB, LPW = 0xCC, AB = 0b111; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = NVME_FEAT_FID_ARBITRATION, + .cdw11 = HPW << 24 | MPW << 16 | LPW << 8 | AB, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_arbitration( + TEST_FD, AB, LPW, MPW, HPW, false, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_arbitration(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_ARBITRATION, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_arbitration(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_power_mgmt(void) +{ + uint8_t PS = 0b10101, WH = 0b101; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_POWER_MGMT, + .cdw11 = WH << 5 | PS, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_power_mgmt(TEST_FD, PS, WH, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_power_mgmt(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_POWER_MGMT, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_power_mgmt(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_lba_range(void) +{ + uint8_t NUM = 64; + struct nvme_lba_range_type range_types; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .nsid = TEST_NSID, + .in_data = &range_types, + .data_len = sizeof(range_types), + .cdw10 = NVME_FEAT_FID_LBA_RANGE, + .cdw11 = NUM - 1, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + arbitrary(&range_types, sizeof(range_types)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_lba_range( + TEST_FD, TEST_NSID, NUM, false, &range_types, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_lba_range(void) +{ + struct nvme_lba_range_type range_types, get_range_types = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .nsid = TEST_NSID, + .data_len = sizeof(range_types), + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_LBA_RANGE, + .out_data = &range_types, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + arbitrary(&range_types, sizeof(range_types)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_lba_range2( + TEST_FD, TEST_SEL, TEST_NSID, &get_range_types, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); + cmp(&get_range_types, &range_types, sizeof(range_types), + "incorrect LBA range types"); +} + +static void test_set_temp_thresh(void) +{ + uint16_t TMPTH = 0xFEDC; + uint8_t TMPSEL = 0x8; + enum nvme_feat_tmpthresh_thsel THSEL = + NVME_FEATURE_TEMPTHRESH_THSEL_UNDER; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_TEMP_THRESH, + .cdw11 = THSEL << 20 | TMPSEL << 16 | TMPTH, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_temp_thresh( + TEST_FD, TMPTH, TMPSEL, THSEL, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_temp_thresh(void) +{ + /* + * nvme_get_features_temp_thresh() doesn't support + * specifying TMPSEL and THSEL + */ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_TEMP_THRESH, + .cdw11 = NVME_FEATURE_TEMPTHRESH_THSEL_OVER << 20, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_temp_thresh(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_err_recovery(void) +{ + uint16_t TLER = 0xCDEF; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .nsid = TEST_NSID, + .cdw10 = NVME_FEAT_FID_ERR_RECOVERY, + .cdw11 = 1 << 16 /* DULBE */ + | TLER, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_err_recovery( + TEST_FD, TEST_NSID, TLER, true, false, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_err_recovery(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .nsid = TEST_NSID, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_ERR_RECOVERY, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_err_recovery2( + TEST_FD, TEST_SEL, TEST_NSID, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_volatile_wc(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_VOLATILE_WC, + .cdw11 = 1 << 0, /* WCE */ + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_volatile_wc(TEST_FD, true, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_volatile_wc(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 + | NVME_FEAT_FID_VOLATILE_WC, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_volatile_wc(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_num_queues(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_NUM_QUEUES, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_num_queues(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_irq_coalesce(void) +{ + uint8_t THR = 0xAB, TIME = 0xCD; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = NVME_FEAT_FID_IRQ_COALESCE, + .cdw11 = TIME << 8 | THR, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_irq_coalesce( + TEST_FD, THR, TIME, false, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_irq_coalesce(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_IRQ_COALESCE, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_irq_coalesce(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_irq_config(void) +{ + uint16_t IV = 0x1234; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_IRQ_CONFIG, + .cdw11 = 1 << 16 /* CD */ + | IV, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_irq_config(TEST_FD, IV, true, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_irq_config(void) +{ + uint16_t IV = 0x5678; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_IRQ_CONFIG, + .cdw11 = IV, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_irq_config(TEST_FD, TEST_SEL, IV, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_write_atomic(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = NVME_FEAT_FID_WRITE_ATOMIC, + .cdw11 = 1 << 0, /* DN */ + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_write_atomic(TEST_FD, true, false, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_write_atomic(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_WRITE_ATOMIC, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_write_atomic(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_async_event(void) +{ + uint32_t EVENTS = 0x87654321; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_ASYNC_EVENT, + .cdw11 = EVENTS, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_async_event(TEST_FD, EVENTS, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_async_event(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_ASYNC_EVENT, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_async_event(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_auto_pst(void) +{ + struct nvme_feat_auto_pst apst; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .in_data = &apst, + .data_len = sizeof(apst), + .cdw10 = NVME_FEAT_FID_AUTO_PST, + .cdw11 = 1 << 0, /* APSTE */ + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + arbitrary(&apst, sizeof(apst)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_auto_pst(TEST_FD, true, false, &apst, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_auto_pst(void) +{ + struct nvme_feat_auto_pst apst, get_apst = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .data_len = sizeof(apst), + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_AUTO_PST, + .out_data = &apst, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + arbitrary(&apst, sizeof(apst)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_auto_pst(TEST_FD, TEST_SEL, &get_apst, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); + cmp(&get_apst, &apst, sizeof(apst), "incorrect apst"); +} + +static void test_get_host_mem_buf(void) +{ + struct nvme_host_mem_buf_attrs attrs, get_attrs = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .data_len = sizeof(attrs), + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_HOST_MEM_BUF, + .out_data = &attrs, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + arbitrary(&attrs, sizeof(attrs)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_host_mem_buf2( + TEST_FD, TEST_SEL, &get_attrs, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); + cmp(&get_attrs, &attrs, sizeof(attrs), "incorrect attrs"); +} + +static void test_set_timestamp(void) +{ + struct nvme_timestamp ts = {.timestamp = {1, 2, 3, 4, 5, 6}}; + uint64_t timestamp = ts.timestamp[0] + | (uint64_t) ts.timestamp[1] << 8 + | (uint64_t) ts.timestamp[2] << 16 + | (uint64_t) ts.timestamp[3] << 24 + | (uint64_t) ts.timestamp[4] << 32 + | (uint64_t) ts.timestamp[5] << 40; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .in_data = &ts, + .data_len = sizeof(ts), + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_TIMESTAMP, + }; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_timestamp(TEST_FD, true, timestamp); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); +} + +static void test_get_timestamp(void) +{ + struct nvme_timestamp ts, get_ts = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .data_len = sizeof(ts), + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_TIMESTAMP, + .out_data = &ts, + }; + int err; + + arbitrary(&ts, sizeof(ts)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_timestamp(TEST_FD, TEST_SEL, &get_ts); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + cmp(&get_ts, &ts, sizeof(ts), "incorrect timestamp"); +} + +static void test_get_kato(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_KATO, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_kato(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_hctm(void) +{ + uint16_t TMT2 = 0x4321, TMT1 = 0x8765; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = NVME_FEAT_FID_HCTM, + .cdw11 = TMT1 << 16 | TMT2, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_hctm(TEST_FD, TMT2, TMT1, false, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_hctm(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_HCTM, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_hctm(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_nopsc(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_NOPSC, + .cdw11 = 1 << 0 /* NOPPME */, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_nopsc(TEST_FD, true, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_nopsc(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_NOPSC, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_nopsc(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_rrl(void) +{ + uint8_t RRL = 0xA; + uint16_t NVMSETID = 0x1234; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = NVME_FEAT_FID_RRL, + .cdw11 = NVMSETID, + .cdw12 = RRL, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_rrl(TEST_FD, RRL, NVMSETID, false, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_rrl(void) +{ + /* nvme_get_features_rrl() doesn't support specifying the NVMSETID */ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_RRL, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_rrl(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_plm_config(void) +{ + uint16_t NVMSETID = 0xFEDC; + struct nvme_plm_config config; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .in_data = &config, + .data_len = sizeof(config), + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_PLM_CONFIG, + .cdw11 = NVMSETID, + .cdw12 = 1 << 0 /* Predictable Latency Enable */, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + arbitrary(&config, sizeof(config)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_plm_config( + TEST_FD, true, NVMSETID, true, &config, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_plm_config(void) +{ + uint16_t NVMSETID = 0xABCD; + struct nvme_plm_config config, get_config = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .data_len = sizeof(config), + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_PLM_CONFIG, + .cdw11 = NVMSETID, + .out_data = &config, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + arbitrary(&config, sizeof(config)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_plm_config( + TEST_FD, TEST_SEL, NVMSETID, &get_config, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); + cmp(&get_config, &config, sizeof(config), "incorrect PLM config"); +} + +static void test_set_plm_window(void) +{ + enum nvme_feat_plm_window_select SEL = NVME_FEATURE_PLM_NDWIN; + uint16_t NVMSETID = 0x4321; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = NVME_FEAT_FID_PLM_WINDOW, + .cdw11 = NVMSETID, + .cdw12 = SEL, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_plm_window( + TEST_FD, SEL, NVMSETID, false, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_plm_window(void) +{ + uint16_t NVMSETID = 0x8765; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_PLM_WINDOW, + .cdw11 = NVMSETID, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_plm_window( + TEST_FD, TEST_SEL, NVMSETID, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_lba_sts_interval(void) +{ + uint16_t LSIRI = 0x1234, LSIPI = 0x5678; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_LBA_STS_INTERVAL, + .cdw11 = LSIPI << 16 | LSIRI, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_lba_sts_interval( + TEST_FD, LSIRI, LSIPI, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_lba_sts_interval(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_LBA_STS_INTERVAL, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_lba_sts_interval(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_host_behavior(void) +{ + /* nvme_set_features_host_behavior() ignores SAVE */ + struct nvme_feat_host_behavior behavior; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .in_data = &behavior, + .data_len = sizeof(behavior), + .cdw10 = NVME_FEAT_FID_HOST_BEHAVIOR, + }; + int err; + + arbitrary(&behavior, sizeof(behavior)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_host_behavior(TEST_FD, true, &behavior); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); +} + +static void test_get_host_behavior(void) +{ + struct nvme_feat_host_behavior behavior, get_behavior = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .data_len = sizeof(behavior), + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_HOST_BEHAVIOR, + .out_data = &behavior, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + arbitrary(&behavior, sizeof(behavior)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_host_behavior( + TEST_FD, TEST_SEL, &get_behavior, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); + cmp(&get_behavior, &behavior, sizeof(behavior), "incorrect behavior"); +} + +static void test_set_sanitize(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = NVME_FEAT_FID_SANITIZE, + .cdw11 = 1 << 0, /* NODRM */ + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_sanitize(TEST_FD, true, false, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_sanitize(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_SANITIZE, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_sanitize(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_endurance_evt_cfg(void) +{ + uint16_t ENDGID = 0x9876; + uint8_t EGWARN = 0xCD; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_ENDURANCE_EVT_CFG, + .cdw11 = EGWARN << 16 | ENDGID, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_endurance_evt_cfg( + TEST_FD, ENDGID, EGWARN, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_endurance_event_cfg(void) +{ + uint16_t ENDGID = 0x6789; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_ENDURANCE_EVT_CFG, + .cdw11 = ENDGID, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_endurance_event_cfg( + TEST_FD, TEST_SEL, ENDGID, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_iocs_profile(void) +{ + uint16_t IOCSI = 0b101100111; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = NVME_FEAT_FID_IOCS_PROFILE, + .cdw11 = IOCSI, + }; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_iocs_profile(TEST_FD, IOCSI, false); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); +} + +static void test_get_iocs_profile(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_IOCS_PROFILE, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_iocs_profile(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_sw_progress(void) +{ + uint8_t PBSLC = 0xBA; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_SW_PROGRESS, + .cdw11 = PBSLC, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_sw_progress(TEST_FD, PBSLC, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_sw_progress(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_SW_PROGRESS, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_sw_progress(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_host_id(void) +{ + uint8_t hostid[8]; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .in_data = hostid, + .data_len = sizeof(hostid), + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_HOST_ID, + .result = TEST_RESULT, + }; + int err; + + arbitrary(hostid, sizeof(hostid)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_host_id(TEST_FD, false, true, hostid); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); +} + +static void test_set_host_id_extended(void) +{ + uint8_t hostid[16]; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .in_data = hostid, + .data_len = sizeof(hostid), + .cdw10 = NVME_FEAT_FID_HOST_ID, + .cdw11 = 1 << 0, /* EXHID */ + .result = TEST_RESULT, + }; + int err; + + arbitrary(hostid, sizeof(hostid)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_host_id(TEST_FD, true, false, hostid); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); +} + +static void test_get_host_id(void) +{ + uint8_t hostid[8], get_hostid[sizeof(hostid)] = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .data_len = sizeof(hostid), + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_HOST_ID, + .out_data = hostid, + .result = TEST_RESULT, + }; + int err; + + arbitrary(hostid, sizeof(hostid)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_host_id( + TEST_FD, TEST_SEL, false, sizeof(hostid), get_hostid); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + cmp(get_hostid, hostid, sizeof(hostid), "incorrect host identifier"); +} + +static void test_get_host_id_extended(void) +{ + uint8_t hostid[16], get_hostid[sizeof(hostid)] = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .data_len = sizeof(hostid), + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_HOST_ID, + .cdw11 = 1 << 0, /* EXHID */ + .out_data = hostid, + .result = TEST_RESULT, + }; + int err; + + arbitrary(hostid, sizeof(hostid)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_host_id( + TEST_FD, TEST_SEL, true, sizeof(hostid), get_hostid); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + cmp(get_hostid, hostid, sizeof(hostid), "incorrect host identifier"); +} + +static void test_set_resv_mask(void) +{ + uint32_t MASK = 0x23456789; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .nsid = TEST_NSID, + .cdw10 = 1 << 31 /* SAVE */ + | NVME_FEAT_FID_RESV_MASK, + .cdw11 = MASK, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_resv_mask2( + TEST_FD, TEST_NSID, MASK, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_resv_mask(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .nsid = TEST_NSID, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_RESV_MASK, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_resv_mask2( + TEST_FD, TEST_SEL, TEST_NSID, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_resv_persist(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .nsid = TEST_NSID, + .cdw10 = NVME_FEAT_FID_RESV_PERSIST, + .cdw11 = 1 << 0, /* PTPL */ + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_resv_persist2( + TEST_FD, TEST_NSID, true, false, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_resv_persist(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .nsid = TEST_NSID, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_RESV_PERSIST, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_resv_persist2( + TEST_FD, TEST_SEL, TEST_NSID, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_write_protect(void) +{ + /* nvme_set_features_write_protect() ignores SAVE */ + enum nvme_feat_nswpcfg_state STATE = + NVME_FEAT_NS_WRITE_PROTECT_PERMANENT; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .nsid = TEST_NSID, + .cdw10 = NVME_FEAT_FID_WRITE_PROTECT, + .cdw11 = STATE, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_write_protect2( + TEST_FD, TEST_NSID, STATE, true, &result); + end_mock_cmds(); + check(err == 0, "set features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_write_protect(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .nsid = TEST_NSID, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_WRITE_PROTECT, + .result = TEST_RESULT, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_write_protect( + TEST_FD, TEST_NSID, TEST_SEL, &result); + end_mock_cmds(); + check(err == 0, "get features returned error %d, errno %m", err); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +/* + * All set_features functions tail-call nvme_set_features(), + * so testing errors in any of them will do + */ + +static void test_set_status_code_error(void) +{ + uint32_t EVENTS = 0x12345678; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .cdw10 = NVME_FEAT_FID_ASYNC_EVENT, + .cdw11 = EVENTS, + .result = TEST_RESULT, + .err = TEST_SC, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_async_event(TEST_FD, EVENTS, false, &result); + end_mock_cmds(); + check(err == TEST_SC, "got error %d, expected %d", err, TEST_SC); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_set_kernel_error(void) +{ + uint32_t MASK = 0x87654321; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_set_features, + .nsid = TEST_NSID, + .cdw10 = NVME_FEAT_FID_RESV_MASK, + .cdw11 = MASK, + .result = TEST_RESULT, + .err = -EIO, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_set_features_resv_mask2( + TEST_FD, TEST_NSID, MASK, false, &result); + end_mock_cmds(); + check(err == -1, "got error %d, expected -1", err); + check(errno == EIO, "unexpected error %m"); + check(!result, "result unexpectedly set to %" PRIu32, result); +} + +/* + * All get_features functions tail-call nvme_get_features(), + * so testing errors in any of them will do + */ + +static void test_get_status_code_error(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_KATO, + .result = TEST_RESULT, + .err = TEST_SC, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_kato(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == TEST_SC, "got error %d, expected %d", err, TEST_SC); + check(result == TEST_RESULT, + "got result %" PRIu32 ", expected %" PRIu32, result, TEST_RESULT); +} + +static void test_get_kernel_error(void) +{ + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_get_features, + .cdw10 = TEST_SEL << 8 | NVME_FEAT_FID_NUM_QUEUES, + .result = TEST_RESULT, + .err = -EBUSY, + }; + uint32_t result = 0; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_get_features_num_queues(TEST_FD, TEST_SEL, &result); + end_mock_cmds(); + check(err == -1, "got error %d, expected -1", err); + check(errno == EBUSY, "unexpected error %m"); + check(!result, "result unexpectedly set to %" PRIu32, result); +} + +static void run_test(const char *test_name, void (*test_fn)(void)) +{ + printf("Running test %s...", test_name); + fflush(stdout); + test_fn(); + puts(" OK"); +} + +#define RUN_TEST(name) run_test(#name, test_ ## name) + +int main(void) +{ + set_mock_fd(TEST_FD); + RUN_TEST(set_features); + RUN_TEST(get_features); + RUN_TEST(set_features_data); + RUN_TEST(get_features_data); + RUN_TEST(set_features_simple); + RUN_TEST(get_features_simple); + RUN_TEST(set_arbitration); + RUN_TEST(get_arbitration); + RUN_TEST(set_power_mgmt); + RUN_TEST(get_power_mgmt); + RUN_TEST(set_lba_range); + RUN_TEST(get_lba_range); + RUN_TEST(set_temp_thresh); + RUN_TEST(get_temp_thresh); + RUN_TEST(set_err_recovery); + RUN_TEST(get_err_recovery); + RUN_TEST(set_volatile_wc); + RUN_TEST(get_volatile_wc); + RUN_TEST(get_num_queues); + RUN_TEST(set_irq_coalesce); + RUN_TEST(get_irq_coalesce); + RUN_TEST(set_irq_config); + RUN_TEST(get_irq_config); + RUN_TEST(set_write_atomic); + RUN_TEST(get_write_atomic); + RUN_TEST(set_async_event); + RUN_TEST(get_async_event); + RUN_TEST(set_auto_pst); + RUN_TEST(get_auto_pst); + RUN_TEST(get_host_mem_buf); + RUN_TEST(set_timestamp); + RUN_TEST(get_timestamp); + RUN_TEST(get_kato); + RUN_TEST(set_hctm); + RUN_TEST(get_hctm); + RUN_TEST(set_nopsc); + RUN_TEST(get_nopsc); + RUN_TEST(set_rrl); + RUN_TEST(get_rrl); + RUN_TEST(set_plm_config); + RUN_TEST(get_plm_config); + RUN_TEST(set_plm_window); + RUN_TEST(get_plm_window); + RUN_TEST(set_lba_sts_interval); + RUN_TEST(get_lba_sts_interval); + RUN_TEST(set_host_behavior); + RUN_TEST(get_host_behavior); + RUN_TEST(set_sanitize); + RUN_TEST(get_sanitize); + RUN_TEST(set_endurance_evt_cfg); + RUN_TEST(get_endurance_event_cfg); + RUN_TEST(set_iocs_profile); + RUN_TEST(get_iocs_profile); + RUN_TEST(set_sw_progress); + RUN_TEST(get_sw_progress); + RUN_TEST(set_host_id); + RUN_TEST(set_host_id_extended); + RUN_TEST(get_host_id); + RUN_TEST(get_host_id_extended); + RUN_TEST(set_resv_mask); + RUN_TEST(get_resv_mask); + RUN_TEST(set_resv_persist); + RUN_TEST(get_resv_persist); + RUN_TEST(set_write_protect); + RUN_TEST(get_write_protect); + RUN_TEST(set_status_code_error); + RUN_TEST(set_kernel_error); + RUN_TEST(get_status_code_error); + RUN_TEST(get_kernel_error); +} diff --git a/test/ioctl/identify.c b/test/ioctl/identify.c new file mode 100644 index 0000000..ccde02b --- /dev/null +++ b/test/ioctl/identify.c @@ -0,0 +1,572 @@ +// SPDX-License-Identifier: LGPL-2.1-or-later + +#include + +#include +#include + +#include "mock.h" +#include "util.h" + +#define TEST_FD 0xFD +#define TEST_NSID 0x12345678 +#define TEST_NVMSETID 0xABCD +#define TEST_UUID 123 +#define TEST_CSI NVME_CSI_KV +#define TEST_CNTID 0x4321 +#define TEST_DOMID 0xFEDC +#define TEST_ENDGID 0x0123 +#define TEST_SC NVME_SC_INVALID_FIELD + +static void test_ns(void) +{ + struct nvme_id_ns expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_NS, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_ns(TEST_FD, TEST_NSID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_ctrl(void) +{ + struct nvme_id_ctrl expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_CTRL, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_ctrl(TEST_FD, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_active_ns_list(void) +{ + struct nvme_ns_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_NS_ACTIVE_LIST, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_active_ns_list(TEST_FD, TEST_NSID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_ns_descs(void) +{ + uint8_t expected_id[NVME_IDENTIFY_DATA_SIZE]; + struct nvme_ns_id_desc *id; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_NS_DESC_LIST, + .out_data = &expected_id, + }; + int err; + + arbitrary(expected_id, sizeof(expected_id)); + id = calloc(1, NVME_IDENTIFY_DATA_SIZE); + check(id, "memory allocation failed"); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_ns_descs(TEST_FD, TEST_NSID, id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(id, expected_id, sizeof(expected_id), "incorrect identify data"); + free(id); +} + +static void test_nvmset_list(void) +{ + struct nvme_id_nvmset_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_NVMSET_LIST, + .cdw11 = TEST_NVMSETID, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_nvmset_list(TEST_FD, TEST_NVMSETID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_ns_csi(void) +{ + uint8_t expected_id[NVME_IDENTIFY_DATA_SIZE]; + uint8_t id[NVME_IDENTIFY_DATA_SIZE] = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_CSI_NS, + .cdw11 = TEST_CSI << 24, + .cdw14 = TEST_UUID, + .out_data = expected_id, + }; + int err; + + arbitrary(expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_ns_csi(TEST_FD, TEST_NSID, TEST_UUID, TEST_CSI, id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(id, expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_zns_identify_ns(void) +{ + struct nvme_zns_id_ns expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_CSI_NS, + .cdw11 = NVME_CSI_ZNS << 24, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_zns_identify_ns(TEST_FD, TEST_NSID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_nvm_identify_ctrl(void) +{ + struct nvme_id_ctrl_nvm expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_CSI_CTRL, + .cdw11 = NVME_CSI_NVM << 24, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_nvm_identify_ctrl(TEST_FD, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_zns_identify_ctrl(void) +{ + struct nvme_zns_id_ctrl expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_CSI_CTRL, + .cdw11 = NVME_CSI_ZNS << 24, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_zns_identify_ctrl(TEST_FD, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_active_ns_list_csi(void) +{ + struct nvme_ns_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_CSI_NS_ACTIVE_LIST, + .cdw11 = TEST_CSI << 24, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_active_ns_list_csi( + TEST_FD, TEST_NSID, TEST_CSI, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_independent_identify_ns(void) +{ + struct nvme_id_independent_id_ns expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_CSI_INDEPENDENT_ID_NS, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + /* That's a mouthful! */ + err = nvme_identify_independent_identify_ns(TEST_FD, TEST_NSID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_allocated_ns_list(void) +{ + struct nvme_ns_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_ALLOCATED_NS_LIST, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_allocated_ns_list(TEST_FD, TEST_NSID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_allocated_ns(void) +{ + struct nvme_id_ns expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_ALLOCATED_NS, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_allocated_ns(TEST_FD, TEST_NSID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_nsid_ctrl_list(void) +{ + struct nvme_ctrl_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(expected_id), + .cdw10 = TEST_CNTID << 16 + | NVME_IDENTIFY_CNS_NS_CTRL_LIST, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_nsid_ctrl_list(TEST_FD, TEST_NSID, TEST_CNTID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_ctrl_list(void) +{ + struct nvme_ctrl_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = TEST_CNTID << 16 + | NVME_IDENTIFY_CNS_CTRL_LIST, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_ctrl_list(TEST_FD, TEST_CNTID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_primary_ctrl(void) +{ + struct nvme_primary_ctrl_cap expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = TEST_CNTID << 16 + | NVME_IDENTIFY_CNS_PRIMARY_CTRL_CAP, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_primary_ctrl(TEST_FD, TEST_CNTID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_secondary_ctrl_list(void) +{ + struct nvme_secondary_ctrl_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = TEST_CNTID << 16 + | NVME_IDENTIFY_CNS_SECONDARY_CTRL_LIST, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_secondary_ctrl_list(TEST_FD, TEST_CNTID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_ns_granularity(void) +{ + struct nvme_id_ns_granularity_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_NS_GRANULARITY, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_ns_granularity(TEST_FD, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_uuid(void) +{ + struct nvme_id_uuid_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_UUID_LIST, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_uuid(TEST_FD, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_domain_list(void) +{ + struct nvme_id_domain_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_DOMAIN_LIST, + .cdw11 = TEST_DOMID, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_domain_list(TEST_FD, TEST_DOMID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_endurance_group_list(void) +{ + struct nvme_id_endurance_group_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_ENDURANCE_GROUP_ID, + .cdw11 = TEST_ENDGID, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_endurance_group_list(TEST_FD, TEST_ENDGID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_allocated_ns_list_csi(void) +{ + struct nvme_ns_list expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(expected_id), + .cdw10 = NVME_IDENTIFY_CNS_CSI_ALLOCATED_NS_LIST, + .cdw11 = TEST_CSI << 24, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_allocated_ns_list_csi( + TEST_FD, TEST_NSID, TEST_CSI, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +static void test_iocs(void) +{ + struct nvme_id_iocs expected_id, id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(expected_id), + .cdw10 = TEST_CNTID << 16 + | NVME_IDENTIFY_CNS_COMMAND_SET_STRUCTURE, + .out_data = &expected_id, + }; + int err; + + arbitrary(&expected_id, sizeof(expected_id)); + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_iocs(TEST_FD, TEST_CNTID, &id); + end_mock_cmds(); + check(err == 0, "identify returned error %d, errno %m", err); + cmp(&id, &expected_id, sizeof(id), "incorrect identify data"); +} + +/* + * All identify functions tail-call nvme_identify(), + * so testing errors in any of them will do + */ + +static void test_status_code_error(void) +{ + struct nvme_id_nvmset_list id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .data_len = sizeof(id), + .cdw10 = NVME_IDENTIFY_CNS_NVMSET_LIST, + .cdw11 = TEST_NVMSETID, + .err = TEST_SC, + }; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_nvmset_list(TEST_FD, TEST_NVMSETID, &id); + end_mock_cmds(); + check(err == TEST_SC, "got error %d, expected %d", err, TEST_SC); +} + +static void test_kernel_error(void) +{ + struct nvme_id_ns id = {}; + struct mock_cmd mock_admin_cmd = { + .opcode = nvme_admin_identify, + .nsid = TEST_NSID, + .data_len = sizeof(id), + .cdw10 = NVME_IDENTIFY_CNS_NS, + .err = -EIO, + }; + int err; + + set_mock_admin_cmds(&mock_admin_cmd, 1); + err = nvme_identify_ns(TEST_FD, TEST_NSID, &id); + end_mock_cmds(); + check(err == -1, "got error %d, expected -1", err); + check(errno == EIO, "unexpected error %m"); +} + +static void run_test(const char *test_name, void (*test_fn)(void)) +{ + printf("Running test %s...", test_name); + fflush(stdout); + test_fn(); + puts(" OK"); +} + +#define RUN_TEST(name) run_test(#name, test_ ## name) + +int main(void) +{ + set_mock_fd(TEST_FD); + RUN_TEST(ns); + RUN_TEST(ctrl); + RUN_TEST(active_ns_list); + RUN_TEST(ns_descs); + RUN_TEST(nvmset_list); + RUN_TEST(ns_csi); + RUN_TEST(zns_identify_ns); + RUN_TEST(nvm_identify_ctrl); + RUN_TEST(zns_identify_ctrl); + RUN_TEST(active_ns_list_csi); + RUN_TEST(independent_identify_ns); + RUN_TEST(allocated_ns_list); + RUN_TEST(allocated_ns); + RUN_TEST(nsid_ctrl_list); + RUN_TEST(ctrl_list); + RUN_TEST(primary_ctrl); + RUN_TEST(secondary_ctrl_list); + RUN_TEST(ns_granularity); + RUN_TEST(uuid); + RUN_TEST(domain_list); + RUN_TEST(endurance_group_list); + RUN_TEST(allocated_ns_list_csi); + RUN_TEST(iocs); + RUN_TEST(status_code_error); + RUN_TEST(kernel_error); +} diff --git a/test/ioctl/meson.build b/test/ioctl/meson.build new file mode 100644 index 0000000..edbe6b3 --- /dev/null +++ b/test/ioctl/meson.build @@ -0,0 +1,32 @@ +mock_ioctl = library( + 'mock-ioctl', + ['mock.c', 'util.c'], +) + +discovery = executable( + 'test-discovery', + 'discovery.c', + dependencies: libnvme_dep, + include_directories: [incdir, internal_incdir], + link_with: mock_ioctl, +) + +test('discovery', discovery, env: ['LD_PRELOAD=' + mock_ioctl.full_path()]) + +features = executable( + 'test-features', + 'features.c', + dependencies: libnvme_dep, + link_with: mock_ioctl, +) + +test('features', features, env: ['LD_PRELOAD=' + mock_ioctl.full_path()]) + +identify = executable( + 'test-identify', + 'identify.c', + dependencies: libnvme_dep, + link_with: mock_ioctl, +) + +test('identify', identify, env: ['LD_PRELOAD=' + mock_ioctl.full_path()]) diff --git a/test/ioctl/mock.c b/test/ioctl/mock.c new file mode 100644 index 0000000..e917244 --- /dev/null +++ b/test/ioctl/mock.c @@ -0,0 +1,168 @@ +// SPDX-License-Identifier: LGPL-2.1-or-later + +#include "mock.h" + +#include +#include +#include +#include +#include + +#include "../../src/nvme/ioctl.h" +#include "util.h" + +struct mock_cmds { + const char *name; + const struct mock_cmd *cmds; + size_t remaining_cmds; +}; + +static int mock_fd = -1; +static struct mock_cmds mock_admin_cmds = {.name = "admin"}; +static struct mock_cmds mock_io_cmds = {.name = "IO"}; + +static void set_mock_cmds( + struct mock_cmds *mock_cmds, const struct mock_cmd *cmds, size_t len) +{ + mock_cmds->cmds = cmds; + mock_cmds->remaining_cmds = len; +} + +static void mock_cmds_done(const struct mock_cmds *mock_cmds) +{ + check(!mock_cmds->remaining_cmds, + "%zu %s commands not executed", + mock_cmds->remaining_cmds, mock_cmds->name); +} + +void set_mock_fd(int fd) +{ + mock_fd = fd; +} + +void set_mock_admin_cmds(const struct mock_cmd *cmds, size_t len) +{ + set_mock_cmds(&mock_admin_cmds, cmds, len); +} + +void set_mock_io_cmds(const struct mock_cmd *cmds, size_t len) +{ + set_mock_cmds(&mock_io_cmds, cmds, len); +} + +void end_mock_cmds(void) +{ + mock_cmds_done(&mock_admin_cmds); + mock_cmds_done(&mock_io_cmds); +} + +#define execute_ioctl(cmd, mock_cmd) ({ \ + check((cmd)->opcode == (mock_cmd)->opcode, \ + "got opcode %" PRIu8 ", expected %" PRIu8, \ + (cmd)->opcode, (mock_cmd)->opcode); \ + check((cmd)->flags == (mock_cmd)->flags, \ + "got flags %" PRIu8 ", expected %" PRIu8, \ + (cmd)->flags, (mock_cmd)->flags); \ + check((cmd)->nsid == (mock_cmd)->nsid, \ + "got nsid %" PRIu32 ", expected %" PRIu32, \ + (cmd)->nsid, (mock_cmd)->nsid); \ + check((cmd)->cdw2 == (mock_cmd)->cdw2, \ + "got cdw2 %" PRIu32 ", expected %" PRIu32, \ + (cmd)->cdw2, (mock_cmd)->cdw2); \ + check((cmd)->cdw3 == (mock_cmd)->cdw3, \ + "got cdw3 %" PRIu32 ", expected %" PRIu32, \ + (cmd)->cdw3, (mock_cmd)->cdw3); \ + check((cmd)->metadata_len == (mock_cmd)->metadata_len, \ + "got metadata_len %" PRIu32 ", expected %" PRIu32, \ + (cmd)->metadata_len, (mock_cmd)->metadata_len); \ + cmp((void const *)(uintptr_t)(cmd)->metadata, \ + (mock_cmd)->metadata, \ + (cmd)->metadata_len, \ + "incorrect metadata"); \ + __u32 data_len = (cmd)->data_len; \ + check(data_len == (mock_cmd)->data_len, \ + "got data_len %" PRIu32 ", expected %" PRIu32, \ + data_len, (mock_cmd)->data_len); \ + void *data = (void *)(uintptr_t)(cmd)->addr; \ + if ((mock_cmd)->in_data) { \ + cmp(data, (mock_cmd)->in_data, data_len, "incorrect data"); \ + } \ + check((cmd)->cdw10 == (mock_cmd)->cdw10, \ + "got cdw10 %" PRIu32 ", expected %" PRIu32, \ + (cmd)->cdw10, (mock_cmd)->cdw10); \ + check((cmd)->cdw11 == (mock_cmd)->cdw11, \ + "got cdw11 %" PRIu32 ", expected %" PRIu32, \ + (cmd)->cdw11, (mock_cmd)->cdw11); \ + check((cmd)->cdw12 == (mock_cmd)->cdw12, \ + "got cdw12 %" PRIu32 ", expected %" PRIu32, \ + (cmd)->cdw12, (mock_cmd)->cdw12); \ + check((cmd)->cdw13 == (mock_cmd)->cdw13, \ + "got cdw13 %" PRIu32 ", expected %" PRIu32, \ + (cmd)->cdw13, (mock_cmd)->cdw13); \ + check((cmd)->cdw14 == (mock_cmd)->cdw14, \ + "got cdw14 %" PRIu32 ", expected %" PRIu32, \ + (cmd)->cdw14, (mock_cmd)->cdw14); \ + check((cmd)->cdw15 == (mock_cmd)->cdw15, \ + "got cdw15 %" PRIu32 ", expected %" PRIu32, \ + (cmd)->cdw15, (mock_cmd)->cdw15); \ + check((cmd)->timeout_ms == (mock_cmd)->timeout_ms, \ + "got timeout_ms %" PRIu32 ", expected %" PRIu32, \ + (cmd)->timeout_ms, (mock_cmd)->timeout_ms); \ + (cmd)->result = (mock_cmd)->result; \ + if ((mock_cmd)->out_data) { \ + memcpy(data, (mock_cmd)->out_data, data_len); \ + } \ +}) + +int ioctl(int fd, unsigned long request, ...) +{ + struct mock_cmds *mock_cmds; + bool result64; + const struct mock_cmd *mock_cmd; + va_list args; + void *cmd; + + check(fd == mock_fd, "got fd %d, expected %d", fd, mock_fd); + switch (request) { + case NVME_IOCTL_ADMIN_CMD: + mock_cmds = &mock_admin_cmds; + result64 = false; + break; + case NVME_IOCTL_ADMIN64_CMD: + mock_cmds = &mock_admin_cmds; + result64 = true; + break; + case NVME_IOCTL_IO_CMD: + mock_cmds = &mock_io_cmds; + result64 = false; + break; + case NVME_IOCTL_IO64_CMD: + mock_cmds = &mock_io_cmds; + result64 = true; + break; + default: + fail("unexpected %s %lu", __func__, request); + } + check(mock_cmds->remaining_cmds, + "unexpected %s command", mock_cmds->name); + mock_cmd = mock_cmds->cmds++; + mock_cmds->remaining_cmds--; + + va_start(args, request); + cmd = va_arg(args, void *); + va_end(args); + if (result64) { + execute_ioctl((struct nvme_passthru_cmd64 *)cmd, mock_cmd); + } else { + check((uint32_t)mock_cmd->result == mock_cmd->result, + "expected 64-bit %s for result %" PRIu64, + __func__, mock_cmd->result); + execute_ioctl((struct nvme_passthru_cmd *)cmd, mock_cmd); + } + if (mock_cmd->err < 0) { + errno = -mock_cmd->err; + return -1; + } + + return mock_cmd->err; +} diff --git a/test/ioctl/mock.h b/test/ioctl/mock.h new file mode 100644 index 0000000..192eba8 --- /dev/null +++ b/test/ioctl/mock.h @@ -0,0 +1,104 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ + +#ifndef _LIBNVME_TEST_IOCTL_MOCK_H +#define _LIBNVME_TEST_IOCTL_MOCK_H + +#include +#include + +/** + * struct mock_cmd - a mock NVMe passthru ioctl() invocation + * @opcode: the expected `opcode` passed to ioctl() + * @flags: the expected `flags` passed to ioctl() + * @nsid: the expected `nsid` passed to ioctl() + * @cdw2: the expected `cdw2` passed to ioctl() + * @cdw3: the expected `cdw3` passed to ioctl() + * @metadata: the expected `metadata` of length `metadata_len` passed to ioctl() + * @in_data: the expected `addr` of length `data_len` passed to ioctl(). + * Set this to NULL to skip checking the data, + * for example if the command is in the read direction. + * @metadata_len: the expected `metadata_len` passed to ioctl() + * @data_len: the expected `data_len` passed to ioctl() + * @cdw10: the expected `cdw10` passed to ioctl() + * @cdw11: the expected `cdw11` passed to ioctl() + * @cdw12: the expected `cdw12` passed to ioctl() + * @cdw13: the expected `cdw13` passed to ioctl() + * @cdw14: the expected `cdw14` passed to ioctl() + * @cdw15: the expected `cdw15` passed to ioctl() + * @timeout_ms: the expected `timeout_ms` passed to ioctl() + * @out_data: if not NULL, `data_len` bytes to copy to the caller's `addr` + * @result: copied to the caller's `result`. + * If `result` doesn't fit in a u32, the ioctl() must be the 64-bit one. + * @err: If negative, ioctl() returns -1 and sets `errno` to `-err`. + * Otherwise, ioctl() returns `err`, representing a NVMe status code. + */ +struct mock_cmd { + uint8_t opcode; + uint8_t flags; + uint32_t nsid; + uint32_t cdw2; + uint32_t cdw3; + const void *metadata; + const void *in_data; + uint32_t metadata_len; + uint32_t data_len; + uint32_t cdw10; + uint32_t cdw11; + uint32_t cdw12; + uint32_t cdw13; + uint32_t cdw14; + uint32_t cdw15; + uint32_t timeout_ms; + const void *out_data; + uint64_t result; + int err; +}; + +/** + * set_mock_fd() - sets the expected file descriptor for NVMe passthru ioctls() + * @fd: file descriptor expected to be passed to ioctl() + */ +void set_mock_fd(int fd); + +/** + * set_mock_admin_cmds() - mocks NVMe admin passthru ioctl() invocations + * @cmds: pointer to start of the mock_cmd slice + * @len: length of the mock_cmd slice (number of ioctl() invocations) + * + * Provides a sequence of mocks for NVMe admin passthru ioctl() invocations. + * Each ioctl() consumes the next mock from the sequence. + * Its arguments are checked against the mock's expected arguments, + * aborting the process if unexpected arguments are passed. + * The mock results (return value, NVMe result and data) + * are returned from the ioctl(). + * + * Analogous to set_mock_io_cmds(), but for admin commands. + * Both admin and IO mocks can be active at the same time. + */ +void set_mock_admin_cmds(const struct mock_cmd *cmds, size_t len); + +/** + * set_mock_io_cmds() - mocks NVMe IO passthru ioctl() invocations + * @cmds: pointer to start of the mock_cmd slice + * @len: length of the mock_cmd slice (number of ioctl() invocations) + * + * Provides a sequence of mocks for NVMe IO passthru ioctl() invocations. + * Each ioctl() consumes the next mock from the sequence. + * Its arguments are checked against the mock's expected arguments, + * aborting the process if unexpected arguments are passed. + * The mock results (return value, NVMe result and data) + * are returned from the ioctl(). + * + * Analogous to set_mock_admin_cmds(), but for IO commands. + * Both admin and IO mocks can be active at the same time. + */ +void set_mock_io_cmds(const struct mock_cmd *cmds, size_t len); + +/** + * end_mock_cmds() - finishes mocking NVMe passthru ioctl() invocations + * + * Checks that all mock ioctl() invocations were performed. + */ +void end_mock_cmds(void); + +#endif /* #ifndef _LIBNVME_TEST_IOCTL_MOCK_H */ diff --git a/test/ioctl/util.c b/test/ioctl/util.c new file mode 100644 index 0000000..09c6e7f --- /dev/null +++ b/test/ioctl/util.c @@ -0,0 +1,65 @@ +// SPDX-License-Identifier: LGPL-2.1-or-later + +#include "util.h" + +#include +#include +#include +#include +#include + +static void hexdump(const uint8_t *buf, size_t len) +{ + size_t i = 0; + + if (!len) + return; + + for (;;) { + fprintf(stderr, "%02X", buf[i++]); + if (i >= len) + break; + + fputc(i % 16 > 0 ? ' ' : '\n', stderr); + } + fputc('\n', stderr); +} + +void fail(const char *fmt, ...) +{ + va_list args; + + va_start(args, fmt); + vfprintf(stderr, fmt, args); + va_end(args); + fputc('\n', stderr); + abort(); +} + +void cmp(const void *actual, const void *expected, size_t len, const char *msg) +{ + if (memcmp(actual, expected, len) == 0) + return; + + fputs(msg, stderr); + fputs("\nactual:\n", stderr); + hexdump(actual, len); + fputs("expected:\n", stderr); + hexdump(expected, len); + abort(); +} + +void arbitrary(void *buf_, size_t len) +{ + uint8_t *buf = buf_; + + while (len--) + *(buf++) = rand(); +} + +size_t arbitrary_range(size_t max) +{ + size_t value; + arbitrary(&value, sizeof(value)); + return value % max; +} diff --git a/test/ioctl/util.h b/test/ioctl/util.h new file mode 100644 index 0000000..aa86422 --- /dev/null +++ b/test/ioctl/util.h @@ -0,0 +1,19 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ + +#ifndef _LIBNVME_TEST_IOCTL_UTIL_H +#define _LIBNVME_TEST_IOCTL_UTIL_H + +#include +#include + +noreturn void fail(const char *fmt, ...) __attribute__((format(printf, 1, 2))); + +#define check(condition, fmt...) ((condition) || (fail(fmt), 0)) + +void cmp(const void *actual, const void *expected, size_t len, const char *msg); + +void arbitrary(void *buf, size_t len); + +size_t arbitrary_range(size_t max); + +#endif /* #ifndef _LIBNVME_TEST_IOCTL_UTIL_H */ diff --git a/test/meson.build b/test/meson.build index 49cd1ac..0c45879 100644 --- a/test/meson.build +++ b/test/meson.build @@ -67,14 +67,20 @@ uuid = executable( test('uuid', uuid) if conf.get('HAVE_NETDB') + mock_ifaddrs = library( + 'mock-ifaddrs', + ['mock-ifaddrs.c', ], + ) + tree = executable( 'tree', ['tree.c'], dependencies: libnvme_dep, - include_directories: [incdir, internal_incdir] + include_directories: [incdir, internal_incdir], + link_with: mock_ifaddrs, ) - test('tree', tree) + test('tree', tree, env: ['LD_PRELOAD=' + mock_ifaddrs.full_path()]) test_util = executable( 'test-util', @@ -84,4 +90,5 @@ if conf.get('HAVE_NETDB') test('Test util.c', test_util) endif +subdir('ioctl') subdir('nbft') diff --git a/test/mi-mctp.c b/test/mi-mctp.c index 6d83d42..1ba2ae8 100644 --- a/test/mi-mctp.c +++ b/test/mi-mctp.c @@ -293,6 +293,89 @@ static void test_mi_resp_err(nvme_mi_ep_t ep, struct test_peer *peer) assert(rc == 0x2); } +static void setup_unaligned_ctrl_list_resp(struct test_peer *peer) +{ + /* even number of controllers */ + peer->tx_buf[8] = 0x02; + peer->tx_buf[9] = 0x00; + + /* controller ID 1 */ + peer->tx_buf[10] = 0x01; + peer->tx_buf[11] = 0x00; + + /* controller ID 2 */ + peer->tx_buf[12] = 0x02; + peer->tx_buf[13] = 0x00; + + peer->tx_buf_len = 14; +} + +/* Will call through the xfer/submit API expecting a full-sized list (so + * resp->data_len is set to sizeof(list)), but the endpoint will return an + * unaligned short list. + */ +static void test_mi_resp_unaligned(nvme_mi_ep_t ep, struct test_peer *peer) +{ + struct nvme_ctrl_list list; + int rc; + + setup_unaligned_ctrl_list_resp(peer); + + memset(&list, 0, sizeof(list)); + + rc = nvme_mi_mi_read_mi_data_ctrl_list(ep, 0, &list); + assert(rc == 0); + + assert(le16_to_cpu(list.num) == 2); + assert(le16_to_cpu(list.identifier[0]) == 1); + assert(le16_to_cpu(list.identifier[1]) == 2); +} + +/* Will call through the xfer/submit API expecting an unaligned list, + * and get a response of exactly that size. + */ +static void test_mi_resp_unaligned_expected(nvme_mi_ep_t ep, + struct test_peer *peer) +{ + /* direct access to the raw submit() API */ + extern int nvme_mi_submit(nvme_mi_ep_t ep, struct nvme_mi_req *req, + struct nvme_mi_resp *resp); + struct nvme_mi_mi_resp_hdr resp_hdr; + struct nvme_mi_mi_req_hdr req_hdr; + struct nvme_ctrl_list list; + struct nvme_mi_resp resp; + struct nvme_mi_req req; + int rc; + + setup_unaligned_ctrl_list_resp(peer); + + memset(&list, 0, sizeof(list)); + + memset(&req_hdr, 0, sizeof(req_hdr)); + req_hdr.hdr.type = NVME_MI_MSGTYPE_NVME; + req_hdr.hdr.nmp = (NVME_MI_ROR_REQ << 7) | (NVME_MI_MT_MI << 3); + req_hdr.opcode = nvme_mi_mi_opcode_mi_data_read; + req_hdr.cdw0 = cpu_to_le32(nvme_mi_dtyp_ctrl_list << 24); + + memset(&req, 0, sizeof(req)); + req.hdr = &req_hdr.hdr; + req.hdr_len = sizeof(req_hdr); + + memset(&resp, 0, sizeof(resp)); + resp.hdr = &resp_hdr.hdr; + resp.hdr_len = sizeof(resp_hdr); + resp.data = &list; + resp.data_len = peer->tx_buf_len; + + rc = nvme_mi_submit(ep, &req, &resp); + assert(rc == 0); + assert(resp.data_len == 6); /* 2-byte length, 2*2 byte controller IDs */ + + assert(le16_to_cpu(list.num) == 2); + assert(le16_to_cpu(list.identifier[0]) == 1); + assert(le16_to_cpu(list.identifier[1]) == 2); +} + static void test_admin_resp_err(nvme_mi_ep_t ep, struct test_peer *peer) { struct nvme_id_ctrl id; @@ -340,30 +423,6 @@ static void test_admin_resp_sizes(nvme_mi_ep_t ep, struct test_peer *peer) nvme_mi_close_ctrl(ctrl); } -/* test: unaligned response sizes - should always report a transport error */ -static void test_admin_resp_sizes_unaligned(nvme_mi_ep_t ep, struct test_peer *peer) -{ - struct nvme_id_ctrl id; - nvme_mi_ctrl_t ctrl; - unsigned int i; - int rc; - - ctrl = nvme_mi_init_ctrl(ep, 1); - assert(ctrl); - - peer->tx_buf[4] = 0x02; /* internal error */ - - for (i = 8; i <= 4096 + 8; i++) { - peer->tx_buf_len = i; - if (!(i & 0x3)) - continue; - rc = nvme_mi_admin_identify_ctrl(ctrl, &id); - assert(rc < 0); - } - - nvme_mi_close_ctrl(ctrl); -} - /* test: timeout value passed to poll */ static int poll_fn_timeout_value(struct test_peer *peer, struct pollfd *fds, nfds_t nfds, int timeout) @@ -664,9 +723,10 @@ struct test { DEFINE_TEST(read_mi_data), DEFINE_TEST(poll_err), DEFINE_TEST(mi_resp_err), + DEFINE_TEST(mi_resp_unaligned), + DEFINE_TEST(mi_resp_unaligned_expected), DEFINE_TEST(admin_resp_err), DEFINE_TEST(admin_resp_sizes), - DEFINE_TEST(admin_resp_sizes_unaligned), DEFINE_TEST(poll_timeout_value), DEFINE_TEST(poll_timeout), DEFINE_TEST(mpr_mi), diff --git a/test/mi.c b/test/mi.c index 7f8e005..1f95db0 100644 --- a/test/mi.c +++ b/test/mi.c @@ -1245,7 +1245,6 @@ static int test_admin_id_secondary_ctrl_list_cb(struct nvme_mi_ep *ep, void *data) { __u16 cns, ctrlid; - __u32 nsid; __u8 *hdr; hdr = (__u8 *)req->hdr; @@ -1256,9 +1255,6 @@ static int test_admin_id_secondary_ctrl_list_cb(struct nvme_mi_ep *ep, cns = hdr[45] << 8 | hdr[44]; assert(cns == NVME_IDENTIFY_CNS_SECONDARY_CTRL_LIST); - nsid = hdr[11] << 24 | hdr[10] << 16 | hdr[9] << 8 | hdr[8]; - assert(nsid == 0x01020304); - ctrlid = hdr[47] << 8 | hdr[46]; assert(ctrlid == 5); @@ -1280,8 +1276,7 @@ static void test_admin_id_secondary_ctrl_list(struct nvme_mi_ep *ep) ctrl = nvme_mi_init_ctrl(ep, 5); assert(ctrl); - rc = nvme_mi_admin_identify_secondary_ctrl_list(ctrl, 0x01020304, - 5, &list); + rc = nvme_mi_admin_identify_secondary_ctrl_list(ctrl, 5, &list); assert(!rc); } diff --git a/test/mock-ifaddrs.c b/test/mock-ifaddrs.c new file mode 100644 index 0000000..87a2e50 --- /dev/null +++ b/test/mock-ifaddrs.c @@ -0,0 +1,123 @@ +// SPDX-License-Identifier: LGPL-2.1-or-later +/** + * This file is part of libnvme. + * Copyright (c) 2023 Martin Belanger, Dell Technologies Inc. + */ +#include +#include +#include +#include +#include +#include +#include +#include +#include + +struct ifaddrs_storage { + struct ifaddrs ifa; + union { + /* Reserve space for the biggest of the sockaddr types */ + struct sockaddr_in s4; + struct sockaddr_in6 s6; + } addr, netmask, broadaddr; + char name[IF_NAMESIZE + 1]; +}; + +static void init_entry(struct ifaddrs_storage *storage, + const char *ifname, + int family, + uint32_t addr1, + uint32_t addr2, + uint32_t addr3, + uint32_t addr4, + bool last) +{ + struct ifaddrs *p; + + p = &storage->ifa; + p->ifa_next = last ? NULL : &storage[1].ifa; + p->ifa_name = storage->name; + strcpy(p->ifa_name, ifname); + p->ifa_flags = 0; + + if (family == AF_INET) { + struct sockaddr_in *ipv4; + + ipv4 = &storage->addr.s4; + ipv4->sin_family = family; + ipv4->sin_port = 0; + ipv4->sin_addr.s_addr = htonl(addr1); + p->ifa_addr = (struct sockaddr *)ipv4; + + ipv4 = &storage->netmask.s4; + ipv4->sin_family = family; + ipv4->sin_port = 0; + ipv4->sin_addr.s_addr = 0xffffff00; + p->ifa_netmask = (struct sockaddr *)ipv4; + + ipv4 = &storage->broadaddr.s4; + ipv4->sin_family = family; + ipv4->sin_port = 0; + ipv4->sin_addr.s_addr = 0; + p->ifa_broadaddr = (struct sockaddr *)ipv4;; + } else { + struct sockaddr_in6 *ipv6; + + ipv6 = &storage->addr.s6; + ipv6->sin6_family = family; + ipv6->sin6_port = 0; + ipv6->sin6_flowinfo = 0; + ipv6->sin6_addr.s6_addr32[0] = htonl(addr1); + ipv6->sin6_addr.s6_addr32[1] = htonl(addr2); + ipv6->sin6_addr.s6_addr32[2] = htonl(addr3); + ipv6->sin6_addr.s6_addr32[3] = htonl(addr4); + ipv6->sin6_scope_id = 0; + p->ifa_addr = (struct sockaddr *)ipv6; + + ipv6 = &storage->netmask.s6; + ipv6->sin6_family = family; + ipv6->sin6_port = 0; + ipv6->sin6_flowinfo = 0; + ipv6->sin6_addr.s6_addr32[0] = 0xffffffff; + ipv6->sin6_addr.s6_addr32[1] = 0xffffffff; + ipv6->sin6_addr.s6_addr32[2] = 0xffffffff; + ipv6->sin6_addr.s6_addr32[3] = 0; + ipv6->sin6_scope_id = 0; + p->ifa_netmask = (struct sockaddr *)ipv6; + + ipv6 = &storage->broadaddr.s6; + ipv6->sin6_family = family; + ipv6->sin6_port = 0; + ipv6->sin6_flowinfo = 0; + ipv6->sin6_addr.s6_addr32[0] = 0; + ipv6->sin6_addr.s6_addr32[1] = 0; + ipv6->sin6_addr.s6_addr32[2] = 0; + ipv6->sin6_addr.s6_addr32[3] = 0; + ipv6->sin6_scope_id = 0; + p->ifa_broadaddr = (struct sockaddr *)ipv6; + } + + p->ifa_data = NULL; +} + +int getifaddrs(struct ifaddrs **ifap) { + struct ifaddrs_storage *storage; + + /* Allocate memory for 4 interfaces */ + storage = (struct ifaddrs_storage *)calloc(4, sizeof(struct ifaddrs_storage)); + *ifap = &storage[0].ifa; + + init_entry(&storage[0], "eth0", AF_INET, 0xc0a80114, 0, 0, 0, false); /* 192.168.1.20 */ + init_entry(&storage[1], "eth0", AF_INET6, 0xfe800000, 0, 0, 0xdeadbeef, false); /* fe80::dead:beef */ + + /* Loopback interface */ + init_entry(&storage[2], "lo", AF_INET, 0x7f000001, 0, 0, 0, false); /* 127.0.0.1 */ + init_entry(&storage[3], "lo", AF_INET6, 0, 0, 0, 1, true); /* ::1 */ + + return 0; +} + +void freeifaddrs(struct ifaddrs *ifa) { + free(ifa); +} + diff --git a/test/test.c b/test/test.c index 2f24e1e..23036bb 100644 --- a/test/test.c +++ b/test/test.c @@ -16,6 +16,7 @@ * somewhere. */ #include +#include #include #include #include @@ -112,7 +113,7 @@ static int test_ctrl(nvme_ctrl_t c) printf(" PASSED: Identify Primary\n"); else printf(" ERROR: Identify Primary:%x\n", ret); - ret = nvme_identify_secondary_ctrl_list(fd, 1, 0, &sec); + ret = nvme_identify_secondary_ctrl_list(fd, 0, &sec); if (!ret) printf(" PASSED: Identify Secondary\n"); else @@ -197,7 +198,7 @@ static int test_ctrl(nvme_ctrl_t c) printf(" Temperature Threshold:%x\n", result); else if (ret > 0) printf(" ERROR: Temperature Threshold:%x\n", ret); - ret = nvme_get_features_err_recovery(fd, sel, &result); + ret = nvme_get_features_err_recovery2(fd, sel, 0, &result); if (!ret) printf(" Error Recovery:%x\n", result); else if (ret > 0) @@ -257,12 +258,12 @@ static int test_ctrl(nvme_ctrl_t c) printf(" SW Progress Marker:%x\n", result); else if (ret > 0) printf(" ERROR: Sanitize:%x\n", ret); - ret = nvme_get_features_resv_mask(fd, sel, &result); + ret = nvme_get_features_resv_mask2(fd, sel, 0, &result); if (!ret) printf(" Reservation Mask:%x\n", result); else if (ret > 0) printf(" ERROR: Reservation Mask:%x\n", ret); - ret = nvme_get_features_resv_persist(fd, sel, &result); + ret = nvme_get_features_resv_persist2(fd, sel, 0, &result); if (!ret) printf(" Reservation Persistence:%x\n", result); else if (ret > 0) @@ -274,7 +275,7 @@ static int test_namespace(nvme_ns_t n) { int ret, nsid = nvme_ns_get_nsid(n), fd = nvme_ns_get_fd(n); struct nvme_id_ns ns = { 0 }, allocated = { 0 }; - struct nvme_ns_id_desc descs = { 0 }; + struct nvme_ns_id_desc *descs; __u32 result = 0; __u8 flbas; @@ -292,11 +293,16 @@ static int test_namespace(nvme_ns_t n) printf(" Identify allocated ns\n"); else printf(" ERROR: Identify allocated ns:%x\n", ret); - ret = nvme_identify_ns_descs(fd, nsid, &descs); + descs = malloc(NVME_IDENTIFY_DATA_SIZE); + if (!descs) + return -1; + + ret = nvme_identify_ns_descs(fd, nsid, descs); if (!ret) printf(" Identify NS Descriptors\n"); else printf(" ERROR: Identify NS Descriptors:%x\n", ret); + free(descs); ret = nvme_get_features_write_protect(fd, nsid, NVME_GET_FEATURES_SEL_CURRENT, &result); if (!ret) diff --git a/test/tree.c b/test/tree.c index b3baac8..c9370f9 100644 --- a/test/tree.c +++ b/test/tree.c @@ -6,10 +6,14 @@ #include #include +#include +#include +#include #include #include +#include struct test_data { /* input data */ @@ -29,6 +33,8 @@ struct test_data { #define DEFAULT_SUBSYSNAME "subsysname" #define DEFAULT_SUBSYSNQN "subsysnqn" +#define SRC_ADDR4 "192.168.56.100" +#define SRC_ADDR6 "1234:5678:abcd:EF01:1234:5678:abcd:EF01" struct test_data test_data[] = { { DEFAULT_SUBSYSNAME, DEFAULT_SUBSYSNQN, "tcp", "192.168.1.1", "192.168.1.20", NULL, "4420" }, @@ -65,8 +71,10 @@ static void show_ctrl(nvme_ctrl_t c) if (d) printf("ctrl%d ", d->ctrl_id); + else + printf(" "); - printf("0x%p: %s %s %s %s %s\n", + printf("0x%p: %s %s %s %s %s ", c, nvme_ctrl_get_transport(c), nvme_ctrl_get_traddr(c), @@ -75,6 +83,41 @@ static void show_ctrl(nvme_ctrl_t c) nvme_ctrl_get_trsvcid(c)); } +static bool match_ctrl(struct test_data *d, nvme_ctrl_t c) +{ + bool pass = true; + const char *trsvid, *host_traddr, *host_iface; + + if (d->c != c) + pass = false; + + if (strcmp(d->transport, nvme_ctrl_get_transport(d->c))) + pass = false; + + if (strcmp(d->traddr, nvme_ctrl_get_traddr(d->c))) + pass = false; + + + host_traddr = nvme_ctrl_get_host_traddr(c); + if (d->host_traddr && + (!host_traddr || strcmp(d->host_traddr, host_traddr))) + pass = false; + + host_iface = nvme_ctrl_get_host_iface(c); + if (d->host_iface && + (!host_iface || strcmp(d->host_iface, host_iface))) + pass = false; + + trsvid = nvme_ctrl_get_trsvcid(c); + if (d->trsvcid && + (!trsvid || strcmp(d->trsvcid, trsvid))) + pass = false; + + printf("[%s]", pass? "PASS" : "FAILED"); + + return pass; +} + static nvme_root_t create_tree() { nvme_root_t r; @@ -97,14 +140,10 @@ static nvme_root_t create_tree() assert(d->c); d->ctrl_id = i; - assert(!strcmp(d->transport, nvme_ctrl_get_transport(d->c))); - assert(!strcmp(d->traddr, nvme_ctrl_get_traddr(d->c))); - assert(!d->host_traddr || !strcmp(d->host_traddr, nvme_ctrl_get_host_traddr(d->c))); - assert(!d->host_iface || !strcmp(d->host_iface, nvme_ctrl_get_host_iface(d->c))); - assert(!d->trsvcid || !strcmp(d->trsvcid, nvme_ctrl_get_trsvcid(d->c))); - printf(" "); show_ctrl(d->c); + match_ctrl(d, d->c); + printf("\n"); } printf("\n"); @@ -118,22 +157,76 @@ static unsigned int count_entries(nvme_root_t r) nvme_ctrl_t c; unsigned int i = 0; - nvme_for_each_host(r, h) { - nvme_for_each_subsystem(h, s) { - nvme_subsystem_for_each_ctrl(s, c) { + nvme_for_each_host(r, h) + nvme_for_each_subsystem(h, s) + nvme_subsystem_for_each_ctrl(s, c) i++; - } - } - } return i; } -static void ctrl_lookups(nvme_root_t r) +static bool tcp_ctrl_lookup(nvme_subsystem_t s, struct test_data *d) +{ + nvme_ctrl_t c; + bool pass = true; + + c = nvme_lookup_ctrl(s, d->transport, d->traddr, NULL, + NULL, d->trsvcid, NULL); + printf("%10s %12s %10s -> ", d->trsvcid, "", ""); + show_ctrl(c); + pass &= match_ctrl(d, c); + printf("\n"); + + if (d->host_traddr) { + c = nvme_lookup_ctrl(s, d->transport, d->traddr, d->host_traddr, + NULL, d->trsvcid, NULL); + printf("%10s %12s %10s -> ", d->trsvcid, d->host_traddr, ""); + show_ctrl(c); + pass &= match_ctrl(d, c); + printf("\n"); + } + + if (d->host_iface) { + c = nvme_lookup_ctrl(s, d->transport, d->traddr, NULL, + d->host_iface, d->trsvcid, NULL); + printf("%10s %12s %10s -> ", d->trsvcid, "", d->host_iface); + show_ctrl(c); + pass &= match_ctrl(d, c); + printf("\n"); + } + + if (d->host_iface && d->traddr) { + c = nvme_lookup_ctrl(s, d->transport, d->traddr, d->host_traddr, + d->host_iface, d->trsvcid, NULL); + printf("%10s %12s %10s -> ", d->trsvcid, d->host_traddr, d->host_iface); + show_ctrl(c); + pass &= match_ctrl(d, c); + printf("\n"); + } + + return pass; +} + +static bool default_ctrl_lookup(nvme_subsystem_t s, struct test_data *d) +{ + nvme_ctrl_t c; + bool pass = true; + + c = nvme_lookup_ctrl(s, d->transport, d->traddr, d->host_traddr, + NULL, NULL, NULL); + printf("%10s %12s %10s -> ", "", "", ""); + show_ctrl(c); + pass &= match_ctrl(d, c); + printf("\n"); + + return pass; +} + +static bool ctrl_lookups(nvme_root_t r) { nvme_host_t h; nvme_subsystem_t s; - nvme_ctrl_t c; + bool pass = true; h = nvme_first_host(r); s = nvme_lookup_subsystem(h, DEFAULT_SUBSYSNAME, DEFAULT_SUBSYSNQN); @@ -142,122 +235,950 @@ static void ctrl_lookups(nvme_root_t r) for (int i = 0; i < ARRAY_SIZE(test_data); i++) { struct test_data *d = &test_data[i]; - printf("%10s %10s ", "", ""); + printf("%10s %12s %10s ", "", "", ""); show_ctrl(d->c); - c = nvme_lookup_ctrl(s, d->transport, d->traddr, d->host_traddr, - NULL, NULL, NULL); - printf("%10s %10s -> ", "-", "-"); - show_ctrl(c); + printf("\n"); - assert(!strcmp(d->transport, nvme_ctrl_get_transport(c))); - assert(!strcmp(d->traddr, nvme_ctrl_get_traddr(c))); - assert(!strcmp(d->host_traddr, nvme_ctrl_get_host_traddr(c))); - - if (d->host_iface) { - c = nvme_lookup_ctrl(s, d->transport, d->traddr, d->host_traddr, - d->host_iface, NULL, NULL); - printf("%10s %10s -> ", d->host_iface, "-"); - show_ctrl(c); - - assert(!strcmp(d->transport, nvme_ctrl_get_transport(c))); - assert(!strcmp(d->traddr, nvme_ctrl_get_traddr(c))); - assert(!strcmp(d->host_traddr, nvme_ctrl_get_host_traddr(c))); - assert(!strcmp(d->host_iface, nvme_ctrl_get_host_iface(c))); - } - - if (d->trsvcid) { - c = nvme_lookup_ctrl(s, d->transport, d->traddr, d->host_traddr, - NULL, d->trsvcid, NULL); - printf("%10s %10s -> ", "-", d->trsvcid); - show_ctrl(c); - - assert(!strcmp(d->transport, nvme_ctrl_get_transport(c))); - assert(!strcmp(d->traddr, nvme_ctrl_get_traddr(c))); - assert(!strcmp(d->host_traddr, nvme_ctrl_get_host_traddr(c))); - assert(!strcmp(d->trsvcid, nvme_ctrl_get_trsvcid(c))); - } - - if (d->host_iface && d->trsvcid) { - c = nvme_lookup_ctrl(s, d->transport, d->traddr, d->host_traddr, - d->host_iface, d->trsvcid, NULL); - printf("%10s %10s -> ", d->host_iface, d->trsvcid); - show_ctrl(c); - - assert(!strcmp(d->transport, nvme_ctrl_get_transport(c))); - assert(!strcmp(d->traddr, nvme_ctrl_get_traddr(c))); - assert(!strcmp(d->host_traddr, nvme_ctrl_get_host_traddr(c))); - assert(!strcmp(d->trsvcid, nvme_ctrl_get_trsvcid(c))); - assert(!strcmp(d->host_iface, nvme_ctrl_get_host_iface(c))); - } + if (!strcmp("tcp", d->transport)) + pass &= tcp_ctrl_lookup(s, d); + else + pass &= default_ctrl_lookup(s, d); printf("\n"); } + + return pass; } -static void test_lookup_1(void) +static bool test_lookup(void) { nvme_root_t r; + bool pass; - printf("test_lookup_1:\n"); + printf("test_lookup:\n"); r = create_tree(); - assert(count_entries(r) == ARRAY_SIZE(test_data)); - ctrl_lookups(r); + pass = count_entries(r) == ARRAY_SIZE(test_data); + pass &= ctrl_lookups(r); nvme_free_tree(r); + + return pass; } -static void test_lookup_2(void) +static bool test_src_addr() { + bool pass = true; nvme_root_t r; - nvme_subsystem_t s; nvme_host_t h; - nvme_ctrl_t c1, c2, c3, c4; + nvme_ctrl_t c; + nvme_subsystem_t s; + char *src_addr, buffer[100]; /* big enough for IPv6 max length */ - printf("test_lookup_2:\n"); + printf("\n" + "test_src_addr:\n"); r = nvme_create_root(stdout, LOG_DEBUG); assert(r); + h = nvme_default_host(r); assert(h); s = nvme_lookup_subsystem(h, DEFAULT_SUBSYSNAME, DEFAULT_SUBSYSNQN); assert(s); - assert(nvme_lookup_ctrl(s, "tcp", "192.168.2.1", "192.168.2.20", - "eth0", "4420", NULL)); + c = nvme_lookup_ctrl(s, "tcp", "192.168.56.1", NULL, NULL, "8009", NULL); + assert(c); - c1 = nvme_lookup_ctrl(s, "tcp", "192.168.1.1", "192.168.1.20", - NULL, NULL, NULL); - assert(c1); - printf("%10s %10s ", "", ""); - show_ctrl(c1); + c->address = NULL; + printf(" - Test c->address = NULL : src_addr = NULL "); + src_addr = nvme_ctrl_get_src_addr(c, buffer, sizeof(buffer)); + if (src_addr != NULL) { + printf("[FAIL]\n"); + fprintf(stderr, + "nvme_ctrl_get_src_addr() c->address=NULL should return src_addr=NULL\n"); + pass = false; + } else { + printf("[PASS]\n"); + } - c2 = nvme_lookup_ctrl(s, "tcp", "192.168.1.1", "192.168.1.20", - "eth0", NULL, NULL); - assert(c1 == c2); - printf("%10s %10s ", "eth0", "-"); - show_ctrl(c2); + c->address = ""; + printf(" - Test c->address = \"\" : src_addr = NULL "); + src_addr = nvme_ctrl_get_src_addr(c, buffer, sizeof(buffer)); + if (src_addr != NULL) { + printf("[FAIL]\n"); + fprintf(stderr, + "nvme_ctrl_get_src_addr() c->address="" should return src_addr=NULL\n"); + pass = false; + } else { + printf("[PASS]\n"); + } - c3 = nvme_lookup_ctrl(s, "tcp", "192.168.1.1", "192.168.1.20", - NULL, "4420", NULL); - assert(c1 == c3); - printf("%10s %10s ", "-", "4420"); - show_ctrl(c3); + c->address = "traddr=192.168.56.1,trsvcid=8009"; + printf(" - Test c->address = \"%s\" : src_addr = NULL ", c->address); + src_addr = nvme_ctrl_get_src_addr(c, buffer, sizeof(buffer)); + if (src_addr != NULL) { + printf("[FAIL]\n"); + fprintf(stderr, + "nvme_ctrl_get_src_addr() c->address=%s should return src_addr=NULL\n", + c->address); + pass = false; + } else { + printf("[PASS]\n"); + } - c4 = nvme_lookup_ctrl(s, "tcp", "192.168.1.1", "192.168.1.20", - "eth0", "4420", NULL); - assert(c1 == c4); - printf("%10s %10s ", "eth0", "4420"); - show_ctrl(c4); + c->address = "traddr=192.168.56.1,trsvcid=8009,src_addr=" SRC_ADDR4; + printf(" - Test c->address = \"%s\" : src_addr = \"" SRC_ADDR4 "\" ", c->address); + src_addr = nvme_ctrl_get_src_addr(c, buffer, sizeof(buffer)); + if (!src_addr || strcmp(src_addr, SRC_ADDR4)) { + printf("[FAIL]\n"); + fprintf(stderr, + "nvme_ctrl_get_src_addr() c->address=%s should return src_addr=" SRC_ADDR4 "\n", + c->address); + pass = false; + } else { + printf("[PASS]\n"); + } + + c->address = "traddr=192.168.56.1,src_addr=" SRC_ADDR4 ",trsvcid=8009"; + printf(" - Test c->address = \"%s\" : src_addr = \"" SRC_ADDR4 "\" ", c->address); + src_addr = nvme_ctrl_get_src_addr(c, buffer, sizeof(buffer)); + if (!src_addr || strcmp(src_addr, SRC_ADDR4)) { + printf("[FAIL]\n"); + fprintf(stderr, + "nvme_ctrl_get_src_addr() c->address=%s should return src_addr=" SRC_ADDR4 "\n", + c->address); + pass = false; + } else { + printf("[PASS]\n"); + } + + c->address = "traddr=1234::abcd,trsvcid=8009,src_addr=" SRC_ADDR6; + printf(" - Test c->address = \"%s\" : src_addr = \"" SRC_ADDR6 "\" ", c->address); + src_addr = nvme_ctrl_get_src_addr(c, buffer, sizeof(buffer)); + if (!src_addr || strcmp(src_addr, SRC_ADDR6)) { + printf("[FAIL]\n"); + fprintf(stderr, + "nvme_ctrl_get_src_addr() c->address=%s should return src_addr=" SRC_ADDR6 "\n", + c->address); + pass = false; + } else { + printf("[PASS]\n"); + } + + c->address = "traddr=1234::abcd,src_addr=" SRC_ADDR6 ",trsvcid=8009"; + printf(" - Test c->address = \"%s\" : src_addr = \"" SRC_ADDR6 "\" ", c->address); + src_addr = nvme_ctrl_get_src_addr(c, buffer, sizeof(buffer)); + if (!src_addr || strcmp(src_addr, SRC_ADDR6)) { + printf("[FAIL]\n"); + fprintf(stderr, + "nvme_ctrl_get_src_addr() c->address=%s should return src_addr=" SRC_ADDR6 "\n", + c->address); + pass = false; + } else { + printf("[PASS]\n"); + } + + c->address = "traddr=1234::abcd,trsvcid=8009,src_addr=" SRC_ADDR6 "%scope"; + printf(" - Test c->address = \"%s\" : src_addr = \"" SRC_ADDR6 "\" ", c->address); + src_addr = nvme_ctrl_get_src_addr(c, buffer, sizeof(buffer)); + if (!src_addr || strcmp(src_addr, SRC_ADDR6)) { + printf("[FAIL]\n"); + fprintf(stderr, + "nvme_ctrl_get_src_addr() c->address=%s should return src_addr=" SRC_ADDR6 "\n", + c->address); + pass = false; + } else { + printf("[PASS]\n"); + } + + c->address = "traddr=1234::abcd,src_addr=" SRC_ADDR6 "%scope,trsvcid=8009"; + printf(" - Test c->address = \"%s\" : src_addr = \"" SRC_ADDR6 "\" ", c->address); + src_addr = nvme_ctrl_get_src_addr(c, buffer, sizeof(buffer)); + if (!src_addr || strcmp(src_addr, SRC_ADDR6)) { + printf("[FAIL]\n"); + fprintf(stderr, + "nvme_ctrl_get_src_addr() c->address=%s should return src_addr=" SRC_ADDR6 "\n", + c->address); + pass = false; + } else { + printf("[PASS]\n"); + } + + c->address = NULL; /* Needed to avoid freeing non-malloced memory (see above) */ nvme_free_tree(r); + + return pass; } +struct ctrl_args { + const char *transport; + const char *traddr; + const char *trsvcid; + const char *host_traddr; + const char *host_iface; + const char *address; + const char *subsysnqn; +}; + +static void set_ctrl_args(struct ctrl_args *args, + const char *transport, + const char *traddr, + const char *trsvcid, + const char *host_traddr, + const char *host_iface, + const char *address, + const char *subsysnqn) +{ + args->transport = transport; + args->traddr = traddr; + args->trsvcid = trsvcid; + args->host_traddr = host_traddr; + args->host_iface = host_iface; + args->address = address; + args->subsysnqn = subsysnqn; +} + +static bool ctrl_match(const char *tag, + int reference_id, + int candidate_id, + struct ctrl_args *reference, + struct ctrl_args *candidate, + bool should_match) +{ + nvme_root_t r; + nvme_host_t h; + nvme_ctrl_t reference_ctrl; /* Existing controller (from sysfs) */ + nvme_ctrl_t candidate_ctrl; + nvme_ctrl_t found_ctrl; + nvme_subsystem_t s; + + r = nvme_create_root(stdout, LOG_INFO); + assert(r); + + h = nvme_default_host(r); + assert(h); + + s = nvme_lookup_subsystem(h, DEFAULT_SUBSYSNAME, reference->subsysnqn ? reference->subsysnqn : DEFAULT_SUBSYSNQN); + assert(s); + + reference_ctrl = nvme_lookup_ctrl(s, reference->transport, reference->traddr, + reference->host_traddr, reference->host_iface, + reference->trsvcid, NULL); + assert(reference_ctrl); + reference_ctrl->name = "nvme1"; /* fake the device name */ + if (reference->address) { + reference_ctrl->address = (char *)reference->address; + } + + /* nvme_ctrl_find() MUST BE RUN BEFORE nvme_lookup_ctrl() */ + found_ctrl = nvme_ctrl_find(s, candidate->transport, candidate->traddr, + candidate->trsvcid, candidate->subsysnqn, + candidate->host_traddr, + candidate->host_iface); + + candidate_ctrl = nvme_lookup_ctrl(s, candidate->transport, candidate->traddr, + candidate->host_traddr, candidate->host_iface, + candidate->trsvcid, NULL); + + if (should_match) { + if (candidate_ctrl != reference_ctrl) { + printf("%s-%d-%d: Candidate (%s, %s, %s, %s, %s, %s) failed to match (%s, %s, %s, %s, %s, %s, %s)\n", + tag, reference_id, candidate_id, + candidate->transport, candidate->traddr, candidate->trsvcid, + candidate->subsysnqn, candidate->host_traddr, candidate->host_iface, + reference->transport, reference->traddr, reference->trsvcid, reference->subsysnqn, + reference->host_traddr, reference->host_iface, reference->address); + return false; + } + + if (!found_ctrl) { + printf("%s-%d-%d: Candidate (%s, %s, %s, %s, %s, %s) failed to find controller\n", + tag, reference_id, candidate_id, + candidate->transport, candidate->traddr, candidate->trsvcid, + candidate->subsysnqn, candidate->host_traddr, candidate->host_iface); + return false; + } + } else { + if (candidate_ctrl == reference_ctrl) { + printf("%s-%d-%d: Candidate (%s, %s, %s, %s, %s, %s) should not match (%s, %s, %s, %s, %s, %s, %s)\n", + tag, reference_id, candidate_id, + candidate->transport, candidate->traddr, candidate->trsvcid, + candidate->subsysnqn, candidate->host_traddr, candidate->host_iface, + reference->transport, reference->traddr, reference->trsvcid, reference->subsysnqn, + reference->host_traddr, reference->host_iface, reference->address); + return false; + } + + if (found_ctrl) { + printf("%s-%d-%d: Candidate (%s, %s, %s, %s, %s, %s) should not have found controller. found_ctrl=%p reference=%p\n", + tag, reference_id, candidate_id, + candidate->transport, candidate->traddr, candidate->trsvcid, candidate->subsysnqn, + candidate->host_traddr, candidate->host_iface, found_ctrl, reference_ctrl); + return false; + } + } + + /* Set the faked data back to NULL before freeing the tree */ + reference_ctrl->name = NULL; + reference_ctrl->address = NULL; + + nvme_free_tree(r); + + return true; +} + +/** + * test_ctrl_match_fc - Test that we can look up FC controllers + * + * @return true when all tests have passed. false otherwise. + */ +static bool test_ctrl_match_fc(void) +{ + bool pass = true; + struct ctrl_args reference = {0}; + struct ctrl_args candidate = {0}; + + printf("test_ctrl_match_fc:\n"); + + /*******************************************************************/ + /* Reference ID 1 */ + set_ctrl_args(&reference, "fc", "21:00:00:e0:8b:05:05:01", "4420", "21:00:00:e0:8b:05:05:20", NULL, NULL, NULL); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "4420", "21:00:00:e0:8b:05:05:20", NULL, NULL, NULL); + pass &= ctrl_match("FC", 1, 0, &reference, &candidate, true); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "4420", NULL, NULL, NULL, NULL); + pass &= ctrl_match("FC", 1, 1, &reference, &candidate, true); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("FC", 1, 2, &reference, &candidate, true); + + set_ctrl_args(&candidate, "fc", "192.168.2.2", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("FC", 1, 3, &reference, &candidate, false); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("FC", 1, 4, &reference, &candidate, false); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "4420", "21:00:00:e0:8b:05:05:21", NULL, NULL, NULL); + pass &= ctrl_match("FC", 1, 5, &reference, &candidate, false); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "8009", NULL, "", NULL, NULL); + pass &= ctrl_match("FC", 1, 6, &reference, &candidate, false); + + + /*******************************************************************/ + /* Reference ID 2 */ + set_ctrl_args(&reference, "fc", "21:00:00:e0:8b:05:05:01", "4420", NULL, NULL, NULL, NULL); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "4420", "21:00:00:e0:8b:05:05:20", NULL, NULL, NULL); + pass &= ctrl_match("FC", 2, 0, &reference, &candidate, true); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "4420", NULL, NULL, NULL, NULL); + pass &= ctrl_match("FC", 2, 1, &reference, &candidate, true); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("FC", 2, 2, &reference, &candidate, true); + + set_ctrl_args(&candidate, "fc", "192.168.2.2", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("FC", 2, 3, &reference, &candidate, false); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("FC", 2, 4, &reference, &candidate, false); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "8009", NULL, "", NULL, NULL); + pass &= ctrl_match("FC", 2, 5, &reference, &candidate, false); + + + /*******************************************************************/ + /* Reference ID 3 */ + set_ctrl_args(&reference, "fc", "21:00:00:e0:8b:05:05:01", "4420", NULL, "eth0", NULL, NULL); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "4420", "21:00:00:e0:8b:05:05:20", NULL, NULL, NULL); + pass &= ctrl_match("FC", 3, 0, &reference, &candidate, true); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "4420", NULL, NULL, NULL, NULL); + pass &= ctrl_match("FC", 3, 1, &reference, &candidate, true); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("FC", 3, 2, &reference, &candidate, true); + + set_ctrl_args(&candidate, "fc", "192.168.2.2", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("FC", 3, 3, &reference, &candidate, false); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("FC", 3, 4, &reference, &candidate, false); + + set_ctrl_args(&candidate, "fc", "21:00:00:e0:8b:05:05:01", "8009", NULL, "", NULL, NULL); + pass &= ctrl_match("FC", 3, 5, &reference, &candidate, false); + + return pass; +} + +/** + * test_ctrl_match_rdma - Test that we can look up RDMA controllers + * + * @return true when all tests have passed. false otherwise. + */ +static bool test_ctrl_match_rdma(void) +{ + bool pass = true; + struct ctrl_args reference = {0}; + struct ctrl_args candidate = {0}; + + printf("test_ctrl_match_rdma:\n"); + + /*******************************************************************/ + /* Reference ID 1 */ + set_ctrl_args(&reference, "rdma", "192.168.2.1", "4420", "192.168.1.20", NULL, NULL, NULL); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "4420", "192.168.1.20", NULL, NULL, NULL); + pass &= ctrl_match("RDMA", 1, 0, &reference, &candidate, true); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "4420", NULL, NULL, NULL, NULL); + pass &= ctrl_match("RDMA", 1, 1, &reference, &candidate, true); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("RDMA", 1, 2, &reference, &candidate, true); + + set_ctrl_args(&candidate, "rdma", "192.168.2.2", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("RDMA", 1, 3, &reference, &candidate, false); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("RDMA", 1, 4, &reference, &candidate, false); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "4420", "192.168.1.21", NULL, NULL, NULL); + pass &= ctrl_match("RDMA", 1, 5, &reference, &candidate, false); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "8009", NULL, "", NULL, NULL); + pass &= ctrl_match("RDMA", 1, 6, &reference, &candidate, false); + + + /*******************************************************************/ + /* Reference ID 2 */ + set_ctrl_args(&reference, "rdma", "192.168.2.1", "4420", NULL, NULL, NULL, NULL); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "4420", "192.168.1.20", NULL, NULL, NULL); + pass &= ctrl_match("RDMA", 2, 0, &reference, &candidate, true); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "4420", NULL, NULL, NULL, NULL); + pass &= ctrl_match("RDMA", 2, 1, &reference, &candidate, true); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("RDMA", 2, 2, &reference, &candidate, true); + + set_ctrl_args(&candidate, "rdma", "192.168.2.2", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("RDMA", 2, 3, &reference, &candidate, false); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("RDMA", 2, 4, &reference, &candidate, false); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "8009", NULL, "", NULL, NULL); + pass &= ctrl_match("RDMA", 2, 5, &reference, &candidate, false); + + + /*******************************************************************/ + /* Reference ID 3 */ + set_ctrl_args(&reference, "rdma", "192.168.2.1", "4420", NULL, "eth0", NULL, NULL); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "4420", "192.168.1.20", NULL, NULL, NULL); + pass &= ctrl_match("RDMA", 3, 0, &reference, &candidate, true); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "4420", NULL, NULL, NULL, NULL); + pass &= ctrl_match("RDMA", 3, 1, &reference, &candidate, true); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("RDMA", 3, 2, &reference, &candidate, true); + + set_ctrl_args(&candidate, "rdma", "192.168.2.2", "4420", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("RDMA", 3, 3, &reference, &candidate, false); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("RDMA", 3, 4, &reference, &candidate, false); + + set_ctrl_args(&candidate, "rdma", "192.168.2.1", "8009", NULL, "", NULL, NULL); + pass &= ctrl_match("RDMA", 3, 5, &reference, &candidate, false); + + return pass; +} + +/** + * test_ctrl_match_tcp - Test that we can look up TCP controllers + * + * @note: The mocked getifaddrs() returns 2 interface entries with the + * following addresses. Therefore the tests must use IP addresses + * that match these. + * + * eth0 + * \_ 192.168.1.20 + * \_ fe80::dead:beef + * + * lo + * \_ 127.0.0.1 + * \_ ::1 + * + * @return true when all tests have passed. false otherwise. + */ +static bool test_ctrl_match_tcp() +{ + bool pass = true; + struct ctrl_args reference = {0}; + struct ctrl_args candidate = {0}; + + printf("\n" + "test_ctrl_match_tcp:\n"); + + /*******************************************************************/ + /* IPv4: Reference ID 1 */ + set_ctrl_args(&reference, "tcp", "123.123.123.123", "8009", NULL, NULL, NULL, NULL); + + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 1, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 1, 1, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 1, 2, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 1, 3, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 1, 4, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 1, 5, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 1, 6, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 1, 7, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 1, 8, &reference, &candidate, true); + + /*******************************************************************/ + /* IPv4: Reference ID 2 */ + set_ctrl_args(&reference, "tcp", "123.123.123.123", "8009", "192.168.1.20", NULL, NULL, NULL); + + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 2, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 2, 1, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 2, 2, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 2, 3, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 2, 4, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 2, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 2, 6, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 2, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 2, 8, &reference, &candidate, false); + + /*******************************************************************/ + /* IPv4: Reference ID 3 */ + set_ctrl_args(&reference, "tcp", "123.123.123.123", "8009", NULL, "eth0", NULL, NULL); + + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 3, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 3, 1, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 3, 2, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 3, 3, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 3, 4, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 3, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 3, 6, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 3, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 3, 8, &reference, &candidate, false); + + /*******************************************************************/ + /* IPv4: Reference ID 4 */ + set_ctrl_args(&reference, "tcp", "123.123.123.123", "8009", "192.168.1.20", "eth0", NULL, NULL); + + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 4, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 4, 1, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 4, 2, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 4, 3, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 4, 4, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 4, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 4, 6, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 4, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 4, 8, &reference, &candidate, false); + + /*******************************************************************/ + /* IPv4: Reference ID 5 */ + set_ctrl_args(&reference, "tcp", "123.123.123.123", "8009", "192.168.1.21", NULL, NULL, NULL); + + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 5, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 5, 1, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 5, 2, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 5, 3, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 5, 4, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 5, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 5, 6, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 5, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 5, 8, &reference, &candidate, false); + + /*******************************************************************/ + /* IPv4: Reference ID 6 */ + set_ctrl_args(&reference, "tcp", "123.123.123.123", "8009", NULL, NULL, "traddr=123.123.123.123,trsvcid=8009,src_addr=192.168.1.20", NULL); + + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 6, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 6, 1, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 6, 2, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 6, 3, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 6, 4, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 6, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 6, 6, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 6, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 6, 8, &reference, &candidate, false); + + /*******************************************************************/ + /* IPv4: Reference ID 7 */ + set_ctrl_args(&reference, "tcp", "123.123.123.123", "8009", NULL, NULL, "traddr=123.123.123.123,trsvcid=8009,src_addr=127.0.0.1", NULL); + + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 7, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 7, 1, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 7, 2, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 7, 3, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", NULL, NULL, NULL); + pass &= ctrl_match("IPv4", 7, 4, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "eth0", NULL, NULL); + pass &= ctrl_match("IPv4", 7, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 7, 6, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 7, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "lo", NULL, NULL); + pass &= ctrl_match("IPv4", 7, 8, &reference, &candidate, false); + + /*******************************************************************/ + /* IPv6: Reference ID 1 */ + set_ctrl_args(&reference, "tcp", "aaaa::bbbb", "8009", NULL, NULL, NULL, NULL); + + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 1, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 1, 1, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 1, 2, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 1, 3, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 1, 4, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 1, 5, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 1, 6, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 1, 7, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 1, 8, &reference, &candidate, true); + + /*******************************************************************/ + /* IPv6: Reference ID 2 */ + set_ctrl_args(&reference, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", NULL, NULL, NULL); + + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 2, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 2, 1, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 2, 2, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 2, 3, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 2, 4, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 2, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 2, 6, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 2, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 2, 8, &reference, &candidate, false); + + /*******************************************************************/ + /* IPv6: Reference ID 3 */ + set_ctrl_args(&reference, "tcp", "aaaa::bbbb", "8009", NULL, "eth0", NULL, NULL); + + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 3, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 3, 1, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 3, 2, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 3, 3, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 3, 4, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 3, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 3, 6, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 3, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 3, 8, &reference, &candidate, false); + + /*******************************************************************/ + /* IPv6: Reference ID 4 */ + set_ctrl_args(&reference, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "eth0", NULL, NULL); + + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 4, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 4, 1, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 4, 2, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 4, 3, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 4, 4, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 4, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 4, 6, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 4, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 4, 8, &reference, &candidate, false); + + /*******************************************************************/ + /* IPv6: Reference ID 5 */ + set_ctrl_args(&reference, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", NULL, NULL, NULL); + + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 5, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 5, 1, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 5, 2, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 5, 3, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 5, 4, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 5, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 5, 6, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 5, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 5, 8, &reference, &candidate, false); + + /*******************************************************************/ + /* IPv6: Reference ID 6 */ + set_ctrl_args(&reference, "tcp", "aaaa::bbbb", "8009", NULL, NULL, "traddr=aaaa::bbbb,trsvcid=8009,src_addr=fe80::dead:beef", NULL); + + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 6, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 6, 1, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 6, 2, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 6, 3, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 6, 4, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 6, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 6, 6, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 6, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 6, 8, &reference, &candidate, false); + + /*******************************************************************/ + /* IPv6: Reference ID 7 */ + set_ctrl_args(&reference, "tcp", "aaaa::bbbb", "8009", NULL, NULL, "traddr=aaaa::bbbb,trsvcid=8009,src_addr=::1", NULL); + + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 7, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 7, 1, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 7, 2, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 7, 3, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", NULL, NULL, NULL); + pass &= ctrl_match("IPv6", 7, 4, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "eth0", NULL, NULL); + pass &= ctrl_match("IPv6", 7, 5, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 7, 6, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:beef", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 7, 7, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "aaaa::bbbb", "8009", "fe80::dead:cafe", "lo", NULL, NULL); + pass &= ctrl_match("IPv6", 7, 8, &reference, &candidate, false); + + return pass; +} + +static bool ctrl_config_match(const char *tag, + int reference_id, + int candidate_id, + struct ctrl_args *reference, + struct ctrl_args *candidate, + bool should_match) +{ + bool match; + nvme_root_t r; + nvme_host_t h; + nvme_ctrl_t reference_ctrl; /* Existing controller (from sysfs) */ + nvme_subsystem_t s; + + r = nvme_create_root(stdout, LOG_INFO); + assert(r); + + h = nvme_default_host(r); + assert(h); + + s = nvme_lookup_subsystem(h, DEFAULT_SUBSYSNAME, reference->subsysnqn ? reference->subsysnqn : DEFAULT_SUBSYSNQN); + assert(s); + + reference_ctrl = nvme_lookup_ctrl(s, reference->transport, reference->traddr, + reference->host_traddr, reference->host_iface, + reference->trsvcid, NULL); + assert(reference_ctrl); + reference_ctrl->name = "nvme1"; /* fake the device name */ + if (reference->address) { + reference_ctrl->address = (char *)reference->address; + } + + match = nvme_ctrl_config_match(reference_ctrl, candidate->transport, candidate->traddr, + candidate->trsvcid, candidate->subsysnqn, + candidate->host_traddr, candidate->host_iface); + + if (should_match) { + if (!match) { + printf("%s-%d-%d: Failed to match config for Candidate (%s, %s, %s, %s, %s, %s)\n", + tag, reference_id, candidate_id, + candidate->transport, candidate->traddr, candidate->trsvcid, + candidate->subsysnqn, candidate->host_traddr, candidate->host_iface); + return false; + } + } else { + if (match) { + printf("%s-%d-%d: Config should not have matched for Candidate (%s, %s, %s, %s, %s, %s)\n", + tag, reference_id, candidate_id, + candidate->transport, candidate->traddr, candidate->trsvcid, + candidate->subsysnqn, candidate->host_traddr, candidate->host_iface); + return false; + } + } + + /* Set the faked data back to NULL before freeing the tree */ + reference_ctrl->name = NULL; + reference_ctrl->address = NULL; + + nvme_free_tree(r); + + return true; +} + +static bool test_ctrl_config_match() +{ + bool pass = true; + struct ctrl_args reference = {0}; + struct ctrl_args candidate = {0}; + + printf("\n" + "test_ctrl_config_match:\n"); + + set_ctrl_args(&reference, "tcp", "123.123.123.123", "8009", NULL, NULL, NULL, NULL); + + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, NULL, NULL, NULL); + pass &= ctrl_config_match("IPv4", 1, 0, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", NULL, NULL, NULL); + pass &= ctrl_config_match("IPv4", 1, 1, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "eth0", NULL, NULL); + pass &= ctrl_config_match("IPv4", 1, 2, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "eth0", NULL, NULL); + pass &= ctrl_config_match("IPv4", 1, 3, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", NULL, NULL, NULL); + pass &= ctrl_config_match("IPv4", 1, 4, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "eth0", NULL, NULL); + pass &= ctrl_config_match("IPv4", 1, 5, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", NULL, "lo", NULL, NULL); + pass &= ctrl_config_match("IPv4", 1, 6, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.20", "lo", NULL, NULL); + pass &= ctrl_config_match("IPv4", 1, 7, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "lo", NULL, NULL); + pass &= ctrl_config_match("IPv4", 1, 8, &reference, &candidate, true); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "lo", NULL, "hello"); + pass &= ctrl_config_match("IPv4", 1, 9, &reference, &candidate, false); + set_ctrl_args(&candidate, "tcp", "123.123.123.123", "8009", "192.168.1.21", "lo", NULL, DEFAULT_SUBSYSNQN); + pass &= ctrl_config_match("IPv4", 1, 9, &reference, &candidate, true); + + return pass; +} + + +/** + * This test module uses a mocked ifaddrs library (mock-ifaddrs.c) + * such that there are 2 fake interfaces (eth0 and lo) with the + * following IP addresses: + * + * - eth0 + * \_ IPv4: 192.168.1.20 + * \_ IPv6: fe80::dead:beef + * + * - lo + * \_ IPv4: 127.0.0.1 + * \_ IPv6: ::1 + */ int main(int argc, char *argv[]) { - test_lookup_1(); - test_lookup_2(); + bool pass = true; - return 0; + pass &= test_lookup(); + pass &= test_src_addr(); + pass &= test_ctrl_match_fc(); + pass &= test_ctrl_match_rdma(); + pass &= test_ctrl_match_tcp(); + pass &= test_ctrl_config_match(); + + fflush(stdout); + + exit(pass ? EXIT_SUCCESS : EXIT_FAILURE); }