BOOLEAN
IoIsErrorUserInduced(
IN NTSTATUS Status
);
IoIsErrorUserInduced determines whether an I/O error encountered while processing a request to a removable-media device was caused by the user.
IoIsErrorUserInduced returns TRUE if an I/O request failed because of a user-induced error.
If IoIsErrorUserInduced returns TRUE, the removable-media driver must call IoSetHardErrorOrVerifyDevice before completing the IRP.
Callers of IoIsErrorUserInduced must be running at IRQL <= DISPATCH_LEVEL.
IoSetHardErrorOrVerifyDevice, IoAllocateErrorLogEntry, IoWriteErrorLogEntry