Skip to content

Commit 24af1b9

Browse files
authored
Merge pull request #357 from t-8ch/host_mem_buf-feature-length
util: Add feature length for host memory buffer
2 parents 904b3a3 + e7e79cb commit 24af1b9

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/nvme/util.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -435,6 +435,9 @@ int nvme_get_feature_length(int fid, __u32 cdw11, __u32 *len)
435435
case NVME_FEAT_FID_HOST_ID:
436436
*len = (cdw11 & 0x1) ? 16 : 8;
437437
break;
438+
case NVME_FEAT_FID_HOST_MEM_BUF:
439+
*len = sizeof(struct nvme_host_mem_buf_attrs);
440+
break;
438441
case NVME_FEAT_FID_ARBITRATION:
439442
case NVME_FEAT_FID_POWER_MGMT:
440443
case NVME_FEAT_FID_TEMP_THRESH:
@@ -445,7 +448,6 @@ int nvme_get_feature_length(int fid, __u32 cdw11, __u32 *len)
445448
case NVME_FEAT_FID_IRQ_CONFIG:
446449
case NVME_FEAT_FID_WRITE_ATOMIC:
447450
case NVME_FEAT_FID_ASYNC_EVENT:
448-
case NVME_FEAT_FID_HOST_MEM_BUF:
449451
case NVME_FEAT_FID_KATO:
450452
case NVME_FEAT_FID_HCTM:
451453
case NVME_FEAT_FID_NOPSC:

0 commit comments

Comments
 (0)