mirror of
https://github.com/reactos/reactos.git
synced 2025-05-16 15:50:24 +00:00
[USBSTOR]
- Only send read format capacity when the device type is zero (direct access device) - Add fixme [INF] - Fix issue - USB CDROM installation now starts svn path=/trunk/; revision=55661
This commit is contained in:
parent
1ead4da36a
commit
c1c3ea3ac8
3 changed files with 31 additions and 8 deletions
|
@ -210,7 +210,15 @@ USBSTOR_HandleTransferError(
|
|||
|
||||
if (NT_SUCCESS(Status))
|
||||
{
|
||||
DPRINT1("Retrying Count %x\n", Context->RetryCount);
|
||||
//
|
||||
// FIXME: inquiry cmd / read format capacity are send w/o irp
|
||||
//
|
||||
ASSERT(Context);
|
||||
ASSERT(Context->PDODeviceExtension);
|
||||
ASSERT(Context->PDODeviceExtension->Self);
|
||||
ASSERT(Context->Irp);
|
||||
|
||||
DPRINT1("Retrying Count %x %p\n", Context->RetryCount, Context->PDODeviceExtension->Self);
|
||||
|
||||
//
|
||||
// re-schedule request
|
||||
|
|
|
@ -964,6 +964,7 @@ USBSTOR_CreatePDO(
|
|||
PDEVICE_OBJECT PDO;
|
||||
NTSTATUS Status;
|
||||
PPDO_DEVICE_EXTENSION PDODeviceExtension;
|
||||
PUFI_INQUIRY_RESPONSE Response;
|
||||
|
||||
//
|
||||
// create child device object
|
||||
|
@ -1012,22 +1013,36 @@ USBSTOR_CreatePDO(
|
|||
*ChildDeviceObject = PDO;
|
||||
|
||||
//
|
||||
// send inquiry command
|
||||
// FIXME: send inquiry command by irp
|
||||
//
|
||||
USBSTOR_SendInquiryCmd(PDO, 0);
|
||||
|
||||
//
|
||||
// retrieve format capacity
|
||||
// check response data
|
||||
//
|
||||
if (NT_SUCCESS(USBSTOR_SendFormatCapacity(PDO, 0)))
|
||||
Response = (PUFI_INQUIRY_RESPONSE)PDODeviceExtension->InquiryData;
|
||||
ASSERT(Response);
|
||||
|
||||
if (Response->DeviceType == 0)
|
||||
{
|
||||
//
|
||||
// check if its a floppy
|
||||
// check if it is a floppy
|
||||
//
|
||||
PDODeviceExtension->IsFloppy = USBSTOR_IsFloppy(PDODeviceExtension->FormatData, PAGE_SIZE /*FIXME*/, &PDODeviceExtension->MediumTypeCode);
|
||||
DPRINT1("[USBSTOR] IsFloppy %x MediumTypeCode %x\n", PDODeviceExtension->IsFloppy, PDODeviceExtension->MediumTypeCode);
|
||||
}
|
||||
Status = USBSTOR_SendFormatCapacity(PDO, 0);
|
||||
if (NT_SUCCESS(Status))
|
||||
{
|
||||
//
|
||||
// check if its a floppy
|
||||
//
|
||||
PDODeviceExtension->IsFloppy = USBSTOR_IsFloppy(PDODeviceExtension->FormatData, PAGE_SIZE /*FIXME*/, &PDODeviceExtension->MediumTypeCode);
|
||||
DPRINT1("[USBSTOR] IsFloppy %x MediumTypeCode %x\n", PDODeviceExtension->IsFloppy, PDODeviceExtension->MediumTypeCode);
|
||||
}
|
||||
|
||||
//
|
||||
// failing command is non critical
|
||||
//
|
||||
Status = STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
|
|
Binary file not shown.
Loading…
Reference in a new issue