提交 2dbf5816 编写于 作者: M Max Gurtovoy 提交者: Jens Axboe

nvmet: avoid dereferencing nvmet_req

No need to dereference req twice to get the cmd when we already
have it stored in a local variable.
Signed-off-by: NMax Gurtovoy <maxg@mellanox.com>
Reviewed-by: NParav Pandit <parav@mellanox.com>
Reviewed-by: NChristoph Hellwig <hch@lst.de>
Signed-off-by: NSagi Grimberg <sagi@grimberg.me>
Signed-off-by: NJens Axboe <axboe@fb.com>
上级 8432bdb2
......@@ -220,7 +220,7 @@ int nvmet_parse_connect_cmd(struct nvmet_req *req)
req->ns = NULL;
if (req->cmd->common.opcode != nvme_fabrics_command) {
if (cmd->common.opcode != nvme_fabrics_command) {
pr_err("invalid command 0x%x on unconnected queue.\n",
cmd->fabrics.opcode);
return NVME_SC_INVALID_OPCODE | NVME_SC_DNR;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册