Skip to content

Commit fca3dd6

Browse files
Martin Belangerigaw
authored andcommitted
libnvme: Rename NVME_LOG_*_DISCOVER to NVME_LOG_*_DISCOVERY
The following 2 enums were renamed, but there were a few instances remaining to be renamed. Those were found in one comment and python example code (so nothing critical). NVME_LOG_LID_DISCOVER -> NVME_LOG_LID_DISCOVERY NVME_LOG_LID_HOST_DISCOVER -> NVME_LOG_LID_HOST_DISCOVERY Signed-off-by: Martin Belanger <[email protected]>
1 parent 3c54948 commit fca3dd6

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

libnvme/examples/discover-loop.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,11 @@ def discover(host, ctrl, iteration):
3131

3232
slp = ctrl.supported_log_pages()
3333
try:
34-
dlp_supp_opts = slp[nvme.NVME_LOG_LID_DISCOVER] >> 16
34+
dlp_supp_opts = slp[nvme.NVME_LOG_LID_DISCOVERY] >> 16
3535
except (TypeError, IndexError):
3636
dlp_supp_opts = 0
3737

38-
print(f"LID {nvme.NVME_LOG_LID_DISCOVER}h (Discovery), supports: {disc_supp_str(dlp_supp_opts)}")
38+
print(f"LID {nvme.NVME_LOG_LID_DISCOVERY}h (Discovery), supports: {disc_supp_str(dlp_supp_opts)}")
3939

4040
try:
4141
lsp = nvme.NVMF_LOG_DISC_LSP_PLEO if dlp_supp_opts & nvme.NVMF_LOG_DISC_LID_PLEOS else 0

libnvme/libnvme/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,11 +42,11 @@ except Exception as e:
4242
supported_log_pages = ctrl.supported_log_pages()
4343
try:
4444
# Get the supported options for the Get Discovery Log Page command
45-
dlp_supp_opts = supported_log_pages[nvme.NVME_LOG_LID_DISCOVER] >> 16
45+
dlp_supp_opts = supported_log_pages[nvme.NVME_LOG_LID_DISCOVERY] >> 16
4646
except (TypeError, IndexError):
4747
dlp_supp_opts = 0
4848

49-
print(f"LID {nvme.NVME_LOG_LID_DISCOVER:02x}h (Discovery), supports: {disc_supp_str(dlp_supp_opts)}")
49+
print(f"LID {nvme.NVME_LOG_LID_DISCOVERY:02x}h (Discovery), supports: {disc_supp_str(dlp_supp_opts)}")
5050
try:
5151
lsp = nvme.NVMF_LOG_DISC_LSP_PLEO if dlp_supp_opts & nvme.NVMF_LOG_DISC_LID_PLEOS else 0
5252
log_pages = ctrl.discover(lsp=lsp)

libnvme/src/nvme/ioctl.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6606,7 +6606,7 @@ nvme_get_log_discovery(struct nvme_transport_handle *hdl,
66066606
* Submits the Get Log Page command specifically for the Host Discovery Log.
66076607
* The @allhoste parameter is placed in the Log Specific Parameter (LSP) field.
66086608
*
6609-
* It automatically sets the Log Identifier (LID) to NVME_LOG_LID_HOST_DISCOVER.
6609+
* It automatically sets the Log Identifier (LID) to NVME_LOG_LID_HOST_DISCOVERY.
66106610
*
66116611
* Return: 0 on success, the NVMe command status on error, or a negative
66126612
* errno otherwise.

0 commit comments

Comments
 (0)