1 /* 2 * PROJECT: ReactOS Kernel 3 * LICENSE: GPL-2.0-or-later (https://spdx.org/licenses/GPL-2.0-or-later) 4 * PURPOSE: Internal header for information classes info interface 5 * COPYRIGHT: Copyright 2020-2022 George Bișoc <george.bisoc@reactos.org> 6 */ 7 8 #pragma once 9 10 /* 11 * Implement generic information class probing code in a 12 * separate header within the NT kernel header internals. 13 * This makes it accessible to other sources by including 14 * the header. 15 */ 16 17 #define ICIF_NONE 0x0 18 #define ICIF_QUERY 0x1 19 #define ICIF_SET 0x2 20 #define ICIF_QUERY_SIZE_VARIABLE 0x4 21 #define ICIF_SET_SIZE_VARIABLE 0x8 22 #define ICIF_SIZE_VARIABLE (ICIF_QUERY_SIZE_VARIABLE | ICIF_SET_SIZE_VARIABLE) 23 24 #define ICIF_PROBE_READ_WRITE 0x0 25 #define ICIF_PROBE_READ 0x1 26 #define ICIF_FORCE_RETURN_LENGTH_PROBE 0x2 27 28 typedef struct _INFORMATION_CLASS_INFO 29 { 30 USHORT RequiredSizeQUERY; 31 UCHAR AlignmentQUERY; 32 USHORT RequiredSizeSET; 33 UCHAR AlignmentSET; 34 USHORT Flags; 35 } INFORMATION_CLASS_INFO, *PINFORMATION_CLASS_INFO; 36 37 #define IQS_SAME(Type, Alignment, Flags) \ 38 { sizeof(Type), sizeof(Alignment), sizeof(Type), sizeof(Alignment), Flags } 39 40 #define IQS(TypeQuery, AlignmentQuery, TypeSet, AlignmentSet, Flags) \ 41 { sizeof(TypeQuery), sizeof(AlignmentQuery), sizeof(TypeSet), sizeof(AlignmentSet), Flags } 42 43 #define IQS_NO_TYPE_LENGTH(Alignment, Flags) \ 44 { 0, sizeof(Alignment), 0, sizeof(Alignment), Flags } 45 46 #define IQS_NONE \ 47 { 0, sizeof(CHAR), 0, sizeof(CHAR), ICIF_NONE } 48