[PATCH v2] nvme: return BLK_STS_OK on success in nvme_setup_rw
Vincent Fu
vincent.fu at samsung.com
Wed Apr 27 12:10:43 PDT 2022
Return BLK_STS_OK instead of 0 on success. Since BLK_STS_OK is defined
as 0 this patch results in no functional change but to avoid confusion
and to be consistent with nvme_setup_write_zeroes as well as
nvme_setup_discard we should have nvme_setup_rw also return BLK_STS_OK.
Signed-off-by: Vincent Fu <vincent.fu at samsung.com>
Reviewed-by: Pankaj Raghav <p.raghav at samsung.com>
Reviewed-by: Sagi Grimberg <sagi at grimberg.me>
---
v1 -> v2:
- improved commit message first line
- added reviewed-by tags
drivers/nvme/host/core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
index b9b0fbde9..f45665e36 100644
--- a/drivers/nvme/host/core.c
+++ b/drivers/nvme/host/core.c
@@ -895,7 +895,7 @@ static inline blk_status_t nvme_setup_rw(struct nvme_ns *ns,
cmnd->rw.control = cpu_to_le16(control);
cmnd->rw.dsmgmt = cpu_to_le32(dsmgmt);
- return 0;
+ return BLK_STS_OK;
}
void nvme_cleanup_cmd(struct request *req)
--
2.25.1
More information about the Linux-nvme
mailing list