From: Chaitanya Kulkarni <chaitanyak@nvidia.com>
To: Jeremy Allison <jallison@ciq.com>,
"jra@samba.org" <jra@samba.org>,
"tansuresh@google.com" <tansuresh@google.com>,
"hch@lst.de" <hch@lst.de>,
"gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
"rafael@kernel.org" <rafael@kernel.org>,
"bhelgaas@google.com" <bhelgaas@google.com>,
"sagi@grimberg.me" <sagi@grimberg.me>
Cc: "linux-nvme@lists.infradead.org" <linux-nvme@lists.infradead.org>
Subject: Re: Make NVME shutdown two-pass - Version 4
Date: Thu, 4 Jan 2024 04:48:15 +0000 [thread overview]
Message-ID: <775d4ce8-e9ed-4d27-80bd-3877e80b810a@nvidia.com> (raw)
In-Reply-To: <20240103210405.3593499-1-jallison@ciq.com>
On 1/3/24 13:04, Jeremy Allison wrote:
> This is version 4 of a patchset originally written by
> Tanjore Suresh <tansuresh@google.com> to make shutdown
> of nvme devices two-pass.
>
> Changes from version 3:
>
> 1). Removed duplicate setting of ctrl->ctrl_config in
> nvme completion function. Noticed by Sagi Grimberg <sagi@grimberg.me>
>
> 2). Removed intermediate function nvme_wait_for_shutdown_cmpl(),
> folded this code directly into nvme_shutdown_wait() by
> exporting nvme_wait_ready() from drivers/nvme/host/core.c.
> Requested by Sagi Grimberg <sagi@grimberg.me>
>
> -------------------------------------------------------------
> Currently the Linux nvme driver shutdown code steps
> through each connected drive, sets the NVME_CC_SHN_NORMAL
> (normal shutdown) flag and then polls the given drive
> waiting for the response NVME_CSTS_SHST_CMPLT flag
> (shutdown complete).
>
> Each drive is taking around 13 seconds to respond to this.
>
> The customer has 20+ drives on the box so this time adds
> up on shutdown when the nvme driver is being shut down.
>
> This patchset changes shutdown to proceed in parallel,
> so the NVME_CC_SHN_NORMAL (normal shutdown) flag is
> sent to all drives first, and then it polls waiting
> for the NVME_CSTS_SHST_CMPLT flag (shutdown complete)
> for all drives.
>
> In the specific customer case it reduces the NVME
> shutdown time from over 300 seconds to around 15
> seconds.
> -------------------------------------------------------------
>
> Thanks for your consideration,
>
> Jeremy Allison.
> CIQ / Samba Team.
>
>
>
Is there any plan to add a blktests for this or this needs a special setup
for testing that cannot be done with blktest ?
-ck
next prev parent reply other threads:[~2024-01-04 4:48 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 ` [PATCH 4/5] nvme: Export nvme_wait_ready() Jeremy Allison
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 ` Chaitanya Kulkarni [this message]
2024-01-04 6:38 ` Make NVME shutdown two-pass - Version 4 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=775d4ce8-e9ed-4d27-80bd-3877e80b810a@nvidia.com \
--to=chaitanyak@nvidia.com \
--cc=bhelgaas@google.com \
--cc=gregkh@linuxfoundation.org \
--cc=hch@lst.de \
--cc=jallison@ciq.com \
--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