次の方法で共有


IOCTL_DISK_DELETE_SECTORS (Compact 2013)

3/26/2014

This I/O control message deletes a specified range of sectors. This is used by the FAL to indicate that the sectors are no longer needed. The sectors are then recycled in the proper manner. For example, this I/O control message should be called by a file system on sectors that are no longer used when a file is deleted. Send this message with DeviceIoControl.

Syntax

BOOL DeviceIoControl(
    HANDLE hDevice,           // handle to device
    DWORD dwIoControlCode,    // use IOCTL_DISK_DELETE_SECTORS
    LPVOID lpInBuffer,        // pointer to input buffer
    DWORD nInBufferSize,      // input buffer size
    LPVOID lpOutBuffer,       // pointer to output buffer
    DWORD nOutBufferSize,     // output buffer size
    LPDWORD lpBytesReturned,  // number of bytes returned
    OVERLAPPED lpOverlapped   // pointer to OVERLAPPED structure
);

Parameters

  • hDevice
    The handle to the device.
  • dwIoControlCode
    [in] Control code for the operation. Use IOCTL_DISK_DELETE_SECTORS for this operation.
  • nInBufferSize
    [in] Size of the DELETE_SECTOR_INFO structure.
  • lpOutBuffer
    [out] Not used; set to NULL.
  • nOutBufferSize
    [out] Not used; set to zero.
  • lpBytesReturned
    [out] Not used; set to NULL.
  • lpOverlapped
    Not used.

Return Values

Returns TRUE value if successful; otherwise, returns FALSE.

Requirements

Header

fmd.h

See Also

Reference

Flash Media Driver IOCTLs
DELETE_SECTOR_INFO