IOCTL_STORAGE_PROTOCOL_COMMAND IOCTL (winioctl.h)
Windows applications can use IOCTL_STORAGE_PROTOCOL_COMMAND to conduct pass-through of protocol specific commands to the storage device or adapter. The request indicates the bus specific command which is further sent to a specific type of device to process. For more information, see the page on working with NVMe drives.
To perform this operation, call the DeviceIoControl function with the following parameters.
BOOL DeviceIoControl(
(HANDLE) hDevice, // handle to device
IOCTL_STORAGE_PROTOCOL_COMMAND, // dwIoControlCode
(LPDWORD) lpInBuffer, // input buffer
(DWORD) nInBufferSize, // size of input buffer
(LPDWORD) lpOutBuffer, // output buffer
(DWORD) nOutBufferSize, // size of output buffer
(LPDWORD) lpBytesReturned, // number of bytes returned
(LPOVERLAPPED) lpOverlapped // OVERLAPPED structure
);
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 10 |
Minimum supported server | Windows Server 2016 |
Header | winioctl.h (include Windows.h) |