ntStatus = AFSCommonWrite( AFSRDRDeviceObject, Irp, NULL);
}
- __except( AFSExceptionFilter( GetExceptionCode(), GetExceptionInformation()) )
+ __except( AFSExceptionFilter( __FUNCTION__, GetExceptionCode(), GetExceptionInformation()) )
{
ntStatus = STATUS_INSUFFICIENT_RESOURCES;
BOOLEAN bReleasePaging = FALSE;
BOOLEAN bExtendingWrite = FALSE;
BOOLEAN bCompleteIrp = TRUE;
- BOOLEAN bForceFlush = FALSE;
BOOLEAN bLockOK;
- BOOLEAN bMapped = TRUE;
HANDLE hCallingUser = OnBehalfOf;
ULONG ulExtensionLength = 0;
BOOLEAN bRetry = FALSE;
if( NULL != pFileObject->SectionObjectPointer->DataSectionObject && !bPagingIo && bNonCachedIo)
{
bNonCachedIo = FALSE;
- bForceFlush = TRUE;
}
if( (!bPagingIo && !bNonCachedIo))
*/
//
- // If they are not mapped and we are the Lazy Writer then just
- // say "not now"
- //
- if (!bMapped && pFcb->Specific.File.LazyWriterThread == PsGetCurrentThread())
- {
-
- AFSDbgLogMsg( AFS_SUBSYSTEM_IO_PROCESSING,
- AFS_TRACE_LEVEL_VERBOSE,
- "AFSCommonWrite (%08lX) Failing lazy writer for unmapped request\n",
- Irp);
-
- try_return ( ntStatus = STATUS_FILE_LOCK_CONFLICT);
- }
-
- //
// Take locks
//
// - if Paging then we need to nothing (the precalls will
liStartingByte.QuadPart,
ulByteCount);
- ntStatus = AFSCachedWrite( DeviceObject, Irp, liStartingByte, ulByteCount, bForceFlush);
+ ntStatus = AFSCachedWrite( DeviceObject, Irp, liStartingByte, ulByteCount, TRUE);
}
else
Irp->IoStatus.Information > 0)
{
+ if ( !bLocked)
+ {
+
+ AFSAcquireShared( &pFcb->NPFcb->Specific.File.ExtentsResource,
+ TRUE);
+ bLocked = TRUE;
+ }
+
//
// Since this is dirty we can mark the extents dirty now.
// AFSMarkDirty will dereference the extents. Do not call
if( pGatherIo)
{
- AFSExFreePool(pGatherIo);
+ AFSExFreePoolWithTag(pGatherIo, AFS_GATHER_TAG);
}
if( NULL != pIoRuns &&
stIoRuns != pIoRuns)
{
- AFSExFreePool(pIoRuns);
+ AFSExFreePoolWithTag(pIoRuns, AFS_IO_RUN_TAG);
}
if( bCompleteIrp)
if( pIoRequest != NULL)
{
- AFSExFreePool( pIoRequest);
+ AFSExFreePoolWithTag( pIoRequest, AFS_GENERIC_MEMORY_14_TAG);
}
}