ReactOS  0.4.12-dev-409-g9f418243
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 #else
18 #error Unknown Architecture
19 #endif
20 
22 VOID
23 NTAPI
28 
31 VOID
32 NTAPI
36 $if (_NTDDK_)
37 
41 VOID
43 KeInvalidateRangeAllCaches(
47 $if (_NTIFS_)
48 
50 NTAPI
52  _In_ ULONG ProcIndex,
54 
55 ULONG
56 NTAPI
60 
61 #if (NTDDI_VERSION >= NTDDI_WIN2K)
62 
63 $if (_WDMDDK_)
64 #if defined(_NTDDK_) || defined(_NTIFS_)
68 VOID
69 NTAPI
71  __in_data_source(USER_MODE) _In_reads_bytes_(Length) CONST VOID *Address, /* CONST is added */
74 #endif /* defined(_NTDDK_) || defined(_NTIFS_) */
75 
79 VOID
80 NTAPI
85 
87 $if (_NTDDK_)
89 VOID
90 NTAPI
94 
97 LONG
98 NTAPI
102  _In_ BOOLEAN Wait);
103 
107 LONG
108 NTAPI
112 
113 _Acquires_lock_(_Global_critical_region_)
116 VOID
117 NTAPI
119 
120 _Releases_lock_(_Global_critical_region_)
123 VOID
124 NTAPI
126 
129 VOID
130 NTAPI
131 KeBugCheck(
132  _In_ ULONG BugCheckCode);
134 $if (_WDMDDK_ || _NTDDK_)
135 #if defined(SINGLE_GROUP_LEGACY_API)
137 
138 $if (_WDMDDK_)
142 VOID
143 NTAPI
145 
149 VOID
150 NTAPI
153 
155 VOID
156 NTAPI
159  _In_ CCHAR Number);
160 
162 KAFFINITY
163 NTAPI
166 $if (_NTDDK_)
167 
169 VOID
170 NTAPI
173  _In_ CCHAR Number);
174 
176 KAFFINITY
177 NTAPI
179 $endif (_NTDDK_)
180 $if (_WDMDDK_ || _NTDDK_)
181 #endif /* defined(SINGLE_GROUP_LEGACY_API) */
183 
184 $if (_WDMDDK_)
185 #if !defined(_M_AMD64)
187 ULONGLONG
188 NTAPI
190 
192 VOID
193 NTAPI
195  _Out_ PLARGE_INTEGER CurrentTime);
196 #endif /* !_M_AMD64 */
197 
198 #if !defined(_X86_) && !defined(_M_ARM)
205 KIRQL
206 NTAPI
209 
210 #define KeAcquireSpinLock(SpinLock, OldIrql) \
211  *(OldIrql) = KeAcquireSpinLockRaiseToDpc(SpinLock)
212 
217 VOID
218 NTAPI
221 
226 VOID
227 NTAPI
231 
236 VOID
237 NTAPI
240 #endif /* !_X86_ */
241 
242 #if defined(_X86_) && (defined(_WDM_INCLUDED_) || defined(WIN9X_COMPAT_SPINLOCK))
244 VOID
245 NTAPI
248 #else
250 VOID
252 {
253  /* Clear the lock */
254  *SpinLock = 0;
255 }
256 #endif
257 
260 VOID
261 NTAPI
263  _In_ ULONG BugCheckCode,
264  _In_ ULONG_PTR BugCheckParameter1,
265  _In_ ULONG_PTR BugCheckParameter2,
266  _In_ ULONG_PTR BugCheckParameter3,
267  _In_ ULONG_PTR BugCheckParameter4);
268 
271 BOOLEAN
272 NTAPI
274  _Inout_ PKTIMER);
275 
279 NTSTATUS
280 NTAPI
282  _In_ KPROCESSOR_MODE WaitMode,
285 
288 BOOLEAN
289 NTAPI
291  _Inout_ PKBUGCHECK_CALLBACK_RECORD CallbackRecord);
292 
293 _Acquires_lock_(_Global_critical_region_)
296 VOID
297 NTAPI
299 
302 VOID
303 NTAPI
305  _Out_ PKDEVICE_QUEUE DeviceQueue);
306 
308 VOID
309 NTAPI
312  _In_ PKDEFERRED_ROUTINE DeferredRoutine,
314 
316 VOID
317 NTAPI
320  _In_ ULONG Level);
321 
324 VOID
325 NTAPI
327  _Out_ PRKSEMAPHORE Semaphore,
329  _In_ LONG Limit);
330 
333 VOID
334 NTAPI
337 
340 VOID
341 NTAPI
345 
348 BOOLEAN
349 NTAPI
351  _Inout_ PKDEVICE_QUEUE DeviceQueue,
353  _In_ ULONG SortKey);
354 
357 BOOLEAN
358 NTAPI
360  _Inout_ PKDEVICE_QUEUE DeviceQueue,
362 
364 BOOLEAN
365 NTAPI
370 
371 _Releases_lock_(_Global_critical_region_)
374 VOID
375 NTAPI
377 
378 NTHALAPI
380 NTAPI
382  _Out_opt_ PLARGE_INTEGER PerformanceFrequency);
383 
386 KPRIORITY
387 NTAPI
390 
392 ULONG
393 NTAPI
395 
398 LONG
399 NTAPI
402 
405 LONG
406 NTAPI
407 KeReadStateMutex(
409 
412 LONG
413 NTAPI
415  _In_ PRKSEMAPHORE Semaphore);
416 
419 BOOLEAN
420 NTAPI
422  _In_ PKTIMER Timer);
423 
426 BOOLEAN
427 NTAPI
429  _Out_ PKBUGCHECK_CALLBACK_RECORD CallbackRecord,
432  _In_ ULONG Length,
433  _In_ PUCHAR Component);
434 
438 LONG
439 NTAPI
442  _In_ BOOLEAN Wait);
443 
447 LONG
448 NTAPI
450  _Inout_ PRKSEMAPHORE Semaphore,
454 
458 NTAPI
460  _Inout_ PKDEVICE_QUEUE DeviceQueue,
461  _In_ ULONG SortKey);
462 
466 NTAPI
468  _Inout_ PKDEVICE_QUEUE DeviceQueue);
469 
472 BOOLEAN
473 NTAPI
475  _Inout_ PKDEVICE_QUEUE DeviceQueue,
477 
480 BOOLEAN
481 NTAPI
483  _Inout_ PRKDPC Dpc);
484 
487 LONG
488 NTAPI
491 
495 LONG
496 NTAPI
497 KeSetEvent(
501 
503 VOID
504 NTAPI
508 
512 KPRIORITY
513 NTAPI
517 
520 BOOLEAN
521 NTAPI
522 KeSetTimer(
525  _In_opt_ PKDPC Dpc);
526 
529 BOOLEAN
530 NTAPI
535  _In_opt_ PKDPC Dpc);
536 
537 NTHALAPI
538 VOID
539 NTAPI
541  _In_ ULONG MicroSeconds);
542 
545 BOOLEAN
546 NTAPI
548  _Inout_ PKINTERRUPT Interrupt,
551 
556 NTSTATUS
557 NTAPI
559  _In_ ULONG Count,
561  _In_ __drv_strictTypeMatch(__drv_typeConst) WAIT_TYPE WaitType,
562  _In_ __drv_strictTypeMatch(__drv_typeCond) KWAIT_REASON WaitReason,
563  _In_ __drv_strictType(KPROCESSOR_MODE/enum _MODE,__drv_typeConst) KPROCESSOR_MODE WaitMode,
567 
568 #define KeWaitForMutexObject KeWaitForSingleObject
569 
574 NTSTATUS
575 NTAPI
578  _In_ __drv_strictTypeMatch(__drv_typeCond) KWAIT_REASON WaitReason,
579  _In_ __drv_strictType(KPROCESSOR_MODE/enum _MODE,__drv_typeConst) KPROCESSOR_MODE WaitMode,
583 $if (_NTIFS_)
584 
586 VOID
587 NTAPI
589  _Out_ PRKMUTANT Mutant,
591 
594 LONG
595 NTAPI
597  _In_ PRKMUTANT Mutant);
598 
602 LONG
603 NTAPI
605  _Inout_ PRKMUTANT Mutant,
608  _In_ BOOLEAN Wait);
609 
611 VOID
612 NTAPI
614  _Out_ PRKQUEUE Queue,
615  _In_ ULONG Count);
616 
619 LONG
620 NTAPI
622  _In_ PRKQUEUE Queue);
623 
627 LONG
628 NTAPI
630  _Inout_ PRKQUEUE Queue,
632 
636 LONG
637 NTAPI
639  _Inout_ PRKQUEUE Queue,
641 
647 NTAPI
649  _Inout_ PRKQUEUE Queue,
650  _In_ KPROCESSOR_MODE WaitMode,
652 
655 VOID
656 NTAPI
659 
662 VOID
663 NTAPI
665 
669 NTAPI
671  _Inout_ PRKQUEUE Queue);
672 
675 VOID
676 NTAPI
680 
683 VOID
684 NTAPI
687 
691 UCHAR
692 NTAPI
696 
699 BOOLEAN
700 NTAPI
703 
704 #if defined(_X86_)
709 NTHALAPI
710 KIRQL
711 FASTCALL
714 #else
720 KIRQL
723 #endif
724 $endif (_NTIFS_)
725 
726 #endif /* (NTDDI_VERSION >= NTDDI_WIN2K) */
727 
728 #if (NTDDI_VERSION >= NTDDI_WINXP)
729 
730 $if (_WDMDDK_)
735 _IRQL_saves_global_(QueuedSpinLock,LockHandle)
738 VOID
739 FASTCALL
743 
749 VOID
750 FASTCALL
754 
755 _Requires_lock_not_held_(*Interrupt->ActualLock)
756 _Acquires_lock_(*Interrupt->ActualLock)
761 KIRQL
762 NTAPI
764  _Inout_ PKINTERRUPT Interrupt);
765 
769 BOOLEAN
770 NTAPI
772 
774 ULONG
775 NTAPI
777 
780 ULONG
781 NTAPI
785 
790 VOID
791 FASTCALL
794 
795 _Requires_lock_held_(*Interrupt->ActualLock)
796 _Releases_lock_(*Interrupt->ActualLock)
799 VOID
800 NTAPI
802  _Inout_ PKINTERRUPT Interrupt,
804 
808 NTAPI
810  _Inout_ PKDEVICE_QUEUE DeviceQueue,
811  _In_ ULONG SortKey);
812 
816 _IRQL_restores_global_(QueuedSpinLock,LockHandle)
818 VOID
819 FASTCALL
823 $if (_NTDDK_)
827 BOOLEAN
828 NTAPI
830 $endif (_NTDDK_)
831 $if (_NTIFS_)
832 
837 KIRQL
838 FASTCALL
841 
845 VOID
846 FASTCALL
849  _In_ KIRQL OldIrql);
850 
852 _Post_satisfies_(return == 1 || return == 0)
854 LOGICAL
855 FASTCALL
859 $endif (_NTIFS_)
860 
861 #endif /* (NTDDI_VERSION >= NTDDI_WINXP) */
862 
863 $if (_WDMDDK_)
864 #if (NTDDI_VERSION >= NTDDI_WINXPSP1)
865 
868 BOOLEAN
869 NTAPI
872 
875 BOOLEAN
876 NTAPI
881  _In_ PUCHAR Component);
882 
883 #endif /* (NTDDI_VERSION >= NTDDI_WINXPSP1) */
884 
885 #if (NTDDI_VERSION >= NTDDI_WINXPSP2)
888 VOID
889 NTAPI
891 #endif /* (NTDDI_VERSION >= NTDDI_WINXPSP2) */
893 $if (_WDMDDK_ || _NTDDK_)
894 #if (NTDDI_VERSION >= NTDDI_WS03)
896 
897 $if (_WDMDDK_)
900 PVOID
901 NTAPI
905 
908 NTSTATUS
909 NTAPI
911  _In_ PVOID Handle);
912 
914 VOID
915 NTAPI
917  _Out_ PRKDPC Dpc,
918  _In_ PKDEFERRED_ROUTINE DeferredRoutine,
920 
924 ULONG_PTR
925 NTAPI
927  _In_ PKIPI_BROADCAST_WORKER BroadcastFunction,
929 
935 KIRQL
936 FASTCALL
939 
944 VOID
945 FASTCALL
949 
952 BOOLEAN
953 FASTCALL
957 
958 $if (_NTDDK_)
960 BOOLEAN
961 NTAPI
963 $endif (_NTDDK_)
964 $if (_WDMDDK_ || _NTDDK_)
965 #endif /* (NTDDI_VERSION >= NTDDI_WS03) */
967 $if (_WDMDDK_ || _NTDDK_)
968 #if (NTDDI_VERSION >= NTDDI_WS03SP1)
970 
971 $if (_WDMDDK_)
974 _Post_satisfies_(return == 1 || return == 0)
976 BOOLEAN
977 FASTCALL
980  _When_(return!=0, _Acquires_lock_(*_Curr_))
982 
986 BOOLEAN
987 NTAPI
989 
990 _Acquires_lock_(_Global_critical_region_)
996 VOID
997 FASTCALL
999  _Inout_ PKGUARDED_MUTEX GuardedMutex);
1000 
1001 _Requires_lock_not_held_(*FastMutex)
1002 _Acquires_lock_(*FastMutex)
1006 VOID
1007 FASTCALL
1009  _Inout_ PKGUARDED_MUTEX GuardedMutex);
1010 
1011 _Acquires_lock_(_Global_critical_region_)
1014 VOID
1015 NTAPI
1017 
1018 _Releases_lock_(_Global_critical_region_)
1021 VOID
1022 NTAPI
1024 
1028 VOID
1029 FASTCALL
1031  _Out_ PKGUARDED_MUTEX GuardedMutex);
1032 
1033 _Requires_lock_held_(*FastMutex)
1034 _Releases_lock_(*FastMutex)
1037 VOID
1038 FASTCALL
1040  _Inout_ PKGUARDED_MUTEX GuardedMutex);
1041 
1042 _Releases_lock_(_Global_critical_region_)
1047 VOID
1048 FASTCALL
1050  _Inout_ PKGUARDED_MUTEX GuardedMutex);
1051 
1055 _Post_satisfies_(return == 1 || return == 0)
1057 BOOLEAN
1058 FASTCALL
1060  _When_ (return, _Requires_lock_not_held_(*_Curr_) _Acquires_exclusive_lock_(*_Curr_)) _Acquires_lock_(_Global_critical_region_)
1061  _Inout_ PKGUARDED_MUTEX GuardedMutex);
1062 $endif (_WDMDDK_)
1063 $if (_NTDDK_)
1067 NTSTATUS
1068 NTAPI
1069 KeExpandKernelStackAndCallout(
1070  _In_ PEXPAND_STACK_CALLOUT Callout,
1072  _In_ SIZE_T Size);
1073 
1074 _Acquires_lock_(_Global_critical_region_)
1077 VOID
1078 NTAPI
1080 
1081 _Releases_lock_(_Global_critical_region_)
1084 VOID
1085 NTAPI
1087 $endif (_NTDDK_)
1088 $if (_WDMDDK_ || _NTDDK_)
1089 #endif /* (NTDDI_VERSION >= NTDDI_WS03SP1) */
1090 $endif (_WDMDDK_ || _NTDDK_)
1091 
1092 #if (NTDDI_VERSION >= NTDDI_VISTA)
1093 $if (_WDMDDK_)
1098 _IRQL_saves_global_(QueuedSpinLock,LockHandle)
1100 VOID
1101 FASTCALL
1105 
1109 _IRQL_restores_global_(QueuedSpinLock,LockHandle)
1111 VOID
1112 FASTCALL
1115 
1118 NTSTATUS
1119 NTAPI
1120 KeQueryDpcWatchdogInformation(
1121  _Out_ PKDPC_WATCHDOG_INFORMATION WatchdogInformation);
1122 $endif (_WDMDDK_)
1123 $if (_WDMDDK_ || _NTDDK_)
1124 #if defined(SINGLE_GROUP_LEGACY_API)
1125 $endif (_WDMDDK_ || _NTDDK_)
1126 
1127 $if (_WDMDDK_)
1131 KAFFINITY
1132 NTAPI
1133 KeSetSystemAffinityThreadEx(
1135 
1139 VOID
1140 NTAPI
1141 KeRevertToUserAffinityThreadEx(
1143 
1145 ULONG
1146 NTAPI
1148  _Out_opt_ PKAFFINITY ActiveProcessors);
1149 
1151 ULONG
1152 NTAPI
1153 KeQueryMaximumProcessorCount(VOID);
1154 $endif (_WDMDDK_)
1155 $if (_NTDDK_)
1157 ULONG
1158 NTAPI
1160  _Out_opt_ PKAFFINITY ActiveProcessors);
1161 
1163 ULONG
1164 NTAPI
1165 KeQueryMaximumProcessorCount(VOID);
1166 $endif (_NTDDK_)
1167 $if (_WDMDDK_ || _NTDDK_)
1168 #endif /* SINGLE_GROUP_LEGACY_API */
1169 $endif (_WDMDDK_ || _NTDDK_)
1170 $if (_NTIFS_)
1173 VOID
1174 KeQueryOwnerMutant(
1175  _In_ PKMUTANT Mutant,
1177 
1182 ULONG
1183 NTAPI
1184 KeRemoveQueueEx(
1185  _Inout_ PKQUEUE Queue,
1186  _In_ KPROCESSOR_MODE WaitMode,
1189  _Out_writes_to_(Count, return) PLIST_ENTRY *EntryArray,
1190  _In_ ULONG Count);
1191 $endif (_NTIFS_)
1192 
1193 #endif /* (NTDDI_VERSION >= NTDDI_VISTA) */
1194 
1195 $if (_WDMDDK_)
1196 #if (NTDDI_VERSION >= NTDDI_WS08)
1197 
1199 PVOID
1200 NTAPI
1201 KeRegisterProcessorChangeCallback(
1204  _In_ ULONG Flags);
1205 
1207 VOID
1208 NTAPI
1209 KeDeregisterProcessorChangeCallback(
1210  _In_ PVOID CallbackHandle);
1211 
1212 #endif /* (NTDDI_VERSION >= NTDDI_WS08) */
1213 $endif (_WDMDDK_)
1214 $if (_WDMDDK_ || _NTDDK_)
1215 #if (NTDDI_VERSION >= NTDDI_WIN7)
1216 $endif (_WDMDDK_ || _NTDDK_)
1217 
1218 $if (_WDMDDK_)
1222 ULONG64
1223 NTAPI
1224 KeQueryTotalCycleTimeProcess(
1227 
1231 ULONG64
1232 NTAPI
1233 KeQueryTotalCycleTimeThread(
1236 
1239 NTSTATUS
1240 NTAPI
1242  _Inout_ PKDPC Dpc,
1244 
1248 VOID
1249 NTAPI
1250 KeSetSystemGroupAffinityThread(
1253 
1257 VOID
1258 NTAPI
1259 KeRevertToUserGroupAffinityThread(
1261 
1264 BOOLEAN
1265 NTAPI
1266 KeSetCoalescableTimer(
1269  _In_ ULONG Period,
1271  _In_opt_ PKDPC Dpc);
1272 
1274 ULONGLONG
1275 NTAPI
1277 
1279 ULONG
1280 NTAPI
1282  _In_ USHORT GroupNumber);
1283 
1285 ULONG
1286 NTAPI
1288  _In_ USHORT GroupNumber);
1289 
1291 USHORT
1292 NTAPI
1294 
1296 USHORT
1297 NTAPI
1299 
1301 KAFFINITY
1302 NTAPI
1304  _In_ USHORT GroupNumber);
1305 
1307 ULONG
1308 NTAPI
1311 
1313 VOID
1314 NTAPI
1319 
1321 USHORT
1322 NTAPI
1325 
1327 USHORT
1328 NTAPI
1330 
1332 USHORT
1333 NTAPI
1335 
1338 NTSTATUS
1339 NTAPI
1340 KeQueryLogicalProcessorRelationship(
1341  _In_opt_ PPROCESSOR_NUMBER ProcessorNumber OPTIONAL,
1345 
1348 _Ret_range_(<=, 0)
1351 NTSTATUS
1352 NTAPI
1353 KeSaveExtendedProcessorState(
1354  _In_ ULONG64 Mask,
1356  _When_(return==0, _Acquires_lock_(*_Curr_))
1357  PXSTATE_SAVE XStateSave);
1358 
1361 VOID
1362 NTAPI
1364  _In_ _Requires_lock_held_(*_Curr_) _Releases_lock_(*_Curr_)
1365  PXSTATE_SAVE XStateSave);
1366 
1367 NTSTATUS
1368 NTAPI
1370  _In_ ULONG ProcIndex,
1372 
1373 ULONG
1374 NTAPI
1377 $endif (_WDMDDK_)
1378 $if (_NTDDK_)
1380 ULONG
1381 NTAPI
1383  _In_ USHORT GroupNumber);
1384 
1386 ULONG
1387 NTAPI
1389  _In_ USHORT GroupNumber);
1390 
1392 USHORT
1393 NTAPI
1395 
1397 USHORT
1398 NTAPI
1400 
1402 KAFFINITY
1403 NTAPI
1405  _In_ USHORT GroupNumber);
1406 
1408 ULONG
1409 NTAPI
1412 
1414 VOID
1415 NTAPI
1420 
1422 USHORT
1423 NTAPI
1426 
1428 USHORT
1429 NTAPI
1431 
1433 USHORT
1434 NTAPI
1436 
1439 NTSTATUS
1440 NTAPI
1441 KeQueryLogicalProcessorRelationship(
1442  _In_opt_ PPROCESSOR_NUMBER ProcessorNumber,
1446 
1449 NTSTATUS
1450 NTAPI
1451 KeSetHardwareCounterConfiguration(
1453  _In_ ULONG Count);
1454 
1457 NTSTATUS
1458 NTAPI
1459 KeQueryHardwareCounterConfiguration(
1462  _Out_ PULONG Count);
1463 $endif (_NTDDK_)
1464 $if (_WDMDDK_ || _NTDDK_)
1465 #endif /* (NTDDI_VERSION >= NTDDI_WIN7) */
1466 $endif (_WDMDDK_ || _NTDDK_)
1467 $if (_WDMDDK_)
1468 #if !defined(_IA64_)
1469 NTHALAPI
1470 VOID
1471 NTAPI
1473 #endif
1474 
1475 /* VOID
1476  * KeInitializeCallbackRecord(
1477  * IN PKBUGCHECK_CALLBACK_RECORD CallbackRecord)
1478  */
1479 #define KeInitializeCallbackRecord(CallbackRecord) \
1480  CallbackRecord->State = BufferEmpty;
1481 
1482 #if defined(_PREFAST_)
1483 
1484 void __PREfastPagedCode(void);
1485 void __PREfastPagedCodeLocked(void);
1486 #define PAGED_CODE() __PREfastPagedCode();
1487 #define PAGED_CODE_LOCKED() __PREfastPagedCodeLocked();
1488 
1489 #elif DBG
1490 
1491 #if (NTDDI_VERSION >= NTDDI_VISTA)
1492 #define PAGED_ASSERT( exp ) NT_ASSERT( exp )
1493 #else
1494 #define PAGED_ASSERT( exp ) ASSERT( exp )
1495 #endif
1496 
1497 #define PAGED_CODE() { \
1498  if (KeGetCurrentIrql() > APC_LEVEL) { \
1499  KdPrint( ("NTDDK: Pageable code called at IRQL > APC_LEVEL (%d)\n", KeGetCurrentIrql() )); \
1500  PAGED_ASSERT(FALSE); \
1501  } \
1502 }
1503 
1504 #define PAGED_CODE_LOCKED() NOP_FUNCTION;
1505 
1506 #else
1507 
1508 #define PAGED_CODE() NOP_FUNCTION;
1509 #define PAGED_CODE_LOCKED() NOP_FUNCTION;
1510 
1511 #endif /* DBG */
1512 
1513 $endif (_WDMDDK_)
NTKERNELAPI ULONGLONG NTAPI KeQueryUnbiasedInterruptTime(VOID)
_In_ LARGE_INTEGER _In_ ULONG _In_ ULONG TolerableDelay
Definition: kefuncs.h:1268
_Requires_lock_held_ SpinLock _Releases_lock_ SpinLock _In_ _IRQL_restores_ KIRQL NewIrql
Definition: kefuncs.h:230
ULONG NTAPI KeQueryRuntimeThread(IN PKTHREAD Thread, OUT PULONG UserTime)
Definition: thrdobj.c:980
NTKERNELAPI DECLSPEC_NORETURN VOID NTAPI KeBugCheck(_In_ ULONG BugCheckCode)
#define _IRQL_requires_same_
Definition: no_sal2.h:652
return
Definition: dirsup.c:529
NTKERNELAPI ULONG NTAPI KeGetRecommendedSharedDataAlignment(VOID)
Definition: cpu.c:471
* PPROCESSOR_NUMBER
Definition: ntbasedef.h:649
#define _Must_inspect_result_
Definition: no_sal2.h:314
_In_ LONG Count
Definition: kefuncs.h:328
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)
LONG NTAPI KeInsertHeadQueue(IN PKQUEUE Queue, IN PLIST_ENTRY Entry)
Definition: queue.c:172
Type
Definition: Type.h:6
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 NTHALAPI
Definition: ntoskrnl.h:39
_In_opt_ PVOID CallbackContext
Definition: kefuncs.h:1203
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_ LARGE_INTEGER DueTime
Definition: kefuncs.h:524
#define _IRQL_saves_
Definition: no_sal2.h:655
VOID NTAPI KeRevertToUserAffinityThread(VOID)
Definition: thrdobj.c:1030
VOID NTAPI KeInitializeMutant(IN PKMUTANT Mutant, IN BOOLEAN InitialOwner)
Definition: mutex.c:22
unsigned char * PUCHAR
Definition: retypes.h:3
#define _In_reads_(size)
Definition: no_sal2.h:228
#define _In_reads_bytes_opt_(size)
Definition: no_sal2.h:230
VOID NTAPI KeAcquireSpinLockAtDpcLevel(IN PKSPIN_LOCK SpinLock)
Definition: spinlock.c:192
#define _Ret_range_(lb, ub)
Definition: no_sal2.h:613
LONG NTSTATUS
Definition: precomp.h:26
_Inout_ PKDEVICE_QUEUE_ENTRY _In_ ULONG SortKey
Definition: kefuncs.h:352
_In_ ULONGLONG _In_ ULONGLONG _In_ BOOLEAN Enable
Definition: ntddpcm.h:140
BOOLEAN NTAPI KeReadStateTimer(IN PKTIMER Timer)
Definition: timerobj.c:269
_In_ KPRIORITY Priority
Definition: kefuncs.h:516
#define _NTIFS_
Definition: ifssupp.h:20
_Out_ PPROCESSOR_NUMBER ProcNumber
Definition: kefuncs.h:53
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:107
BOOLEAN NTAPI KeRemoveQueueDpc(IN PKDPC Dpc)
Definition: dpc.c:877
_In_ LARGE_INTEGER _In_ ULONG Period
Definition: kefuncs.h:1268
_In_ UCHAR Processor
Definition: kefuncs.h:695
#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)
_Requires_lock_not_held_(Vcb->fcb_lock) _Acquires_shared_lock_(Vcb -> fcb_lock) static __inline void acquire_fcb_lock_shared(device_extension *Vcb)
Definition: btrfs_drv.h:910
NTKERNELAPI ULONG NTAPI KeQueryActiveProcessorCountEx(_In_ USHORT GroupNumber)
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
_In_ PVOID Parameter
Definition: ldrtypes.h:239
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
#define _Out_writes_to_(size, count)
Definition: no_sal2.h:378
NTKERNELAPI VOID NTAPI KeSetImportanceDpc(_Inout_ PRKDPC Dpc, _In_ KDPC_IMPORTANCE Importance)
#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:826
LONG KPRIORITY
Definition: compat.h:454
Definition: Mutex.h:15
#define _In_opt_
Definition: no_sal2.h:213
VOID NTAPI KeSetSystemAffinityThread(IN KAFFINITY Affinity)
Definition: thrdobj.c:1116
KBUGCHECK_CALLBACK_ROUTINE * PKBUGCHECK_CALLBACK_ROUTINE
Definition: ketypes.h:320
_In_ PKSERVICE_ROUTINE _In_opt_ PVOID _In_opt_ PKSPIN_LOCK SpinLock
Definition: iofuncs.h:798
_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:63
PLIST_ENTRY NTAPI KeRundownQueue(IN PKQUEUE Queue)
Definition: queue.c:438
_Out_ PUSHORT NodeNumber
Definition: iofuncs.h:2567
UCHAR KIRQL
Definition: env_spec_w32.h:591
_Must_inspect_result_ _In_ PFLT_GET_OPERATION_STATUS_CALLBACK CallbackRoutine
Definition: fltkernel.h:1035
_Must_inspect_result_ _In_ ULONG Flags
Definition: wsk.h:170
_In_ LOGICAL_PROCESSOR_RELATIONSHIP RelationshipType
Definition: kefuncs.h:1342
NTSTATUS(* NTAPI)(IN PFILE_FULL_EA_INFORMATION EaBuffer, IN ULONG EaLength, OUT PULONG ErrorOffset)
Definition: IoEaTest.cpp:117
VOID NTAPI KeStackAttachProcess(IN PKPROCESS Process, OUT PRKAPC_STATE ApcState)
Definition: procobj.c:701
_In_ KPRIORITY _In_ BOOLEAN Abandoned
Definition: kefuncs.h:606
_In_ KPRIORITY _In_ LONG Adjustment
Definition: kefuncs.h:451
long LONG
Definition: pedump.c:60
NTKERNELAPI VOID NTAPI KeInitializeQueue(_Out_ PRKQUEUE Queue, _In_ ULONG Count)
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:167
_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:165
_Must_inspect_result_ NTKERNELAPI NTSTATUS NTAPI KeSetTargetProcessorDpcEx(_Inout_ PKDPC Dpc, _In_ PPROCESSOR_NUMBER ProcNumber)
FORCEINLINE VOID KeInitializeSpinLock(_Out_ PKSPIN_LOCK SpinLock)
Definition: kefuncs.h:251
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:409
unsigned char BOOLEAN
#define _Out_writes_bytes_opt_(a)
Definition: btrfs_drv.h:171
_Requires_lock_held_ SpinLock _Releases_lock_ SpinLock _IRQL_requires_(DISPATCH_LEVEL) NTKERNELAPI VOID NTAPI KeReleaseSpinLock(_Inout_ PKSPIN_LOCK SpinLock
Definition: expool.c:1455
LONG NTAPI KeReadStateQueue(IN PKQUEUE Queue)
Definition: queue.c:226
smooth NULL
Definition: ftsmooth.c:416
_When_(Wait==0, _IRQL_requires_max_(DISPATCH_LEVEL)) _When_(Wait
static WCHAR Address[46]
Definition: ping.c:68
#define KeLeaveGuardedRegion()
Definition: ke_x.h:63
KSYNCHRONIZE_ROUTINE * PKSYNCHRONIZE_ROUTINE
Definition: ketypes.h:863
#define _Out_writes_bytes_(size)
Definition: no_sal2.h:370
#define FORCEINLINE
Definition: ntbasedef.h:221
#define _Out_
Definition: no_sal2.h:323
VOID NTAPI KeInitializeTimer(OUT PKTIMER Timer)
Definition: timerobj.c:233
#define _At_(target, annos)
Definition: no_sal2.h:11
#define NTKERNELAPI
#define _Kernel_float_restored_
Definition: no_sal2.h:659
NTKERNELAPI USHORT NTAPI KeQueryNodeMaximumProcessorCount(_In_ USHORT NodeNumber)
Definition: bufpool.h:45
_In_ KPRIORITY Increment
Definition: kefuncs.h:101
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:19
PKDEVICE_QUEUE_ENTRY NTAPI KeRemoveByKeyDeviceQueueIfBusy(IN PKDEVICE_QUEUE DeviceQueue, IN ULONG SortKey)
Definition: devqueue.c:273
PROCESSOR_CALLBACK_FUNCTION * PPROCESSOR_CALLBACK_FUNCTION
Definition: ketypes.h:362
_Must_inspect_result_ _In_ __in_data_source(USER_MODE) SIZE_T Size
#define _Points_to_data_
Definition: no_sal2.h:445
*Count PHARDWARE_COUNTER CounterArray
Definition: kefuncs.h:1460
_Must_inspect_result_ NTKERNELAPI BOOLEAN NTAPI KeDeregisterBugCheckCallback(_Inout_ PKBUGCHECK_CALLBACK_RECORD CallbackRecord)
enum _EVENT_TYPE EVENT_TYPE
_Out_ PULONG UserTime
Definition: kefuncs.h:784
_In_ LOGICAL_PROCESSOR_RELATIONSHIP _Out_writes_bytes_opt_ Length PSYSTEM_LOGICAL_PROCESSOR_INFORMATION_EX Information
Definition: kefuncs.h:1343
_In_opt_ PVOID _In_opt_ PVOID SystemArgument1
Definition: ketypes.h:675
BOOLEAN NTAPI KeInvalidateAllCaches(VOID)
Definition: cpu.c:459
#define _Out_opt_
Definition: no_sal2.h:339
enum _KDPC_IMPORTANCE KDPC_IMPORTANCE
_In_ HANDLE Handle
Definition: extypes.h:390
_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:337
_In_ LARGE_INTEGER _In_opt_ PKDPC Dpc
Definition: kefuncs.h:524
#define IPI_LEVEL
Definition: env_spec_w32.h:701
BOOLEAN NTAPI KeCancelTimer(IN OUT PKTIMER Timer)
Definition: timerobj.c:206
_Out_ PCLIENT_ID ClientId
Definition: kefuncs.h:1176
VOID NTAPI KeInitializeSemaphore(IN PKSEMAPHORE Semaphore, IN LONG Count, IN LONG Limit)
Definition: semphobj.c:22
_In_ PKSYNCHRONIZE_ROUTINE SynchronizeRoutine
Definition: kefuncs.h:549
enum _LOGICAL_PROCESSOR_RELATIONSHIP LOGICAL_PROCESSOR_RELATIONSHIP
KAFFINITY NTAPI KeQueryActiveProcessors(VOID)
Definition: cpu.c:433
_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:50
#define _DECL_HAL_KE_IMPORT
uint64_t ULONGLONG
Definition: typedefs.h:65
_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:215
NTKERNELAPI USHORT NTAPI KeQueryHighestNodeNumber(VOID)
BOOLEAN NTAPI KeInsertDeviceQueue(IN PKDEVICE_QUEUE DeviceQueue, IN PKDEVICE_QUEUE_ENTRY DeviceQueueEntry)
Definition: devqueue.c:41
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:2653
_In_ BOOLEAN Alertable
Definition: kefuncs.h:283
#define _Post_same_lock_(lock1, lock2)
Definition: no_sal2.h:697
#define _Inout_
Definition: no_sal2.h:244
_In_ ULONG _In_ ULONG _In_ ULONG Length
Definition: ntddpcm.h:101
KIRQL NTAPI KeAcquireInterruptSpinLock(IN PKINTERRUPT Interrupt)
Definition: spinlock.c:148
CCHAR KPROCESSOR_MODE
Definition: ketypes.h:7
#define KeEnterGuardedRegion()
Definition: ke_x.h:34
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
static IUnknown Object
Definition: main.c:512
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:618
unsigned char UCHAR
Definition: xmlstorage.h:181
*LockHandle LockHandle NTKERNELAPI VOID FASTCALL KeAcquireInStackQueuedSpinLockForDpc(_Inout_ PKSPIN_LOCK SpinLock, _Out_ PKLOCK_QUEUE_HANDLE LockHandle)
VOID FASTCALL KeReleaseGuardedMutexUnsafe(IN OUT PKGUARDED_MUTEX GuardedMutex)
Definition: gmutex.c:75
_Out_ PKAPC_STATE ApcState
Definition: kefuncs.h:679
VOID NTAPI ProbeForRead(IN CONST VOID *Address, IN SIZE_T Length, IN ULONG Alignment)
Definition: exintrin.c:102
#define _Kernel_float_saved_
Definition: no_sal2.h:660
NMI_CALLBACK * PNMI_CALLBACK
Definition: ketypes.h:338
_Requires_lock_held_ Interrupt _Releases_lock_ Interrupt _In_ _IRQL_restores_ KIRQL OldIrql
Definition: kefuncs.h:803
Definition: ketypes.h:687
KDEFERRED_ROUTINE * PKDEFERRED_ROUTINE
Definition: ketypes.h:678
_Out_opt_ PGROUP_AFFINITY PreviousAffinity
Definition: kefuncs.h:1252
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:83
KIRQL * PKIRQL
Definition: env_spec_w32.h:592
_MODE
Definition: ketypes.h:10
Definition: typedefs.h:117
#define SYNCH_LEVEL
Definition: env_spec_w32.h:704
IN PVOID IN PVOID IN USHORT IN USHORT Size
Definition: pci.h:359
#define PASSIVE_LEVEL
Definition: env_spec_w32.h:693
KIRQL FASTCALL KeAcquireQueuedSpinLock(IN KSPIN_LOCK_QUEUE_NUMBER LockNumber)
Definition: spinlock.c:108
_In_opt_ PENTER_STATE_SYSTEM_HANDLER _In_opt_ PVOID _In_ LONG _In_opt_ LONG volatile * Number
Definition: ntpoapi.h:204
#define _In_reads_bytes_(size)
Definition: no_sal2.h:229
#define _Maybe_raises_SEH_exception_
Definition: no_sal2.h:313
NTKERNELAPI ULONG NTAPI KeQueryActiveProcessorCount(OUT PKAFFINITY ActiveProcessors OPTIONAL)
Definition: ke.c:15
_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_ _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
#define _In_
Definition: no_sal2.h:204
_In_ PKSYNCHRONIZE_ROUTINE _In_opt_ __drv_aliasesMem PVOID SynchronizeContext
Definition: kefuncs.h:549
ULONG_PTR SIZE_T
Definition: typedefs.h:78
enum _KSPIN_LOCK_QUEUE_NUMBER KSPIN_LOCK_QUEUE_NUMBER
LONG NTAPI KeReadStateMutant(IN PKMUTANT Mutant)
Definition: mutex.c:87
#define _IRQL_restores_global_(kind, param)
Definition: no_sal2.h:654
KIRQL FASTCALL KeAcquireSpinLockForDpc(IN PKSPIN_LOCK SpinLock)
Definition: spinlock.c:398
#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:114
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:75
VOID NTAPI KeAttachProcess(IN PKPROCESS Process)
Definition: procobj.c:579
#define _IRQL_saves_global_(kind, param)
Definition: no_sal2.h:656
VOID NTAPI KeUnstackDetachProcess(IN PRKAPC_STATE ApcState)
Definition: procobj.c:753
EXPAND_STACK_CALLOUT * PEXPAND_STACK_CALLOUT
Definition: ketypes.h:1093
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
unsigned int * PULONG
Definition: retypes.h:1
Definition: optimize.h:109
#define KeReleaseSpinLock(sl, irql)
Definition: env_spec_w32.h:627
#define __drv_strictTypeMatch(mode)
Definition: driverspecs.h:312
NTKERNELAPI ULONG NTAPI KeQueryMaximumProcessorCountEx(_In_ USHORT GroupNumber)
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:93
VOID NTAPI KeSetTargetProcessorDpc(IN PKDPC Dpc, IN CCHAR Number)
Definition: dpc.c:970
#define _Literal_
Definition: no_sal2.h:310
_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
*Count PHARDWARE_COUNTER _In_ ULONG MaximumCount
Definition: kefuncs.h:1460
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:142
_In_ KPRIORITY _In_ BOOLEAN Wait
Definition: kefuncs.h:101
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:1405
_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:742
_In_ BOOLEAN _In_ PLARGE_INTEGER Interval
Definition: kefuncs.h:283
VOID FASTCALL KeReleaseInStackQueuedSpinLockFromDpcLevel(IN PKLOCK_QUEUE_HANDLE LockHandle)
Definition: spinlock.c:369
NTKERNELAPI USHORT NTAPI KeGetCurrentNodeNumber(VOID)
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:1371
_Inout_ PKDEVICE_QUEUE_ENTRY DeviceQueueEntry
Definition: kefuncs.h:352
VOID NTAPI KeClearEvent(IN PKEVENT Event)
Definition: eventobj.c:22
_Out_ PULONG64 CycleTimeStamp
Definition: kefuncs.h:1226
$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:303
PVOID PVOID PWCHAR PVOID USHORT PULONG Reason
Definition: env.c:45
NTKERNELAPI VOID NTAPI KeInitializeThreadedDpc(_Out_ PRKDPC Dpc, _In_ PKDEFERRED_ROUTINE DeferredRoutine, _In_opt_ PVOID DeferredContext)
#define APC_LEVEL
Definition: env_spec_w32.h:695
_IRQL_requires_max_(DISPATCH_LEVEL) NTKERNELAPI VOID NTAPI KeClearEvent(_Inout_ PRKEVENT Event)
Definition: rmap.c:30
_In_ BOOLEAN InitialOwner
Definition: kefuncs.h:590
VOID NTAPI KeFlushQueuedDpcs(VOID)
Definition: dpc.c:918
_In_ LONG _In_ LONG Limit
Definition: kefuncs.h:328
ULONGLONG NTAPI KeQueryInterruptTime(VOID)
Definition: clock.c:203
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_
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:1273
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:1273
BOOLEAN NTAPI KeSetKernelStackSwapEnable(IN BOOLEAN Enable)
Definition: thrdobj.c:997
#define _IRQL_restores_
Definition: no_sal2.h:653
_Kernel_float_restored_ NTKERNELAPI VOID NTAPI KeRestoreExtendedProcessorState(_In_ _Requires_lock_held_(*_Curr_) _Releases_lock_(*_Curr_) PXSTATE_SAVE XStateSave)
_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