NVMe Admin Commands
Here are the NVMe admin commands with opcodes:
- Create and Delete I/O Submission Queue (01h, 00h)
- Get Log Page (02h)
- Create and Delete I/O Completion Queue (05h, 04h)
- Identify (06h)
- Abort (08h)
- Get and Set Features (0Ah, 09h)
- Asynchronous Event Request (0Ch)
- Namespace Management (0Dh)
- Firmware Commit and Image Download (10h, 11h)
- Device Self-test (14h)
- Namespace Attachment (15h)
- Keep Alive (18h)
- Directive Send and Receive (19h, 1Ah)
- Virtualization Management (1Ch)
- NVMe-MI Send and Receive (1Dh, 1Eh)
- Doorbell Buffer Config (7Ch)
- Format NVM (80h)
- Security Send and Receive (81h, 82h)
- Sanitize (84h)
Submission Queue Entry
As we have seen from the id-ctrl output, submission queue entry (SQE) size is 64 bytes. What is in this 64-bytes ? It consists of:
- Command Dword 0 (CDW0), 4 bytes: Includes Command Identifier (2 bytes) and Opcode (1 byte)
- Namespace Identifier (NSID), 4 bytes. If it is not used, it should be cleared to zero. If it is set to 0xFFFFFFFF, it causes command to be applied to all namespaces.
- Following 8 bytes are reserved.
- Metadata Pointer (MPTR), 8 bytes.
- Data Pointer (DPTR), 16 bytes.
- Command Dword 10 (CDW10), 4 bytes
- Command Dword 11 (CDW11), 4 bytes
- Command Dword 12 (CDW12), 4 bytes
- Command Dword 13 (CDW13), 4 bytes
- Command Dword 14 (CDW14), 4 bytes
- Command Dword 15 (CDW15), 4 bytes
NVM Commands
Here are the NVM commands with opcodes:
- Flush (00h)
- Write and Read (01h, 02h)
- Write Uncorrectable (04h)
- Compare (05h)
- Write Zeroes (08h)
- Dataset Management (09h)
- Reservation Register and Report (0Dh, 0Eh)
- Reservation Acquire and Release (11h, 15h)
NVME I/O Commands
A QUICK TOUR OF NVM EXPRESS (NVME)
蛋蛋读NVMe之一
蛋蛋读NVMe之二
蛋蛋读NVMe之三
蛋蛋读NVMe之四