mirror of
https://github.com/torvalds/linux.git
synced 2026-11-07 06:17:02 +01:00
nvme-auth: update error log in nvme_auth_submit()
nvme_auth_submit() issues both AUTH Send and AUTH Receive commands, but the failure messages are hardcoded to "auth_send failed", which can be misleading when an AUTH Receive fails. So print the correct direction instead. Reviewed-by: Hannes Reinecke <hare@kernel.org> Signed-off-by: Martin George <marting@netapp.com> Signed-off-by: Keith Busch <kbusch@kernel.org>
This commit is contained in:
parent
36ede1aa85
commit
7847eb57bb
|
|
@ -85,10 +85,12 @@ static int nvme_auth_submit(struct nvme_ctrl *ctrl, int qid,
|
|||
qid == 0 ? NVME_QID_ANY : qid, flags);
|
||||
if (ret > 0)
|
||||
dev_warn(ctrl->device,
|
||||
"qid %d auth_send failed with status %d\n", qid, ret);
|
||||
"qid %d auth_%s failed with status %d\n",
|
||||
qid, auth_send ? "send" : "receive", ret);
|
||||
else if (ret < 0)
|
||||
dev_err(ctrl->device,
|
||||
"qid %d auth_send failed with error %d\n", qid, ret);
|
||||
"qid %d auth_%s failed with error %d\n",
|
||||
qid, auth_send ? "send" : "receive", ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user