sys: FspVolumeTransact: timeout early if there are retried IRP completions (to avoid stalling unnecessarily)

This commit is contained in:
Bill Zissimopoulos
2016-03-16 00:29:30 -07:00
parent a5765defd3
commit 0cf70387ff
2 changed files with 4 additions and 1 deletions

View File

@ -619,7 +619,9 @@ NTSTATUS FspVolumeTransact(
/* wait for an IRP to arrive */
KeQuerySystemTime(&Timeout);
Timeout.QuadPart += FsvolDeviceExtension->VolumeParams.TransactTimeout * 10000ULL;
Timeout.QuadPart += 0 == RepostedIrp ?
FsvolDeviceExtension->VolumeParams.TransactTimeout * 10000ULL :
FspVolumeTransactEarlyTimeout;
/* convert millis to nanos and add to absolute time */
while (0 == (PendingIrp = FspIoqNextPendingIrp(FsvolDeviceExtension->Ioq, 0, &Timeout, Irp)))
{