nda protocol rate reporting

Report the NVMe spec, number of lanes (and max) as well as the PCIe
generation we're negotiated at (and max) for the camcontrol rate
command.

Reviewed by: scottl (the output, not the code)
Sponsored by: Netflix
This commit is contained in:
Warner Losh 2018-05-09 18:41:04 +00:00
parent ca9551221b
commit 0272270a8d
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=333424

View File

@ -5167,7 +5167,22 @@ cts_print(struct cam_device *device, struct ccb_trans_settings *cts)
"enabled" : "disabled");
}
}
if (cts->protocol == PROTO_NVME) {
struct ccb_trans_settings_nvme *nvmex =
&cts->xport_specific.nvme;
if (nvmex->valid & CTS_NVME_VALID_SPEC) {
fprintf(stdout, "%sNVMe Spec: %d.%d\n", pathstr,
NVME_MAJOR(nvmex->spec),
NVME_MINOR(nvmex->spec));
}
if (nvmex->valid & CTS_NVME_VALID_LINK) {
fprintf(stdout, "%sPCIe lanes: %d (%d max)\n", pathstr,
nvmex->lanes, nvmex->max_lanes);
fprintf(stdout, "%sPCIe Generation: %d (%d max)\n", pathstr,
nvmex->speed, nvmex->max_speed);
}
}
}
/*