From: Keith Busch <kbusch@kernel.org>
To: linux-nvme@lists.infradead.org, sagi@grimberg.me, hch@lst.de
Cc: axboe@kernel.dk, Keith Busch <kbusch@kernel.org>
Subject: [PATCHv2 2/2] nvme: translate zone resource errors
Date: Tue, 15 Sep 2020 11:12:30 -0700 [thread overview]
Message-ID: <20200915181230.3674743-2-kbusch@kernel.org> (raw)
In-Reply-To: <20200915181230.3674743-1-kbusch@kernel.org>
Translate zoned resource errors to the appropriate blk_status_t.
Signed-off-by: Keith Busch <kbusch@kernel.org>
---
v1->v2:
Use BLK_STS_ZONE_RESOURCE instead of BLK_STS_DEV_RESOURCE
drivers/nvme/host/core.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
index f3a61a24d45f..6d5c95a3e03c 100644
--- a/drivers/nvme/host/core.c
+++ b/drivers/nvme/host/core.c
@@ -236,6 +236,9 @@ static blk_status_t nvme_error_status(u16 status)
return BLK_STS_NEXUS;
case NVME_SC_HOST_PATH_ERROR:
return BLK_STS_TRANSPORT;
+ case NVME_SC_ZONE_TOO_MANY_ACTIVE:
+ case NVME_SC_ZONE_TOO_MANY_OPEN:
+ return BLK_STS_ZONE_RESOURCE;
default:
return BLK_STS_IOERR;
}
--
2.24.1
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
next prev parent reply other threads:[~2020-09-15 18:12 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-15 18:12 [PATCHv2 1/2] block: map BLK_STS_ZONE_RESOURCE to errno Keith Busch
2020-09-15 18:12 ` Keith Busch [this message]
2020-09-15 23:56 ` [PATCHv2 2/2] nvme: translate zone resource errors Damien Le Moal
2020-09-16 21:00 ` Keith Busch
2020-09-17 5:48 ` hch
2020-09-17 6:14 ` Damien Le Moal
2020-09-15 23:59 ` [PATCHv2 1/2] block: map BLK_STS_ZONE_RESOURCE to errno Damien Le Moal
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=20200915181230.3674743-2-kbusch@kernel.org \
--to=kbusch@kernel.org \
--cc=axboe@kernel.dk \
--cc=hch@lst.de \
--cc=linux-nvme@lists.infradead.org \
--cc=sagi@grimberg.me \
/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.