Add a wrapper which calls into mpath_synchronize.

Signed-off-by: John Garry <[email protected]>
---
 drivers/nvme/host/nvme.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/nvme/host/nvme.h b/drivers/nvme/host/nvme.h
index 01a7a25bcd254..cc63ed8131c36 100644
--- a/drivers/nvme/host/nvme.h
+++ b/drivers/nvme/host/nvme.h
@@ -1062,6 +1062,11 @@ void nvme_mpath_ioctl_begin(struct mpath_device 
*mpath_device,
                        unsigned int cmd, void **opaque);
 void nvme_mpath_ioctl_finish(void *opaque);
 
+static inline void nvme_mpath_synchronize(struct nvme_ns_head *head)
+{
+       mpath_synchronize(head->mpath_head);
+}
+
 static inline void nvme_trace_bio_complete(struct request *req)
 {
        struct nvme_ns *ns = req->q->queuedata;
@@ -1094,6 +1099,9 @@ static inline bool nvme_ctrl_use_ana(struct nvme_ctrl 
*ctrl)
 {
        return false;
 }
+static inline void nvme_mpath_synchronize(struct nvme_ns_head *head)
+{
+}
 static inline void nvme_failover_req(struct request *req)
 {
 }
-- 
2.43.5


Reply via email to