2010-03-30 21:50:05 +00:00
|
|
|
$if (_WDMDDK_ || _NTDDK_)
|
2010-03-13 00:34:48 +00:00
|
|
|
/******************************************************************************
|
|
|
|
* Executive Types *
|
|
|
|
******************************************************************************/
|
2012-01-13 17:45:26 +00:00
|
|
|
$endif (_WDMDDK_ || _NTDDK_)
|
2010-03-27 10:45:04 +00:00
|
|
|
$if (_WDMDDK_)
|
2010-03-13 00:34:48 +00:00
|
|
|
#define EX_RUNDOWN_ACTIVE 0x1
|
|
|
|
#define EX_RUNDOWN_COUNT_SHIFT 0x1
|
|
|
|
#define EX_RUNDOWN_COUNT_INC (1 << EX_RUNDOWN_COUNT_SHIFT)
|
|
|
|
|
|
|
|
typedef struct _FAST_MUTEX {
|
|
|
|
volatile LONG Count;
|
|
|
|
PKTHREAD Owner;
|
|
|
|
ULONG Contention;
|
|
|
|
KEVENT Event;
|
|
|
|
ULONG OldIrql;
|
|
|
|
} FAST_MUTEX, *PFAST_MUTEX;
|
|
|
|
|
|
|
|
typedef enum _SUITE_TYPE {
|
2010-03-18 22:45:30 +00:00
|
|
|
SmallBusiness,
|
|
|
|
Enterprise,
|
|
|
|
BackOffice,
|
|
|
|
CommunicationServer,
|
|
|
|
TerminalServer,
|
|
|
|
SmallBusinessRestricted,
|
|
|
|
EmbeddedNT,
|
|
|
|
DataCenter,
|
|
|
|
SingleUserTS,
|
|
|
|
Personal,
|
|
|
|
Blade,
|
|
|
|
EmbeddedRestricted,
|
|
|
|
SecurityAppliance,
|
|
|
|
StorageServer,
|
|
|
|
ComputeServer,
|
|
|
|
WHServer,
|
|
|
|
MaxSuiteType
|
2010-03-13 00:34:48 +00:00
|
|
|
} SUITE_TYPE;
|
|
|
|
|
|
|
|
typedef enum _EX_POOL_PRIORITY {
|
2010-03-18 22:45:30 +00:00
|
|
|
LowPoolPriority,
|
|
|
|
LowPoolPrioritySpecialPoolOverrun = 8,
|
|
|
|
LowPoolPrioritySpecialPoolUnderrun = 9,
|
|
|
|
NormalPoolPriority = 16,
|
|
|
|
NormalPoolPrioritySpecialPoolOverrun = 24,
|
|
|
|
NormalPoolPrioritySpecialPoolUnderrun = 25,
|
|
|
|
HighPoolPriority = 32,
|
|
|
|
HighPoolPrioritySpecialPoolOverrun = 40,
|
|
|
|
HighPoolPrioritySpecialPoolUnderrun = 41
|
2010-03-13 00:34:48 +00:00
|
|
|
} EX_POOL_PRIORITY;
|
|
|
|
|
|
|
|
#if !defined(_WIN64) && (defined(_NTDDK_) || defined(_NTIFS_) || defined(_NDIS_))
|
|
|
|
#define LOOKASIDE_ALIGN
|
|
|
|
#else
|
|
|
|
#define LOOKASIDE_ALIGN /* FIXME: DECLSPEC_CACHEALIGN */
|
|
|
|
#endif
|
|
|
|
|
|
|
|
typedef struct _LOOKASIDE_LIST_EX *PLOOKASIDE_LIST_EX;
|
|
|
|
|
2012-01-22 14:43:53 +00:00
|
|
|
_IRQL_requires_same_
|
|
|
|
_Function_class_(ALLOCATE_FUNCTION)
|
2010-03-13 00:34:48 +00:00
|
|
|
typedef PVOID
|
2010-03-18 22:48:53 +00:00
|
|
|
(NTAPI *PALLOCATE_FUNCTION)(
|
2012-01-22 14:43:53 +00:00
|
|
|
_In_ POOL_TYPE PoolType,
|
|
|
|
_In_ SIZE_T NumberOfBytes,
|
|
|
|
_In_ ULONG Tag);
|
2010-03-13 00:34:48 +00:00
|
|
|
|
2012-01-22 14:43:53 +00:00
|
|
|
_IRQL_requires_same_
|
|
|
|
_Function_class_(ALLOCATE_FUNCTION_EX)
|
2010-03-13 00:34:48 +00:00
|
|
|
typedef PVOID
|
2010-03-18 22:48:53 +00:00
|
|
|
(NTAPI *PALLOCATE_FUNCTION_EX)(
|
2012-01-22 14:43:53 +00:00
|
|
|
_In_ POOL_TYPE PoolType,
|
|
|
|
_In_ SIZE_T NumberOfBytes,
|
|
|
|
_In_ ULONG Tag,
|
|
|
|
_Inout_ PLOOKASIDE_LIST_EX Lookaside);
|
2010-03-13 00:34:48 +00:00
|
|
|
|
2012-01-22 14:43:53 +00:00
|
|
|
_IRQL_requires_same_
|
|
|
|
_Function_class_(FREE_FUNCTION)
|
2010-03-13 00:34:48 +00:00
|
|
|
typedef VOID
|
2010-03-18 22:48:53 +00:00
|
|
|
(NTAPI *PFREE_FUNCTION)(
|
2012-01-22 14:43:53 +00:00
|
|
|
_In_ PVOID Buffer);
|
2010-03-13 00:34:48 +00:00
|
|
|
|
2012-01-22 14:43:53 +00:00
|
|
|
_IRQL_requires_same_
|
|
|
|
_Function_class_(FREE_FUNCTION_EX)
|
2010-03-13 00:34:48 +00:00
|
|
|
typedef VOID
|
2010-03-18 22:48:53 +00:00
|
|
|
(NTAPI *PFREE_FUNCTION_EX)(
|
2012-01-22 14:43:53 +00:00
|
|
|
_In_ PVOID Buffer,
|
|
|
|
_Inout_ PLOOKASIDE_LIST_EX Lookaside);
|
2010-03-13 00:34:48 +00:00
|
|
|
|
2012-01-22 14:43:53 +00:00
|
|
|
_IRQL_requires_same_
|
|
|
|
_Function_class_(CALLBACK_FUNCTION)
|
2010-03-13 00:34:48 +00:00
|
|
|
typedef VOID
|
[DDK]
- Fix PIO_CSQ_INSERT_IRP_EX redefinition.
[NTDDK]
- Remove a couple of duplicate definitions.
[XDK]
- Move several definitions to their appropriate places.
- Add COMPUTE_PAGES_SPANNED, NODE_REQUIREMENT, MM_ANY_NODE_OK, PNTFS_DEREF_EXPORTED_SECURITY_DESCRIPTOR, PsWrapApcWow64Thread, IRP_MN_DEVICE_ENUMERATED, USE_DMA_MACROS, NO_LEGACY_DRIVERS, FO_FLAGS_VALID_ONLY_DURING_CREATE, LOADER_PARTITION_INFORMATION_EX, BOOTDISK_INFORMATION_LITE, IO_CSQ_INSERT_IRP_EX, STATUS_CONTINUE_COMPLETION and several missing Ex*, REG_*, Cm*, Mm*, SL_*, Io*, IO_*, CONNECT_*, WDM_* and WMI* definitions.
- Update ExGetCurrentResourceThread and PADAPTER_OBJECT.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46290
2010-03-20 23:01:57 +00:00
|
|
|
(NTAPI CALLBACK_FUNCTION)(
|
2012-01-22 14:43:53 +00:00
|
|
|
_In_opt_ PVOID CallbackContext,
|
|
|
|
_In_opt_ PVOID Argument1,
|
|
|
|
_In_opt_ PVOID Argument2);
|
[DDK]
- Fix PIO_CSQ_INSERT_IRP_EX redefinition.
[NTDDK]
- Remove a couple of duplicate definitions.
[XDK]
- Move several definitions to their appropriate places.
- Add COMPUTE_PAGES_SPANNED, NODE_REQUIREMENT, MM_ANY_NODE_OK, PNTFS_DEREF_EXPORTED_SECURITY_DESCRIPTOR, PsWrapApcWow64Thread, IRP_MN_DEVICE_ENUMERATED, USE_DMA_MACROS, NO_LEGACY_DRIVERS, FO_FLAGS_VALID_ONLY_DURING_CREATE, LOADER_PARTITION_INFORMATION_EX, BOOTDISK_INFORMATION_LITE, IO_CSQ_INSERT_IRP_EX, STATUS_CONTINUE_COMPLETION and several missing Ex*, REG_*, Cm*, Mm*, SL_*, Io*, IO_*, CONNECT_*, WDM_* and WMI* definitions.
- Update ExGetCurrentResourceThread and PADAPTER_OBJECT.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46290
2010-03-20 23:01:57 +00:00
|
|
|
typedef CALLBACK_FUNCTION *PCALLBACK_FUNCTION;
|
2010-03-13 00:34:48 +00:00
|
|
|
|
|
|
|
#define GENERAL_LOOKASIDE_LAYOUT \
|
2010-04-23 10:50:19 +00:00
|
|
|
_ANONYMOUS_UNION union { \
|
2010-03-13 00:34:48 +00:00
|
|
|
SLIST_HEADER ListHead; \
|
|
|
|
SINGLE_LIST_ENTRY SingleListHead; \
|
|
|
|
} DUMMYUNIONNAME; \
|
|
|
|
USHORT Depth; \
|
|
|
|
USHORT MaximumDepth; \
|
|
|
|
ULONG TotalAllocates; \
|
2010-04-23 10:50:19 +00:00
|
|
|
_ANONYMOUS_UNION union { \
|
2010-03-13 00:34:48 +00:00
|
|
|
ULONG AllocateMisses; \
|
|
|
|
ULONG AllocateHits; \
|
|
|
|
} DUMMYUNIONNAME2; \
|
|
|
|
ULONG TotalFrees; \
|
2010-04-23 10:50:19 +00:00
|
|
|
_ANONYMOUS_UNION union { \
|
2010-03-13 00:34:48 +00:00
|
|
|
ULONG FreeMisses; \
|
|
|
|
ULONG FreeHits; \
|
|
|
|
} DUMMYUNIONNAME3; \
|
|
|
|
POOL_TYPE Type; \
|
|
|
|
ULONG Tag; \
|
|
|
|
ULONG Size; \
|
2010-04-23 10:50:19 +00:00
|
|
|
_ANONYMOUS_UNION union { \
|
2010-03-13 00:34:48 +00:00
|
|
|
PALLOCATE_FUNCTION_EX AllocateEx; \
|
|
|
|
PALLOCATE_FUNCTION Allocate; \
|
|
|
|
} DUMMYUNIONNAME4; \
|
2010-04-23 10:50:19 +00:00
|
|
|
_ANONYMOUS_UNION union { \
|
2010-03-13 00:34:48 +00:00
|
|
|
PFREE_FUNCTION_EX FreeEx; \
|
|
|
|
PFREE_FUNCTION Free; \
|
|
|
|
} DUMMYUNIONNAME5; \
|
|
|
|
LIST_ENTRY ListEntry; \
|
|
|
|
ULONG LastTotalAllocates; \
|
2010-04-23 10:50:19 +00:00
|
|
|
_ANONYMOUS_UNION union { \
|
2010-03-13 00:34:48 +00:00
|
|
|
ULONG LastAllocateMisses; \
|
|
|
|
ULONG LastAllocateHits; \
|
|
|
|
} DUMMYUNIONNAME6; \
|
|
|
|
ULONG Future[2];
|
|
|
|
|
|
|
|
typedef struct LOOKASIDE_ALIGN _GENERAL_LOOKASIDE {
|
2010-03-18 22:45:30 +00:00
|
|
|
GENERAL_LOOKASIDE_LAYOUT
|
2010-03-13 00:34:48 +00:00
|
|
|
} GENERAL_LOOKASIDE, *PGENERAL_LOOKASIDE;
|
|
|
|
|
|
|
|
typedef struct _GENERAL_LOOKASIDE_POOL {
|
2010-03-18 22:45:30 +00:00
|
|
|
GENERAL_LOOKASIDE_LAYOUT
|
2010-03-13 00:34:48 +00:00
|
|
|
} GENERAL_LOOKASIDE_POOL, *PGENERAL_LOOKASIDE_POOL;
|
|
|
|
|
[XDK]
- Move several definitions to their appropriate places.
- Add FIELD_OFFSET, FIELD_SIZE, POOL_TAGGING, IF_DEBUG, IF_NTOS_DEBUG, LOOKASIDE_CHECK, KIPI_COUNTS, KTIMER_ACTUAL_LENGTH, LOGICAL_PROCESSOR_RELATIONSHIP, LTP_PC_SMT, SYSTEM_LOGICAL_PROCESSOR_INFORMATION, NUMA_NODE_RELATIONSHIP, GROUP_RELATIONSHIP, SYSTEM_LOGICAL_PROCESSOR_INFORMATION_EX, SINGLE_GROUP_LEGACY_API, KMESSAGE_SERVICE_ROUTINE, KSEMAPHORE_ACTUAL_LENGTH and several missing CACHE_*, PROCESSOR_* and KAPC_* definitions.
- Group some related definitions.
- Base several ASSERT_* macros on NT_ASSERT instead of ASSERT.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46284
2010-03-20 11:47:30 +00:00
|
|
|
#define LOOKASIDE_CHECK(f) \
|
|
|
|
C_ASSERT(FIELD_OFFSET(GENERAL_LOOKASIDE,f) == FIELD_OFFSET(GENERAL_LOOKASIDE_POOL,f))
|
|
|
|
|
|
|
|
LOOKASIDE_CHECK(TotalFrees);
|
|
|
|
LOOKASIDE_CHECK(Tag);
|
|
|
|
LOOKASIDE_CHECK(Future);
|
|
|
|
|
2012-01-22 14:43:53 +00:00
|
|
|
typedef struct LOOKASIDE_ALIGN _PAGED_LOOKASIDE_LIST {
|
2010-03-18 22:45:30 +00:00
|
|
|
GENERAL_LOOKASIDE L;
|
2010-03-13 00:34:48 +00:00
|
|
|
#if !defined(_AMD64_) && !defined(_IA64_)
|
2010-03-18 22:45:30 +00:00
|
|
|
FAST_MUTEX Lock__ObsoleteButDoNotDelete;
|
2010-03-13 00:34:48 +00:00
|
|
|
#endif
|
|
|
|
} PAGED_LOOKASIDE_LIST, *PPAGED_LOOKASIDE_LIST;
|
|
|
|
|
|
|
|
typedef struct LOOKASIDE_ALIGN _NPAGED_LOOKASIDE_LIST {
|
2010-03-18 22:45:30 +00:00
|
|
|
GENERAL_LOOKASIDE L;
|
2010-03-13 00:34:48 +00:00
|
|
|
#if !defined(_AMD64_) && !defined(_IA64_)
|
2010-03-18 22:45:30 +00:00
|
|
|
KSPIN_LOCK Lock__ObsoleteButDoNotDelete;
|
2010-03-13 00:34:48 +00:00
|
|
|
#endif
|
|
|
|
} NPAGED_LOOKASIDE_LIST, *PNPAGED_LOOKASIDE_LIST;
|
|
|
|
|
[NTOSKRNL]
- Remove duplicate SINGLE_GROUP_LEGACY_API definition.
[PSDK]
- Add missing GROUP_AFFINITY structure.
[NTDDK]
- Remove ExFreePool definition.
[NDK]
- Remove duplicate PROCESSOR_CACHE_TYPE and CACHE_DESCRIPTOR definitions (they now exist in wdm.h).
[XDK]
- Move several definitions to their appropriate places.
- Add PROCESSOR_CALLBACK_FUNCTION, INVALID_PROCESSOR_INDEX, XSTATE_SAVE, LOOKASIDE_MINIMUM_BLOCK_SIZE and several missing Ke*, KBUGCHECK_*, KB_ADD_PAGES_FLAG_*, EXCEPTION_*, KE_PROCESSOR_CHANGE_*, Ex*, FirstEntrySList, and EX_*, RESOURCE_* definitions.
- Update ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList, ExFreeToPagedLookasideList, OWNER_ENTRY and ERESOURCE.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46287
2010-03-20 16:58:43 +00:00
|
|
|
#define LOOKASIDE_MINIMUM_BLOCK_SIZE (RTL_SIZEOF_THROUGH_FIELD (SLIST_ENTRY, Next))
|
|
|
|
|
2010-03-13 00:34:48 +00:00
|
|
|
typedef struct _LOOKASIDE_LIST_EX {
|
2010-03-18 22:45:30 +00:00
|
|
|
GENERAL_LOOKASIDE_POOL L;
|
2010-03-13 00:34:48 +00:00
|
|
|
} LOOKASIDE_LIST_EX;
|
|
|
|
|
[NTOSKRNL]
- Remove duplicate SINGLE_GROUP_LEGACY_API definition.
[PSDK]
- Add missing GROUP_AFFINITY structure.
[NTDDK]
- Remove ExFreePool definition.
[NDK]
- Remove duplicate PROCESSOR_CACHE_TYPE and CACHE_DESCRIPTOR definitions (they now exist in wdm.h).
[XDK]
- Move several definitions to their appropriate places.
- Add PROCESSOR_CALLBACK_FUNCTION, INVALID_PROCESSOR_INDEX, XSTATE_SAVE, LOOKASIDE_MINIMUM_BLOCK_SIZE and several missing Ke*, KBUGCHECK_*, KB_ADD_PAGES_FLAG_*, EXCEPTION_*, KE_PROCESSOR_CHANGE_*, Ex*, FirstEntrySList, and EX_*, RESOURCE_* definitions.
- Update ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList, ExFreeToPagedLookasideList, OWNER_ENTRY and ERESOURCE.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46287
2010-03-20 16:58:43 +00:00
|
|
|
#if (NTDDI_VERSION >= NTDDI_VISTA)
|
|
|
|
|
|
|
|
#define EX_LOOKASIDE_LIST_EX_FLAGS_RAISE_ON_FAIL 0x00000001UL
|
|
|
|
#define EX_LOOKASIDE_LIST_EX_FLAGS_FAIL_NO_RAISE 0x00000002UL
|
|
|
|
|
|
|
|
#define EX_MAXIMUM_LOOKASIDE_DEPTH_BASE 256
|
|
|
|
#define EX_MAXIMUM_LOOKASIDE_DEPTH_LIMIT 1024
|
|
|
|
|
|
|
|
#endif /* (NTDDI_VERSION >= NTDDI_VISTA) */
|
|
|
|
|
2010-03-13 00:34:48 +00:00
|
|
|
typedef struct _EX_RUNDOWN_REF {
|
2010-04-23 10:50:19 +00:00
|
|
|
_ANONYMOUS_UNION union {
|
2010-03-18 22:45:30 +00:00
|
|
|
volatile ULONG_PTR Count;
|
|
|
|
volatile PVOID Ptr;
|
2010-04-23 10:50:19 +00:00
|
|
|
} DUMMYUNIONNAME;
|
2010-03-13 00:34:48 +00:00
|
|
|
} EX_RUNDOWN_REF, *PEX_RUNDOWN_REF;
|
|
|
|
|
2010-03-18 22:45:30 +00:00
|
|
|
typedef struct _EX_RUNDOWN_REF_CACHE_AWARE *PEX_RUNDOWN_REF_CACHE_AWARE;
|
2010-03-13 00:34:48 +00:00
|
|
|
|
[NTOSKRNL]
- Remove duplicate SINGLE_GROUP_LEGACY_API definition.
[PSDK]
- Add missing GROUP_AFFINITY structure.
[NTDDK]
- Remove ExFreePool definition.
[NDK]
- Remove duplicate PROCESSOR_CACHE_TYPE and CACHE_DESCRIPTOR definitions (they now exist in wdm.h).
[XDK]
- Move several definitions to their appropriate places.
- Add PROCESSOR_CALLBACK_FUNCTION, INVALID_PROCESSOR_INDEX, XSTATE_SAVE, LOOKASIDE_MINIMUM_BLOCK_SIZE and several missing Ke*, KBUGCHECK_*, KB_ADD_PAGES_FLAG_*, EXCEPTION_*, KE_PROCESSOR_CHANGE_*, Ex*, FirstEntrySList, and EX_*, RESOURCE_* definitions.
- Update ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList, ExFreeToPagedLookasideList, OWNER_ENTRY and ERESOURCE.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46287
2010-03-20 16:58:43 +00:00
|
|
|
typedef enum _WORK_QUEUE_TYPE {
|
|
|
|
CriticalWorkQueue,
|
|
|
|
DelayedWorkQueue,
|
|
|
|
HyperCriticalWorkQueue,
|
|
|
|
MaximumWorkQueue
|
|
|
|
} WORK_QUEUE_TYPE;
|
|
|
|
|
2012-01-22 14:43:53 +00:00
|
|
|
_IRQL_requires_same_
|
|
|
|
_Function_class_(WORKER_THREAD_ROUTINE)
|
2010-03-13 00:34:48 +00:00
|
|
|
typedef VOID
|
[NTOSKRNL]
- Remove duplicate SINGLE_GROUP_LEGACY_API definition.
[PSDK]
- Add missing GROUP_AFFINITY structure.
[NTDDK]
- Remove ExFreePool definition.
[NDK]
- Remove duplicate PROCESSOR_CACHE_TYPE and CACHE_DESCRIPTOR definitions (they now exist in wdm.h).
[XDK]
- Move several definitions to their appropriate places.
- Add PROCESSOR_CALLBACK_FUNCTION, INVALID_PROCESSOR_INDEX, XSTATE_SAVE, LOOKASIDE_MINIMUM_BLOCK_SIZE and several missing Ke*, KBUGCHECK_*, KB_ADD_PAGES_FLAG_*, EXCEPTION_*, KE_PROCESSOR_CHANGE_*, Ex*, FirstEntrySList, and EX_*, RESOURCE_* definitions.
- Update ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList, ExFreeToPagedLookasideList, OWNER_ENTRY and ERESOURCE.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46287
2010-03-20 16:58:43 +00:00
|
|
|
(NTAPI WORKER_THREAD_ROUTINE)(
|
2012-01-22 14:43:53 +00:00
|
|
|
_In_ PVOID Parameter);
|
[NTOSKRNL]
- Remove duplicate SINGLE_GROUP_LEGACY_API definition.
[PSDK]
- Add missing GROUP_AFFINITY structure.
[NTDDK]
- Remove ExFreePool definition.
[NDK]
- Remove duplicate PROCESSOR_CACHE_TYPE and CACHE_DESCRIPTOR definitions (they now exist in wdm.h).
[XDK]
- Move several definitions to their appropriate places.
- Add PROCESSOR_CALLBACK_FUNCTION, INVALID_PROCESSOR_INDEX, XSTATE_SAVE, LOOKASIDE_MINIMUM_BLOCK_SIZE and several missing Ke*, KBUGCHECK_*, KB_ADD_PAGES_FLAG_*, EXCEPTION_*, KE_PROCESSOR_CHANGE_*, Ex*, FirstEntrySList, and EX_*, RESOURCE_* definitions.
- Update ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList, ExFreeToPagedLookasideList, OWNER_ENTRY and ERESOURCE.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46287
2010-03-20 16:58:43 +00:00
|
|
|
typedef WORKER_THREAD_ROUTINE *PWORKER_THREAD_ROUTINE;
|
2010-03-13 00:34:48 +00:00
|
|
|
|
|
|
|
typedef struct _WORK_QUEUE_ITEM {
|
2010-03-18 22:45:30 +00:00
|
|
|
LIST_ENTRY List;
|
|
|
|
PWORKER_THREAD_ROUTINE WorkerRoutine;
|
|
|
|
volatile PVOID Parameter;
|
2010-03-13 00:34:48 +00:00
|
|
|
} WORK_QUEUE_ITEM, *PWORK_QUEUE_ITEM;
|
|
|
|
|
[NTOSKRNL]
- Remove duplicate SINGLE_GROUP_LEGACY_API definition.
[PSDK]
- Add missing GROUP_AFFINITY structure.
[NTDDK]
- Remove ExFreePool definition.
[NDK]
- Remove duplicate PROCESSOR_CACHE_TYPE and CACHE_DESCRIPTOR definitions (they now exist in wdm.h).
[XDK]
- Move several definitions to their appropriate places.
- Add PROCESSOR_CALLBACK_FUNCTION, INVALID_PROCESSOR_INDEX, XSTATE_SAVE, LOOKASIDE_MINIMUM_BLOCK_SIZE and several missing Ke*, KBUGCHECK_*, KB_ADD_PAGES_FLAG_*, EXCEPTION_*, KE_PROCESSOR_CHANGE_*, Ex*, FirstEntrySList, and EX_*, RESOURCE_* definitions.
- Update ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList, ExFreeToPagedLookasideList, OWNER_ENTRY and ERESOURCE.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46287
2010-03-20 16:58:43 +00:00
|
|
|
typedef ULONG_PTR ERESOURCE_THREAD, *PERESOURCE_THREAD;
|
|
|
|
|
|
|
|
typedef struct _OWNER_ENTRY {
|
|
|
|
ERESOURCE_THREAD OwnerThread;
|
2010-04-23 10:50:19 +00:00
|
|
|
_ANONYMOUS_UNION union {
|
|
|
|
_ANONYMOUS_STRUCT struct {
|
[NTOSKRNL]
- Remove duplicate SINGLE_GROUP_LEGACY_API definition.
[PSDK]
- Add missing GROUP_AFFINITY structure.
[NTDDK]
- Remove ExFreePool definition.
[NDK]
- Remove duplicate PROCESSOR_CACHE_TYPE and CACHE_DESCRIPTOR definitions (they now exist in wdm.h).
[XDK]
- Move several definitions to their appropriate places.
- Add PROCESSOR_CALLBACK_FUNCTION, INVALID_PROCESSOR_INDEX, XSTATE_SAVE, LOOKASIDE_MINIMUM_BLOCK_SIZE and several missing Ke*, KBUGCHECK_*, KB_ADD_PAGES_FLAG_*, EXCEPTION_*, KE_PROCESSOR_CHANGE_*, Ex*, FirstEntrySList, and EX_*, RESOURCE_* definitions.
- Update ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList, ExFreeToPagedLookasideList, OWNER_ENTRY and ERESOURCE.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46287
2010-03-20 16:58:43 +00:00
|
|
|
ULONG IoPriorityBoosted:1;
|
|
|
|
ULONG OwnerReferenced:1;
|
|
|
|
ULONG OwnerCount:30;
|
2010-04-23 10:50:19 +00:00
|
|
|
} DUMMYSTRUCTNAME;
|
[NTOSKRNL]
- Remove duplicate SINGLE_GROUP_LEGACY_API definition.
[PSDK]
- Add missing GROUP_AFFINITY structure.
[NTDDK]
- Remove ExFreePool definition.
[NDK]
- Remove duplicate PROCESSOR_CACHE_TYPE and CACHE_DESCRIPTOR definitions (they now exist in wdm.h).
[XDK]
- Move several definitions to their appropriate places.
- Add PROCESSOR_CALLBACK_FUNCTION, INVALID_PROCESSOR_INDEX, XSTATE_SAVE, LOOKASIDE_MINIMUM_BLOCK_SIZE and several missing Ke*, KBUGCHECK_*, KB_ADD_PAGES_FLAG_*, EXCEPTION_*, KE_PROCESSOR_CHANGE_*, Ex*, FirstEntrySList, and EX_*, RESOURCE_* definitions.
- Update ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList, ExFreeToPagedLookasideList, OWNER_ENTRY and ERESOURCE.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46287
2010-03-20 16:58:43 +00:00
|
|
|
ULONG TableSize;
|
2010-04-23 10:50:19 +00:00
|
|
|
} DUMMYUNIONNAME;
|
[NTOSKRNL]
- Remove duplicate SINGLE_GROUP_LEGACY_API definition.
[PSDK]
- Add missing GROUP_AFFINITY structure.
[NTDDK]
- Remove ExFreePool definition.
[NDK]
- Remove duplicate PROCESSOR_CACHE_TYPE and CACHE_DESCRIPTOR definitions (they now exist in wdm.h).
[XDK]
- Move several definitions to their appropriate places.
- Add PROCESSOR_CALLBACK_FUNCTION, INVALID_PROCESSOR_INDEX, XSTATE_SAVE, LOOKASIDE_MINIMUM_BLOCK_SIZE and several missing Ke*, KBUGCHECK_*, KB_ADD_PAGES_FLAG_*, EXCEPTION_*, KE_PROCESSOR_CHANGE_*, Ex*, FirstEntrySList, and EX_*, RESOURCE_* definitions.
- Update ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList, ExFreeToPagedLookasideList, OWNER_ENTRY and ERESOURCE.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46287
2010-03-20 16:58:43 +00:00
|
|
|
} OWNER_ENTRY, *POWNER_ENTRY;
|
|
|
|
|
|
|
|
typedef struct _ERESOURCE {
|
|
|
|
LIST_ENTRY SystemResourcesList;
|
|
|
|
POWNER_ENTRY OwnerTable;
|
|
|
|
SHORT ActiveCount;
|
|
|
|
USHORT Flag;
|
|
|
|
volatile PKSEMAPHORE SharedWaiters;
|
|
|
|
volatile PKEVENT ExclusiveWaiters;
|
|
|
|
OWNER_ENTRY OwnerEntry;
|
|
|
|
ULONG ActiveEntries;
|
|
|
|
ULONG ContentionCount;
|
|
|
|
ULONG NumberOfSharedWaiters;
|
|
|
|
ULONG NumberOfExclusiveWaiters;
|
|
|
|
#if defined(_WIN64)
|
|
|
|
PVOID Reserved2;
|
|
|
|
#endif
|
2010-04-23 10:50:19 +00:00
|
|
|
_ANONYMOUS_UNION union {
|
[NTOSKRNL]
- Remove duplicate SINGLE_GROUP_LEGACY_API definition.
[PSDK]
- Add missing GROUP_AFFINITY structure.
[NTDDK]
- Remove ExFreePool definition.
[NDK]
- Remove duplicate PROCESSOR_CACHE_TYPE and CACHE_DESCRIPTOR definitions (they now exist in wdm.h).
[XDK]
- Move several definitions to their appropriate places.
- Add PROCESSOR_CALLBACK_FUNCTION, INVALID_PROCESSOR_INDEX, XSTATE_SAVE, LOOKASIDE_MINIMUM_BLOCK_SIZE and several missing Ke*, KBUGCHECK_*, KB_ADD_PAGES_FLAG_*, EXCEPTION_*, KE_PROCESSOR_CHANGE_*, Ex*, FirstEntrySList, and EX_*, RESOURCE_* definitions.
- Update ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList, ExFreeToPagedLookasideList, OWNER_ENTRY and ERESOURCE.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46287
2010-03-20 16:58:43 +00:00
|
|
|
PVOID Address;
|
|
|
|
ULONG_PTR CreatorBackTraceIndex;
|
2010-04-23 10:50:19 +00:00
|
|
|
} DUMMYUNIONNAME;
|
[NTOSKRNL]
- Remove duplicate SINGLE_GROUP_LEGACY_API definition.
[PSDK]
- Add missing GROUP_AFFINITY structure.
[NTDDK]
- Remove ExFreePool definition.
[NDK]
- Remove duplicate PROCESSOR_CACHE_TYPE and CACHE_DESCRIPTOR definitions (they now exist in wdm.h).
[XDK]
- Move several definitions to their appropriate places.
- Add PROCESSOR_CALLBACK_FUNCTION, INVALID_PROCESSOR_INDEX, XSTATE_SAVE, LOOKASIDE_MINIMUM_BLOCK_SIZE and several missing Ke*, KBUGCHECK_*, KB_ADD_PAGES_FLAG_*, EXCEPTION_*, KE_PROCESSOR_CHANGE_*, Ex*, FirstEntrySList, and EX_*, RESOURCE_* definitions.
- Update ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList, ExFreeToPagedLookasideList, OWNER_ENTRY and ERESOURCE.
- Group some related definitions.
[WDM]
- Update wdm.h to reflect XDK changes.
svn path=/branches/header-work/; revision=46287
2010-03-20 16:58:43 +00:00
|
|
|
KSPIN_LOCK SpinLock;
|
|
|
|
} ERESOURCE, *PERESOURCE;
|
|
|
|
|
|
|
|
/* ERESOURCE.Flag */
|
|
|
|
#define ResourceNeverExclusive 0x0010
|
|
|
|
#define ResourceReleaseByOtherThread 0x0020
|
|
|
|
#define ResourceOwnedExclusive 0x0080
|
|
|
|
|
|
|
|
#define RESOURCE_HASH_TABLE_SIZE 64
|
|
|
|
|
|
|
|
typedef struct _RESOURCE_HASH_ENTRY {
|
|
|
|
LIST_ENTRY ListEntry;
|
|
|
|
PVOID Address;
|
|
|
|
ULONG ContentionCount;
|
|
|
|
ULONG Number;
|
|
|
|
} RESOURCE_HASH_ENTRY, *PRESOURCE_HASH_ENTRY;
|
|
|
|
|
|
|
|
typedef struct _RESOURCE_PERFORMANCE_DATA {
|
|
|
|
ULONG ActiveResourceCount;
|
|
|
|
ULONG TotalResourceCount;
|
|
|
|
ULONG ExclusiveAcquire;
|
|
|
|
ULONG SharedFirstLevel;
|
|
|
|
ULONG SharedSecondLevel;
|
|
|
|
ULONG StarveFirstLevel;
|
|
|
|
ULONG StarveSecondLevel;
|
|
|
|
ULONG WaitForExclusive;
|
|
|
|
ULONG OwnerTableExpands;
|
|
|
|
ULONG MaximumTableExpand;
|
|
|
|
LIST_ENTRY HashTable[RESOURCE_HASH_TABLE_SIZE];
|
|
|
|
} RESOURCE_PERFORMANCE_DATA, *PRESOURCE_PERFORMANCE_DATA;
|
|
|
|
|
2010-03-23 19:24:29 +00:00
|
|
|
/* Global debug flag */
|
|
|
|
#if DEVL
|
|
|
|
extern ULONG NtGlobalFlag;
|
|
|
|
#define IF_NTOS_DEBUG(FlagName) if (NtGlobalFlag & (FLG_##FlagName))
|
|
|
|
#else
|
|
|
|
#define IF_NTOS_DEBUG(FlagName) if(FALSE)
|
|
|
|
#endif
|
|
|
|
|
2010-03-27 10:45:04 +00:00
|
|
|
$endif (_WDMDDK_)
|
2010-03-23 19:24:29 +00:00
|
|
|
$if (_NTDDK_)
|
|
|
|
typedef struct _ZONE_SEGMENT_HEADER {
|
|
|
|
SINGLE_LIST_ENTRY SegmentList;
|
|
|
|
PVOID Reserved;
|
|
|
|
} ZONE_SEGMENT_HEADER, *PZONE_SEGMENT_HEADER;
|
|
|
|
|
|
|
|
typedef struct _ZONE_HEADER {
|
|
|
|
SINGLE_LIST_ENTRY FreeList;
|
|
|
|
SINGLE_LIST_ENTRY SegmentList;
|
|
|
|
ULONG BlockSize;
|
|
|
|
ULONG TotalSegmentSize;
|
|
|
|
} ZONE_HEADER, *PZONE_HEADER;
|
|
|
|
|
|
|
|
#define PROTECTED_POOL 0x80000000
|
2010-03-13 00:34:48 +00:00
|
|
|
|
2010-03-27 10:45:04 +00:00
|
|
|
$endif (_NTDDK_)
|
2010-03-30 21:50:05 +00:00
|
|
|
$if (_NTIFS_)
|
|
|
|
#define INVALID_PROCESSOR_INDEX 0xffffffff
|
|
|
|
|
|
|
|
#define EX_PUSH_LOCK ULONG_PTR
|
|
|
|
#define PEX_PUSH_LOCK PULONG_PTR
|
|
|
|
$endif (_NTIFS_)
|