All of lore.kernel.org
 help / color / mirror / Atom feed
From: hch@infradead.org (Christoph Hellwig)
Subject: [PATCH 2/2] nvme-multipath: improve logging
Date: Sun, 28 Apr 2019 05:09:55 -0700	[thread overview]
Message-ID: <20190428120955.GC9759@infradead.org> (raw)
In-Reply-To: <20190425024041.17657-3-chaitanya.kulkarni@wdc.com>

On Wed, Apr 24, 2019@07:40:41PM -0700, Chaitanya Kulkarni wrote:
> This patch improves the logging for nvme-multipath code.
> 
> Signed-off-by: Hannes Reinecke <hare at suse.com>
> Signed-off-by: Chaitanya Kulkarni <chaitanya.kulkarni at wdc.com>
> ---
>  drivers/nvme/host/multipath.c | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/nvme/host/multipath.c b/drivers/nvme/host/multipath.c
> index f0716f6ce41f..721aa2ea4363 100644
> --- a/drivers/nvme/host/multipath.c
> +++ b/drivers/nvme/host/multipath.c
> @@ -81,6 +81,9 @@ void nvme_failover_req(struct request *req)
>  		 * Reset the controller for any non-ANA error as we don't know
>  		 * what caused the error.
>  		 */
> +		dev_info(ns->ctrl->device,
> +			"nvme status 0x%04x, resetting controller\n",
> +			status);

Do we need something ind?cating this is the multipath driver failing
over?

> -	dev_info(ctrl->device, "ANA group %d: %s.\n",
> +	if (desc->state < ARRAY_SIZE(nvme_ana_state_names))
> +		dev_dbg(ctrl->device, "ANA group %d: %s.\n",
>  			le32_to_cpu(desc->grpid),
>  			nvme_ana_state_names[desc->state]);
> +	else
> +		dev_dbg(ctrl->device, "ANA group %d: unknown.\n",
> +			le32_to_cpu(desc->grpid));

I don't think we need the unknown case here as nvme_parse_ana_log
rejects invalid states already.

      reply	other threads:[~2019-04-28 12:09 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-25  2:40 [PATCH 0/2] nvme: improve logging Chaitanya Kulkarni
2019-04-25  2:40 ` [PATCH 1/2] " Chaitanya Kulkarni
2019-04-28 12:05   ` Christoph Hellwig
2019-04-28 19:32     ` Chaitanya Kulkarni
2019-04-29 11:50       ` Christoph Hellwig
2019-04-29 15:58         ` Chaitanya Kulkarni
2019-04-25  2:40 ` [PATCH 2/2] nvme-multipath: " Chaitanya Kulkarni
2019-04-28 12:09   ` Christoph Hellwig [this message]

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=20190428120955.GC9759@infradead.org \
    --to=hch@infradead.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.