linux-nvme / nvme-cli

NVMe management command line interface.
https://nvmexpress.org
GNU General Public License v2.0
1.44k stars 646 forks source link

nvme-print: add the cancel opcode the nvme_cmd_to_string() list #2346

Closed maurizio-lombardi closed 2 months ago

maurizio-lombardi commented 3 months ago

Print the correct opcode name instead of "Unknown".

maurizio-lombardi commented 3 months ago

tested against a modified Linux nvmet target:

$ nvme effects-log /dev/nvme0n1 -H [...] I/O Commands IOCS0 [Flush ] 00000001 CSUPP+ LBCC- NCC- NIC- CCC- USS- No command restriction IOCS1 [Write ] 00000003 CSUPP+ LBCC+ NCC- NIC- CCC- USS- No command restriction IOCS2 [Read ] 00000001 CSUPP+ LBCC- NCC- NIC- CCC- USS- No command restriction IOCS8 [Write Zeroes ] 00000003 CSUPP+ LBCC+ NCC- NIC- CCC- USS- No command restriction IOCS9 [Dataset Management ] 00000001 CSUPP+ LBCC- NCC- NIC- CCC- USS- No command restriction IOCS24 [Cancel ] 00000001 CSUPP+ LBCC- NCC- NIC- CCC- USS- No command restriction

maurizio-lombardi commented 2 months ago

@igaw Can you merge this?

igaw commented 2 months ago

Sure, thanks!