ReactOS  0.4.15-dev-5089-g555bec6
kefuncs.h
Go to the documentation of this file.
1 /******************************************************************************
2  * Kernel Functions *
3  ******************************************************************************/
5 #if defined(_M_IX86)
6 $include(x86/ke.h)
7 #elif defined(_M_AMD64)
8 $include(amd64/ke.h)
9 #elif defined(_M_IA64)
10 $include(ia64/ke.h)
11 #elif defined(_M_PPC)
12 $include(ppc/ke.h)
13 #elif defined(_M_MIPS)
14 $include(mips/ke.h)
15 #elif defined(_M_ARM)
16 $include(arm/ke.h)
17 #elif defined(_M_ARM64)
18 $include(arm64/ke.h)
19 #else
20 #error Unknown Architecture
21 #endif
22 
24 VOID
25 NTAPI
30 
33 VOID
34 NTAPI
38 $if (_NTDDK_)
39 
43 VOID
45 KeInvalidateRangeAllCaches(
49 
50 #if (NTDDI_VERSION >= NTDDI_WIN2K)
51 
52 $if (_WDMDDK_)
53 #if defined(_NTDDK_) || defined(_NTIFS_)
57 VOID
58 NTAPI
60  __in_data_source(USER_MODE) _In_reads_bytes_(Length) CONST VOID *Address, /* CONST is added */
63 #endif /* defined(_NTDDK_) || defined(_NTIFS_) */
64 
68 VOID
69 NTAPI
74 
76 $if (_NTDDK_)
78 VOID
79 NTAPI
83 
86 LONG
87 NTAPI
91  _In_ BOOLEAN Wait);
92 
96 LONG
97 NTAPI
101 
102 _Acquires_lock_(_Global_critical_region_)
105 VOID
106 NTAPI
108 
109 _Releases_lock_(_Global_critical_region_)
112 VOID
113 NTAPI
115 
118 VOID
119 NTAPI
120 KeBugCheck(
121  _In_ ULONG BugCheckCode);
123 $if (_WDMDDK_ || _NTDDK_)
124 #if defined(SINGLE_GROUP_LEGACY_API)
126 
127 $if (_WDMDDK_)
131 VOID
132 NTAPI
134 
138 VOID
139 NTAPI
142 
144 VOID
145 NTAPI
148  _In_ CCHAR Number);
149 
151 KAFFINITY
152 NTAPI
155 $if (_NTDDK_)
156 
158 VOID
159 NTAPI
162  _In_ CCHAR Number);
163 
165 KAFFINITY
166 NTAPI
168 $endif (_NTDDK_)
169 $if (_WDMDDK_ || _NTDDK_)
170 #endif /* defined(SINGLE_GROUP_LEGACY_API) */
172 
173 $if (_WDMDDK_)
174 #if !defined(_M_AMD64)
176 ULONGLONG
177 NTAPI
179 
181 VOID
182 NTAPI
184  _Out_ PLARGE_INTEGER CurrentTime);
185 #endif /* !_M_AMD64 */
186 
187 #if !defined(_X86_) && !defined(_M_ARM)
194 KIRQL
195 NTAPI
198 
199 #define KeAcquireSpinLock(SpinLock, OldIrql) \
200  *(OldIrql) = KeAcquireSpinLockRaiseToDpc(SpinLock)
201 
206 VOID
207 NTAPI
210 
215 VOID
216 NTAPI
220 
225 VOID
226 NTAPI
229 #endif /* !_X86_ */
230 
231 #if defined(_X86_) && (defined(_WDM_INCLUDED_) || defined(WIN9X_COMPAT_SPINLOCK))
233 VOID
234 NTAPI
237 #else
239 VOID
241 {
242  /* Clear the lock */
243  *SpinLock = 0;
244 }
245 #endif
246 
249 VOID
250 NTAPI
252  _In_ ULONG BugCheckCode,
253  _In_ ULONG_PTR BugCheckParameter1,
254  _In_ ULONG_PTR BugCheckParameter2,
255  _In_ ULONG_PTR BugCheckParameter3,
256  _In_ ULONG_PTR BugCheckParameter4);
257 
260 BOOLEAN
261 NTAPI
263  _Inout_ PKTIMER);
264 
268 NTSTATUS
269 NTAPI
271  _In_ KPROCESSOR_MODE WaitMode,
274 
277 BOOLEAN
278 NTAPI
281 
282 _Acquires_lock_(_Global_critical_region_)
285 VOID
286 NTAPI
288 
291 VOID
292 NTAPI
294  _Out_ PKDEVICE_QUEUE DeviceQueue);
295 
297 VOID
298 NTAPI
301  _In_ PKDEFERRED_ROUTINE DeferredRoutine,
303 
305 VOID
306 NTAPI
309  _In_ ULONG Level);
310 
313 VOID
314 NTAPI
316  _Out_ PRKSEMAPHORE Semaphore,
318  _In_ LONG Limit);
319 
322 VOID
323 NTAPI
326 
329 VOID
330 NTAPI
334 
337 BOOLEAN
338 NTAPI
340  _Inout_ PKDEVICE_QUEUE DeviceQueue,
342  _In_ ULONG SortKey);
343 
346 BOOLEAN
347 NTAPI
349  _Inout_ PKDEVICE_QUEUE DeviceQueue,
351 
353 BOOLEAN
354 NTAPI
359 
360 _Releases_lock_(_Global_critical_region_)
363 VOID
364 NTAPI
366 
367 NTHALAPI
369 NTAPI
371  _Out_opt_ PLARGE_INTEGER PerformanceFrequency);
372 
375 KPRIORITY
376 NTAPI
379 
381 ULONG
382 NTAPI
384 
387 LONG
388 NTAPI
391 
394 LONG
395 NTAPI
396 KeReadStateMutex(
398 
401 LONG
402 NTAPI
404  _In_ PRKSEMAPHORE Semaphore);
405 
408 BOOLEAN
409 NTAPI
411  _In_ PKTIMER Timer);
412 
415 BOOLEAN
416 NTAPI
421  _In_ ULONG Length,
423 
427 LONG
428 NTAPI
431  _In_ BOOLEAN Wait);
432 
436 LONG
437 NTAPI
439  _Inout_ PRKSEMAPHORE Semaphore,
443 
447 NTAPI
449  _Inout_ PKDEVICE_QUEUE DeviceQueue,
450  _In_ ULONG SortKey);
451 
455 NTAPI
457  _Inout_ PKDEVICE_QUEUE DeviceQueue);
458 
461 BOOLEAN
462 NTAPI
464  _Inout_ PKDEVICE_QUEUE DeviceQueue,
466 
469 BOOLEAN
470 NTAPI
472  _Inout_ PRKDPC Dpc);
473 
476 LONG
477 NTAPI
480 
484 LONG
485 NTAPI
486 KeSetEvent(
490 
492 VOID
493 NTAPI
497 
501 KPRIORITY
502 NTAPI
506 
509 BOOLEAN
510 NTAPI
511 KeSetTimer(
514  _In_opt_ PKDPC Dpc);
515 
518 BOOLEAN
519 NTAPI
524  _In_opt_ PKDPC Dpc);
525 
526 NTHALAPI
527 VOID
528 NTAPI
530  _In_ ULONG MicroSeconds);
531 
534 BOOLEAN
535 NTAPI
540 
545 NTSTATUS
546 NTAPI
548  _In_ ULONG Count,
550  _In_ __drv_strictTypeMatch(__drv_typeConst) WAIT_TYPE WaitType,
551  _In_ __drv_strictTypeMatch(__drv_typeCond) KWAIT_REASON WaitReason,
552  _In_ __drv_strictType(KPROCESSOR_MODE/enum _MODE,__drv_typeConst) KPROCESSOR_MODE WaitMode,
556 
557 #define KeWaitForMutexObject KeWaitForSingleObject
558 
563 NTSTATUS
564 NTAPI
567  _In_ __drv_strictTypeMatch(__drv_typeCond) KWAIT_REASON WaitReason,
568  _In_ __drv_strictType(KPROCESSOR_MODE/enum _MODE,__drv_typeConst) KPROCESSOR_MODE WaitMode,
572 $if (_NTIFS_)
573 
575 VOID
576 NTAPI
578  _Out_ PRKMUTANT Mutant,
580 
583 LONG
584 NTAPI
586  _In_ PRKMUTANT Mutant);
587 
591 LONG
592 NTAPI
594  _Inout_ PRKMUTANT Mutant,
597  _In_ BOOLEAN Wait);
598 
600 VOID
601 NTAPI
604  _In_ ULONG Count);
605 
608 LONG
609 NTAPI
612 
616 LONG
617 NTAPI
621 
625 LONG
626 NTAPI
630 
636 NTAPI
639  _In_ KPROCESSOR_MODE WaitMode,
641 
644 VOID
645 NTAPI
648 
651 VOID
652 NTAPI
654 
658 NTAPI
661 
664 VOID
665 NTAPI
669 
672 VOID
673 NTAPI
676 
680 UCHAR
681 NTAPI
685 
688 BOOLEAN
689 NTAPI
692 
693 #if defined(_X86_)
698 NTHALAPI
699 KIRQL
700 FASTCALL
703 #else
709 KIRQL
712 #endif
713 $endif (_NTIFS_)
714 
715 #endif /* (NTDDI_VERSION >= NTDDI_WIN2K) */
716 
717 #if (NTDDI_VERSION >= NTDDI_WINXP)
718 
719 $if (_WDMDDK_)
724 _IRQL_saves_global_(QueuedSpinLock,LockHandle)
727 VOID
728 FASTCALL
732 
738 VOID
739 FASTCALL
743 
745 _Acquires_lock_(*Interrupt->ActualLock)
750 KIRQL
751 NTAPI
754 
758 BOOLEAN
759 NTAPI
761 
763 ULONG
764 NTAPI
766 
769 ULONG
770 NTAPI
774 
779 VOID
780 FASTCALL
783 
784 _Requires_lock_held_(*Interrupt->ActualLock)
785 _Releases_lock_(*Interrupt->ActualLock)
788 VOID
789 NTAPI
793 
797 NTAPI
799  _Inout_ PKDEVICE_QUEUE DeviceQueue,
800  _In_ ULONG SortKey);
801 
805 _IRQL_restores_global_(QueuedSpinLock,LockHandle)
807 VOID
808 FASTCALL
812 $if (_NTDDK_)
816 BOOLEAN
817 NTAPI
819 $endif (_NTDDK_)
820 $if (_NTIFS_)
821 
826 KIRQL
827 FASTCALL
830 
834 VOID
835 FASTCALL
838  _In_ KIRQL OldIrql);
839 
841 _Post_satisfies_(return == 1 || return == 0)
843 LOGICAL
844 FASTCALL
848 $endif (_NTIFS_)
849 
850 #endif /* (NTDDI_VERSION >= NTDDI_WINXP) */
851 
852 $if (_WDMDDK_)
853 #if (NTDDI_VERSION >= NTDDI_WINXPSP1)
854 
857 BOOLEAN
858 NTAPI
861 
864 BOOLEAN
865 NTAPI
871 
872 #endif /* (NTDDI_VERSION >= NTDDI_WINXPSP1) */
873 
874 #if (NTDDI_VERSION >= NTDDI_WINXPSP2)
877 VOID
878 NTAPI
880 #endif /* (NTDDI_VERSION >= NTDDI_WINXPSP2) */
882 $if (_WDMDDK_ || _NTDDK_)
883 #if (NTDDI_VERSION >= NTDDI_WS03)
885 
886 $if (_WDMDDK_)
889 PVOID
890 NTAPI
894 
897 NTSTATUS
898 NTAPI
900  _In_ PVOID Handle);
901 
903 VOID
904 NTAPI
906  _Out_ PRKDPC Dpc,
907  _In_ PKDEFERRED_ROUTINE DeferredRoutine,
909 
913 ULONG_PTR
914 NTAPI
916  _In_ PKIPI_BROADCAST_WORKER BroadcastFunction,
918 
924 KIRQL
925 FASTCALL
928 
933 VOID
934 FASTCALL
938 
941 BOOLEAN
942 FASTCALL
946 
947 $if (_NTDDK_)
949 BOOLEAN
950 NTAPI
952 $endif (_NTDDK_)
953 $if (_WDMDDK_ || _NTDDK_)
954 #endif /* (NTDDI_VERSION >= NTDDI_WS03) */
956 $if (_WDMDDK_ || _NTDDK_)
957 #if (NTDDI_VERSION >= NTDDI_WS03SP1)
959 
960 $if (_WDMDDK_)
963 _Post_satisfies_(return == 1 || return == 0)
965 BOOLEAN
966 FASTCALL
969  _When_(return!=0, _Acquires_lock_(*_Curr_))
971 
975 BOOLEAN
976 NTAPI
978 
979 _Acquires_lock_(_Global_critical_region_)
985 VOID
986 FASTCALL
988  _Inout_ PKGUARDED_MUTEX GuardedMutex);
989 
990 _Requires_lock_not_held_(*FastMutex)
991 _Acquires_lock_(*FastMutex)
995 VOID
996 FASTCALL
998  _Inout_ PKGUARDED_MUTEX GuardedMutex);
999 
1000 _Acquires_lock_(_Global_critical_region_)
1003 VOID
1004 NTAPI
1006 
1007 _Releases_lock_(_Global_critical_region_)
1010 VOID
1011 NTAPI
1013 
1017 VOID
1018 FASTCALL
1020  _Out_ PKGUARDED_MUTEX GuardedMutex);
1021 
1022 _Requires_lock_held_(*FastMutex)
1023 _Releases_lock_(*FastMutex)
1026 VOID
1027 FASTCALL
1029  _Inout_ PKGUARDED_MUTEX GuardedMutex);
1030 
1031 _Releases_lock_(_Global_critical_region_)
1036 VOID
1037 FASTCALL
1039  _Inout_ PKGUARDED_MUTEX GuardedMutex);
1040 
1044 _Post_satisfies_(return == 1 || return == 0)
1046 BOOLEAN
1047 FASTCALL
1049  _When_ (return, _Requires_lock_not_held_(*_Curr_) _Acquires_exclusive_lock_(*_Curr_)) _Acquires_lock_(_Global_critical_region_)
1050  _Inout_ PKGUARDED_MUTEX GuardedMutex);
1051 $endif (_WDMDDK_)
1052 $if (_NTDDK_)
1056 NTSTATUS
1057 NTAPI
1058 KeExpandKernelStackAndCallout(
1059  _In_ PEXPAND_STACK_CALLOUT Callout,
1061  _In_ SIZE_T Size);
1062 
1063 _Acquires_lock_(_Global_critical_region_)
1066 VOID
1067 NTAPI
1069 
1070 _Releases_lock_(_Global_critical_region_)
1073 VOID
1074 NTAPI
1076 $endif (_NTDDK_)
1077 $if (_WDMDDK_ || _NTDDK_)
1078 #endif /* (NTDDI_VERSION >= NTDDI_WS03SP1) */
1079 $endif (_WDMDDK_ || _NTDDK_)
1080 
1081 #if (NTDDI_VERSION >= NTDDI_VISTA)
1082 $if (_WDMDDK_)
1087 _IRQL_saves_global_(QueuedSpinLock,LockHandle)
1089 VOID
1090 FASTCALL
1094 
1098 _IRQL_restores_global_(QueuedSpinLock,LockHandle)
1100 VOID
1101 FASTCALL
1104 
1107 NTSTATUS
1108 NTAPI
1109 KeQueryDpcWatchdogInformation(
1110  _Out_ PKDPC_WATCHDOG_INFORMATION WatchdogInformation);
1111 $endif (_WDMDDK_)
1112 $if (_WDMDDK_ || _NTDDK_)
1113 #if defined(SINGLE_GROUP_LEGACY_API)
1114 $endif (_WDMDDK_ || _NTDDK_)
1115 
1116 $if (_WDMDDK_)
1120 KAFFINITY
1121 NTAPI
1122 KeSetSystemAffinityThreadEx(
1124 
1128 VOID
1129 NTAPI
1130 KeRevertToUserAffinityThreadEx(
1132 
1134 ULONG
1135 NTAPI
1137  _Out_opt_ PKAFFINITY ActiveProcessors);
1138 
1140 ULONG
1141 NTAPI
1142 KeQueryMaximumProcessorCount(VOID);
1143 $endif (_WDMDDK_)
1144 $if (_NTDDK_)
1146 ULONG
1147 NTAPI
1149  _Out_opt_ PKAFFINITY ActiveProcessors);
1150 
1152 ULONG
1153 NTAPI
1154 KeQueryMaximumProcessorCount(VOID);
1155 $endif (_NTDDK_)
1156 $if (_WDMDDK_ || _NTDDK_)
1157 #endif /* SINGLE_GROUP_LEGACY_API */
1158 $endif (_WDMDDK_ || _NTDDK_)
1159 $if (_NTIFS_)
1162 VOID
1163 KeQueryOwnerMutant(
1164  _In_ PKMUTANT Mutant,
1166 
1171 ULONG
1172 NTAPI
1173 KeRemoveQueueEx(
1175  _In_ KPROCESSOR_MODE WaitMode,
1178  _Out_writes_to_(Count, return) PLIST_ENTRY *EntryArray,
1179  _In_ ULONG Count);
1180 $endif (_NTIFS_)
1181 
1182 #endif /* (NTDDI_VERSION >= NTDDI_VISTA) */
1183 
1184 $if (_WDMDDK_)
1185 #if (NTDDI_VERSION >= NTDDI_WS08)
1186 
1188 PVOID
1189 NTAPI
1190 KeRegisterProcessorChangeCallback(
1193  _In_ ULONG Flags);
1194 
1196 VOID
1197 NTAPI
1198 KeDeregisterProcessorChangeCallback(
1199  _In_ PVOID CallbackHandle);
1200 
1201 #endif /* (NTDDI_VERSION >= NTDDI_WS08) */
1202 $endif (_WDMDDK_)
1203 $if (_WDMDDK_ || _NTDDK_)
1204 #if (NTDDI_VERSION >= NTDDI_WIN7)
1205 
1207 ULONG
1208 NTAPI
1209 KeQueryActiveProcessorCountEx(
1210  _In_ USHORT GroupNumber);
1211 
1213 ULONG
1214 NTAPI
1216  _In_ USHORT GroupNumber);
1217 
1219 USHORT
1220 NTAPI
1222 
1224 USHORT
1225 NTAPI
1227 
1229 KAFFINITY
1230 NTAPI
1232  _In_ USHORT GroupNumber);
1233 
1235 ULONG
1236 NTAPI
1238  _Out_opt_ PPROCESSOR_NUMBER ProcNumber);
1239 
1241 VOID
1242 NTAPI
1247 
1249 USHORT
1250 NTAPI
1253 
1255 USHORT
1256 NTAPI
1258 
1260 USHORT
1261 NTAPI
1263 
1266 NTSTATUS
1267 NTAPI
1268 KeQueryLogicalProcessorRelationship(
1269  _In_opt_ PPROCESSOR_NUMBER ProcessorNumber OPTIONAL,
1273 
1274 $endif (_WDMDDK_ || _NTDDK_)
1275 
1276 $if (_WDMDDK_)
1280 ULONG64
1281 NTAPI
1282 KeQueryTotalCycleTimeProcess(
1285 
1289 ULONG64
1290 NTAPI
1291 KeQueryTotalCycleTimeThread(
1294 
1297 NTSTATUS
1298 NTAPI
1300  _Inout_ PKDPC Dpc,
1301  _In_ PPROCESSOR_NUMBER ProcNumber);
1302 
1306 VOID
1307 NTAPI
1308 KeSetSystemGroupAffinityThread(
1311 
1315 VOID
1316 NTAPI
1317 KeRevertToUserGroupAffinityThread(
1319 
1322 BOOLEAN
1323 NTAPI
1324 KeSetCoalescableTimer(
1327  _In_ ULONG Period,
1329  _In_opt_ PKDPC Dpc);
1330 
1332 ULONGLONG
1333 NTAPI
1335 
1338 _Ret_range_(<=, 0)
1341 NTSTATUS
1342 NTAPI
1343 KeSaveExtendedProcessorState(
1344  _In_ ULONG64 Mask,
1346  _When_(return==0, _Acquires_lock_(*_Curr_))
1347  PXSTATE_SAVE XStateSave);
1348 
1351 VOID
1352 NTAPI
1354  _In_ _Requires_lock_held_(*_Curr_) _Releases_lock_(*_Curr_)
1355  PXSTATE_SAVE XStateSave);
1356 
1357 NTSTATUS
1358 NTAPI
1360  _In_ ULONG ProcIndex,
1361  _Out_ PPROCESSOR_NUMBER ProcNumber);
1362 
1363 ULONG
1364 NTAPI
1366  _In_ PPROCESSOR_NUMBER ProcNumber);
1367 $endif (_WDMDDK_)
1368 $if (_NTDDK_)
1371 NTSTATUS
1372 NTAPI
1373 KeSetHardwareCounterConfiguration(
1375  _In_ ULONG Count);
1376 
1379 NTSTATUS
1380 NTAPI
1381 KeQueryHardwareCounterConfiguration(
1384  _Out_ PULONG Count);
1385 $endif (_NTDDK_)
1386 $if (_WDMDDK_ || _NTDDK_)
1387 #endif /* (NTDDI_VERSION >= NTDDI_WIN7) */
1388 $endif (_WDMDDK_ || _NTDDK_)
1389 $if (_WDMDDK_)
1390 #if !defined(_IA64_)
1391 NTHALAPI
1392 VOID
1393 NTAPI
1395 #endif
1396 
1397 /* VOID
1398  * KeInitializeCallbackRecord(
1399  * IN PKBUGCHECK_CALLBACK_RECORD CallbackRecord)
1400  */
1401 #define KeInitializeCallbackRecord(CallbackRecord) \
1402  (CallbackRecord)->State = BufferEmpty;
1403 
1404 #if defined(_PREFAST_)
1405 
1406 void __PREfastPagedCode(void);
1407 void __PREfastPagedCodeLocked(void);
1408 #define PAGED_CODE() __PREfastPagedCode();
1409 #define PAGED_CODE_LOCKED() __PREfastPagedCodeLocked();
1410 
1411 #elif DBG
1412 
1413 #if (NTDDI_VERSION >= NTDDI_VISTA)
1414 #define PAGED_ASSERT( exp ) NT_ASSERT( exp )
1415 #else
1416 #define PAGED_ASSERT( exp ) ASSERT( exp )
1417 #endif
1418 
1419 #define PAGED_CODE() { \
1420  if (KeGetCurrentIrql() > APC_LEVEL) { \
1421  KdPrint( ("NTDDK: Pageable code called at IRQL > APC_LEVEL (%d)\n", KeGetCurrentIrql() )); \
1422  PAGED_ASSERT(FALSE); \
1423  } \
1424 }
1425 
1426 #define PAGED_CODE_LOCKED() NOP_FUNCTION;
1427 
1428 #else
1429 
1430 #define PAGED_CODE() NOP_FUNCTION;
1431 #define PAGED_CODE_LOCKED() NOP_FUNCTION;
1432 
1433 #endif /* DBG */
1434 
1435 $endif (_WDMDDK_)
NTKERNELAPI ULONGLONG NTAPI KeQueryUnbiasedInterruptTime(VOID)
_In_ LARGE_INTEGER _In_ ULONG _In_ ULONG TolerableDelay
Definition: kefuncs.h:1326
_Requires_lock_held_ SpinLock _Releases_lock_ SpinLock _In_ _IRQL_restores_ KIRQL NewIrql
Definition: kefuncs.h:219
ULONG NTAPI KeQueryRuntimeThread(IN PKTHREAD Thread, OUT PULONG UserTime)
Definition: thrdobj.c:980
NTKERNELAPI DECLSPEC_NORETURN VOID NTAPI KeBugCheck(_In_ ULONG BugCheckCode)
return
Definition: dirsup.c:529
NTKERNELAPI ULONG NTAPI KeGetRecommendedSharedDataAlignment(VOID)
Definition: cpu.c:496
* PPROCESSOR_NUMBER
Definition: ntbasedef.h:642
_In_ LONG Count
Definition: kefuncs.h:317
BOOLEAN NTAPI KeSetTimer(IN OUT PKTIMER Timer, IN LARGE_INTEGER DueTime, IN PKDPC Dpc OPTIONAL)
Definition: timerobj.c:281
NTHALAPI VOID NTAPI KeStallExecutionProcessor(_In_ ULONG MicroSeconds)
Definition: delay.c:30
_In_ ULONG _In_ ULONG _In_ ULONG Length
Definition: ntddpcm.h:101
LONG NTAPI KeInsertHeadQueue(IN PKQUEUE Queue, IN PLIST_ENTRY Entry)
Definition: queue.c:172
_Must_inspect_result_ _In_ PWDF_DPC_CONFIG _In_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFDPC * Dpc
Definition: wdfdpc.h:107
#define _In_opt_
Definition: ms_sal.h:309
#define _Inout_
Definition: ms_sal.h:378
ULONG NTAPI KeGetProcessorIndexFromNumber(_In_ PPROCESSOR_NUMBER ProcNumber)
BOOLEAN NTAPI KeAreAllApcsDisabled(VOID)
Definition: apc.c:985
VOID FASTCALL KeAcquireGuardedMutex(IN PKGUARDED_MUTEX GuardedMutex)
Definition: gmutex.c:42
#define _Out_
Definition: ms_sal.h:345
#define _At_(target, annos)
Definition: ms_sal.h:244
#define NTHALAPI
Definition: ntoskrnl.h:40
_In_opt_ PVOID CallbackContext
Definition: kefuncs.h:1192
NTKERNELAPI VOID NTAPI KeQueryNodeActiveAffinity(_In_ USHORT NodeNumber, _Out_opt_ PGROUP_AFFINITY Affinity, _Out_opt_ PUSHORT Count)
KIPI_BROADCAST_WORKER * PKIPI_BROADCAST_WORKER
Definition: ketypes.h:605
$include(setypes.h) $include(obtypes.h) $include(rtltypes.h) $include(rtlfuncs.h) _IRQL_requires_max_(PASSIVE_LEVEL) __kernel_entry NTSYSCALLAPI NTSTATUS NTAPI NtQueryObject(_In_opt_ HANDLE Handle
NTKERNELAPI VOID NTAPI KeInitializeMutex(_Out_ PRKMUTEX Mutex, _In_ ULONG Level)
_In_ ULONG Component
Definition: potypes.h:496
_Must_inspect_result_ _In_ WDFDEVICE _In_ PIRP _In_ WDFQUEUE Queue
Definition: wdfdevice.h:2221
VOID NTAPI KeRevertToUserAffinityThread(VOID)
Definition: thrdobj.c:1030
_In_ WDFDPC _In_ BOOLEAN Wait
Definition: wdfdpc.h:167
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFINTERRUPT * Interrupt
Definition: wdfinterrupt.h:372
VOID NTAPI KeInitializeMutant(IN PKMUTANT Mutant, IN BOOLEAN InitialOwner)
Definition: mutex.c:22
unsigned char * PUCHAR
Definition: retypes.h:3
#define _Points_to_data_
Definition: ms_sal.h:552
VOID NTAPI KeAcquireSpinLockAtDpcLevel(IN PKSPIN_LOCK SpinLock)
Definition: spinlock.c:198
LONG NTSTATUS
Definition: precomp.h:26
_Inout_ PKDEVICE_QUEUE_ENTRY _In_ ULONG SortKey
Definition: kefuncs.h:341
_In_ ULONGLONG _In_ ULONGLONG _In_ BOOLEAN Enable
Definition: ntddpcm.h:140
#define _Out_writes_to_(size, count)
Definition: ms_sal.h:355
BOOLEAN NTAPI KeReadStateTimer(IN PKTIMER Timer)
Definition: timerobj.c:269
#define NTKRNLVISTAAPI
#define _NTIFS_
Definition: ifssupp.h:20
VOID NTAPI KeInitializeDeviceQueue(IN PKDEVICE_QUEUE DeviceQueue)
Definition: devqueue.c:22
NTKERNELAPI DECLSPEC_NORETURN VOID NTAPI KeBugCheckEx(_In_ ULONG BugCheckCode, _In_ ULONG_PTR BugCheckParameter1, _In_ ULONG_PTR BugCheckParameter2, _In_ ULONG_PTR BugCheckParameter3, _In_ ULONG_PTR BugCheckParameter4)
Definition: rtlcompat.c:108
BOOLEAN NTAPI KeRemoveQueueDpc(IN PKDPC Dpc)
Definition: dpc.c:878
_In_ LARGE_INTEGER _In_ ULONG Period
Definition: kefuncs.h:1326
IN PVOID IN PVOID IN USHORT IN USHORT Size
Definition: pci.h:361
_In_ UCHAR Processor
Definition: kefuncs.h:684
#define _WDMDDK_
Definition: wdm.template.h:26
$if(_WDMDDK_) NTKERNELAPI VOID NTAPI KeInitializeEvent(_Out_ PRKEVENT Event
Definition: ke.h:1
NTHALAPI LARGE_INTEGER NTAPI KeQueryPerformanceCounter(_Out_opt_ PLARGE_INTEGER PerformanceFrequency)
LONG NTAPI KeSetBasePriorityThread(IN PKTHREAD Thread, IN LONG Increment)
Definition: thrdobj.c:1184
_IRQL_requires_same_ typedef _In_ ULONG _In_ UCHAR Level
Definition: wmitypes.h:55
KSPIN_LOCK * PKSPIN_LOCK
Definition: env_spec_w32.h:73
BOOLEAN NTAPI KeSetTimerEx(IN OUT PKTIMER Timer, IN LARGE_INTEGER DueTime, IN LONG Period, IN PKDPC Dpc OPTIONAL)
Definition: timerobj.c:294
KPRIORITY NTAPI KeQueryPriorityThread(IN PKTHREAD Thread)
Definition: thrdobj.c:1017
_Acquires_exclusive_lock_(Vcb->Resource)) FINISHED FatAcquireExclusiveVcb_Real(IN PIRP_CONTEXT IrpContext
NTKRNLVISTAAPI USHORT NTAPI KeGetCurrentNodeNumber(VOID)
_In_ PVOID Parameter
Definition: ldrtypes.h:241
VOID FASTCALL KeAcquireInStackQueuedSpinLock(IN PKSPIN_LOCK SpinLock, IN PKLOCK_QUEUE_HANDLE LockHandle)
Definition: spinlock.c:130
LONG NTAPI KeReleaseMutex(IN PKMUTEX Mutex, IN BOOLEAN Wait)
Definition: mutex.c:189
LONG NTAPI KeSetEvent(IN PKEVENT Event, IN KPRIORITY Increment, IN BOOLEAN Wait)
Definition: eventobj.c:159
NTSTATUS NTAPI KeWaitForSingleObject(IN PVOID Object, IN KWAIT_REASON WaitReason, IN KPROCESSOR_MODE WaitMode, IN BOOLEAN Alertable, IN PLARGE_INTEGER Timeout OPTIONAL)
Definition: wait.c:416
#define FASTCALL
Definition: nt_native.h:50
NTKERNELAPI VOID NTAPI KeSetImportanceDpc(_Inout_ PRKDPC Dpc, _In_ KDPC_IMPORTANCE Importance)
_In_ WDFREQUEST _In_ NTSTATUS _In_ ULONG_PTR Information
Definition: wdfrequest.h:1044
#define DECLSPEC_NORETURN
Definition: ntbasedef.h:176
VOID NTAPI ProbeForWrite(IN PVOID Address, IN SIZE_T Length, IN ULONG Alignment)
Definition: exintrin.c:143
_In_ PCALLBACK_FUNCTION CallbackFunction
Definition: exfuncs.h:1034
LONG KPRIORITY
Definition: compat.h:662
Definition: Mutex.h:15
VOID NTAPI KeSetSystemAffinityThread(IN KAFFINITY Affinity)
Definition: thrdobj.c:1116
KBUGCHECK_CALLBACK_ROUTINE * PKBUGCHECK_CALLBACK_ROUTINE
Definition: ketypes.h:320
_Acquires_lock_(_Global_critical_region_) _IRQL_requires_max_(APC_LEVEL) NTKERNELAPI VOID NTAPI KeEnterCriticalRegion(VOID)
Definition: Object.c:59
uint32_t ULONG_PTR
Definition: typedefs.h:65
PLIST_ENTRY NTAPI KeRundownQueue(IN PKQUEUE Queue)
Definition: queue.c:438
_Out_ PUSHORT NodeNumber
Definition: iofuncs.h:2574
UCHAR KIRQL
Definition: env_spec_w32.h:591
_Must_inspect_result_ _In_ PFLT_GET_OPERATION_STATUS_CALLBACK CallbackRoutine
Definition: fltkernel.h:1035
KBUGCHECK_REASON_CALLBACK_RECORD CallbackRecord
_In_ LOGICAL_PROCESSOR_RELATIONSHIP RelationshipType
Definition: kefuncs.h:1270
NTSTATUS(* NTAPI)(IN PFILE_FULL_EA_INFORMATION EaBuffer, IN ULONG EaLength, OUT PULONG ErrorOffset)
Definition: IoEaTest.cpp:117
#define FALSE
Definition: types.h:117
VOID NTAPI KeStackAttachProcess(IN PKPROCESS Process, OUT PRKAPC_STATE ApcState)
Definition: procobj.c:704
_In_ KPRIORITY _In_ BOOLEAN Abandoned
Definition: kefuncs.h:595
_In_ KPRIORITY _In_ LONG Adjustment
Definition: kefuncs.h:440
long LONG
Definition: pedump.c:60
NTKERNELAPI VOID NTAPI KeInitializeQueue(_Out_ PRKQUEUE Queue, _In_ ULONG Count)
_Must_inspect_result_ _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFSPINLOCK * SpinLock
Definition: wdfsync.h:225
NTSTATUS NTAPI KeDelayExecutionThread(IN KPROCESSOR_MODE WaitMode, IN BOOLEAN Alertable, IN PLARGE_INTEGER Interval OPTIONAL)
Definition: wait.c:283
LOGICAL FASTCALL KeTryToAcquireQueuedSpinLock(IN KSPIN_LOCK_QUEUE_NUMBER LockNumber, OUT PKIRQL OldIrql)
Definition: spinlock.c:192
#define __drv_aliasesMem
Definition: btrfs_drv.h:203
_Requires_lock_held_ LockHandle _Releases_lock_ LockHandle LockHandle NTKERNELAPI VOID FASTCALL KeReleaseInStackQueuedSpinLockForDpc(_In_ PKLOCK_QUEUE_HANDLE LockHandle)
VOID NTAPI KeReleaseInterruptSpinLock(IN PKINTERRUPT Interrupt, IN KIRQL OldIrql)
Definition: spinlock.c:171
#define _Maybe_raises_SEH_exception_
Definition: ms_sal.h:2956
_Must_inspect_result_ NTKERNELAPI NTSTATUS NTAPI KeSetTargetProcessorDpcEx(_Inout_ PKDPC Dpc, _In_ PPROCESSOR_NUMBER ProcNumber)
FORCEINLINE VOID KeInitializeSpinLock(_Out_ PKSPIN_LOCK SpinLock)
Definition: kefuncs.h:240
NTKERNELAPI BOOLEAN NTAPI KeInsertQueueDpc(_Inout_ PRKDPC Dpc, _In_opt_ PVOID SystemArgument1, _In_opt_ PVOID SystemArgument2)
BOOLEAN NTAPI KeInsertByKeyDeviceQueue(IN PKDEVICE_QUEUE DeviceQueue, IN PKDEVICE_QUEUE_ENTRY DeviceQueueEntry, IN ULONG SortKey)
Definition: devqueue.c:83
KAFFINITY * PKAFFINITY
Definition: basetsd.h:197
VOID FASTCALL KeReleaseSpinLockForDpc(IN PKSPIN_LOCK SpinLock, IN KIRQL OldIrql)
Definition: spinlock.c:435
unsigned char BOOLEAN
_Requires_lock_held_ SpinLock _Releases_lock_ SpinLock _IRQL_requires_(DISPATCH_LEVEL) NTKERNELAPI VOID NTAPI KeReleaseSpinLock(_Inout_ PKSPIN_LOCK SpinLock
Definition: expool.c:1456
LONG NTAPI KeReadStateQueue(IN PKQUEUE Queue)
Definition: queue.c:226
_When_(Wait==0, _IRQL_requires_max_(DISPATCH_LEVEL)) _When_(Wait
static WCHAR Address[46]
Definition: ping.c:68
#define KeLeaveGuardedRegion()
Definition: ke_x.h:68
KSYNCHRONIZE_ROUTINE * PKSYNCHRONIZE_ROUTINE
Definition: ketypes.h:863
#define _In_
Definition: ms_sal.h:308
VOID NTAPI KeInitializeTimer(OUT PKTIMER Timer)
Definition: timerobj.c:233
#define NTKERNELAPI
#define _IRQL_requires_same_
Definition: driverspecs.h:232
NTKRNLVISTAAPI ULONG NTAPI KeQueryActiveProcessorCount(OUT PKAFFINITY ActiveProcessors OPTIONAL)
Definition: ke.c:15
NTKERNELAPI USHORT NTAPI KeQueryNodeMaximumProcessorCount(_In_ USHORT NodeNumber)
Definition: bufpool.h:45
_In_ KPRIORITY Increment
Definition: kefuncs.h:90
LONG NTAPI KePulseEvent(IN PKEVENT Event, IN KPRIORITY Increment, IN BOOLEAN Wait)
Definition: eventobj.c:68
KBUGCHECK_REASON_CALLBACK_ROUTINE * PKBUGCHECK_REASON_CALLBACK_ROUTINE
Definition: ketypes.h:259
WaitType
Definition: shlextdbg.cpp:17
PKDEVICE_QUEUE_ENTRY NTAPI KeRemoveByKeyDeviceQueueIfBusy(IN PKDEVICE_QUEUE DeviceQueue, IN ULONG SortKey)
Definition: devqueue.c:273
#define _Requires_lock_not_held_(lock)
PROCESSOR_CALLBACK_FUNCTION * PPROCESSOR_CALLBACK_FUNCTION
Definition: ketypes.h:362
#define _Out_writes_bytes_opt_(size)
Definition: ms_sal.h:351
_Must_inspect_result_ _In_ __in_data_source(USER_MODE) SIZE_T Size
#define _Kernel_float_restored_
Definition: driverspecs.h:239
*Count PHARDWARE_COUNTER CounterArray
Definition: kefuncs.h:1382
_Must_inspect_result_ NTKERNELAPI BOOLEAN NTAPI KeDeregisterBugCheckCallback(_Inout_ PKBUGCHECK_CALLBACK_RECORD CallbackRecord)
enum _EVENT_TYPE EVENT_TYPE
_Out_ PULONG UserTime
Definition: kefuncs.h:773
_In_opt_ PVOID _In_opt_ PVOID SystemArgument1
Definition: ketypes.h:675
BOOLEAN NTAPI KeInvalidateAllCaches(VOID)
Definition: cpu.c:484
enum _KDPC_IMPORTANCE KDPC_IMPORTANCE
_In_ HANDLE _Outptr_result_bytebuffer_ ViewSize PVOID * BaseAddress
Definition: mmfuncs.h:404
VOID FASTCALL KeAcquireInStackQueuedSpinLockAtDpcLevel(IN PKSPIN_LOCK SpinLock, IN PKLOCK_QUEUE_HANDLE LockHandle)
Definition: spinlock.c:363
#define _Ret_range_(lb, ub)
Definition: ms_sal.h:573
#define IPI_LEVEL
Definition: env_spec_w32.h:701
BOOLEAN NTAPI KeCancelTimer(IN OUT PKTIMER Timer)
Definition: timerobj.c:206
_Must_inspect_result_ _In_ ULONG Flags
Definition: wsk.h:170
_Out_ PCLIENT_ID ClientId
Definition: kefuncs.h:1165
VOID NTAPI KeInitializeSemaphore(IN PKSEMAPHORE Semaphore, IN LONG Count, IN LONG Limit)
Definition: semphobj.c:22
_In_ PKSYNCHRONIZE_ROUTINE SynchronizeRoutine
Definition: kefuncs.h:538
enum _LOGICAL_PROCESSOR_RELATIONSHIP LOGICAL_PROCESSOR_RELATIONSHIP
unsigned int Mask
Definition: fpcontrol.c:82
KAFFINITY NTAPI KeQueryActiveProcessors(VOID)
Definition: cpu.c:458
_Must_inspect_result_ _Success_(return !=FALSE) _IRQL_requires_max_(APC_LEVEL) _Post_satisfies_(return
Returns the name of an atom.
Definition: fsctrl.c:3139
char CCHAR
Definition: typedefs.h:51
#define _DECL_HAL_KE_IMPORT
uint64_t ULONGLONG
Definition: typedefs.h:67
_Requires_lock_not_held_ SpinLock _Acquires_lock_ SpinLock _IRQL_raises_(SYNCH_LEVEL) _IRQL_saves_ NTKERNELAPI KIRQL KeAcquireSpinLockRaiseToSynch(_Inout_ PKSPIN_LOCK SpinLock)
NTKERNELAPI VOID NTAPI KeQuerySystemTime(_Out_ PLARGE_INTEGER CurrentTime)
VOID NTAPI KeReleaseSpinLockFromDpcLevel(IN PKSPIN_LOCK SpinLock)
Definition: spinlock.c:221
BOOLEAN NTAPI KeInsertDeviceQueue(IN PKDEVICE_QUEUE DeviceQueue, IN PKDEVICE_QUEUE_ENTRY DeviceQueueEntry)
Definition: devqueue.c:41
Type
Definition: Type.h:6
VOID FASTCALL KeReleaseQueuedSpinLock(IN KSPIN_LOCK_QUEUE_NUMBER LockNumber, IN KIRQL OldIrql)
Definition: spinlock.c:154
_In_ ULONG _In_ ULONG _In_ ULONG _Out_ PKIRQL _Out_ PKAFFINITY Affinity
Definition: halfuncs.h:170
enum _WAIT_TYPE WAIT_TYPE
_In_opt_ PFILE_OBJECT _In_opt_ PETHREAD Thread
Definition: fltkernel.h:2652
_In_ BOOLEAN Alertable
Definition: kefuncs.h:272
KIRQL NTAPI KeAcquireInterruptSpinLock(IN PKINTERRUPT Interrupt)
Definition: spinlock.c:154
CCHAR KPROCESSOR_MODE
Definition: ketypes.h:7
#define KeEnterGuardedRegion()
Definition: ke_x.h:39
NTSTATUS NTAPI KeWaitForMultipleObjects(IN ULONG Count, IN PVOID Object[], IN WAIT_TYPE WaitType, IN KWAIT_REASON WaitReason, IN KPROCESSOR_MODE WaitMode, IN BOOLEAN Alertable, IN PLARGE_INTEGER Timeout OPTIONAL, OUT PKWAIT_BLOCK WaitBlockArray OPTIONAL)
Definition: wait.c:586
LONG NTAPI KeReleaseMutant(IN PKMUTANT Mutant, IN KPRIORITY Increment, IN BOOLEAN Abandon, IN BOOLEAN Wait)
Definition: mutex.c:98
_Requires_lock_held_(Number) _Releases_lock_(Number) _DECL_HAL_KE_IMPORT VOID FASTCALL KeReleaseQueuedSpinLock(_In_ KSPIN_LOCK_QUEUE_NUMBER Number
unsigned __int64 ULONG64
Definition: imports.h:198
enum _TIMER_TYPE TIMER_TYPE
VOID NTAPI KeDetachProcess(VOID)
Definition: procobj.c:621
_In_ WDFINTERRUPT _In_ WDF_INTERRUPT_POLICY _In_ WDF_INTERRUPT_PRIORITY Priority
Definition: wdfinterrupt.h:651
unsigned char UCHAR
Definition: xmlstorage.h:181
*LockHandle LockHandle NTKERNELAPI VOID FASTCALL KeAcquireInStackQueuedSpinLockForDpc(_Inout_ PKSPIN_LOCK SpinLock, _Out_ PKLOCK_QUEUE_HANDLE LockHandle)
#define _IRQL_restores_global_(kind, param)
Definition: driverspecs.h:234
VOID FASTCALL KeReleaseGuardedMutexUnsafe(IN OUT PKGUARDED_MUTEX GuardedMutex)
Definition: gmutex.c:75
_Out_ PKAPC_STATE ApcState
Definition: kefuncs.h:668
VOID NTAPI ProbeForRead(IN CONST VOID *Address, IN SIZE_T Length, IN ULONG Alignment)
Definition: exintrin.c:102
NMI_CALLBACK * PNMI_CALLBACK
Definition: ketypes.h:338
#define _Kernel_float_saved_
Definition: driverspecs.h:240
_Requires_lock_held_ Interrupt _Releases_lock_ Interrupt _In_ _IRQL_restores_ KIRQL OldIrql
Definition: kefuncs.h:792
Definition: ketypes.h:687
KDEFERRED_ROUTINE * PKDEFERRED_ROUTINE
Definition: ketypes.h:678
_Out_opt_ PGROUP_AFFINITY PreviousAffinity
Definition: kefuncs.h:1310
PLIST_ENTRY NTAPI KeRemoveQueue(IN PKQUEUE Queue, IN KPROCESSOR_MODE WaitMode, IN PLARGE_INTEGER Timeout OPTIONAL)
Definition: queue.c:238
BOOLEAN NTAPI KeRemoveEntryDeviceQueue(IN PKDEVICE_QUEUE DeviceQueue, IN PKDEVICE_QUEUE_ENTRY DeviceQueueEntry)
Definition: devqueue.c:348
#define KeEnterCriticalRegion()
Definition: ke_x.h:88
KIRQL * PKIRQL
Definition: env_spec_w32.h:592
_MODE
Definition: ketypes.h:10
Definition: typedefs.h:119
#define SYNCH_LEVEL
Definition: env_spec_w32.h:704
#define PASSIVE_LEVEL
Definition: env_spec_w32.h:693
#define _Must_inspect_result_
Definition: ms_sal.h:558
KIRQL FASTCALL KeAcquireQueuedSpinLock(IN KSPIN_LOCK_QUEUE_NUMBER LockNumber)
Definition: spinlock.c:108
#define _In_reads_(size)
Definition: ms_sal.h:319
_In_opt_ PENTER_STATE_SYSTEM_HANDLER _In_opt_ PVOID _In_ LONG _In_opt_ LONG volatile * Number
Definition: ntpoapi.h:204
_IRQL_requires_min_(PASSIVE_LEVEL) _IRQL_requires_max_(DISPATCH_LEVEL) NTKERNELAPI LONG NTAPI KeSetBasePriorityThread(_Inout_ PRKTHREAD Thread
NTKERNELAPI KAFFINITY NTAPI KeQueryGroupAffinity(_In_ USHORT GroupNumber)
_Must_inspect_result_ NTKERNELAPI BOOLEAN NTAPI KeRegisterBugCheckReasonCallback(_Out_ PKBUGCHECK_REASON_CALLBACK_RECORD CallbackRecord, _In_ PKBUGCHECK_REASON_CALLBACK_ROUTINE CallbackRoutine, _In_ KBUGCHECK_CALLBACK_REASON Reason, _In_ PUCHAR Component)
_Must_inspect_result_ _In_ WDFCOLLECTION _In_ WDFOBJECT Object
_Must_inspect_result_ _Maybe_raises_SEH_exception_ _In_ __drv_strictType(KPROCESSOR_MODE/enum _MODE, __drv_typeConst) KPROCESSOR_MODE AccessMode)
_In_opt_ PVOID _In_opt_ PVOID _In_opt_ PVOID SystemArgument2
Definition: ketypes.h:675
VOID NTAPI KeFlushWriteBuffer(VOID)
Definition: misc.c:39
BOOLEAN NTAPI KeAreApcsDisabled(VOID)
Definition: apc.c:958
#define DISPATCH_LEVEL
Definition: env_spec_w32.h:696
_In_ PKSYNCHRONIZE_ROUTINE _In_opt_ __drv_aliasesMem PVOID SynchronizeContext
Definition: kefuncs.h:538
ULONG_PTR SIZE_T
Definition: typedefs.h:80
enum _KSPIN_LOCK_QUEUE_NUMBER KSPIN_LOCK_QUEUE_NUMBER
LONG NTAPI KeReadStateMutant(IN PKMUTANT Mutant)
Definition: mutex.c:87
KIRQL FASTCALL KeAcquireSpinLockForDpc(IN PKSPIN_LOCK SpinLock)
Definition: spinlock.c:424
#define HIGH_LEVEL
Definition: env_spec_w32.h:703
NTKERNELAPI USHORT NTAPI KeQueryMaximumGroupCount(VOID)
VOID FASTCALL KeInitializeGuardedMutex(OUT PKGUARDED_MUTEX GuardedMutex)
Definition: gmutex.c:31
#define KeLeaveCriticalRegion()
Definition: ke_x.h:119
static ULONG Timeout
Definition: ping.c:61
#define KeInitializeEvent(pEvt, foo, foo2)
Definition: env_spec_w32.h:477
NTKERNELAPI ULONG NTAPI KeQueryTimeIncrement(VOID)
Definition: clock.c:153
LONG NTAPI KeReleaseSemaphore(IN PKSEMAPHORE Semaphore, IN KPRIORITY Increment, IN LONG Adjustment, IN BOOLEAN Wait)
Definition: semphobj.c:54
Definition: ketypes.h:566
NTKERNELAPI ULONG NTAPI KeGetCurrentProcessorNumberEx(_Out_opt_ PPROCESSOR_NUMBER ProcNumber)
KPRIORITY NTAPI KeSetPriorityThread(IN PKTHREAD Thread, IN KPRIORITY Priority)
Definition: thrdobj.c:1327
unsigned short USHORT
Definition: pedump.c:61
_Releases_lock_(_Global_critical_region_) _IRQL_requires_max_(APC_LEVEL) NTKERNELAPI VOID NTAPI KeLeaveCriticalRegion(VOID)
Definition: Object.c:101
BOOLEAN FASTCALL KeTryToAcquireGuardedMutex(IN OUT PKGUARDED_MUTEX GuardedMutex)
Definition: gmutex.c:86
ULONG_PTR KAFFINITY
Definition: compat.h:85
VOID NTAPI KeAttachProcess(IN PKPROCESS Process)
Definition: procobj.c:582
VOID NTAPI KeUnstackDetachProcess(IN PRKAPC_STATE ApcState)
Definition: procobj.c:756
EXPAND_STACK_CALLOUT * PEXPAND_STACK_CALLOUT
Definition: ketypes.h:1095
LONG NTAPI KeInsertQueue(IN PKQUEUE Queue, IN PLIST_ENTRY Entry)
Definition: queue.c:198
LONG NTAPI KeReadStateSemaphore(IN PKSEMAPHORE Semaphore)
Definition: semphobj.c:41
PKDEVICE_QUEUE_ENTRY NTAPI KeRemoveDeviceQueue(IN PKDEVICE_QUEUE DeviceQueue)
Definition: devqueue.c:153
#define FORCEINLINE
Definition: wdftypes.h:67
#define _Out_opt_
Definition: ms_sal.h:346
unsigned int * PULONG
Definition: retypes.h:1
Definition: optimize.h:109
#define NULL
Definition: types.h:112
#define KeReleaseSpinLock(sl, irql)
Definition: env_spec_w32.h:627
#define __drv_strictTypeMatch(mode)
Definition: driverspecs.h:329
NTKERNELAPI ULONG NTAPI KeQueryMaximumProcessorCountEx(_In_ USHORT GroupNumber)
_In_ WDFTIMER _In_ LONGLONG DueTime
Definition: wdftimer.h:187
VOID FASTCALL KeReleaseGuardedMutex(IN OUT PKGUARDED_MUTEX GuardedMutex)
Definition: gmutex.c:53
KIRQL FASTCALL KeAcquireSpinLockRaiseToSynch(PKSPIN_LOCK SpinLock)
Definition: spinlock.c:62
PKDEVICE_QUEUE_ENTRY NTAPI KeRemoveByKeyDeviceQueue(IN PKDEVICE_QUEUE DeviceQueue, IN ULONG SortKey)
Definition: devqueue.c:197
NTKERNELAPI USHORT NTAPI KeQueryActiveGroupCount(VOID)
KIRQL NTAPI KeAcquireSpinLockRaiseToDpc(PKSPIN_LOCK SpinLock)
Definition: spinlock.c:41
_In_ KDPC_IMPORTANCE Importance
Definition: kefuncs.h:82
#define _In_reads_bytes_opt_(size)
Definition: ms_sal.h:322
VOID NTAPI KeSetTargetProcessorDpc(IN PKDPC Dpc, IN CCHAR Number)
Definition: dpc.c:971
_Must_inspect_result_ _In_ PLARGE_INTEGER _In_ PLARGE_INTEGER _In_ ULONG _In_ PFILE_OBJECT _In_ PVOID Process
Definition: fsrtlfuncs.h:219
enum _KWAIT_REASON KWAIT_REASON
_In_ HANDLE Handle
Definition: extypes.h:390
*Count PHARDWARE_COUNTER _In_ ULONG MaximumCount
Definition: kefuncs.h:1382
LONG NTAPI KeReadStateEvent(IN PKEVENT Event)
Definition: eventobj.c:120
VOID FASTCALL KeAcquireGuardedMutexUnsafe(IN OUT PKGUARDED_MUTEX GuardedMutex)
Definition: gmutex.c:64
LONG NTAPI KeResetEvent(IN PKEVENT Event)
Definition: eventobj.c:133
unsigned int ULONG
Definition: retypes.h:1
_Must_inspect_result_ _In_ WAIT_TYPE _In_opt_ PLARGE_INTEGER _In_opt_ PKWAIT_BLOCK WaitBlockArray
Definition: fsrtlfuncs.h:1151
BOOLEAN NTAPI KeSynchronizeExecution(IN OUT PKINTERRUPT Interrupt, IN PKSYNCHRONIZE_ROUTINE SynchronizeRoutine, IN PVOID SynchronizeContext OPTIONAL)
Definition: interrupt.c:165
unsigned __int64 * PULONG64
Definition: imports.h:198
KBUGCHECK_CALLBACK_REASON
Definition: ketypes.h:247
NTSTATUS NTAPI KeGetProcessorNumberFromIndex(_In_ ULONG ProcIndex, _Out_ PPROCESSOR_NUMBER ProcNumber)
NTSTATUS NTAPI KeDeregisterNmiCallback(IN PVOID Handle)
Definition: bug.c:1361
_Must_inspect_result_ NTKERNELAPI BOOLEAN NTAPI KeRegisterBugCheckCallback(_Out_ PKBUGCHECK_CALLBACK_RECORD CallbackRecord, _In_ PKBUGCHECK_CALLBACK_ROUTINE CallbackRoutine, _In_reads_bytes_opt_(Length) PVOID Buffer, _In_ ULONG Length, _In_ PUCHAR Component)
*LockHandle LockHandle _Out_ PKLOCK_QUEUE_HANDLE LockHandle
Definition: kefuncs.h:731
_In_ BOOLEAN _In_ PLARGE_INTEGER Interval
Definition: kefuncs.h:272
VOID FASTCALL KeReleaseInStackQueuedSpinLockFromDpcLevel(IN PKLOCK_QUEUE_HANDLE LockHandle)
Definition: spinlock.c:395
UCHAR NTAPI KeSetIdealProcessorThread(IN PKTHREAD Thread, IN UCHAR Processor)
Definition: thrdobj.c:1075
PVOID NTAPI KeRegisterNmiCallback(IN PNMI_CALLBACK CallbackRoutine, IN PVOID Context)
Definition: bug.c:1327
NTKRNLVISTAAPI USHORT NTAPI KeQueryHighestNodeNumber(VOID)
_Inout_ PKDEVICE_QUEUE_ENTRY DeviceQueueEntry
Definition: kefuncs.h:341
VOID NTAPI KeClearEvent(IN PKEVENT Event)
Definition: eventobj.c:22
_Out_ PULONG64 CycleTimeStamp
Definition: kefuncs.h:1284
$endif(_WDMDDK_) $if(_NTDDK_) _IRQL_requires_min_(PASSIVE_LEVEL) _IRQL_requires_max_(DISPATCH_LEVEL) NTKERNELAPI VOID FASTCALL KeInvalidateRangeAllCaches(_In_ PVOID BaseAddress
Definition: ke.h:202
_Requires_lock_held_ LockHandle _Releases_lock_ LockHandle LockHandle _DECL_HAL_KE_IMPORT VOID FASTCALL KeReleaseInStackQueuedSpinLock(_In_ PKLOCK_QUEUE_HANDLE LockHandle)
BOOLEAN FASTCALL KeTryToAcquireSpinLockAtDpcLevel(IN OUT PKSPIN_LOCK SpinLock)
Definition: spinlock.c:309
PVOID PVOID PWCHAR PVOID USHORT PULONG Reason
Definition: env.c:47
#define _Out_writes_bytes_(size)
Definition: ms_sal.h:350
NTKERNELAPI VOID NTAPI KeInitializeThreadedDpc(_Out_ PRKDPC Dpc, _In_ PKDEFERRED_ROUTINE DeferredRoutine, _In_opt_ PVOID DeferredContext)
#define APC_LEVEL
Definition: env_spec_w32.h:695
#define _IRQL_restores_
Definition: driverspecs.h:233
#define _Post_same_lock_(lock1, lock2)
_IRQL_requires_max_(DISPATCH_LEVEL) NTKERNELAPI VOID NTAPI KeClearEvent(_Inout_ PRKEVENT Event)
Definition: hardware.c:1705
_In_ BOOLEAN InitialOwner
Definition: kefuncs.h:579
VOID NTAPI KeFlushQueuedDpcs(VOID)
Definition: dpc.c:919
_In_ LONG _In_ LONG Limit
Definition: kefuncs.h:317
ULONGLONG NTAPI KeQueryInterruptTime(VOID)
Definition: clock.c:203
#define _IRQL_saves_
Definition: driverspecs.h:235
unsigned short * PUSHORT
Definition: retypes.h:2
#define CONST
Definition: pedump.c:81
_Must_inspect_result_ _Post_satisfies_(return==1||return==0) _DECL_HAL_KE_IMPORT LOGICAL FASTCALL KeTryToAcquireQueuedSpinLock(_In_ KSPIN_LOCK_QUEUE_NUMBER Number
#define _NTDDK_
#define _Literal_
Definition: ms_sal.h:553
base of all file and directory entries
Definition: entries.h:82
VOID NTAPI KeInitializeTimerEx(OUT PKTIMER Timer, IN TIMER_TYPE Type)
Definition: timerobj.c:244
NTKERNELAPI VOID NTAPI KeInitializeDpc(_Out_ __drv_aliasesMem PRKDPC Dpc, _In_ PKDEFERRED_ROUTINE DeferredRoutine, _In_opt_ __drv_aliasesMem PVOID DeferredContext)
* PKAPC_STATE
Definition: ketypes.h:1285
ULONG_PTR NTAPI KeIpiGenericCall(IN PKIPI_BROADCAST_WORKER Function, IN ULONG_PTR Argument)
Definition: ipi.c:196
BOOLEAN NTAPI KeDeregisterBugCheckReasonCallback(IN PKBUGCHECK_REASON_CALLBACK_RECORD CallbackRecord)
Definition: bug.c:1229
BOOLEAN NTAPI KeSetKernelStackSwapEnable(IN BOOLEAN Enable)
Definition: thrdobj.c:997
_Kernel_float_restored_ NTKERNELAPI VOID NTAPI KeRestoreExtendedProcessorState(_In_ _Requires_lock_held_(*_Curr_) _Releases_lock_(*_Curr_) PXSTATE_SAVE XStateSave)
#define _IRQL_saves_global_(kind, param)
Definition: driverspecs.h:236
#define _In_reads_bytes_(size)
Definition: ms_sal.h:321
_Must_inspect_result_ NTKERNELAPI BOOLEAN FASTCALL KeTestSpinLock(_In_ PKSPIN_LOCK SpinLock)
PULONG MinorVersion OPTIONAL
Definition: CrossNt.h:68
_In_opt_ PVOID DeferredContext
Definition: ketypes.h:675