ExAcquireRundownProtectionCacheAwareEx function (wdm.h)

The ExAcquireRundownProtectionCacheAwareEx routine tries to acquire cache-aware run-down protection on a shared object so the caller can safely access the object.

Syntax

BOOLEAN ExAcquireRundownProtectionCacheAwareEx(
  [in, out] PEX_RUNDOWN_REF_CACHE_AWARE RunRefCacheAware,
  [in]      ULONG                       Count
);

Parameters

[in, out] RunRefCacheAware

Pointer to the opaque EX_RUNDOWN_REF_CACHE_AWARE structure returned by a previous call to ExAllocateCacheAwareRundownProtection or ExInitializeRundownProtectionCacheAware.

[in] Count

The amount by which to increment to the run-down instance count of the object. The count is incremented only if the routine returns TRUE. For more information, see Remarks.

Return value

ExAcquireRundownProtectionCacheAwareEx returns TRUE if the routine successfully acquires run-down protection for the caller. Otherwise, it returns FALSE. A return value of FALSE indicates that the run down of the object has started and that the object must be treated as invalid.

Remarks

The RunRefCacheAware parameter points to an EX_RUNDOWN_REF_CACHE_AWARE structure that tracks the run-down status of the associated object. This status information includes a count of instances of cache-aware run-down protection that are currently in effect on the object. The ExAcquireRundownProtectionCacheAwareEx and ExReleaseRundownProtectionCacheAwareEx routines increment and decrement this count by arbitrary amounts. Two related routines, ExAcquireRundownProtectionCacheAware and ExReleaseRundownProtectionCacheAware, increment and decrement this count by one.

As long as the run-down block itself is nonpaged, this function can be called at DISPATCH_LEVEL.

For more information, see Cache-aware run-down protection.

Requirements

Requirement Value
Minimum supported server Windows Server 2003, Service Pack 1
Header wdm.h (include Wdm.h)
DDI compliance rules HwStorPortProhibitedDDIs(storport)

See also

ExAcquireRundownProtectionCacheAware

ExAllocateCacheAwareRundownProtection

ExFreeCacheAwareRundownProtection

ExInitializeRundownProtectionCacheAware

ExReInitializeRundownProtectionCacheAware

ExReleaseRundownProtectionCacheAware

ExReleaseRundownProtectionCacheAwareEx

ExRundownCompletedCacheAware

ExSizeOfRundownProtectionCacheAware

ExWaitForRundownProtectionReleaseCacheAware