Author: fireball
Date: Sun Sep 9 21:06:14 2007
New Revision: 28983
URL:
http://svn.reactos.org/svn/reactos?rev=28983&view=rev
Log:
- Make sure CLASS2 driver returns STATUS_UNSUCCESSFUL if receiving a RESET_DEVICE ioctl.
Modified:
trunk/reactos/drivers/storage/class/class2/class2.c
Modified: trunk/reactos/drivers/storage/class/class2/class2.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/class/clas…
==============================================================================
--- trunk/reactos/drivers/storage/class/class2/class2.c (original)
+++ trunk/reactos/drivers/storage/class/class2/class2.c Sun Sep 9 21:06:14 2007
@@ -3551,6 +3551,14 @@
NTSTATUS status;
ULONG modifiedIoControlCode;
+ // Class can't handle RESET_DEVICE ioctl
+ if (irpStack->Parameters.DeviceIoControl.IoControlCode ==
IOCTL_STORAGE_RESET_DEVICE)
+ {
+ status = Irp->IoStatus.Status = STATUS_UNSUCCESSFUL;
+ IoCompleteRequest(Irp, IO_NO_INCREMENT);
+ goto SetStatusAndReturn;
+ }
+
//
// If this is a pass through I/O control, set the minor function code
// and device address and pass it to the port driver.