Skip to content

Commit 5e1fd04

Browse files
martin-gpyigaw
authored andcommitted
nvme-print: display fw-rev in list-subsys output
Include the subsys firmware revision as well in the list-subsys verbose output. Signed-off-by: Martin George <[email protected]>
1 parent 3ccb47d commit 5e1fd04

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

nvme-print-json.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2543,6 +2543,8 @@ static void json_print_nvme_subsystem_list(nvme_root_t r, bool show_ana)
25432543
if (json_print_ops.flags & VERBOSE) {
25442544
obj_add_str(subsystem_attrs, "Model",
25452545
nvme_subsystem_get_model(s));
2546+
obj_add_str(subsystem_attrs, "Firmware",
2547+
nvme_subsystem_get_fw_rev(s));
25462548
obj_add_str(subsystem_attrs, "IOPolicy",
25472549
nvme_subsystem_get_iopolicy(s));
25482550
obj_add_str(subsystem_attrs, "Type",
@@ -4501,6 +4503,8 @@ static void json_simple_topology(nvme_root_t r)
45014503
if (json_print_ops.flags & VERBOSE) {
45024504
obj_add_str(subsystem_attrs, "Model",
45034505
nvme_subsystem_get_model(s));
4506+
obj_add_str(subsystem_attrs, "Firmware",
4507+
nvme_subsystem_get_fw_rev(s));
45044508
obj_add_str(subsystem_attrs, "IOPolicy",
45054509
nvme_subsystem_get_iopolicy(s));
45064510
obj_add_str(subsystem_attrs, "Type",

nvme-print-stdout.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1114,6 +1114,8 @@ static void stdout_subsys_config(nvme_subsystem_t s)
11141114
if (stdout_print_ops.flags & VERBOSE) {
11151115
printf("%*s model=%s\n", len, " ",
11161116
nvme_subsystem_get_model(s));
1117+
printf("%*s firmware=%s\n", len, " ",
1118+
nvme_subsystem_get_fw_rev(s));
11171119
printf("%*s iopolicy=%s\n", len, " ",
11181120
nvme_subsystem_get_iopolicy(s));
11191121
printf("%*s type=%s\n", len, " ",

0 commit comments

Comments
 (0)