diff options
author | Hans Rosenfeld <rosenfeld@grumpf.hope-2000.org> | 2022-03-18 17:04:04 +0100 |
---|---|---|
committer | Hans Rosenfeld <rosenfeld@grumpf.hope-2000.org> | 2022-09-09 16:54:04 +0200 |
commit | 153f3212c5a48deec74be10ba87dd04bc99edbbb (patch) | |
tree | 0a7983be84c0d0ab8dc84b8d3b5fe97b011be4cf /usr/src/lib/fm | |
parent | fec047081731fd77caf46ec0471c501b2cb33894 (diff) | |
download | illumos-gate-153f3212c5a48deec74be10ba87dd04bc99edbbb.tar.gz |
14815 nvmeadm: identify support for namespace management
Reviewed by: Andrew Giles <agiles@tintri.com>
Reviewed by: Guy Morrogh <gmorrogh@tintri.com>
Reviewed by: Robert Mustacchi <rm+illumos@fingolfin.org>
Approved by: Dan McDonald <danmcd@mnx.io>
Diffstat (limited to 'usr/src/lib/fm')
-rw-r--r-- | usr/src/lib/fm/topo/modules/common/disk/disk_nvme.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/usr/src/lib/fm/topo/modules/common/disk/disk_nvme.c b/usr/src/lib/fm/topo/modules/common/disk/disk_nvme.c index a50705070e..79a2a6c1e2 100644 --- a/usr/src/lib/fm/topo/modules/common/disk/disk_nvme.c +++ b/usr/src/lib/fm/topo/modules/common/disk/disk_nvme.c @@ -11,6 +11,7 @@ /* * Copyright 2020 Joyent, Inc. + * Copyright 2022 Tintri by DDN, Inc. All rights reserved. */ /* @@ -584,9 +585,10 @@ discover_nvme_ctl(di_node_t node, di_minor_t minor, void *arg) } nioc.n_len = NVME_IDENTIFY_BUFSIZE; nioc.n_buf = (uintptr_t)idctl; + nioc.n_arg = NVME_IDENTIFY_CTRL; - if (ioctl(fd, NVME_IOC_IDENTIFY_CTRL, &nioc) != 0) { - topo_mod_dprintf(mod, "NVME_IOC_IDENTIFY_CTRL ioctl " + if (ioctl(fd, NVME_IOC_IDENTIFY, &nioc) != 0) { + topo_mod_dprintf(mod, "NVME_IOC_IDENTIFY ioctl " "failed: %s", strerror(errno)); (void) topo_mod_seterrno(mod, EMOD_UNKNOWN); goto error; @@ -594,6 +596,7 @@ discover_nvme_ctl(di_node_t node, di_minor_t minor, void *arg) nioc.n_len = sizeof (nvme_version_t); nioc.n_buf = (uintptr_t)&nvme_info.nei_vers; + nioc.n_arg = 0; if (ioctl(fd, NVME_IOC_VERSION, &nioc) != 0) { topo_mod_dprintf(mod, "NVME_IOC_VERSION ioctl failed: %s", |