Is idenditfy ctrl cmd supposed to return a 'result' for RDMA?
Daniel Wagner
dwagner at suse.de
Thu Apr 11 12:24:20 PDT 2024
On Thu, Apr 11, 2024 at 12:51:40PM +0200, Daniel Wagner wrote:
> but got a bit lost in the RDMA code. So I am not sure, is this supposed to
> happen?
After reading up in the spec, it doesn't seem so. After adding
diff --git a/drivers/nvme/target/admin-cmd.c b/drivers/nvme/target/admin-cmd.c
index f5b7054a4a05..a297020f4bea 100644
--- a/drivers/nvme/target/admin-cmd.c
+++ b/drivers/nvme/target/admin-cmd.c
@@ -486,6 +486,7 @@ static void nvmet_execute_identify_ctrl(struct nvmet_req *req)
kfree(id);
out:
+ req->cqe->result.u64 = 0;
nvmet_req_complete(req, status);
}
the problem goes away. I've also noticed that many other commands return
a lot of 'funky' results as well. I haven't understood why setting
the result explicitly to 0 is necessary for RDMA yet.
More information about the Linux-nvme
mailing list