End_Critical_Section


include vmm.inc

VMMcall End_Critical_Section

Releases the critical section if the current virtual machine owns the section and the claim count is zero. Uses Flags.

This service decrements the claim count and releases the critical section if the new count is zero. Since releasing the critical section lowers the execution priority of the current virtual machine, this service causes a task switch if a nonsuspended virtual machine has higher priority.

It is extremely risky for a virtual device to end a critical section it did not enter, or which it entered from a thread other than the current thread.

See also Begin_Critical_Section, End_Crit_And_Suspend