KeReleaseSpinLock macro

The KeReleaseSpinLock routine releases a spin lock and restores the original IRQL at which the caller was running.

Syntax

VOID
KeReleaseSpinLock (
    _Inout_ PKSPIN_LOCK SpinLock,
    _In_ _IRQL_restores_ KIRQL NewIrql
    );

Parameters

SpinLock

Pointer to a KSPIN_LOCK spin lock for which the caller provides the storage.

NewIrql

Specifies the KIRQL value saved from the preceding call to KeAcquireSpinLock.

Return value

None

Remarks

This call is a reciprocal to KeAcquireSpinLock. The input NewIrql value must be the OldIrql returned by KeAcquireSpinLock.

For more information about spin locks, see Spin Locks.

Callers of this routine are running at IRQL = DISPATCH_LEVEL. On return from KeReleaseSpinLock, IRQL is restored to the NewIrql value.

Requirements

   
Minimum supported client Available starting with Windows 2000.
Target Platform Universal
Header wdm.h (include Wdm.h, Ntddk.h, Ntifs.h)
Library Hal.lib
IRQL DISPATCH_LEVEL (see Remarks section)
DDI compliance rules IrqlKeReleaseSpinLock, MarkingQueuedIrps, SpinLock, SpinLockDpc, SpinlockRelease, SpinLockSafe, ReqSendWhileSpinlock, Spinlock(kmdf), SpinlockDpc(kmdf), SpinlockRelease(kmdf), HwStorPortProhibitedDDIs, IrqlKeReleaseSpinLock(storport), SpinLock(storport), SpinLockDpc(storport), SpinLockRelease(storport), SpinLockSafe(storport)

See also

KeAcquireSpinLock

KeInitializeSpinLock