Вопрос

There are two ways to disable all APCs:

  1. call KeEnterGuardedRegion();

  2. call KeRaiseIrql(APC_LEVEL, &old_irql);

What's the difference?

Это было полезно?

Решение

See the MSDN documentation titled Disabling APCs:

Using a guarded region is faster than raising and lowering the current IRQL, but guarded regions are only available in Windows Server 2003 and later versions of Windows.

So, if your code needs to support Windows XP, use KeRaiseIrql.

If not, use KeEnterGuardedRegion.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top