From 26e17c070f845e4d93bff080eead9f5d22253319 Mon Sep 17 00:00:00 2001 From: Ian Moffett Date: Wed, 10 Jul 2024 22:00:27 -0400 Subject: kernel: nvme: Improve nvme_identify() Require an NSID and CNS value to be passed to the nvme_identify() function. This enables the caller to control what type of data is returned by the NVMe controller. Signed-off-by: Ian Moffett --- sys/include/dev/ic/nvmevar.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'sys/include') diff --git a/sys/include/dev/ic/nvmevar.h b/sys/include/dev/ic/nvmevar.h index aa68331..355abd8 100644 --- a/sys/include/dev/ic/nvmevar.h +++ b/sys/include/dev/ic/nvmevar.h @@ -37,6 +37,10 @@ #define NVME_OP_CREATE_IOCQ 0x05 #define NVME_OP_IDENTIFY 0x06 +/* Identify CNS values */ +#define ID_CNS_CTRL 0x01 /* Identify controller */ +#define ID_CNS_NSID_LIST 0x07 /* Active NSID list */ + struct nvme_identify_cmd { uint8_t opcode; uint8_t flags; -- cgit v1.2.3