mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2024-11-25 10:01:02 +01:00
nvme: Add SMART WARNING for persistent memory region
NVME 2.0 added persistent memory regions, and this bit reports critical warnings / errors with those regions. Sponsored by: Netflix Reviewed by: mav Differential Revision: https://reviews.freebsd.org/D44213
This commit is contained in:
parent
5cdedf676d
commit
2a2682ee53
@ -553,8 +553,9 @@ enum nvme_critical_warning_state {
|
||||
NVME_CRIT_WARN_ST_DEVICE_RELIABILITY = 0x4,
|
||||
NVME_CRIT_WARN_ST_READ_ONLY = 0x8,
|
||||
NVME_CRIT_WARN_ST_VOLATILE_MEMORY_BACKUP = 0x10,
|
||||
NVME_CRIT_WARN_ST_PERSISTENT_MEMORY_REGION = 0x20,
|
||||
};
|
||||
#define NVME_CRIT_WARN_ST_RESERVED_MASK (0xE0)
|
||||
#define NVME_CRIT_WARN_ST_RESERVED_MASK (0xC0)
|
||||
#define NVME_ASYNC_EVENT_NS_ATTRIBUTE (0x100)
|
||||
#define NVME_ASYNC_EVENT_FW_ACTIVATE (0x200)
|
||||
|
||||
|
@ -663,6 +663,9 @@ nvme_ctrlr_log_critical_warnings(struct nvme_controller *ctrlr,
|
||||
if (state & NVME_CRIT_WARN_ST_VOLATILE_MEMORY_BACKUP)
|
||||
nvme_printf(ctrlr, "SMART WARNING: volatile memory backup device failed\n");
|
||||
|
||||
if (state & NVME_CRIT_WARN_ST_PERSISTENT_MEMORY_REGION)
|
||||
nvme_printf(ctrlr, "SMART WARNING: persistent memory read only or unreliable\n");
|
||||
|
||||
if (state & NVME_CRIT_WARN_ST_RESERVED_MASK)
|
||||
nvme_printf(ctrlr, "SMART WARNING: unknown critical warning(s): state = 0x%02x\n",
|
||||
state & NVME_CRIT_WARN_ST_RESERVED_MASK);
|
||||
|
Loading…
Reference in New Issue
Block a user