mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 10:04:49 +00:00
Sorry i didn't have all the assertions correct in ntoskrnl/mm/pool.c
Now i've moved them to npool.c and ppool.c, where they are shorter. svn path=/trunk/; revision=11145
This commit is contained in:
parent
adeb131ada
commit
0b03f1a2a9
3 changed files with 7 additions and 15 deletions
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: npool.c,v 1.90 2004/09/25 06:41:16 arty Exp $
|
/* $Id: npool.c,v 1.91 2004/10/01 20:51:28 arty Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -1556,6 +1556,8 @@ ExAllocateNonPagedPoolWithTag(ULONG Type, ULONG Size, ULONG Tag, PVOID Caller)
|
||||||
PVOID block;
|
PVOID block;
|
||||||
KIRQL oldIrql;
|
KIRQL oldIrql;
|
||||||
|
|
||||||
|
ASSERT_IRQL(DISPATCH_LEVEL);
|
||||||
|
|
||||||
POOL_TRACE("ExAllocatePool(NumberOfBytes %d) caller %x ",
|
POOL_TRACE("ExAllocatePool(NumberOfBytes %d) caller %x ",
|
||||||
Size,Caller);
|
Size,Caller);
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: pool.c,v 1.34 2004/10/01 04:00:11 arty Exp $
|
/* $Id: pool.c,v 1.35 2004/10/01 20:51:29 arty Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -93,8 +93,6 @@ ExAllocatePool (POOL_TYPE PoolType, ULONG NumberOfBytes)
|
||||||
*/
|
*/
|
||||||
{
|
{
|
||||||
PVOID Block;
|
PVOID Block;
|
||||||
ASSERT_IRQL(DISPATCH_LEVEL);
|
|
||||||
assert(KeGetCurrentIrql() == PASSIVE_LEVEL || PoolType == NonPagedPool);
|
|
||||||
|
|
||||||
#if defined(__GNUC__)
|
#if defined(__GNUC__)
|
||||||
|
|
||||||
|
@ -124,9 +122,6 @@ ExAllocatePoolWithTag (ULONG PoolType, ULONG NumberOfBytes, ULONG Tag)
|
||||||
{
|
{
|
||||||
PVOID Block;
|
PVOID Block;
|
||||||
|
|
||||||
ASSERT_IRQL(DISPATCH_LEVEL);
|
|
||||||
assert(KeGetCurrentIrql() == PASSIVE_LEVEL || PoolType != PagedPool);
|
|
||||||
|
|
||||||
#if defined(__GNUC__)
|
#if defined(__GNUC__)
|
||||||
|
|
||||||
Block = EiAllocatePool(PoolType,
|
Block = EiAllocatePool(PoolType,
|
||||||
|
@ -168,9 +163,6 @@ ExAllocatePoolWithTagPriority(
|
||||||
IN EX_POOL_PRIORITY Priority
|
IN EX_POOL_PRIORITY Priority
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
ASSERT_IRQL(DISPATCH_LEVEL);
|
|
||||||
assert(KeGetCurrentIrql() == PASSIVE_LEVEL || PoolType != PagedPool);
|
|
||||||
|
|
||||||
/* Check if this is one of the "Special" Flags, used by the Verifier */
|
/* Check if this is one of the "Special" Flags, used by the Verifier */
|
||||||
if (Priority & 8) {
|
if (Priority & 8) {
|
||||||
/* Check if this is a xxSpecialUnderrun */
|
/* Check if this is a xxSpecialUnderrun */
|
||||||
|
@ -198,9 +190,6 @@ ExAllocatePoolWithQuotaTag (IN POOL_TYPE PoolType,
|
||||||
PVOID Block;
|
PVOID Block;
|
||||||
PEPROCESS Process;
|
PEPROCESS Process;
|
||||||
|
|
||||||
ASSERT_IRQL(DISPATCH_LEVEL);
|
|
||||||
assert(KeGetCurrentIrql() == PASSIVE_LEVEL || PoolType == NonPagedPool);
|
|
||||||
|
|
||||||
/* Allocate the Pool First */
|
/* Allocate the Pool First */
|
||||||
Block = EiAllocatePool(PoolType,
|
Block = EiAllocatePool(PoolType,
|
||||||
NumberOfBytes,
|
NumberOfBytes,
|
||||||
|
@ -263,7 +252,6 @@ ExFreePool(IN PVOID Block)
|
||||||
VOID STDCALL
|
VOID STDCALL
|
||||||
ExFreePoolWithTag(IN PVOID Block, IN ULONG Tag)
|
ExFreePoolWithTag(IN PVOID Block, IN ULONG Tag)
|
||||||
{
|
{
|
||||||
ASSERT_IRQL(DISPATCH_LEVEL);
|
|
||||||
/* FIXME: Validate the tag */
|
/* FIXME: Validate the tag */
|
||||||
ExFreePool(Block);
|
ExFreePool(Block);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: ppool.c,v 1.30 2004/08/15 16:39:08 chorns Exp $
|
/* $Id: ppool.c,v 1.31 2004/10/01 20:51:29 arty Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -172,6 +172,8 @@ ExAllocatePagedPoolWithTag (IN POOL_TYPE PoolType,
|
||||||
PVOID BlockAddress;
|
PVOID BlockAddress;
|
||||||
ULONG Alignment;
|
ULONG Alignment;
|
||||||
|
|
||||||
|
ASSERT_IRQL(PASSIVE_LEVEL);
|
||||||
|
|
||||||
ExAcquireFastMutex(&MmPagedPoolLock);
|
ExAcquireFastMutex(&MmPagedPoolLock);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Reference in a new issue