Skip to content

Commit 2d5c98d

Browse files
ikegami-tigaw
authored andcommitted
nvme-print: add NVMe 2.1 get and set features FIDs string
Fixed also the indentation error. Signed-off-by: Tokunori Ikegami <[email protected]>
1 parent 700623f commit 2d5c98d

File tree

1 file changed

+36
-29
lines changed

1 file changed

+36
-29
lines changed

nvme-print.c

Lines changed: 36 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -875,43 +875,50 @@ void nvme_show_sanitize_log(struct nvme_sanitize_log_page *sanitize,
875875
const char *nvme_feature_to_string(enum nvme_features_id feature)
876876
{
877877
switch (feature) {
878-
case NVME_FEAT_FID_ARBITRATION: return "Arbitration";
879-
case NVME_FEAT_FID_POWER_MGMT: return "Power Management";
880-
case NVME_FEAT_FID_LBA_RANGE: return "LBA Range Type";
881-
case NVME_FEAT_FID_TEMP_THRESH: return "Temperature Threshold";
882-
case NVME_FEAT_FID_ERR_RECOVERY:return "Error Recovery";
883-
case NVME_FEAT_FID_VOLATILE_WC: return "Volatile Write Cache";
884-
case NVME_FEAT_FID_NUM_QUEUES: return "Number of Queues";
885-
case NVME_FEAT_FID_IRQ_COALESCE:return "Interrupt Coalescing";
886-
case NVME_FEAT_FID_IRQ_CONFIG: return "Interrupt Vector Configuration";
887-
case NVME_FEAT_FID_WRITE_ATOMIC:return "Write Atomicity Normal";
888-
case NVME_FEAT_FID_ASYNC_EVENT: return "Async Event Configuration";
889-
case NVME_FEAT_FID_AUTO_PST: return "Autonomous Power State Transition";
890-
case NVME_FEAT_FID_HOST_MEM_BUF:return "Host Memory Buffer";
891-
case NVME_FEAT_FID_TIMESTAMP: return "Timestamp";
892-
case NVME_FEAT_FID_KATO: return "Keep Alive Timer";
893-
case NVME_FEAT_FID_HCTM: return "Host Controlled Thermal Management";
894-
case NVME_FEAT_FID_NOPSC: return "Non-Operational Power State Config";
895-
case NVME_FEAT_FID_RRL: return "Read Recovery Level";
896-
case NVME_FEAT_FID_PLM_CONFIG: return "Predictable Latency Mode Config";
897-
case NVME_FEAT_FID_PLM_WINDOW: return "Predictable Latency Mode Window";
878+
case NVME_FEAT_FID_ARBITRATION: return "Arbitration";
879+
case NVME_FEAT_FID_POWER_MGMT: return "Power Management";
880+
case NVME_FEAT_FID_LBA_RANGE: return "LBA Range Type";
881+
case NVME_FEAT_FID_TEMP_THRESH: return "Temperature Threshold";
882+
case NVME_FEAT_FID_ERR_RECOVERY: return "Error Recovery";
883+
case NVME_FEAT_FID_VOLATILE_WC: return "Volatile Write Cache";
884+
case NVME_FEAT_FID_NUM_QUEUES: return "Number of Queues";
885+
case NVME_FEAT_FID_IRQ_COALESCE: return "Interrupt Coalescing";
886+
case NVME_FEAT_FID_IRQ_CONFIG: return "Interrupt Vector Configuration";
887+
case NVME_FEAT_FID_WRITE_ATOMIC: return "Write Atomicity Normal";
888+
case NVME_FEAT_FID_ASYNC_EVENT: return "Async Event Configuration";
889+
case NVME_FEAT_FID_AUTO_PST: return "Autonomous Power State Transition";
890+
case NVME_FEAT_FID_HOST_MEM_BUF: return "Host Memory Buffer";
891+
case NVME_FEAT_FID_TIMESTAMP: return "Timestamp";
892+
case NVME_FEAT_FID_KATO: return "Keep Alive Timer";
893+
case NVME_FEAT_FID_HCTM: return "Host Controlled Thermal Management";
894+
case NVME_FEAT_FID_NOPSC: return "Non-Operational Power State Config";
895+
case NVME_FEAT_FID_RRL: return "Read Recovery Level";
896+
case NVME_FEAT_FID_PLM_CONFIG: return "Predictable Latency Mode Config";
897+
case NVME_FEAT_FID_PLM_WINDOW: return "Predictable Latency Mode Window";
898898
case NVME_FEAT_FID_LBA_STS_INTERVAL: return "LBA Status Interval";
899899
case NVME_FEAT_FID_HOST_BEHAVIOR: return "Host Behavior";
900-
case NVME_FEAT_FID_SANITIZE: return "Sanitize";
900+
case NVME_FEAT_FID_SANITIZE: return "Sanitize";
901901
case NVME_FEAT_FID_ENDURANCE_EVT_CFG: return "Endurance Event Group Configuration";
902902
case NVME_FEAT_FID_IOCS_PROFILE: return "I/O Command Set Profile";
903903
case NVME_FEAT_FID_SPINUP_CONTROL: return "Spinup Control";
904+
case NVME_FEAT_FID_POWER_LOSS_SIGNAL: return "Power Loss Signaling Config";
905+
case NVME_FEAT_FID_PERF_CHARACTERISTICS:return "Performance Characteristics";
906+
case NVME_FEAT_FID_FDP: return "Flexible Direct Placement";
907+
case NVME_FEAT_FID_FDP_EVENTS: return "Flexible Direct Placement Events";
908+
case NVME_FEAT_FID_NS_ADMIN_LABEL: return "Namespace Admin Label";
909+
case NVME_FEAT_FID_KEY_VALUE: return "Key Value Configuration";
910+
case NVME_FEAT_FID_CTRL_DATA_QUEUE: return "Controller Data Queue";
911+
case NVME_FEAT_FID_EMB_MGMT_CTRL_ADDR: return "Embedded Management Controller Address";
912+
case NVME_FEAT_FID_HOST_MGMT_AGENT_ADDR:return "Host Management Agent Address";
904913
case NVME_FEAT_FID_ENH_CTRL_METADATA: return "Enhanced Controller Metadata";
905914
case NVME_FEAT_FID_CTRL_METADATA: return "Controller Metadata";
906-
case NVME_FEAT_FID_NS_METADATA: return "Namespace Metadata";
907-
case NVME_FEAT_FID_SW_PROGRESS: return "Software Progress";
908-
case NVME_FEAT_FID_HOST_ID: return "Host Identifier";
909-
case NVME_FEAT_FID_RESV_MASK: return "Reservation Notification Mask";
910-
case NVME_FEAT_FID_RESV_PERSIST:return "Reservation Persistence";
915+
case NVME_FEAT_FID_NS_METADATA: return "Namespace Metadata";
916+
case NVME_FEAT_FID_SW_PROGRESS: return "Software Progress";
917+
case NVME_FEAT_FID_HOST_ID: return "Host Identifier";
918+
case NVME_FEAT_FID_RESV_MASK: return "Reservation Notification Mask";
919+
case NVME_FEAT_FID_RESV_PERSIST: return "Reservation Persistence";
911920
case NVME_FEAT_FID_WRITE_PROTECT: return "Namespace Write Protect";
912-
case NVME_FEAT_FID_FDP: return "Flexible Direct Placement";
913-
case NVME_FEAT_FID_FDP_EVENTS: return "Flexible Direct Placement Events";
914-
case NVME_FEAT_FID_CTRL_DATA_QUEUE: return "Controller Data Queue";
921+
case NVME_FEAT_FID_BP_WRITE_PROTECT: return "Boot Partition Write Protection Config";
915922
}
916923
/*
917924
* We don't use the "default:" statement to let the compiler warning if

0 commit comments

Comments
 (0)