Skip to content

nvme-cli: limit printing iopolicy in subsystem header

Nilay Shroff linux-nvme 1 version Applied

Status from this message: Applied, thanks!

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 5 repliesApplied

Patches in v1 Applied

#Subject and filesSizeRepliesApplied
1/2nvme: avoid printing iopolicy in list-subsys outputnvme-print-stdout.c+8 -62 replies
2/2nvme: add iopolicy field in JSON outputnvme-print-json.c+2 -22 replies

Reviews trailers per patch

All 2 patches have a Reviewed-by or Acked-by.

PatchChaitanya KulkarniMartin George
1/2R-b R-b
2/2R-b R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/2] nvme-cli: limit printing iopolicy in subsystem header

Hi,

The nvme-cli currently prints the iopolicy value in the subsystem header for both the show-topology and list-subsys commands. This behavior was introduced by commit d0b4c6cf0006 (“nvme: extend show-topology command to add support for multipath”).

Printing the iopolicy value in the output of the show-topology command is intentional and useful. The command also displays additional columns such as Nodes or queue-depth, depending on the configured I/O policy. Including the iopolicy in the header makes it easier to correlate the output with the active policy and understand the resulting I/O path behavior.

However, the iopolicy value is not particularly relevant for the list-subsys command. It currently appears there for non-verbose output because both show-topology and list-subsys commands share a common helper function that prints the subsystem header. As a result, the iopolicy field unintentionally leaked into the list-subsys output.

In addition, while the iopolicy field is shown in the regular text output of show-topology, it was missing from the JSON output format when show-topology is executed in non-verbose mode. This patchset addresses both of these issues and consists of two patches:
First patch avoids printing the iopolicy field in the list-subsys output unless the command is invoked with the verbose flag.
Second patch adds the iopolicy field to the JSON output of the show-topology command.

Thanks!

Nilay Shroff (2):
nvme: avoid printing iopolicy in list-subsys output
nvme: add iopolicy field in JSON output

 nvme-print-json.c   |  4 ++--
 nvme-print-stdout.c | 14 ++++++++------
 2 files changed, 10 insertions(+), 8 deletions(-)
Signature · 1 line
2.52.0