nvme_spec: add Zoned Namespace Command Set Specific identify data structures

Add the I/O Command Set Specific Identify Namespace Data Structure
and the I/O Command Set Specific Identify Controller Data Structure
for the Zoned Namespace Command Set.

These data structures are defined in the NVMe Zoned Namespace Command
Set Specification.

Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com>
Change-Id: I1434765ecbb22e1020c6b299cd05ba8a614b1cda
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4310
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Broadcom CI
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
This commit is contained in:
Niklas Cassel 2020-09-17 11:06:10 +00:00 committed by Tomasz Zawadzki
parent d1db020954
commit 069b536766

View File

@ -1986,6 +1986,14 @@ struct __attribute__((packed)) __attribute__((aligned)) spdk_nvme_ctrlr_data {
};
SPDK_STATIC_ASSERT(sizeof(struct spdk_nvme_ctrlr_data) == 4096, "Incorrect size");
struct spdk_nvme_ctrlr_data_zns {
/** zone append size limit */
uint8_t zasl;
uint8_t reserved1[4095];
};
SPDK_STATIC_ASSERT(sizeof(struct spdk_nvme_ctrlr_data_zns) == 4096, "Incorrect size");
struct __attribute__((packed)) spdk_nvme_primary_ctrl_capabilities {
/** controller id */
uint16_t cntlid;
@ -2262,6 +2270,51 @@ struct spdk_nvme_ns_data {
};
SPDK_STATIC_ASSERT(sizeof(struct spdk_nvme_ns_data) == 4096, "Incorrect size");
struct spdk_nvme_ns_data_zns {
/** zone operation characteristics */
struct {
uint16_t variable_zone_capacity : 1;
uint16_t zone_active_excursions : 1;
uint16_t reserved0 : 14;
} zoc;
/** optional zoned command support */
struct {
uint16_t read_across_zone_boundaries : 1;
uint16_t reserved0 : 15;
} ozcs;
/** maximum active resources */
uint32_t mar;
/** maximum open resources */
uint32_t mor;
/** reset recommended limit */
uint32_t rrl;
/** finish recommended limit */
uint32_t frl;
uint8_t reserved20[2796];
/** zns lba format extension support */
struct {
/** zone size */
uint64_t zsze;
/** zone descriptor extension size */
uint64_t zdes : 8;
uint64_t reserved15 : 56;
} lbafe[16];
uint8_t reserved3072[768];
uint8_t vendor_specific[256];
};
SPDK_STATIC_ASSERT(sizeof(struct spdk_nvme_ns_data_zns) == 4096, "Incorrect size");
/**
* Deallocated logical block features - read value
*/