From: Benjamin Marzinski <bmarz...@redhat.com>

Revert "nvme: allow local retry and proper failover for REQ_FAILFAST_TRANSPORT"

Upstream Status: RHEL-only

This reverts commit cc8eb42bd5823a6a776c8a65fff79125bb955bc3.

Since RHEL no longer supports non-native NVMe multipathing, we no longer
need to carry this RHEL-only patch improving dm-multipath on NVMe
devices.

Signed-off-by: Benjamin Marzinski <bmarz...@redhat.com>

diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
index blahblah..blahblah 100644
--- a/drivers/nvme/host/core.c
+++ b/drivers/nvme/host/core.c
@@ -393,7 +393,6 @@ enum nvme_disposition {
        COMPLETE,
        RETRY,
        FAILOVER,
-       FAILUP,
        AUTHENTICATE,
 };
 
@@ -402,7 +401,7 @@ static inline enum nvme_disposition 
nvme_decide_disposition(struct request *req)
        if (likely(nvme_req(req)->status == 0))
                return COMPLETE;
 
-       if ((req->cmd_flags & (REQ_FAILFAST_DEV | REQ_FAILFAST_DRIVER)) ||
+       if (blk_noretry_request(req) ||
            (nvme_req(req)->status & NVME_STATUS_DNR) ||
            nvme_req(req)->retries >= nvme_max_retries)
                return COMPLETE;
@@ -410,11 +409,10 @@ static inline enum nvme_disposition 
nvme_decide_disposition(struct request *req)
        if ((nvme_req(req)->status & NVME_SCT_SC_MASK) == NVME_SC_AUTH_REQUIRED)
                return AUTHENTICATE;
 
-       if (req->cmd_flags & (REQ_NVME_MPATH | REQ_FAILFAST_TRANSPORT)) {
+       if (req->cmd_flags & REQ_NVME_MPATH) {
                if (nvme_is_path_error(nvme_req(req)->status) ||
                    blk_queue_dying(req->q))
-                       return (req->cmd_flags & REQ_NVME_MPATH) ?
-                               FAILOVER : FAILUP;
+                       return FAILOVER;
        } else {
                if (blk_queue_dying(req->q))
                        return COMPLETE;
@@ -456,12 +454,6 @@ void nvme_end_req(struct request *req)
        blk_mq_end_request(req, status);
 }
 
-static inline void nvme_failup_req(struct request *req)
-{
-       nvme_req(req)->status = NVME_SC_HOST_PATH_ERROR;
-       nvme_end_req(req);
-}
-
 void nvme_complete_rq(struct request *req)
 {
        struct nvme_ctrl *ctrl = nvme_req(req)->ctrl;
@@ -491,9 +483,6 @@ void nvme_complete_rq(struct request *req)
        case FAILOVER:
                nvme_failover_req(req);
                return;
-       case FAILUP:
-               nvme_failup_req(req);
-               return;
        case AUTHENTICATE:
 #ifdef CONFIG_NVME_HOST_AUTH
                queue_work(nvme_wq, &ctrl->dhchap_auth_work);

--
https://gitlab.com/cki-project/kernel-ark/-/merge_requests/3690

-- 
_______________________________________________
kernel mailing list -- kernel@lists.fedoraproject.org
To unsubscribe send an email to kernel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/kernel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to