]>
www.infradead.org Git - users/sagi/libnvme.git/log
Daniel Wagner [Thu, 10 Feb 2022 09:09:18 +0000 (10:09 +0100)]
Merge pull request #221 from hreinecke/dump-tree
tree: add nvme_dump_tree()
Hannes Reinecke [Thu, 3 Feb 2022 11:21:17 +0000 (12:21 +0100)]
tree: add nvme_dump_tree()
Dump the internal tree in JSON format to stdout for debugging.
Signed-off-by: Hannes Reinecke <hare@suse.de>
[dwagner: dropped json wrapper definition usage]
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Thu, 10 Feb 2022 08:49:47 +0000 (09:49 +0100)]
Merge pull request #227 from igaw/cleanup-libuuid-dep
tree: Remove dead !LIBUUID code
Daniel Wagner [Tue, 8 Feb 2022 17:40:32 +0000 (18:40 +0100)]
tree: Remove dead !LIBUUID code
We have added a hard dependency to libuuid. Remove the ifdefs and the
dead code.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Tue, 8 Feb 2022 10:42:56 +0000 (11:42 +0100)]
Merge pull request #226 from linux-nvme/kernel-doc-ci
build: Add kernel-doc CI build
Daniel Wagner [Mon, 7 Feb 2022 15:01:57 +0000 (16:01 +0100)]
build: Add kernel-doc CI build
We want to catching documentation failures early. Let's add a
dedicated documentation CI build. To keep build times low just
shortcut here and do not call meson to build the complete
documentation.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Tue, 8 Feb 2022 10:07:41 +0000 (11:07 +0100)]
Merge pull request #213 from jeffreyalien/telemetry-da4-2
[libnvme] Add Support for Telemetry Log Page Data Area 4
Jeff Lien [Mon, 31 Jan 2022 21:14:46 +0000 (15:14 -0600)]
linux: Add size and data area parm to nvme_get_telemetry_log
This is necessary to support the retrieval of data area 4.
Signed-off-by: Jeff Lien <jeff.lien@wdc.com>
Daniel Wagner [Tue, 8 Feb 2022 09:23:13 +0000 (10:23 +0100)]
Merge pull request #223 from hreinecke/json-mandatory
Make JSON-C mandatory
Daniel Wagner [Mon, 7 Feb 2022 14:34:04 +0000 (15:34 +0100)]
Merge pull request #225 from igaw/fail-on-warnings
build: Make CI build fail on warnings
Daniel Wagner [Mon, 7 Feb 2022 14:31:24 +0000 (15:31 +0100)]
build: Make CI build fail on warnings
Currently, warnings are hidden in the logs and the build is marked as
succeeded. Mark all warnings as error so that we see them show up in
the review process.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Fri, 4 Feb 2022 11:52:31 +0000 (12:52 +0100)]
Merge pull request #222 from igaw/mesonize-doc
doc: Mesonize documentation generation
Daniel Wagner [Fri, 4 Feb 2022 11:48:45 +0000 (12:48 +0100)]
doc: Regenerate all documentation
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Fri, 4 Feb 2022 11:45:19 +0000 (12:45 +0100)]
doc: Fix sphinx setup
sphinx warns about cyclic refernce. Do not include the index into the
index file.
Also add the build dir and index.rst to the ignore list. This avoids
another type of warnings.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Thu, 3 Feb 2022 17:00:15 +0000 (18:00 +0100)]
doc: Mesonize documentation generation
Introduce a new config flag -Ddocs-build=true which controls if the
build system should generate documentation or not. If disabled but
-Ddocs=man is used then the pre compiled documentation will be
installed.
Furthmore, we are hooking up the sphinx tooling so that we generate
the HTML documentation ouf of the rst files.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Fri, 4 Feb 2022 11:14:54 +0000 (12:14 +0100)]
types: Fix doc description
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Thu, 3 Feb 2022 16:50:49 +0000 (17:50 +0100)]
tree: Remove doublicated declaration
nvme_host_get_hostnqn() and nvme_host_get_hostid() are declared
twice. Remove one.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Thu, 3 Feb 2022 10:38:35 +0000 (11:38 +0100)]
doc: Remove unused make.bat file
The file was added by the initial doc experiment commit. It's not
used. Remove it.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Fri, 4 Feb 2022 10:41:41 +0000 (11:41 +0100)]
Merge pull request #166 from sc108-lee/for-upstream/tp4095
For upstream/tp4095
Steven Seungcheol Lee [Fri, 4 Feb 2022 08:23:31 +0000 (17:23 +0900)]
nvme: get log domain id included in Log Specific Identifier
domid was not used in nvme_get_log as well
Signed-off-by: Steven Seungcheol Lee <sc108.lee@samsung.com>
Steven Seungcheol Lee [Thu, 23 Dec 2021 01:51:38 +0000 (10:51 +0900)]
nvme: Add nulbaf(Number of Unique Capability LBA Formats) field on nvmd_id_ns
Add explaination for mssrl, mcl, src
Based on spec NVMe - TP 4095 Namespace Capability Reporting 2021.06.28 - Ratified
Steven Seungcheol Lee [Mon, 17 Jan 2022 03:22:22 +0000 (12:22 +0900)]
ioctl: Add identify ioctl for CNS 09h, 0Ah
09h - Identify Namespace data structure for the specified
User Data Format index containing the namespace capabilities
for the NVM Command Set.
0Ah - I/O Command Set specific Identify Namespace data structure
for the specified User Data Format index containing
the namespace capabilities for the I/O Command Set
specified in the CSI field.
Signed-off-by: Steven Seungcheol Lee <sc108.lee@samsung.com>
Steven Seungcheol Lee [Mon, 17 Jan 2022 03:12:36 +0000 (12:12 +0900)]
types: Add NVM Command Set id-ns structure
Add uuid index argument on nvme_identify_ns_csi
Signed-off-by: Steven Seungcheol Lee <sc108.lee@samsung.com>
Steven Seungcheol Lee [Mon, 17 Jan 2022 02:35:54 +0000 (11:35 +0900)]
ioctl: Modify identify command argument based on spec
CNS Specific identifier presents all names below for DWORD11 bits [15:00]
NVM Set Identifier(NVM Set List (04h))
Domain Identifier(Domain List (18h))
Endurance Group Identifier(Endurance Group List (19h))
Signed-off-by: Steven Seungcheol Lee <sc108.lee@samsung.com>
Daniel Wagner [Fri, 4 Feb 2022 09:32:09 +0000 (10:32 +0100)]
Merge pull request #224 from Arunpandian15/Enhanced_ctrl_MD
nvme: Add Enhanced Controller Meta Data(FID: 0x7D)
Arunpandian J [Fri, 4 Feb 2022 09:12:36 +0000 (14:42 +0530)]
nvme: Add Enhanced Controller Meta Data(FID: 0x7D)
Reviewed-by: Steven Seungcheol Lee <sc108.lee@samsung.com>
Signed-off-by: Arunpandian J <apj.arun@samsung.com>
Hannes Reinecke [Fri, 4 Feb 2022 08:06:45 +0000 (09:06 +0100)]
Make JSON-C mandatory during built
We already have a JSON-C subproject, so we can make it mandatory
during build anyway.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Fri, 4 Feb 2022 07:55:14 +0000 (08:55 +0100)]
json: remove wrapper definitions
Switch to JSON-C API.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Fri, 4 Feb 2022 07:44:01 +0000 (08:44 +0100)]
tree: do not print function twice
nvme_msg() already prints out the function name, no need to specify
it in the message itself.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Daniel Wagner [Fri, 4 Feb 2022 07:21:28 +0000 (08:21 +0100)]
Merge pull request #199 from Arunpandian15/Supported_Cap_Config_List_Log_Page
nvme: Add Supported Capacity Configuration List log page(LID: 0x11)
Arunpandian J [Thu, 3 Feb 2022 08:25:36 +0000 (13:55 +0530)]
nvme: Add Supported Capacity Configuration List log page(LID: 0x11)
Reviewed-by: Steven Seungcheol Lee <sc108.lee@samsung.com>
Signed-off-by: Arunpandian J <apj.arun@samsung.com>
Hannes Reinecke [Thu, 3 Feb 2022 13:38:23 +0000 (14:38 +0100)]
Merge pull request #220 from hreinecke/dhchap-fix
tree: do not set dhchap_key to 'none'
Hannes Reinecke [Thu, 3 Feb 2022 11:28:13 +0000 (12:28 +0100)]
tree: do not set dhchap_key to 'none'
When no dhchap key is set the kernel will set the sysfs attribute
to 'none'. And we shouldn't display this value in our internal tree
as it really means 'not set'.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Daniel Wagner [Thu, 3 Feb 2022 11:03:46 +0000 (12:03 +0100)]
Merge pull request #211 from hreinecke/config-errors
Return json parsing errors
Hannes Reinecke [Thu, 3 Feb 2022 10:43:37 +0000 (11:43 +0100)]
Merge pull request #219 from hreinecke/lookup-restart
Restart controller lookup
Hannes Reinecke [Thu, 3 Feb 2022 10:34:51 +0000 (11:34 +0100)]
tree: loop address may be NULL
Return an empty string in nvme_ctrl_get_address() and not a NULL
to get a better output.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Thu, 3 Feb 2022 10:05:49 +0000 (11:05 +0100)]
tree: loop controllers can have transport addresses
Loop controllers may have transport addresses, so we need to parse
them to allocated correct objects.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Daniel Wagner [Thu, 3 Feb 2022 10:02:59 +0000 (11:02 +0100)]
Merge pull request #215 from hreinecke/regen-doc
Scripts for regenerating documentation
Hannes Reinecke [Wed, 2 Feb 2022 12:18:27 +0000 (13:18 +0100)]
Add scripts to regenerate documentation
Import the 'kernel-doc' script from the linux kernel sources and
add scripts to regenerate libnvme.rst and man-pages.
Signed-off-by: Hannes Reinecke <hare@suse.de>
[dwagner: moved scripts from internal to doc]
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Hannes Reinecke [Thu, 3 Feb 2022 08:46:33 +0000 (09:46 +0100)]
tree: restart controller lookup
nvme_lookup_ctrl() might match more than one controller (eg for loop
devices), in which case the iterator will only ever find the first one.
So add a parameter 'p' to nvme_lookup_ctrl() to re-start the iteration
at a given point instead of just the first one.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Thu, 3 Feb 2022 07:45:51 +0000 (08:45 +0100)]
tree: fixup memory leak in nvme_scan_ctrl()
'subsysname' was never freed.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Daniel Wagner [Wed, 2 Feb 2022 14:51:33 +0000 (15:51 +0100)]
Merge pull request #217 from martin-belanger/fix-license
Fix license info
Martin Belanger [Wed, 2 Feb 2022 14:41:02 +0000 (09:41 -0500)]
fix license info
Signed-off-by: Martin Belanger <martin.belanger@dell.com>
Hannes Reinecke [Wed, 2 Feb 2022 12:17:00 +0000 (13:17 +0100)]
Fixup wrong kernel-doc annotations
Some function descriptions weren't properly specified.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Wed, 2 Feb 2022 12:00:08 +0000 (13:00 +0100)]
Add documentation section descriptions
Add DOC: statements to the header files to have each header file
start its own section in the API documentation.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Daniel Wagner [Wed, 2 Feb 2022 11:47:06 +0000 (12:47 +0100)]
Merge pull request #214 from hreinecke/kdoc
Sanitize kernel-doc comments
Hannes Reinecke [Wed, 2 Feb 2022 10:24:47 +0000 (11:24 +0100)]
Regenerate libnvme.rst
Regenerate libnvme.rst with 'kernel-doc src/nvme/{filters,ioctl,linux,tree,types,fabrics,util}.h > doc/libnvme.rst'
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Wed, 2 Feb 2022 10:04:13 +0000 (11:04 +0100)]
Fixup sphinx warnings
When configuring with 'meson -Dman=true' sphinx is printing out errors
on the generated libnvme.rst file. This patch fixes up the function
documentations to fixup these warnings.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Wed, 2 Feb 2022 07:23:49 +0000 (08:23 +0100)]
util.h: fixup kernel-doc comments
To keep sphinx happy.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Wed, 2 Feb 2022 07:23:49 +0000 (08:23 +0100)]
fabrics.c: fixup kernel-doc comments
To keep sphinx happy.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Wed, 2 Feb 2022 07:23:49 +0000 (08:23 +0100)]
types.h: fixup kernel-doc comments
To keep sphinx happy.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Wed, 2 Feb 2022 07:23:49 +0000 (08:23 +0100)]
tree.h: fixup kernel-doc comments
To keep sphinx happy.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Wed, 2 Feb 2022 07:23:49 +0000 (08:23 +0100)]
linux.h: fixup kernel-doc comments
To keep sphinx happy.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Wed, 2 Feb 2022 07:23:49 +0000 (08:23 +0100)]
ioctl.h: fixup kernel-doc comments
To keep sphinx happy.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Wed, 2 Feb 2022 06:59:43 +0000 (07:59 +0100)]
Merge pull request #209 from hreinecke/doc-proto
Document function prototypes
Hannes Reinecke [Tue, 1 Feb 2022 13:00:24 +0000 (14:00 +0100)]
Ignore errors when opening JSON configuration file
The JSON configuration file is optional, so any errors during
opening can be ignored.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Tue, 1 Feb 2022 12:49:04 +0000 (13:49 +0100)]
Return error from nvme_read_config()
nvme_read_config() can fail, so we should be returning an error code
to inform the caller about it.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Tue, 1 Feb 2022 12:27:28 +0000 (13:27 +0100)]
tree: document function prototypes
Document all function prototypes in tree.h.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Daniel Wagner [Tue, 1 Feb 2022 10:44:20 +0000 (11:44 +0100)]
Merge pull request #205 from igaw/fix-64bit-alignment
ioctl: Sort members their natural size
Hannes Reinecke [Tue, 1 Feb 2022 10:31:05 +0000 (11:31 +0100)]
Rename nvme_path_get_subsystem()
Misnamed, should be nvme_path_get_ctrl() to be consistent with the
other library functions.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Daniel Wagner [Tue, 1 Feb 2022 10:31:03 +0000 (11:31 +0100)]
Merge pull request #207 from igaw/rename-__nvme_get_log_page
Rename nvme get log page
Hannes Reinecke [Tue, 1 Feb 2022 10:28:23 +0000 (11:28 +0100)]
Remove nvme_reset_topology()
Identical to nvme_refresh_topology().
Signed-off-by: Hannes Reinecke <hare@suse.de>
Daniel Wagner [Mon, 31 Jan 2022 12:24:56 +0000 (13:24 +0100)]
libvnme: Remove __nvme_msg from export map
nvme-cli was using the library infrastructure for logging. In the
meantime this has been removed, hence we can remove this function from
the export map.
Furthermore, move nvme_msg() and __nvme_msg() to private header.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Mon, 31 Jan 2022 12:22:15 +0000 (13:22 +0100)]
linux: Rename __nvme_get_log_page()
The prefix of __nvme_get_log_page() is confusing as it usually
indicates this is a private function. Rename this function to
nvme_get_log_page().
The already existing one nvme_get_log_page() is renamed to
nvme_get_log_page_padded() which is asking for 4k transfers.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Hannes Reinecke [Tue, 1 Feb 2022 10:22:58 +0000 (11:22 +0100)]
Merge pull request #202 from hreinecke/msg-redirect
Redirect error messages
Hannes Reinecke [Tue, 1 Feb 2022 06:50:40 +0000 (07:50 +0100)]
Rework nvme_scan_filter()
Split off nvme_scan_filter() into nvme_create_root() and export the
remaining functionality as nvme_scan_topology(). With that
nvme_scan_filter() becomes pointless as the component functions
can be called directly.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Daniel Wagner [Mon, 31 Jan 2022 09:43:58 +0000 (10:43 +0100)]
ioctl: Sort members their natural size
Previous attempt to align the members of all *_args structure didn't
take into account that pointer types vary between 32bit and 64bit
depending the arch. The only reliable alignemnt is to sort the members
according their natural size: 64bit, pointers, 32bit, 16bit, 8bit.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Hannes Reinecke [Mon, 31 Jan 2022 08:53:48 +0000 (09:53 +0100)]
Merge pull request #204 from igaw/fix-nvme_get_log_args-layout
ioctl: Fix struct nvme_get_log_args memberm alignment
Hannes Reinecke [Mon, 31 Jan 2022 08:12:13 +0000 (09:12 +0100)]
libnvme/tests: fixup create-ctrl-obj.py
Add the new 'root' argument to nvme.ctrl()
Signed-off-by: Hannes Reinecke <hare@suse.de>
Daniel Wagner [Mon, 31 Jan 2022 08:17:50 +0000 (09:17 +0100)]
ioctl: Fix struct nvme_get_log_args memberm alignment
Commit
781b9105cc43 ("nvme: Add Media Unit Status log page(LID:
0x10)") placed the domid member between two u8 members. The access
domid member would not be 16 bit aligned which is caused problems on
certain architectures. Let's fix the aligemnt by moving domid before
lsp. This give us following layout
struct nvme_get_log_args {
int args_size; /* 0 4 */
int fd; /* 4 4 */
__u32 * result; /* 8 8 */
__u32 timeout; /* 16 4 */
enum nvme_cmd_get_log_lid lid; /* 20 4 */
__u64 lpo; /* 24 8 */
void * log; /* 32 8 */
__u32 len; /* 40 4 */
__u32 nsid; /* 44 4 */
enum nvme_csi csi; /* 48 4 */
__u16 lsi; /* 52 2 */
__u16 domid; /* 54 2 */
__u8 lsp; /* 56 1 */
__u8 uuidx; /* 57 1 */
_Bool rae; /* 58 1 */
_Bool ot; /* 59 1 */
/* size: 64, cachelines: 1, members: 16 */
/* padding: 4 */
} __attribute__((__aligned__(8)));
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Hannes Reinecke [Mon, 31 Jan 2022 08:07:02 +0000 (09:07 +0100)]
Remove stale definition for nvme_log_message
No functionality anymore.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Mon, 31 Jan 2022 08:04:46 +0000 (09:04 +0100)]
Move global logging variables into nvme_root_t
Move the global logging variables into nvme_root_t to make them
settable by the application.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Fri, 28 Jan 2022 13:18:25 +0000 (14:18 +0100)]
Add 'nvme_root_t' argument to nvme_msg()
Add a 'nvme_root_t' argument to nvme_msg() to allow for error
messages to be redirected to a different filedescriptor than
'stderr'.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Fri, 28 Jan 2022 12:42:58 +0000 (13:42 +0100)]
Merge hostname2traddr()
For some reason we have two versions of hostname2traddr().
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Mon, 31 Jan 2022 06:53:31 +0000 (07:53 +0100)]
Merge pull request #203 from igaw/fix-error-codes
Fix error codes
Daniel Wagner [Fri, 28 Jan 2022 16:58:40 +0000 (17:58 +0100)]
util: Set errno in error case nvme_get_directive_receive_length
The API says we return -1 in the error case and set the errno
accordingly. Update nvme_get_directive_receive_length
to fulfill the promise.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Fri, 28 Jan 2022 16:52:14 +0000 (17:52 +0100)]
ioctl: Set errno when command args check fails
In error the function is supposed to return -1 and set the errno
accordingly.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Fri, 28 Jan 2022 13:18:15 +0000 (14:18 +0100)]
Merge pull request #201 from Arunpandian15/types_h_cleanup
Clean up Patch for types.h, ioctl.h
Arunpandian J [Fri, 28 Jan 2022 11:49:32 +0000 (17:19 +0530)]
Clean up Patch for types.h, ioctl.h
Signed-off-by: Arunpandian J <apj.arun@samsung.com>
Hannes Reinecke [Fri, 28 Jan 2022 10:44:59 +0000 (11:44 +0100)]
Update README.md
Add documentation on how to build a static library.
Hannes Reinecke [Fri, 21 Jan 2022 16:52:07 +0000 (17:52 +0100)]
Merge pull request #196 from hreinecke/rc-cleanup
Cleanups for release candidate
Hannes Reinecke [Fri, 21 Jan 2022 16:42:21 +0000 (17:42 +0100)]
fabrics: remove documentation for nvmf_add_ctrl_opts()
function is gone, no need for the documentation.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Fri, 21 Jan 2022 16:28:00 +0000 (17:28 +0100)]
fabrics: Update prototype documentation
Fill out missing bits in the function prototyp documentation.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Fri, 21 Jan 2022 16:13:20 +0000 (17:13 +0100)]
fabrics: Remove nvmf_add_ctrl_opts()
Unused, and nvmf_add_ctrl() is doing exactly the same.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Fri, 21 Jan 2022 12:53:30 +0000 (13:53 +0100)]
Merge pull request #195 from hreinecke/disable-sqflow
fabrics: kill 'disable_sqflow' argument to nvmf_add_ctrl()
Hannes Reinecke [Fri, 21 Jan 2022 12:47:20 +0000 (13:47 +0100)]
fabrics: kill 'disable_sqflow' argument to nvmf_add_ctrl()
The 'disable_sqflow' argument to nvmf_add_ctrl() is pointless, as
'struct fabrics_config' is exported and the caller can set it
directly there, without having to involve library functions at all.
And consequently we can also remove nvme_ctrl_disable_sqflow().
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Fri, 21 Jan 2022 12:00:46 +0000 (13:00 +0100)]
Merge pull request #194 from hreinecke/ctrl-init
tree: only open controller device node if required
Hannes Reinecke [Fri, 21 Jan 2022 11:53:51 +0000 (12:53 +0100)]
tree: only open controller device node if required
Opening the controller device will fail if the controller is resetting,
so trying to open it during controller initialisation will fail, and
the controller will not displayed correctly.
So only try to open the controller device if required, allowing the
initialisation to continue.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Daniel Wagner [Fri, 21 Jan 2022 09:45:58 +0000 (10:45 +0100)]
Merge pull request #192 from igaw/fix-nvme_get_log_args
ioctl: Initialize all members in nvme_get_log_args
Daniel Wagner [Fri, 21 Jan 2022 09:39:53 +0000 (10:39 +0100)]
ioctl: Initialize all members in nvme_get_log_args
Commit
781b9105cc43 ("nvme: Add Media Unit Status log page(LID:
0x10)") introduces a new member in nvme_get_log_args. Older compilers
are not happy when we don't initialize all members in the inline
functions.
In file included from ../subprojects/libnvme/src/libnvme.h:19:0,
from ../subprojects/libnvme/test/cpp.cc:10:
../subprojects/libnvme/src/nvme/ioctl.h: In function ‘int nvme_get_log_cmd_effects(int, nvme_csi, nvme_cmd_effects_log*)’:
../subprojects/libnvme/src/nvme/ioctl.h:1328:2: sorry, unimplemented: non-trivial designated initializers not supported
};
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Fri, 21 Jan 2022 09:20:35 +0000 (10:20 +0100)]
Merge pull request #191 from hreinecke/tls
fabrics: add fabrics config option 'tls'
Daniel Wagner [Fri, 21 Jan 2022 09:02:10 +0000 (10:02 +0100)]
Merge pull request #157 from Arunpandian15/Media_Unit_Status_Log_Page
nvme: Add Media Unit Status log page(LID: 0x10)
Hannes Reinecke [Thu, 20 Jan 2022 14:39:48 +0000 (15:39 +0100)]
fabrics: add fabrics config option 'tls'
Add an option 'tls' to the fabrics config to start TLS encryption
on the connection.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Hannes Reinecke [Thu, 20 Jan 2022 18:47:51 +0000 (19:47 +0100)]
Merge pull request #186 from igaw/print-format-specifier
src: Use PRIu64 format specifier for uint64 types
Hannes Reinecke [Thu, 20 Jan 2022 15:55:05 +0000 (16:55 +0100)]
Merge pull request #135 from hreinecke/ctrl-loss-args
Fix up handling of '-1' values
Daniel Wagner [Wed, 19 Jan 2022 14:54:50 +0000 (15:54 +0100)]
src: Use PRIu64 format specifier for uint64 types
When compiling for 32bit architectures the compiler is complaining
about the wrong format specifier for uint64. Use the the PRIu64 format
specifier in this case which is supported from 32bit and 64bit.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Daniel Wagner [Wed, 19 Jan 2022 13:27:05 +0000 (14:27 +0100)]
Merge pull request #185 from martin-belanger/ccan-static-lib
Define ccan as a static library
Martin Belanger [Tue, 18 Jan 2022 16:14:14 +0000 (11:14 -0500)]
Define ccan as a static library
ccan gets built as a static library, which gets linked
to libnvme.so.
Signed-off-by: Martin Belanger <martin.belanger@dell.com>
Arunpandian J [Wed, 19 Jan 2022 12:44:34 +0000 (18:14 +0530)]
nvme: Add Media Unit Status log page(LID: 0x10)
Reviewed-by: Steven Seungcheol Lee <sc108.lee@samsung.com>
Signed-off-by: Arunpandian J <apj.arun@samsung.com>
Daniel Wagner [Wed, 19 Jan 2022 08:23:58 +0000 (09:23 +0100)]
Merge pull request #164 from sc108-lee/add/flbas_to_lbaf_inuse
util: modify flbas rsvd bits to be used