diff options
author | Alexander Motin <mav@FreeBSD.org> | 2022-08-05 14:58:19 +0000 |
---|---|---|
committer | Alexander Motin <mav@FreeBSD.org> | 2022-08-05 14:58:19 +0000 |
commit | a69c0964625f4e20a7d5f22d51e036e13eedbeeb (patch) | |
tree | 65a5d531a6037460eb9aa8e4f5e5c7338c79953d /sys/dev/nvme/nvme_qpair.c | |
parent | 101480e926858c90e6b0db780f48742cf60a0487 (diff) | |
download | src-a69c0964625f4e20a7d5f22d51e036e13eedbeeb.tar.gz src-a69c0964625f4e20a7d5f22d51e036e13eedbeeb.zip |
nvme: Print CRD, M and DNR status bits on errors.
It may help with some issues debugging.
MFC after: 1 week
Diffstat (limited to 'sys/dev/nvme/nvme_qpair.c')
-rw-r--r-- | sys/dev/nvme/nvme_qpair.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/sys/dev/nvme/nvme_qpair.c b/sys/dev/nvme/nvme_qpair.c index 3b20a7e209fa..e0b3517529d5 100644 --- a/sys/dev/nvme/nvme_qpair.c +++ b/sys/dev/nvme/nvme_qpair.c @@ -344,14 +344,18 @@ static void nvme_qpair_print_completion(struct nvme_qpair *qpair, struct nvme_completion *cpl) { - uint16_t sct, sc; + uint8_t sct, sc, crd, m, dnr; sct = NVME_STATUS_GET_SCT(cpl->status); sc = NVME_STATUS_GET_SC(cpl->status); - - nvme_printf(qpair->ctrlr, "%s (%02x/%02x) sqid:%d cid:%d cdw0:%x\n", - get_status_string(sct, sc), sct, sc, cpl->sqid, cpl->cid, - cpl->cdw0); + crd = NVME_STATUS_GET_CRD(cpl->status); + m = NVME_STATUS_GET_M(cpl->status); + dnr = NVME_STATUS_GET_DNR(cpl->status); + + nvme_printf(qpair->ctrlr, "%s (%02x/%02x) crd:%x m:%x dnr:%x " + "sqid:%d cid:%d cdw0:%x\n", + get_status_string(sct, sc), sct, sc, crd, m, dnr, + cpl->sqid, cpl->cid, cpl->cdw0); } static bool |