ExAcquireResourceExclusiveLite recursive calls

Hello all,
This is “Extending my FS knowledge base” type of question:
During a kernel debug on NT40-SP6a, I saw the call stack below in one of
system threads:

ChildEBP RetAddr Args to Child
f1251e08 801185ea 80c5e180 8094bb78 80d1c100 nt!KiSwapThread+0x1b1
f1251e2c 80109c01 80b0b268 00000000 00000000
nt!KeWaitForSingleObject+0x1b8
f1251e5c 801091b6 8094bb78 80b0b268 8094bbac
nt!ExpWaitForResource+0x29
f1251e78 8010920d 00000000 8094bbac 8094bb78
nt!ExpAcquireResourceExclusiveLite+0x74
f1251e8c 8010919e 8094bb78 00000001 8094bbac
nt!ExAcquireResourceExclusiveLite+0x47
f1251ea8 8010920d f1251ee0 e1dbd484 e1dbd470
nt!ExpAcquireResourceExclusiveLite+0x5c
f1251ebc f0f77b48 8094bb78 00000001 80d1c110
nt!ExAcquireResourceExclusiveLite+0x47
f1251ee0 f0f9a087 80d1c110 80d1c110 80d1c1dc
srv!UnlinkRfcbFromLfcb+0x34
f1251ef0 f0f99d1d 80d1c110 00000000 f1251f3c
srv!SrvCloseCachedRfcb+0x43
f1251f14 f0f79c96 80c5eb60 80c5ec60 00000000
srv!SrvOplockBreakNotification+0xa6
f1251f3c f0f79bf4 80c5eb60 00000000 00000000
srv!DequeueAndProcessWorkItem+0x5d
f1251f4c 8013a1da 80c5eb60 00000000 00000000 srv!WorkerThread+0x27
f1251f7c 80145c3e f0f79bcd 80c5eb60 00000000
nt!PspSystemThreadStartup+0x54
00000000 00000000 00000000 00000000 00000000 nt!KiThreadStartup+0x16

I read that ERESOURCE can be used in recursive serialization, but the 2
ExAcquireResourceExclusiveLite consecutive calls one after another for the
same ERESOURCE, without any intermediate calls (e.g. MM servicing page
faults), are to strange for me to understand.
What could be a reason for such call stack?

WBR Primoz

That’s an “implementation detail” - it’s really just a single call - the
code just happens to use recursive calls to itself when a wait is required.

/simgr

-----Original Message-----
From: Primoz Beltram [mailto:xxxxx@hermes.si]
Sent: Friday, September 27, 2002 5:14 AM
To: File Systems Developers
Subject: [ntfsd] ExAcquireResourceExclusiveLite recursive calls

Hello all,
This is “Extending my FS knowledge base” type of question:
During a kernel debug on NT40-SP6a, I saw the call stack below in one of
system threads:

ChildEBP RetAddr Args to Child
f1251e08 801185ea 80c5e180 8094bb78 80d1c100 nt!KiSwapThread+0x1b1
f1251e2c 80109c01 80b0b268 00000000 00000000
nt!KeWaitForSingleObject+0x1b8
f1251e5c 801091b6 8094bb78 80b0b268 8094bbac
nt!ExpWaitForResource+0x29
f1251e78 8010920d 00000000 8094bbac 8094bb78
nt!ExpAcquireResourceExclusiveLite+0x74
f1251e8c 8010919e 8094bb78 00000001 8094bbac
nt!ExAcquireResourceExclusiveLite+0x47
f1251ea8 8010920d f1251ee0 e1dbd484 e1dbd470
nt!ExpAcquireResourceExclusiveLite+0x5c
f1251ebc f0f77b48 8094bb78 00000001 80d1c110
nt!ExAcquireResourceExclusiveLite+0x47
f1251ee0 f0f9a087 80d1c110 80d1c110 80d1c1dc
srv!UnlinkRfcbFromLfcb+0x34
f1251ef0 f0f99d1d 80d1c110 00000000 f1251f3c
srv!SrvCloseCachedRfcb+0x43
f1251f14 f0f79c96 80c5eb60 80c5ec60 00000000
srv!SrvOplockBreakNotification+0xa6
f1251f3c f0f79bf4 80c5eb60 00000000 00000000
srv!DequeueAndProcessWorkItem+0x5d
f1251f4c 8013a1da 80c5eb60 00000000 00000000 srv!WorkerThread+0x27
f1251f7c 80145c3e f0f79bcd 80c5eb60 00000000
nt!PspSystemThreadStartup+0x54
00000000 00000000 00000000 00000000 00000000 nt!KiThreadStartup+0x16

I read that ERESOURCE can be used in recursive serialization, but the 2
ExAcquireResourceExclusiveLite consecutive calls one after another for the
same ERESOURCE, without any intermediate calls (e.g. MM servicing page
faults), are to strange for me to understand.
What could be a reason for such call stack?

WBR Primoz


You are currently subscribed to ntfsd as: xxxxx@stratus.com
To unsubscribe send a blank email to %%email.unsub%%