Disk I/O Control Codes

The following summarizes the public I/O control codes that disk-type drivers support. However, each device driver is required to handle only those I/O control codes that its particular device(s) support.

For example, only a floppy driver would handle IOCTL_STORAGE_GET_MEDIA_TYPES requests; it would not handle IOCTL_DISK_GET/SET_PARTITION_INFO or IOCTL_GET/SET_DRIVE_LAYOUT requests. As another example, a filter driver like the system-supplied diskperf driver that monitors disk performance statistics would handle IOCTL_DISK_PERFORMANCE requests from a corresponding (user-mode) application; it would simply pass down other IOCTL_DISK_XXX requests to the underlying disk device driver.

All public I/O control codes for drivers of disk-type devices use buffered I/O. Consequently, the input or output data buffer for these requests is at Irp->AssociatedIrp.SystemBuffer.

Class drivers for storage devices handle additional public I/O control codes, along with those described in this section. For more information about requirements for storage class drivers, see General Storage I/O Control Codes.

The IOCTL_INTERNAL_DISK_XXXXX codes can be used for communication between two kernel-mode drivers.



Send comments about this topic to Microsoft