projects
/
linux-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7dc3bfc
)
nvme: fix nvme_pr_* status code parsing
author
Weiwen Hu
<huweiwen@linux.alibaba.com>
Thu, 30 May 2024 06:16:46 +0000
(14:16 +0800)
committer
Keith Busch
<kbusch@kernel.org>
Fri, 31 May 2024 20:50:59 +0000
(13:50 -0700)
Fix the parsing if extra status bits (e.g. MORE) is present.
Fixes:
7fb42780d06c
("nvme: Convert NVMe errors to PR errors")
Signed-off-by: Weiwen Hu <huweiwen@linux.alibaba.com>
Signed-off-by: Keith Busch <kbusch@kernel.org>
drivers/nvme/host/pr.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/nvme/host/pr.c
b/drivers/nvme/host/pr.c
index e05571b2a1b0c95deaf5c042f0baca4d490c3562..8fa1ffcdaed48911970673d51924c7cba5f44557 100644
(file)
--- a/
drivers/nvme/host/pr.c
+++ b/
drivers/nvme/host/pr.c
@@
-77,7
+77,7
@@
static int nvme_sc_to_pr_err(int nvme_sc)
if (nvme_is_path_error(nvme_sc))
return PR_STS_PATH_FAILED;
- switch (nvme_sc) {
+ switch (nvme_sc
& 0x7ff
) {
case NVME_SC_SUCCESS:
return PR_STS_SUCCESS;
case NVME_SC_RESERVATION_CONFLICT: