Skip to content

Commit

Permalink
nvmet: fix rw control endian access
Browse files Browse the repository at this point in the history
Fixes: 3ec5c62 ("nvmet: handle rw's limited retry flag")
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202501142128.WexgyMTv-lkp@intel.com/
Cc: Guixin Liu <kanie@linux.alibaba.com>
Signed-off-by: Keith Busch <kbusch@kernel.org>
  • Loading branch information
keithbusch committed Jan 14, 2025
1 parent e7b94c5 commit 3c47c2c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/nvme/target/io-cmd-bdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ static void nvmet_bdev_execute_rw(struct nvmet_req *req)
iter_flags = SG_MITER_FROM_SG;
}

if (req->cmd->rw.control & NVME_RW_LR)
if (req->cmd->rw.control & cpu_to_le16(NVME_RW_LR))
opf |= REQ_FAILFAST_DEV;

if (is_pci_p2pdma_page(sg_page(req->sg)))
Expand Down

0 comments on commit 3c47c2c

Please sign in to comment.