From: Jeremy Allison <jallison@ciq.com>
To: jallison@ciq.com, jra@samba.org, tansuresh@google.com,
hch@lst.de, gregkh@linuxfoundation.org, rafael@kernel.org,
bhelgaas@google.com, sagi@grimberg.me
Cc: linux-nvme@lists.infradead.org
Subject: [PATCH 4/5] nvme: Export nvme_wait_ready().
Date: Wed, 3 Jan 2024 13:04:04 -0800 [thread overview]
Message-ID: <20240103210405.3593499-5-jallison@ciq.com> (raw)
In-Reply-To: <20240103210405.3593499-1-jallison@ciq.com>
We will be calling this from drivers/nvme/host/pci.c
in the next commit.
Signed-off-by: Jeremy Allison <jallison@ciq.com>
---
drivers/nvme/host/core.c | 3 ++-
drivers/nvme/host/nvme.h | 2 ++
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
index e1b2facb7d6a..c7d448f186fb 100644
--- a/drivers/nvme/host/core.c
+++ b/drivers/nvme/host/core.c
@@ -2192,7 +2192,7 @@ const struct block_device_operations nvme_bdev_ops = {
.pr_ops = &nvme_pr_ops,
};
-static int nvme_wait_ready(struct nvme_ctrl *ctrl, u32 mask, u32 val,
+int nvme_wait_ready(struct nvme_ctrl *ctrl, u32 mask, u32 val,
u32 timeout, const char *op)
{
unsigned long timeout_jiffies = jiffies + timeout * HZ;
@@ -2218,6 +2218,7 @@ static int nvme_wait_ready(struct nvme_ctrl *ctrl, u32 mask, u32 val,
return ret;
}
+EXPORT_SYMBOL_GPL(nvme_wait_ready);
int nvme_disable_ctrl(struct nvme_ctrl *ctrl, enum shutdown_type shutdown_type)
{
diff --git a/drivers/nvme/host/nvme.h b/drivers/nvme/host/nvme.h
index 1a748640f2fb..8c30f9856621 100644
--- a/drivers/nvme/host/nvme.h
+++ b/drivers/nvme/host/nvme.h
@@ -754,6 +754,8 @@ void nvme_cancel_tagset(struct nvme_ctrl *ctrl);
void nvme_cancel_admin_tagset(struct nvme_ctrl *ctrl);
bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
enum nvme_ctrl_state new_state);
+int nvme_wait_ready(struct nvme_ctrl *ctrl, u32 mask, u32 val,
+ u32 timeout, const char *op);
int nvme_disable_ctrl(struct nvme_ctrl *ctrl, enum shutdown_type shutdown_type);
int nvme_enable_ctrl(struct nvme_ctrl *ctrl);
int nvme_init_ctrl(struct nvme_ctrl *ctrl, struct device *dev,
--
2.39.3
next prev parent reply other threads:[~2024-01-03 21:04 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-03 21:04 Make NVME shutdown two-pass - Version 4 Jeremy Allison
2024-01-03 21:04 ` [PATCH 1/5] driver core: Support two-pass driver shutdown Jeremy Allison
2024-01-04 13:12 ` Sagi Grimberg
2024-01-04 17:27 ` Jeremy Allison
2024-01-03 21:04 ` [PATCH 2/5] PCI: Support two-pass shutdown Jeremy Allison
2024-01-04 18:55 ` Bjorn Helgaas
2024-01-04 19:34 ` Jeremy Allison
2024-01-03 21:04 ` [PATCH 3/5] nvme: Change 'bool shutdown' into an enum shutdown_type Jeremy Allison
2024-01-04 13:26 ` Sagi Grimberg
2024-01-04 17:43 ` Jeremy Allison
2024-01-04 18:44 ` Jeremy Allison
2024-01-08 17:42 ` Sagi Grimberg
2024-01-08 18:41 ` Jeremy Allison
2024-01-03 21:04 ` Jeremy Allison [this message]
2024-01-03 21:04 ` [PATCH 5/5] nvme: Add two-pass shutdown support Jeremy Allison
2024-01-04 13:14 ` Sagi Grimberg
2024-01-04 17:30 ` Jeremy Allison
2024-01-04 4:48 ` Make NVME shutdown two-pass - Version 4 Chaitanya Kulkarni
2024-01-04 6:38 ` Jeremy Allison
2024-01-04 19:00 ` Keith Busch
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240103210405.3593499-5-jallison@ciq.com \
--to=jallison@ciq.com \
--cc=bhelgaas@google.com \
--cc=gregkh@linuxfoundation.org \
--cc=hch@lst.de \
--cc=jra@samba.org \
--cc=linux-nvme@lists.infradead.org \
--cc=rafael@kernel.org \
--cc=sagi@grimberg.me \
--cc=tansuresh@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox