[PATCH] nvme: remove duplicated judgement

Ma, Jianpeng jianpeng.ma at intel.com
Mon Oct 7 22:31:18 PDT 2024


Function blk_rq_is_poll is also called in blk_rq_poll function, so
remove from func nvme_ns_char_uring_cmd_iopoll.

Signed-off-by: Jianpeng Ma <jianpeng.ma at intel.com>
---
 drivers/nvme/host/ioctl.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/nvme/host/ioctl.c b/drivers/nvme/host/ioctl.c
index b9b79ccfabf8..75f3a34e15a3 100644
--- a/drivers/nvme/host/ioctl.c
+++ b/drivers/nvme/host/ioctl.c
@@ -667,7 +667,7 @@ int nvme_ns_chr_uring_cmd_iopoll(struct io_uring_cmd *ioucmd,
        struct nvme_uring_cmd_pdu *pdu = nvme_uring_cmd_pdu(ioucmd);
        struct request *req = pdu->req;

-       if (req && blk_rq_is_poll(req))
+       if (req)
                return blk_rq_poll(req, iob, poll_flags);
        return 0;
 }
--
2.43.0
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-nvme-remove-duplicated-judgement.patch
Type: application/octet-stream
Size: 925 bytes
Desc: 0001-nvme-remove-duplicated-judgement.patch
URL: <http://lists.infradead.org/pipermail/linux-nvme/attachments/20241008/6890f5e0/attachment.obj>


More information about the Linux-nvme mailing list