Commit 2fd4167f authored by Jon Derrick's avatar Jon Derrick Committed by Christoph Hellwig

nvme: fabrics commands should use the fctype field for data direction

Fabrics commands with opcode 0x7F use the fctype field to indicate data
direction.
Signed-off-by: default avatarJon Derrick <jonathan.derrick@intel.com>
Reviewed-by: default avatarSagi Grimberg <sai@grmberg.me>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Fixes: eb793e2c ("nvme.h: add NVMe over Fabrics definitions")
parent 6484f5d1
...@@ -1006,7 +1006,7 @@ static inline bool nvme_is_write(struct nvme_command *cmd) ...@@ -1006,7 +1006,7 @@ static inline bool nvme_is_write(struct nvme_command *cmd)
* Why can't we simply have a Fabrics In and Fabrics out command? * Why can't we simply have a Fabrics In and Fabrics out command?
*/ */
if (unlikely(cmd->common.opcode == nvme_fabrics_command)) if (unlikely(cmd->common.opcode == nvme_fabrics_command))
return cmd->fabrics.opcode & 1; return cmd->fabrics.fctype & 1;
return cmd->common.opcode & 1; return cmd->common.opcode & 1;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment