ReactOS 0.4.16-dev-1946-g52006dd
ps_i.h
Go to the documentation of this file.
1/*
2 * PROJECT: ReactOS Kernel
3 * LICENSE: GPL-2.0-or-later (https://spdx.org/licenses/GPL-2.0-or-later)
4 * PURPOSE: Info Classes for the Process Manager
5 * COPYRIGHT: Copyright Alex Ionescu <alex.ionescu@reactos.org>
6 * Copyright Thomas Weidenmueller <w3seek@reactos.org>
7 * Copyright 2020-2021 George Bișoc <george.bisoc@reactos.org>
8 */
9
10#include "icif.h"
11
12//
13// Process Information Classes
14//
16{
17 /* ProcessBasicInformation */
19 (
21 ULONG,
23 ),
24
25 /* ProcessQuotaLimits */
27 (
29 ULONG,
30
31 /* NOTE: ICIF_SIZE_VARIABLE is for QUOTA_LIMITS_EX support */
33 ),
34
35 /* ProcessIoCounters */
37 (
39 ULONG,
41 ),
42
43 /* ProcessVmCounters */
45 (
47 ULONG,
49 ),
50
51 /* ProcessTimes */
53 (
55 ULONG,
57 ),
58
59 /* ProcessBasePriority */
61 (
63 ULONG,
65 ),
66
67 /* ProcessRaisePriority */
69 (
70 ULONG,
71 ULONG,
73 ),
74
75 /* ProcessDebugPort */
77 (
78 HANDLE,
79 ULONG,
81 ),
82
83 /* ProcessExceptionPort */
85 (
86 HANDLE,
87 ULONG,
89 ),
90
91 /* ProcessAccessToken */
93 (
95 ULONG,
97 ),
98
99 /* ProcessLdtInformation */
101 (
103 ULONG,
105 ),
106
107 /* ProcessLdtSize */
109 (
111 ULONG,
113 ),
114
115 /* ProcessDefaultHardErrorMode */
117 (
118 ULONG,
119 ULONG,
121 ),
122
123 /* ProcessIoPortHandlers */
125 (
126 UCHAR,
127 ULONG,
129 ),
130
131 /* ProcessPooledUsageAndLimits */
133 (
135 ULONG,
137 ),
138
139 /* ProcessWorkingSetWatch */
141 (
143 ULONG,
145 ),
146
147 /* ProcessUserModeIOPL is only implemented in x86 */
148#if defined (_X86_)
150 (
151 ULONG,
153 ),
154#else
155 IQS_NONE,
156#endif
157
158 /* ProcessEnableAlignmentFaultFixup */
159 IQS
160 (
161 BOOLEAN,
162 CHAR,
163 BOOLEAN,
164 CHAR,
166 ),
167
168 /* ProcessPriorityClass */
169 IQS
170 (
172 ULONG,
174 CHAR,
176 ),
177
178 /* ProcessWx86Information */
180 (
181 ULONG,
182 ULONG,
184 ),
185
186 /* ProcessHandleCount */
188 (
189 ULONG,
190 ULONG,
192 ),
193
194 /* ProcessAffinityMask */
196 (
197 KAFFINITY,
198 ULONG,
200 ),
201
202 /* ProcessPriorityBoost */
204 (
205 ULONG,
206 ULONG,
208 ),
209
210 /* ProcessDeviceMap */
211 IQS
212 (
214 ULONG,
216 ULONG,
218 ),
219
220 /* ProcessSessionInformation */
222 (
224 ULONG,
226 ),
227
228 /* ProcessForegroundInformation */
229 IQS
230 (
231 CHAR,
232 CHAR,
233 BOOLEAN,
234 CHAR,
236 ),
237
238 /* ProcessWow64Information */
240 (
241 ULONG_PTR,
242 ULONG,
244 ),
245
246 /* ProcessImageFileName */
248 (
250 ULONG,
252 ),
253
254 /* ProcessLUIDDeviceMapsEnabled */
256 (
257 ULONG,
258 ULONG,
260 ),
261
262 /* ProcessBreakOnTermination */
264 (
265 ULONG,
266 ULONG,
268 ),
269
270 /* ProcessDebugObjectHandle */
272 (
273 HANDLE,
274 ULONG,
276 ),
277
278 /* ProcessDebugFlags */
280 (
281 ULONG,
282 ULONG,
284 ),
285
286 /* ProcessHandleTracing */
287 IQS
288 (
290 ULONG,
291 ULONG,
292 ULONG,
294 ),
295
296 /* ProcessIoPriority */
297 IQS_NONE,
298
299 /* ProcessExecuteFlags */
301 (
302 ULONG,
303 ULONG,
305 ),
306
307 /* ProcessTlsInformation */
308 IQS_NONE,
309
310 /* ProcessCookie */
312 (
313 ULONG,
314 ULONG,
316 ),
317
318 /* ProcessImageInformation */
320 (
322 ULONG,
324 ),
325
326 /* ProcessCycleTime */
327 IQS_NONE,
328
329 /* ProcessPagePriority */
330 IQS_NONE,
331
332 /* ProcessInstrumentationCallback */
333 IQS_NONE,
334
335 /* ProcessThreadStackAllocation */
336 IQS_NONE,
337
338 /* ProcessWorkingSetWatchEx */
339 IQS_NONE,
340
341 /* ProcessImageFileNameWin32 */
343 (
345 ULONG,
347 ),
348
349 /* ProcessImageFileMapping */
350 IQS_NONE,
351
352 /* ProcessAffinityUpdateMode */
353 IQS_NONE,
354
355 /* ProcessMemoryAllocationMode */
356 IQS_NONE,
357};
358
359//
360// Thread Information Classes
361//
363{
364 /* ThreadBasicInformation */
366 (
368 ULONG,
370 ),
371
372 /* ThreadTimes */
374 (
376 ULONG,
378 ),
379
380 /* ThreadPriority */
382 (
383 KPRIORITY,
384 ULONG,
386 ),
387
388 /* ThreadBasePriority */
390 (
391 LONG,
392 ULONG,
394 ),
395
396 /* ThreadAffinityMask */
398 (
399 KAFFINITY,
400 ULONG,
402 ),
403
404 /* ThreadImpersonationToken */
406 (
407 HANDLE,
408 ULONG,
410 ),
411
412 /* ThreadDescriptorTableEntry is only implemented in x86 as well as the descriptor entry */
413#if defined(_X86_)
415 (
416 DESCRIPTOR_TABLE_ENTRY,
417 ULONG,
419 ),
420#else
421 IQS_NONE,
422#endif
423
424 /* ThreadEnableAlignmentFaultFixup */
425 IQS
426 (
427 CHAR,
428 CHAR,
429 BOOLEAN,
430 UCHAR,
432 ),
433
434 /* ThreadEventPair_Reusable */
435 IQS_NONE,
436
437 /* ThreadQuerySetWin32StartAddress */
438 IQS
439 (
440 PVOID,
441 ULONG,
442 ULONG_PTR,
443 ULONG,
445 ),
446
447 /* ThreadZeroTlsCell */
449 (
450 ULONG,
451 ULONG,
453 ),
454
455 /* ThreadPerformanceCount */
457 (
459 ULONG,
461 ),
462
463 /* ThreadAmILastThread */
465 (
466 ULONG,
467 ULONG,
469 ),
470
471 /* ThreadIdealProcessor */
473 (
474 ULONG_PTR,
475 ULONG,
477 ),
478
479 /* ThreadPriorityBoost */
480 IQS
481 (
482 ULONG,
483 ULONG,
484 ULONG_PTR,
485 ULONG,
487 ),
488
489 /* ThreadSetTlsArrayAddress */
491 (
492 PVOID,
493 ULONG,
495 ),
496
497 /* ThreadIsIoPending */
499 (
500 ULONG,
501 ULONG,
503 ),
504
505 /* ThreadHideFromDebugger */
507 (
508 CHAR,
509 ULONG,
511 ),
512
513 /* ThreadBreakOnTermination */
515 (
516 ULONG,
517 ULONG,
519 ),
520
521 /* ThreadSwitchLegacyState */
523 (
524 ULONG,
525 ULONG,
527 ),
528
529 /* ThreadIsTerminated */
531 (
532 ULONG,
533 ULONG,
535 ),
536
537 /* ThreadLastSystemCall */
538 IQS_NONE,
539
540 /* ThreadIoPriority */
541 IQS_NONE,
542
543 /* ThreadCycleTime */
544 IQS_NONE,
545
546 /* ThreadPagePriority */
547 IQS_NONE,
548
549 /* ThreadActualBasePriority */
550 IQS_NONE,
551
552 /* ThreadTebInformation */
553 IQS_NONE,
554
555 /* ThreadCSwitchMon */
556 IQS_NONE,
557
558#if 0 // Hermes will surely fix this properly
559 // Windows 7
560 /* ThreadCSwitchPmu */
561 IQS_NONE,
562 /* ThreadWow64Context */
563 IQS_NONE,
564 /* ThreadGroupInformation */
565 IQS_NONE,
566 /* ThreadUmsInformation */
567 IQS_NONE,
568 /* ThreadCounterProfiling */
569 IQS_NONE,
570 /* ThreadIdealProcessorEx */
571 IQS_NONE,
572
573 // Windows 8
574 /* ThreadCpuAccountingInformation */
575 IQS_NONE,
576
577 // Windows 8.1
578 /* ThreadSuspendCount */
579 IQS_NONE,
580
581 // Windows 10
582 /* ThreadHeterogeneousCpuPolicy */
583 IQS_NONE,
584 /* ThreadContainerId */
585 IQS_NONE,
586 /* ThreadNameInformation */
587 IQS_NONE,
588 /* ThreadSelectedCpuSets */
589 IQS_NONE,
590 /* ThreadSystemThreadInformation */
591 IQS_NONE,
592 /* ThreadActualGroupAffinity */
593 IQS_NONE,
594
595 /* ThreadDynamicCodePolicyInfo */
596 IQS_NONE,
597 /* ThreadExplicitCaseSensitivity */
598 IQS_NONE,
599 /* ThreadWorkOnBehalfTicket */
600 IQS_NONE,
601 /* ThreadSubsystemInformation */
602 IQS_NONE,
603 /* ThreadDbgkWerReportActive */
604 IQS_NONE,
605 /* ThreadAttachContainer */
606 IQS_NONE,
607 /* ThreadManageWritesToExecutableMemory */
608 IQS_NONE,
609 /* ThreadPowerThrottlingState */
610 IQS_NONE,
611 /* ThreadWorkloadClass */
612 IQS_NONE,
613 /* ThreadCreateStateChange */
614 IQS_NONE,
615 /* ThreadApplyStateChange */
616 IQS_NONE,
617 /* ThreadStrongerBadHandleChecks */
618 IQS_NONE,
619 /* ThreadEffectiveIoPriority */
620 IQS_NONE,
621 /* ThreadEffectivePagePriority */
622 IQS_NONE,
623#endif
624};
unsigned char BOOLEAN
BOOL Query(LPCTSTR *ServiceArgs, DWORD ArgCount, BOOL bExtended)
Definition: query.c:292
ULONG_PTR KAFFINITY
Definition: compat.h:85
LONG KPRIORITY
Definition: compat.h:803
#define ICIF_QUERY_SIZE_VARIABLE
Definition: icif.h:20
#define IQS_NONE
Definition: icif.h:46
#define ICIF_QUERY
Definition: icif.h:18
#define ICIF_SET
Definition: icif.h:19
#define ICIF_SET_SIZE_VARIABLE
Definition: icif.h:21
#define IQS(TypeQuery, AlignmentQuery, TypeSet, AlignmentSet, Flags)
Definition: icif.h:40
#define IQS_NO_TYPE_LENGTH(Alignment, Flags)
Definition: icif.h:43
#define ICIF_SIZE_VARIABLE
Definition: icif.h:22
#define IQS_SAME(Type, Alignment, Flags)
Definition: icif.h:37
#define RTL_FIELD_TYPE(type, field)
Definition: ntbasedef.h:679
static BOOL Set
Definition: pageheap.c:10
long LONG
Definition: pedump.c:60
static const INFORMATION_CLASS_INFO PsThreadInfoClass[]
Definition: ps_i.h:362
static const INFORMATION_CLASS_INFO PsProcessInfoClass[]
Definition: ps_i.h:15
uint32_t ULONG_PTR
Definition: typedefs.h:65
uint32_t ULONG
Definition: typedefs.h:59
unsigned char UCHAR
Definition: xmlstorage.h:181
char CHAR
Definition: xmlstorage.h:175