Commit 14d23248 authored by Changpeng Liu's avatar Changpeng Liu Committed by Ben Walker
Browse files

examples/nvme/identify: only print arbitration information if the drive can support WRR arbitration



Some drives can return get features with Arbitration feature ID successfully even
the drive can't support this feature, so we will not print this information for
the drives which can't support this feature.

Change-Id: Ife8a40120de7adcacd99d8513cfbcae1c15330dd
Signed-off-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/463481


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
parent 0d9279c5
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1248,7 +1248,7 @@ print_controller(struct spdk_nvme_ctrlr *ctrlr, const struct spdk_nvme_transport
	}
	printf("\n");

	if (features[SPDK_NVME_FEAT_ARBITRATION].valid) {
	if (features[SPDK_NVME_FEAT_ARBITRATION].valid && (cap.bits.ams & SPDK_NVME_CAP_AMS_WRR)) {
		uint32_t arb = features[SPDK_NVME_FEAT_ARBITRATION].result;
		unsigned ab, lpw, mpw, hpw;