IOCTL_SCSISCAN_SET_TIMEOUT IOCTL

The IOCTL_SCSISCAN_SET_TIMEOUT control code modifies the time-out value used by the kernel-mode still image driver for SCSI buses when it accesses a device.

Major Code

IRP_MJ_DEVICE_CONTROL

Input Buffer

The location containing a time-out value, in half seconds.

Input Buffer Length

Size of the input buffer

Output Buffer

Set to NULL.

Output Buffer Length

Set to 0.

Status Block

Irp->IoStatus.Status is set to STATUS_SUCCESS if the request is successful. Otherwise, Status to the appropriate error condition as a NTSTATUS code.

Remarks

When the kernel-mode SCSI still image driver sends a SCSI command to a device, by default the driver waits 30 seconds before timing out the operation. You can change the time-out value for a device by calling the DeviceloControl function with the IOCTL_SCSISCAN_CMD control code. The specified time-out value stays in effect until the device is closed.

Time-out values are specified in half seconds. Thus a specified value of 100 causes the driver to wait 50 seconds before timing out the device.

For more information, see Accessing Kernel-Mode Drivers for Still Image Devices.

Code example

ULONG timeout = 240;
fRet = DeviceIoControl( m_DeviceDataHandle,
        (DWORD)IOCTL_SCSISCAN_SET_TIMEOUT,
        &timeout,
        sizeof(ULONG),
        NULL, NULL, &dwBytesReturned, NULL);

Requirements

   
Header scsiscan.h (include Scsiscan.h)

See Also

Creating IOCTL Requests in Drivers

WdfIoTargetSendInternalIoctlOthersSynchronously

WdfIoTargetSendInternalIoctlSynchronously

WdfIoTargetSendIoctlSynchronously