The following table identifies the control codes that are used in disk management.
Control code Operation
IOCTL_DISK_CREATE_DISK :
Initializes the specified disk and disk partition table by using the specified information.
IOCTL_DISK_DELETE_DRIVE_LAYOUT
Removes the boot signature from the master boot record.
IOCTL_DISK_FORMAT_TRACKS :
Formats a contiguous set of floppy disk tracks.
IOCTL_DISK_FORMAT_TRACKS_EX :
Formats a contiguous set of floppy disk tracks with an extended set of track specification parameters.
IOCTL_DISK_GET_CACHE_INFORMATION:
Retrieves the disk cache configuration data.
IOCTL_DISK_GET_DRIVE_GEOMETRY_EX :
Retrieves information about the physical disk's geometry.
IOCTL_DISK_GET_DRIVE_LAYOUT_EX
Retrieves information about the number of partitions on a disk and the features of each partition.
IOCTL_DISK_GET_LENGTH_INFO
Retrieves the length of the specified disk, volume, or partition.
IOCTL_DISK_GET_PARTITION_INFO_EX
Retrieves partition information for AT and EFI (Extensible Firmware Interface) partitions.
IOCTL_DISK_GROW_PARTITION
Enlarges the specified partition.
IOCTL_DISK_IS_WRITABLE
Determines whether the specified disk is writable.
IOCTL_DISK_PERFORMANCE
Provides disk performance information.
IOCTL_DISK_PERFORMANCE_OFF
Disables disk performance information.
IOCTL_DISK_REASSIGN_BLOCKS
Maps disk blocks to spare-block pool.
IOCTL_DISK_SET_CACHE_INFORMATION
Sets the disk cache configuration data.
IOCTL_DISK_SET_DRIVE_LAYOUT_EX
Partitions a disk.
IOCTL_DISK_SET_PARTITION_INFO_EX
Sets the disk partition type.
IOCTL_DISK_UPDATE_PROPERTIES
Invalidates the cached partition table of the specified disk and re-enumerates the disk.
IOCTL_DISK_VERIFY
Performs logical format of a disk extent.
The following are defragmentation control codes.
Value Meaning
FSCTL_GET_RETRIEVAL_POINTERS Gets information about the cluster use of a file.
FSCTL_GET_VOLUME_BITMAP Gets a bitmap of cluster allocation.
FSCTL_MOVE_FILE Moves all or part of a file from one set of clusters to another within a volume.
The following list identifies the obsolete control codes:
IOCTL_DISK_CONTROLLER_NUMBER
IOCTL_DISK_GET_DRIVE_GEOMETRY
IOCTL_DISK_GET_DRIVE_LAYOUT
IOCTL_DISK_GET_PARTITION_INFO
IOCTL_DISK_HISTOGRAM_DATA
IOCTL_DISK_HISTOGRAM_RESET
IOCTL_DISK_HISTOGRAM_STRUCTURE
IOCTL_DISK_LOGGING
IOCTL_DISK_REQUEST_DATA
IOCTL_DISK_REQUEST_STRUCTURE
IOCTL_DISK_SET_DRIVE_LAYOUT
IOCTL_DISK_SET_PARTITION_INFO