Windows: AFSPerformObjectInvalidate hold ExtentsResource shared
The AFSPerformObjectInvalidate() was obtaining exclusive
access to the Fcb ExtentsResource even though it was not
tearing down the extents list. The ExtentsResource could
be held shared instead. Doing so will avoid the following
deadlock:
Thread 1:
nt!MmPurgeSection+0x403
nt!CcPurgeCacheSection+0x100
AFSRedirLib!AFSPerformObjectInvalidate+0xd4
AFSRedirLib!AFSWorkerThread+0xa4
nt!PspSystemThreadStartup+0x2e
Thread 2:
AFSRedirLib!AFSAcquireShared+0x18
AFSRedirLib!AFSMarkDirty+0x68
AFSRedirLib!AFSNonCachedWrite+0x603
AFSRedirLib!AFSCommonWrite+0x5fa
AFSRedirLib!AFSWrite+0x20
nt!IofCallDriver+0x45
AFSRedir!AFSWrite+0x57
nt!IofCallDriver+0x45
fltMgr!FltpDispatch+0x6f
nt!IofCallDriver+0x45
AMFilter+0x2c6e
nt!IofCallDriver+0x45
PMDriver+0x112a
nt!IofCallDriver+0x45
OpLoader+0x1cd2
nt!IofCallDriver+0x45
savonaccesscontrol+0x6f15
savonaccessfilter+0x2fa0
nt!IofCallDriver+0x45
nt!IoAsynchronousPageWrite+0xd0
nt!MiMappedPageWriter+0x127
nt!PspSystemThreadStartup+0x2e
Thread 1 is attempting to perform a cache purge which cannot complete
until Thread 2 is finished but Thread 2 requires the ExtentsResource
which is held by Thread 1.
Change-Id: I4582093cf973f61cf6aff0df5e23b6711ec708b3
Reviewed-on: http://gerrit.openafs.org/6744
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>