Don't wait after the flush command for a non busy hd. Modified: trunk/reactos/drivers/storage/atapi/atapi.c _____
Modified: trunk/reactos/drivers/storage/atapi/atapi.c --- trunk/reactos/drivers/storage/atapi/atapi.c 2005-09-26 20:00:48 UTC (rev 18104) +++ trunk/reactos/drivers/storage/atapi/atapi.c 2005-09-26 20:06:49 UTC (rev 18105) @@ -947,7 +947,6 @@
if (Result != SRB_STATUS_PENDING) { DevExt->CurrentSrb = NULL; - Srb->SrbStatus = (UCHAR)Result;
ScsiPortNotification(RequestComplete, DeviceExtension, @@ -2350,22 +2349,6 @@ DeviceExtension->DeviceFlags[Srb->TargetId] & DEVICE_48BIT_ADDRESS ? IDE_CMD_FLUSH_CACHE_EXT : IDE_CMD_FLUSH_CACHE, AtapiNoDataInterrupt);
- /* Wait for controller ready */ - for (Retries = 0; Retries < IDE_MAX_WRITE_RETRIES; Retries++) - { - Status = IDEReadStatus(DeviceExtension->CommandPortBase); - if (!(Status & IDE_SR_BUSY) || (Status & IDE_SR_ERR)) - { - break; - } - ScsiPortStallExecution(10); - } - if (Retries >= IDE_MAX_WRITE_RETRIES) - { - DPRINT1("Drive is BUSY for too long after sending write command\n"); - DeviceExtension->Handler = NULL; - return(SRB_STATUS_BUSY); - }
DPRINT("AtapiFlushCache() done!\n");