30ef07cbf04d95bc53ca0f6528732b0ecd95cb90
[reactos.git] / reactos / ntoskrnl / fs / notify.c
1 /* $Id: notify.c,v 1.11 2004/06/27 13:58:05 navaraf Exp $
2 *
3 * reactos/ntoskrnl/fs/notify.c
4 *
5 */
6 #include <ntos.h>
7 #include <ddk/ntifs.h>
8
9 #define NDEBUG
10 #include <internal/debug.h>
11
12 /**********************************************************************
13 * NAME EXPORTED
14 * FsRtlNotifyChangeDirectory@28
15 *
16 * DESCRIPTION
17 *
18 * ARGUMENTS
19 *
20 * RETURN VALUE
21 *
22 * @implemented
23 */
24 VOID
25 STDCALL
26 FsRtlNotifyChangeDirectory (
27 IN PNOTIFY_SYNC NotifySync,
28 IN PVOID FsContext,
29 IN PSTRING FullDirectoryName,
30 IN PLIST_ENTRY NotifyList,
31 IN BOOLEAN WatchTree,
32 IN ULONG CompletionFilter,
33 IN PIRP NotifyIrp
34 )
35 {
36 FsRtlNotifyFullChangeDirectory (
37 NotifySync,
38 NotifyList,
39 FsContext,
40 FullDirectoryName,
41 WatchTree,
42 TRUE, /* IgnoreBuffer */
43 CompletionFilter,
44 NotifyIrp,
45 NULL,
46 NULL
47 );
48 }
49
50
51
52 /**********************************************************************
53 * NAME EXPORTED
54 * FsRtlNotifyCleanup@12
55 *
56 * DESCRIPTION
57 *
58 * ARGUMENTS
59 *
60 * RETURN VALUE
61 *
62 * @unimplemented
63 */
64 VOID
65 STDCALL
66 FsRtlNotifyCleanup (
67 IN PNOTIFY_SYNC NotifySync,
68 IN PLIST_ENTRY NotifyList,
69 IN PVOID FsContext
70 )
71 {
72 }
73
74
75 /*
76 * @unimplemented
77 */
78 STDCALL
79 VOID
80 FsRtlNotifyFilterChangeDirectory (
81 IN PNOTIFY_SYNC NotifySync,
82 IN PLIST_ENTRY NotifyList,
83 IN PVOID FsContext,
84 IN PSTRING FullDirectoryName,
85 IN BOOLEAN WatchTree,
86 IN BOOLEAN IgnoreBuffer,
87 IN ULONG CompletionFilter,
88 IN PIRP NotifyIrp,
89 IN PCHECK_FOR_TRAVERSE_ACCESS TraverseCallback OPTIONAL,
90 IN PSECURITY_SUBJECT_CONTEXT SubjectContext OPTIONAL,
91 IN PFILTER_REPORT_CHANGE FilterCallback OPTIONAL
92 )
93 {
94 UNIMPLEMENTED;
95 }
96
97 /*
98 * @unimplemented
99 */
100 STDCALL
101 VOID
102 FsRtlNotifyFilterReportChange (
103 IN PNOTIFY_SYNC NotifySync,
104 IN PLIST_ENTRY NotifyList,
105 IN PSTRING FullTargetName,
106 IN USHORT TargetNameOffset,
107 IN PSTRING StreamName OPTIONAL,
108 IN PSTRING NormalizedParentName OPTIONAL,
109 IN ULONG FilterMatch,
110 IN ULONG Action,
111 IN PVOID TargetContext,
112 IN PVOID FilterContext
113 )
114 {
115 UNIMPLEMENTED;
116 }
117
118
119 /**********************************************************************
120 * NAME EXPORTED
121 * FsRtlNotifyFullChangeDirectory@40
122 *
123 * DESCRIPTION
124 *
125 * ARGUMENTS
126 *
127 * RETURN VALUE
128 *
129 * @unimplemented
130 */
131 VOID
132 STDCALL
133 FsRtlNotifyFullChangeDirectory (
134 IN PNOTIFY_SYNC NotifySync,
135 IN PLIST_ENTRY NotifyList,
136 IN PVOID FsContext,
137 IN PSTRING FullDirectoryName,
138 IN BOOLEAN WatchTree,
139 IN BOOLEAN IgnoreBuffer,
140 IN ULONG CompletionFilter,
141 IN PIRP NotifyIrp,
142 IN PCHECK_FOR_TRAVERSE_ACCESS TraverseCallback OPTIONAL,
143 IN PSECURITY_SUBJECT_CONTEXT SubjectContext OPTIONAL
144 )
145 {
146 #if defined(__GNUC__) || (defined(_MSC_VER) && _MSC_VER >= 1300)
147 DbgPrint("%s()\n", __FUNCTION__);
148 #else
149 DbgPrint("FsRtlNotifyFullChangeDirectory()\n");
150 #endif
151 }
152
153
154 /**********************************************************************
155 * NAME EXPORTED
156 * FsRtlNotifyFullReportChange@36
157 *
158 * DESCRIPTION
159 *
160 * ARGUMENTS
161 *
162 * RETURN VALUE
163 *
164 * @unimplemented
165 */
166 VOID
167 STDCALL
168 FsRtlNotifyFullReportChange (
169 IN PNOTIFY_SYNC NotifySync,
170 IN PLIST_ENTRY NotifyList,
171 IN PSTRING FullTargetName,
172 IN USHORT TargetNameOffset,
173 IN PSTRING StreamName OPTIONAL,
174 IN PSTRING NormalizedParentName OPTIONAL,
175 IN ULONG FilterMatch,
176 IN ULONG Action,
177 IN PVOID TargetContext
178 )
179 {
180 }
181
182
183 /**********************************************************************
184 * NAME EXPORTED
185 * FsRtlNotifyInitializeSync@4
186 *
187 * DESCRIPTION
188 *
189 * ARGUMENTS
190 *
191 * RETURN VALUE
192 *
193 * @implemented
194 */
195 VOID
196 STDCALL
197 FsRtlNotifyInitializeSync (
198 IN PNOTIFY_SYNC NotifySync
199 )
200 {
201 #if 0
202 *NotifySync = NULL;
203 *NotifySync = ExAllocatePoolWithTag (
204 0x10, // PoolType???
205 sizeof (NOTIFY_SYNC), // NumberOfBytes = 0x28
206 FSRTL_TAG
207 );
208
209 *NotifySync->Unknown0 = 1;
210 *NotifySync->Unknown2 = 0;
211 *NotifySync->Unknown3 = 1;
212 *NotifySync->Unknown4 = 4;
213 *NotifySync->Unknown5 = 0;
214 *NotifySync->Unknown9 = 0;
215 *NotifySync->Unknown10 = 0;
216 #endif
217 }
218
219
220 /**********************************************************************
221 * NAME EXPORTED
222 * FsRtlNotifyReportChange@20
223 *
224 * DESCRIPTION
225 *
226 * ARGUMENTS
227 *
228 * RETURN VALUE
229 *
230 * @implemented
231 */
232 VOID
233 STDCALL
234 FsRtlNotifyReportChange (
235 IN PNOTIFY_SYNC NotifySync,
236 IN PLIST_ENTRY NotifyList,
237 IN PSTRING FullTargetName,
238 IN PUSHORT FileNamePartLength,
239 IN ULONG FilterMatch
240 )
241 {
242 FsRtlNotifyFullReportChange (
243 NotifySync,
244 NotifyList,
245 FullTargetName,
246 (FullTargetName->Length - *FileNamePartLength), /*?*/
247 NULL,
248 NULL,
249 FilterMatch,
250 0, /* Action ? */
251 NULL
252 );
253 }
254
255
256 /**********************************************************************
257 * NAME EXPORTED
258 * FsRtlNotifyUninitializeSync@4
259 *
260 * DESCRIPTION
261 * Uninitialize a NOTIFY_SYNC object.
262 *
263 * ARGUMENTS
264 * NotifySync is the address of a pointer
265 * to a PNOTIFY_SYNC object previously initialized by
266 * FsRtlNotifyInitializeSync().
267 *
268 * RETURN VALUE
269 * None.
270 *
271 * @implemented
272 */
273 VOID
274 STDCALL
275 FsRtlNotifyUninitializeSync (
276 IN OUT PNOTIFY_SYNC NotifySync
277 )
278 {
279 #if 0
280 if (NULL != *NotifySync)
281 {
282 ExFreePool (*NotifySync);
283 *NotifySync = NULL;
284 }
285 #endif
286 }
287
288 /**********************************************************************
289 * NAME EXPORTED
290 * FsRtlNotifyVolumeEvent@8
291 *
292 * DESCRIPTION
293 * NOTE: Only present in NT 5+.
294 *
295 * ARGUMENTS
296 *
297 * RETURN VALUE
298 *
299 * @unimplemented
300 */
301 NTSTATUS
302 STDCALL
303 FsRtlNotifyVolumeEvent (
304 IN PFILE_OBJECT FileObject,
305 IN ULONG EventCode
306 )
307 {
308 return STATUS_NOT_IMPLEMENTED;
309 }
310
311 /*
312 *
313 * @unimplemented
314 */
315 STDCALL
316 NTSTATUS
317 FsRtlRegisterFileSystemFilterCallbacks (
318 IN PVOID Unknown1,
319 IN PVOID Unknown2
320 )
321 {
322 UNIMPLEMENTED;
323 return STATUS_NOT_IMPLEMENTED;
324 }
325 /* EOF */