* [PATCH 1/1] nvme: update enumerations for status codes
@ 2021-01-04 12:59 Max Gurtovoy
2021-01-14 11:12 ` Hannes Reinecke
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Max Gurtovoy @ 2021-01-04 12:59 UTC (permalink / raw)
To: oren, linux-nvme, sagi, kbusch, hch, chaitanya.kulkarni
Cc: israelr, mgurtovoy, nitzanc
All the updates are mentioned in the ratified NVMe 1.4 spec.
Signed-off-by: Max Gurtovoy <mgurtovoy@nvidia.com>
---
include/linux/nvme.h | 24 ++++++++++++++++++++----
1 file changed, 20 insertions(+), 4 deletions(-)
diff --git a/include/linux/nvme.h b/include/linux/nvme.h
index d92535997687..1c9c34be8194 100644
--- a/include/linux/nvme.h
+++ b/include/linux/nvme.h
@@ -1467,20 +1467,29 @@ enum {
NVME_SC_SGL_INVALID_DATA = 0xf,
NVME_SC_SGL_INVALID_METADATA = 0x10,
NVME_SC_SGL_INVALID_TYPE = 0x11,
-
+ NVME_SC_CMB_INVALID_USE = 0x12,
+ NVME_SC_PRP_INVALID_OFFSET = 0x13,
+ NVME_SC_ATOMIC_WU_EXCEEDED = 0x14,
+ NVME_SC_OP_DENIED = 0x15,
NVME_SC_SGL_INVALID_OFFSET = 0x16,
- NVME_SC_SGL_INVALID_SUBTYPE = 0x17,
-
+ NVME_SC_RESERVED = 0x17,
+ NVME_SC_HOST_ID_INCONSIST = 0x18,
+ NVME_SC_KA_TIMEOUT_EXPIRED = 0x19,
+ NVME_SC_KA_TIMEOUT_INVALID = 0x1A,
+ NVME_SC_ABORTED_PREEMPT_ABORT = 0x1B,
NVME_SC_SANITIZE_FAILED = 0x1C,
NVME_SC_SANITIZE_IN_PROGRESS = 0x1D,
-
+ NVME_SC_SGL_INVALID_GRANULARITY = 0x1E,
+ NVME_SC_CMD_NOT_SUP_CMB_QUEUE = 0x1F,
NVME_SC_NS_WRITE_PROTECTED = 0x20,
NVME_SC_CMD_INTERRUPTED = 0x21,
+ NVME_SC_TRANSIENT_TR_ERR = 0x22,
NVME_SC_LBA_RANGE = 0x80,
NVME_SC_CAP_EXCEEDED = 0x81,
NVME_SC_NS_NOT_READY = 0x82,
NVME_SC_RESERVATION_CONFLICT = 0x83,
+ NVME_SC_FORMAT_IN_PROGRESS = 0x84,
/*
* Command Specific Status:
@@ -1513,8 +1522,15 @@ enum {
NVME_SC_NS_NOT_ATTACHED = 0x11a,
NVME_SC_THIN_PROV_NOT_SUPP = 0x11b,
NVME_SC_CTRL_LIST_INVALID = 0x11c,
+ NVME_SC_SELT_TEST_IN_PROGRESS = 0x11d,
NVME_SC_BP_WRITE_PROHIBITED = 0x11e,
+ NVME_SC_CTRL_ID_INVALID = 0x11f,
+ NVME_SC_SEC_CTRL_STATE_INVALID = 0x120,
+ NVME_SC_CTRL_RES_NUM_INVALID = 0x121,
+ NVME_SC_RES_ID_INVALID = 0x122,
NVME_SC_PMR_SAN_PROHIBITED = 0x123,
+ NVME_SC_ANA_GROUP_ID_INVALID = 0x124,
+ NVME_SC_ANA_ATTACH_FAILED = 0x125,
/*
* I/O Command Set Specific - NVM commands:
--
2.25.4
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH 1/1] nvme: update enumerations for status codes
2021-01-04 12:59 [PATCH 1/1] nvme: update enumerations for status codes Max Gurtovoy
@ 2021-01-14 11:12 ` Hannes Reinecke
2021-01-14 17:52 ` Christoph Hellwig
2021-01-20 5:09 ` Chaitanya Kulkarni
2 siblings, 0 replies; 7+ messages in thread
From: Hannes Reinecke @ 2021-01-14 11:12 UTC (permalink / raw)
To: Max Gurtovoy, oren, linux-nvme, sagi, kbusch, hch,
chaitanya.kulkarni
Cc: israelr, nitzanc
On 1/4/21 1:59 PM, Max Gurtovoy wrote:
> All the updates are mentioned in the ratified NVMe 1.4 spec.
>
> Signed-off-by: Max Gurtovoy <mgurtovoy@nvidia.com>
> ---
> include/linux/nvme.h | 24 ++++++++++++++++++++----
> 1 file changed, 20 insertions(+), 4 deletions(-)
>
> diff --git a/include/linux/nvme.h b/include/linux/nvme.h
> index d92535997687..1c9c34be8194 100644
> --- a/include/linux/nvme.h
> +++ b/include/linux/nvme.h
> @@ -1467,20 +1467,29 @@ enum {
> NVME_SC_SGL_INVALID_DATA = 0xf,
> NVME_SC_SGL_INVALID_METADATA = 0x10,
> NVME_SC_SGL_INVALID_TYPE = 0x11,
> -
> + NVME_SC_CMB_INVALID_USE = 0x12,
> + NVME_SC_PRP_INVALID_OFFSET = 0x13,
> + NVME_SC_ATOMIC_WU_EXCEEDED = 0x14,
> + NVME_SC_OP_DENIED = 0x15,
> NVME_SC_SGL_INVALID_OFFSET = 0x16,
> - NVME_SC_SGL_INVALID_SUBTYPE = 0x17,
> -
> + NVME_SC_RESERVED = 0x17,
> + NVME_SC_HOST_ID_INCONSIST = 0x18,
> + NVME_SC_KA_TIMEOUT_EXPIRED = 0x19,
> + NVME_SC_KA_TIMEOUT_INVALID = 0x1A,
> + NVME_SC_ABORTED_PREEMPT_ABORT = 0x1B,
> NVME_SC_SANITIZE_FAILED = 0x1C,
> NVME_SC_SANITIZE_IN_PROGRESS = 0x1D,
> -
> + NVME_SC_SGL_INVALID_GRANULARITY = 0x1E,
> + NVME_SC_CMD_NOT_SUP_CMB_QUEUE = 0x1F,
> NVME_SC_NS_WRITE_PROTECTED = 0x20,
> NVME_SC_CMD_INTERRUPTED = 0x21,
> + NVME_SC_TRANSIENT_TR_ERR = 0x22,
>
> NVME_SC_LBA_RANGE = 0x80,
> NVME_SC_CAP_EXCEEDED = 0x81,
> NVME_SC_NS_NOT_READY = 0x82,
> NVME_SC_RESERVATION_CONFLICT = 0x83,
> + NVME_SC_FORMAT_IN_PROGRESS = 0x84,
>
> /*
> * Command Specific Status:
> @@ -1513,8 +1522,15 @@ enum {
> NVME_SC_NS_NOT_ATTACHED = 0x11a,
> NVME_SC_THIN_PROV_NOT_SUPP = 0x11b,
> NVME_SC_CTRL_LIST_INVALID = 0x11c,
> + NVME_SC_SELT_TEST_IN_PROGRESS = 0x11d,
> NVME_SC_BP_WRITE_PROHIBITED = 0x11e,
> + NVME_SC_CTRL_ID_INVALID = 0x11f,
> + NVME_SC_SEC_CTRL_STATE_INVALID = 0x120,
> + NVME_SC_CTRL_RES_NUM_INVALID = 0x121,
> + NVME_SC_RES_ID_INVALID = 0x122,
> NVME_SC_PMR_SAN_PROHIBITED = 0x123,
> + NVME_SC_ANA_GROUP_ID_INVALID = 0x124,
> + NVME_SC_ANA_ATTACH_FAILED = 0x125,
>
> /*
> * I/O Command Set Specific - NVM commands:
>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Cheers,
Hannes
--
Dr. Hannes Reinecke Kernel Storage Architect
hare@suse.de +49 911 74053 688
SUSE Software Solutions GmbH, Maxfeldstr. 5, 90409 Nürnberg
HRB 36809 (AG Nürnberg), Geschäftsführer: Felix Imendörffer
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 1/1] nvme: update enumerations for status codes
2021-01-04 12:59 [PATCH 1/1] nvme: update enumerations for status codes Max Gurtovoy
2021-01-14 11:12 ` Hannes Reinecke
@ 2021-01-14 17:52 ` Christoph Hellwig
2021-01-19 14:20 ` Max Gurtovoy
2021-01-20 5:09 ` Chaitanya Kulkarni
2 siblings, 1 reply; 7+ messages in thread
From: Christoph Hellwig @ 2021-01-14 17:52 UTC (permalink / raw)
To: Max Gurtovoy
Cc: sagi, chaitanya.kulkarni, israelr, linux-nvme, oren, nitzanc,
kbusch, hch
Can we use this as a chance to resync with nvme-cli and have one
version of the header that works for both?
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 1/1] nvme: update enumerations for status codes
2021-01-14 17:52 ` Christoph Hellwig
@ 2021-01-19 14:20 ` Max Gurtovoy
0 siblings, 0 replies; 7+ messages in thread
From: Max Gurtovoy @ 2021-01-19 14:20 UTC (permalink / raw)
To: Christoph Hellwig
Cc: sagi, chaitanya.kulkarni, israelr, linux-nvme, nitzanc, kbusch,
oren
On 1/14/2021 7:52 PM, Christoph Hellwig wrote:
> Can we use this as a chance to resync with nvme-cli and have one
> version of the header that works for both?
Did you mean that both nvme-cli nvme.h files will be completely the same ?
nvme.h in nvme-cli has some weird cpu_to_le and le_to_cpu stuff and others..
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 1/1] nvme: update enumerations for status codes
2021-01-04 12:59 [PATCH 1/1] nvme: update enumerations for status codes Max Gurtovoy
2021-01-14 11:12 ` Hannes Reinecke
2021-01-14 17:52 ` Christoph Hellwig
@ 2021-01-20 5:09 ` Chaitanya Kulkarni
2021-01-20 10:02 ` Max Gurtovoy
2 siblings, 1 reply; 7+ messages in thread
From: Chaitanya Kulkarni @ 2021-01-20 5:09 UTC (permalink / raw)
To: Max Gurtovoy, oren@nvidia.com, linux-nvme@lists.infradead.org,
sagi@grimberg.me, kbusch@kernel.org, hch@lst.de
Cc: israelr@nvidia.com, nitzanc@nvidia.com
Max,
On 1/4/21 04:59, Max Gurtovoy wrote:
> All the updates are mentioned in the ratified NVMe 1.4 spec.
>
> Signed-off-by: Max Gurtovoy <mgurtovoy@nvidia.com>
> ---
I'm not against keeping the header file up to date with the spec,
but should we add the error status into the kernel code even if
we are not using it in the host/target driver ?
Here we add 24 lines which we have not used at all.
> include/linux/nvme.h | 24 ++++++++++++++++++++----
> 1 file changed, 20 insertions(+), 4 deletions(-)
>
Regarding the nvme-cli this is much needed a sync since it does
decode all the errors if I'm not wrong.
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 1/1] nvme: update enumerations for status codes
2021-01-20 5:09 ` Chaitanya Kulkarni
@ 2021-01-20 10:02 ` Max Gurtovoy
2021-01-21 8:08 ` Chaitanya Kulkarni
0 siblings, 1 reply; 7+ messages in thread
From: Max Gurtovoy @ 2021-01-20 10:02 UTC (permalink / raw)
To: Chaitanya Kulkarni, oren@nvidia.com,
linux-nvme@lists.infradead.org, sagi@grimberg.me,
kbusch@kernel.org, hch@lst.de
Cc: israelr@nvidia.com, nitzanc@nvidia.com
On 1/20/2021 7:09 AM, Chaitanya Kulkarni wrote:
> Max,
> On 1/4/21 04:59, Max Gurtovoy wrote:
>> All the updates are mentioned in the ratified NVMe 1.4 spec.
>>
>> Signed-off-by: Max Gurtovoy <mgurtovoy@nvidia.com>
>> ---
> I'm not against keeping the header file up to date with the spec,
> but should we add the error status into the kernel code even if
> we are not using it in the host/target driver ?
I we go with this approach we should remove half of the code inside nvme.h
>
> Here we add 24 lines which we have not used at all.
>> include/linux/nvme.h | 24 ++++++++++++++++++++----
>> 1 file changed, 20 insertions(+), 4 deletions(-)
>>
> Regarding the nvme-cli this is much needed a sync since it does
> decode all the errors if I'm not wrong.
I can sync it in V2.
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 1/1] nvme: update enumerations for status codes
2021-01-20 10:02 ` Max Gurtovoy
@ 2021-01-21 8:08 ` Chaitanya Kulkarni
0 siblings, 0 replies; 7+ messages in thread
From: Chaitanya Kulkarni @ 2021-01-21 8:08 UTC (permalink / raw)
To: Max Gurtovoy, sagi@grimberg.me, kbusch@kernel.org, hch@lst.de
Cc: israelr@nvidia.com, nitzanc@nvidia.com, oren@nvidia.com,
linux-nvme@lists.infradead.org
On 1/20/21 2:03 AM, Max Gurtovoy wrote:
> On 1/20/2021 7:09 AM, Chaitanya Kulkarni wrote:
>> Max,
>> On 1/4/21 04:59, Max Gurtovoy wrote:
>>> All the updates are mentioned in the ratified NVMe 1.4 spec.
>>>
>>> Signed-off-by: Max Gurtovoy <mgurtovoy@nvidia.com>
>>> ---
>> I'm not against keeping the header file up to date with the spec,
>> but should we add the error status into the kernel code even if
>> we are not using it in the host/target driver ?
> I we go with this approach we should remove half of the code inside nvme.h
Yes you are right and I really don't understand the need to add symbols
when they are not used I think I'm also guilty of some :P.
It will be great if someone can clarify the need to add symbols when they
arenot used in the kernel or a use case which needs this sort of update.
>
>> Here we add 24 lines which we have not used at all.
>>> include/linux/nvme.h | 24 ++++++++++++++++++++----
>>> 1 file changed, 20 insertions(+), 4 deletions(-)
>>>
>> Regarding the nvme-cli this is much needed a sync since it does
>> decode all the errors if I'm not wrong.
> I can sync it in V2.
>
>
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2021-01-21 8:09 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-01-04 12:59 [PATCH 1/1] nvme: update enumerations for status codes Max Gurtovoy
2021-01-14 11:12 ` Hannes Reinecke
2021-01-14 17:52 ` Christoph Hellwig
2021-01-19 14:20 ` Max Gurtovoy
2021-01-20 5:09 ` Chaitanya Kulkarni
2021-01-20 10:02 ` Max Gurtovoy
2021-01-21 8:08 ` Chaitanya Kulkarni
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox