Skip to contentSkip to conversation

nvme-cli: add print for command name to effects-log

PATCH New Minwoo Im 1 participant 1 message Jan 26, 2018 NVMe

lore
Share & tools
lore

Minwoo Im

author
#0 lore raw

PATCH 1/1 nvme-cli: add print for command name to effects-log

Commands Supported and Effects log page describes commands supported and effects of commands. It would be better if command names are printed out with their opcodes.

So, Add the command names following NVMe 1.3a specification to effects-log command to both normal mode and json mode.

Example of commands output
========
Admin Command Set

ACS0     [Delete I/O Submission Queue     ] 00000001
ACS1     [Create I/O Submission Queue     ] 00000001
ACS2     [Get Log Page                    ] 00000001
ACS4     [Delete I/O Completion Queue     ] 00000001
ACS5     [Create I/O Completion Queue     ] 00000001
ACS6     [Identify                        ] 00000001
ACS8     [Abort                           ] 00000001
ACS9     [Set Features                    ] 00000001
ACS10    [Get Features                    ] 00000001
ACS12    [Asynchronous Event Request      ] 00000001
ACS16    [Firmware Commit                 ] 00000001
ACS17    [Firmware Image Download         ] 00000001
ACS128   [Format NVM                      ] 00020003
ACS129   [Security Send                   ] 00020003
ACS130   [Security Receive                ] 00010001

NVM Command Set

IOCS0    [Flush                           ] 00010001
IOCS1    [Write                           ] 00000003
IOCS2    [Read                            ] 00000001
IOCS4    [Write Uncorrectable             ] 00000003
IOCS5    [Compare                         ] 00000001
IOCS8    [Write Zeroes                    ] 00000003
IOCS9    [Dataset Management              ] 00010003

=======

Signed-off-by Minwoo Im <minwoo.im.dev at gmail.com>
---
 linux/nvme.h |  4 ++++
 nvme-print.c | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++-----
 2 files changed, 63 insertions(+), 5 deletions(-)
linux/nvme.h +4 -0
index 9c152e4..8bacf3a 100644
@@ -749,10 +749,14 @@ enum nvme_admin_opcode {
 	nvme_admin_ns_mgmt		= 0x0d,
 	nvme_admin_activate_fw		= 0x10,
 	nvme_admin_download_fw		= 0x11,
+	nvme_admin_dev_self_test	= 0x14,
 	nvme_admin_ns_attach		= 0x15,
 	nvme_admin_keep_alive		= 0x18,
 	nvme_admin_directive_send	= 0x19,
 	nvme_admin_directive_recv	= 0x1a,
+	nvme_admin_virtual_mgmt		= 0x1c,
+	nvme_admin_nvme_mi_send		= 0x1d,
+	nvme_admin_nvme_mi_recv		= 0x1e,
 	nvme_admin_dbbuf		= 0x7C,
 	nvme_admin_format_nvm		= 0x80,
 	nvme_admin_security_send	= 0x81,
nvme-print.c +59 -5

104 lines not on this page · raw message

Signature · 1 line
2.7.4