ReactOS
0.4.16-dev-197-g92996da
pool.c
Go to the documentation of this file.
1
/*
2
* PROJECT: ReactOS Universal Audio Class Driver
3
* LICENSE: GPL - See COPYING in the top level directory
4
* FILE: drivers/usb/usbaudio/pool.c
5
* PURPOSE: USB Audio device driver.
6
* PROGRAMMERS:
7
* Johannes Anderwald (johannes.anderwald@reactos.org)
8
*/
9
#include "
usbaudio.h
"
10
11
PVOID
12
NTAPI
13
AllocFunction
(
14
IN
ULONG
ItemSize
)
15
{
16
PVOID
Item
=
ExAllocatePoolWithTag
(
NonPagedPool
,
ItemSize
,
USBAUDIO_TAG
);
17
if
(
Item
)
18
{
19
// zero item
20
RtlZeroMemory
(
Item
,
ItemSize
);
21
}
22
23
// done
24
return
Item
;
25
}
26
27
VOID
28
NTAPI
29
FreeFunction
(
30
IN
PVOID
Item
)
31
{
32
/* free item */
33
ExFreePoolWithTag
(
Item
,
USBAUDIO_TAG
);
34
}
35
AllocFunction
PVOID NTAPI AllocFunction(IN ULONG ItemSize)
Definition:
pool.c:13
FreeFunction
VOID NTAPI FreeFunction(IN PVOID Item)
Definition:
pool.c:29
ExAllocatePoolWithTag
#define ExAllocatePoolWithTag(hernya, size, tag)
Definition:
env_spec_w32.h:350
NonPagedPool
#define NonPagedPool
Definition:
env_spec_w32.h:307
void
Definition:
nsiface.idl:2307
ExFreePoolWithTag
#define ExFreePoolWithTag(_P, _T)
Definition:
module.h:1109
ItemSize
static UCHAR ItemSize[4]
Definition:
parser.c:16
NTAPI
#define NTAPI
Definition:
typedefs.h:36
RtlZeroMemory
#define RtlZeroMemory(Destination, Length)
Definition:
typedefs.h:262
IN
#define IN
Definition:
typedefs.h:39
ULONG
uint32_t ULONG
Definition:
typedefs.h:59
usbaudio.h
USBAUDIO_TAG
#define USBAUDIO_TAG
Definition:
usbaudio.h:13
Item
_In_ WDFCOLLECTION _In_ WDFOBJECT Item
Definition:
wdfcollection.h:153
drivers
usb
usbaudio
pool.c
Generated on Wed Oct 30 2024 06:05:49 for ReactOS by
1.9.6