update for HEAD-2003091401
[reactos.git] / ntoskrnl / fs / pool.c
1 /* $Id$
2  *
3  * reactos/ntoskrnl/fs/pool.c
4  *
5  */
6 #include <ntos.h>
7 #include <ddk/ntifs.h>
8 #include <internal/ifs.h>
9
10
11 /**********************************************************************
12  * NAME                                                 EXPORTED
13  *      FsRtlAllocatePool@8
14  *
15  * DESCRIPTION
16  *      
17  * ARGUMENTS
18  *
19  * RETURN VALUE
20  *
21  * NOTE
22  *      IFS_POOL_TAG is "FSrt" in mem view.
23  *
24  * @implemented
25  */
26 PVOID
27 STDCALL
28 FsRtlAllocatePool (
29         IN      POOL_TYPE       PoolType,
30         IN      ULONG           NumberOfBytes
31         )
32 {
33         PVOID   Address;
34
35         Address = ExAllocatePoolWithTag (
36                         PoolType,
37                         NumberOfBytes,
38                         IFS_POOL_TAG
39                         );
40         if (NULL == Address)
41         {
42                 ExRaiseStatus (STATUS_INSUFFICIENT_RESOURCES);
43         }
44         return Address;
45 }
46
47
48 /**********************************************************************
49  * NAME                                                 EXPORTED
50  *      FsRtlAllocatePoolWithQuota@8
51  *
52  * DESCRIPTION
53  *      
54  * ARGUMENTS
55  *
56  * RETURN VALUE
57  *
58  * NOTE
59  *      IFS_POOL_TAG is "FSrt" in mem view.
60  *
61  * @implemented
62  */
63 PVOID
64 STDCALL
65 FsRtlAllocatePoolWithQuota (
66         IN      POOL_TYPE       PoolType,
67         IN      ULONG           NumberOfBytes
68         )
69 {
70         PVOID   Address;
71
72         Address = ExAllocatePoolWithQuotaTag (
73                         PoolType,
74                         NumberOfBytes,
75                         IFS_POOL_TAG
76                         );
77         if (NULL == Address)
78         {
79                 ExRaiseStatus (STATUS_INSUFFICIENT_RESOURCES);
80         }
81         return Address;
82 }
83
84
85 /**********************************************************************
86  * NAME                                                 EXPORTED
87  *      FsRtlAllocatePoolWithQuotaTag@12
88  *
89  * DESCRIPTION
90  *      
91  * ARGUMENTS
92  *
93  * RETURN VALUE
94  *
95  * @implemented
96  */
97 PVOID
98 STDCALL
99 FsRtlAllocatePoolWithQuotaTag (
100         IN      POOL_TYPE       PoolType,
101         IN      ULONG           NumberOfBytes,
102         IN      ULONG           Tag
103         )
104 {
105         PVOID   Address;
106
107         Address = ExAllocatePoolWithQuotaTag (
108                         PoolType,
109                         NumberOfBytes,
110                         Tag
111                         );
112         if (NULL == Address)
113         {
114                 ExRaiseStatus (STATUS_INSUFFICIENT_RESOURCES);
115         }
116         return Address;
117 }
118
119
120 /**********************************************************************
121  * NAME                                                 EXPORTED
122  *      FsRtlAllocatePoolWithTag@12
123  *
124  * DESCRIPTION
125  *      
126  * ARGUMENTS
127  *
128  * RETURN VALUE
129  *
130  * @implemented
131  */
132 PVOID
133 STDCALL
134 FsRtlAllocatePoolWithTag (
135         IN      POOL_TYPE       PoolType,
136         IN      ULONG           NumberOfBytes,
137         IN      ULONG           Tag
138         )
139 {
140         PVOID   Address;
141
142         Address = ExAllocatePoolWithTag (
143                         PoolType,
144                         NumberOfBytes,
145                         Tag
146                         );
147         if (NULL == Address)
148         {
149                 ExRaiseStatus (STATUS_INSUFFICIENT_RESOURCES);
150         }
151         return Address;
152 }
153
154
155
156 /* EOF */