[PATCH] nvme-multipath: use nvme_ctrl_use_ana helper to check ANA
Minwoo Im
minwoo.im.dev at gmail.com
Thu Feb 25 05:57:44 EST 2021
Call nvme_ctrl_use_ana helper to check whether the given controller uses
ANA or not.
Signed-off-by: Minwoo Im <minwoo.im.dev at gmail.com>
---
drivers/nvme/host/multipath.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/nvme/host/multipath.c b/drivers/nvme/host/multipath.c
index c658b73a41b7..bbb582b12226 100644
--- a/drivers/nvme/host/multipath.c
+++ b/drivers/nvme/host/multipath.c
@@ -82,7 +82,7 @@ void nvme_failover_req(struct request *req)
* ready to serve this namespace. Kick of a re-read of the ANA
* information page, and just try any other available path for now.
*/
- if (nvme_is_ana_error(status) && ns->ctrl->ana_log_buf) {
+ if (nvme_is_ana_error(status) && nvme_ctrl_use_ana(ns->ctrl)) {
set_bit(NVME_NS_ANA_PENDING, &ns->flags);
queue_work(nvme_wq, &ns->ctrl->ana_work);
}
--
2.25.1
More information about the Linux-nvme
mailing list