Skip to content

Commit 66652af

Browse files
RevanthRajashekarkeithbusch
authored andcommitted
nvme-cli: Update PMR Capability and PMR Status
1. Adding Controller Memory Space Supported(CMSS) in PMRCAP 2. Adding Persistent Memory Region Status(CBAI) in PMRSTS Signed-off-by: Revanth Rajashekar <[email protected]>
1 parent bc7cca2 commit 66652af

1 file changed

Lines changed: 7 additions & 3 deletions

File tree

nvme-print.c

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3776,6 +3776,9 @@ static void show_registers_cmbsts(__u32 cmbsts)
37763776

37773777
static void show_registers_pmrcap(__u32 pmrcap)
37783778
{
3779+
printf("\tController Memory Space Supported (CMSS) : "\
3780+
"Referencing PMR with host supplied addresses is %s\n",
3781+
((pmrcap & 0x01000000) >> 24) ? "Supported" : "Not Supported");
37793782
printf("\tPersistent Memory Region Timeout (PMRTO): %x\n", (pmrcap & 0x00ff0000) >> 16);
37803783
printf("\tPersistent Memory Region Write Barrier Mechanisms(PMRWBM): %x\n", (pmrcap & 0x00003c00) >> 10);
37813784
printf("\tPersistent Memory Region Time Units (PMRTU): PMR time unit is %s\n",
@@ -3805,11 +3808,12 @@ static const char *nvme_register_pmr_hsts_to_string(__u8 hsts)
38053808

38063809
static void show_registers_pmrsts(__u32 pmrsts, __u32 pmrctl)
38073810
{
3808-
printf("\tHealth Status (HSTS): %s\n", nvme_register_pmr_hsts_to_string((pmrsts & 0x00000e00) >> 9));
3809-
printf("\tNot Ready (NRDY): The Persistent Memory Region is %s to process "\
3811+
printf("\tController Base Address Invalid (CBAI): %x\n", (pmrsts & 0x00001000) >> 12);
3812+
printf("\tHealth Status (HSTS): %s\n", nvme_register_pmr_hsts_to_string((pmrsts & 0x00000e00) >> 9));
3813+
printf("\tNot Ready (NRDY): The Persistent Memory Region is %s to process "\
38103814
"PCI Express memory read and write requests\n",
38113815
(pmrsts & 0x00000100) == 0 && (pmrctl & 0x00000001) ? "READY":"Not Ready");
3812-
printf("\tError (ERR): %x\n", (pmrsts & 0x000000ff));
3816+
printf("\tError (ERR) : %x\n", (pmrsts & 0x000000ff));
38133817
}
38143818

38153819
static const char *nvme_register_pmr_pmrszu_to_string(__u8 pmrszu)

0 commit comments

Comments
 (0)