[DISK] Disable IsFloppyDevice check.
authorVictor Perevertkin <victor@perevertkin.ru>
Sat, 27 Apr 2019 21:44:55 +0000 (00:44 +0300)
committerVictor Perevertkin <victor@perevertkin.ru>
Tue, 11 Jun 2019 01:39:43 +0000 (04:39 +0300)
It wrongly marks USB flash drives as a floppy device

drivers/storage/class/disk/disk.c

index b91e88e..580c899 100644 (file)
@@ -969,12 +969,14 @@ Return Value:
     // IsFloppyDevice also checks for write cache enabled.
     //
 
+#if 0
     if (IsFloppyDevice(deviceObject) && deviceObject->Characteristics & FILE_REMOVABLE_MEDIA &&
         (((PINQUIRYDATA)LunInfo->InquiryData)->DeviceType == DIRECT_ACCESS_DEVICE)) {
 
         status = STATUS_NO_SUCH_DEVICE;
         goto CreateDiskDeviceObjectsExit;
     }
+#endif
 
     DisableWriteCache(deviceObject,LunInfo);