Minor changes and some interfaces updated in FsRtl.
[reactos.git] / reactos / ntoskrnl / fs / notify.c
1 /* $Id: notify.c,v 1.3 2002/01/13 22:02:31 ea Exp $
2 *
3 * reactos/ntoskrnl/fs/notify.c
4 *
5 */
6 #include <ntos.h>
7 #include <ddk/ntifs.h>
8
9
10 /**********************************************************************
11 * NAME EXPORTED
12 * FsRtlNotifyChangeDirectory@28
13 *
14 * DESCRIPTION
15 *
16 * ARGUMENTS
17 *
18 * RETURN VALUE
19 *
20 */
21 VOID
22 STDCALL
23 FsRtlNotifyChangeDirectory (
24 IN PNOTIFY_SYNC NotifySync,
25 IN PVOID FsContext,
26 IN PSTRING FullDirectoryName,
27 IN PLIST_ENTRY NotifyList,
28 IN BOOLEAN WatchTree,
29 IN ULONG CompletionFilter,
30 IN PIRP NotifyIrp
31 )
32 {
33 FsRtlNotifyFullChangeDirectory (
34 NotifySync,
35 NotifyList,
36 FsContext,
37 FullDirectoryName,
38 WatchTree,
39 TRUE, /* IgnoreBuffer */
40 CompletionFilter,
41 NotifyIrp,
42 NULL,
43 NULL
44 );
45 }
46
47
48 /**********************************************************************
49 * NAME EXPORTED
50 * FsRtlNotifyCleanup@12
51 *
52 * DESCRIPTION
53 *
54 * ARGUMENTS
55 *
56 * RETURN VALUE
57 *
58 */
59 VOID
60 STDCALL
61 FsRtlNotifyCleanup (
62 IN PNOTIFY_SYNC NotifySync,
63 IN PLIST_ENTRY NotifyList,
64 IN PVOID FsContext
65 )
66 {
67 }
68
69
70 /**********************************************************************
71 * NAME EXPORTED
72 * FsRtlNotifyFullChangeDirectory@40
73 *
74 * DESCRIPTION
75 *
76 * ARGUMENTS
77 *
78 * RETURN VALUE
79 *
80 */
81 VOID
82 STDCALL
83 FsRtlNotifyFullChangeDirectory (
84 IN PNOTIFY_SYNC NotifySync,
85 IN PLIST_ENTRY NotifyList,
86 IN PVOID FsContext,
87 IN PSTRING FullDirectoryName,
88 IN BOOLEAN WatchTree,
89 IN BOOLEAN IgnoreBuffer,
90 IN ULONG CompletionFilter,
91 IN PIRP NotifyIrp,
92 IN PCHECK_FOR_TRAVERSE_ACCESS TraverseCallback OPTIONAL,
93 IN PSECURITY_SUBJECT_CONTEXT SubjectContext OPTIONAL
94 )
95 {
96 DbgPrint("%s()\n", __FUNCTION__);
97 }
98
99
100 /**********************************************************************
101 * NAME EXPORTED
102 * FsRtlNotifyFullReportChange@36
103 *
104 * DESCRIPTION
105 *
106 * ARGUMENTS
107 *
108 * RETURN VALUE
109 *
110 */
111 VOID
112 STDCALL
113 FsRtlNotifyFullReportChange (
114 IN PNOTIFY_SYNC NotifySync,
115 IN PLIST_ENTRY NotifyList,
116 IN PSTRING FullTargetName,
117 IN USHORT TargetNameOffset,
118 IN PSTRING StreamName OPTIONAL,
119 IN PSTRING NormalizedParentName OPTIONAL,
120 IN ULONG FilterMatch,
121 IN ULONG Action,
122 IN PVOID TargetContext
123 )
124 {
125 }
126
127
128 /**********************************************************************
129 * NAME EXPORTED
130 * FsRtlNotifyInitializeSync@4
131 *
132 * DESCRIPTION
133 *
134 * ARGUMENTS
135 *
136 * RETURN VALUE
137 *
138 */
139 VOID
140 STDCALL
141 FsRtlNotifyInitializeSync (
142 IN PNOTIFY_SYNC * NotifySync
143 )
144 {
145 *NotifySync = NULL;
146 *NotifySync = ExAllocatePoolWithTag (
147 0x10, // PoolType???
148 sizeof (NOTIFY_SYNC), // NumberOfBytes = 0x28
149 FSRTL_TAG
150 );
151 #if 0
152 *NotifySync->Unknown0 = 1;
153 *NotifySync->Unknown2 = 0;
154 *NotifySync->Unknown3 = 1;
155 *NotifySync->Unknown4 = 4;
156 *NotifySync->Unknown5 = 0;
157 *NotifySync->Unknown9 = 0;
158 *NotifySync->Unknown10 = 0;
159 #endif
160 }
161
162
163 /**********************************************************************
164 * NAME EXPORTED
165 * FsRtlNotifyReportChange@20
166 *
167 * DESCRIPTION
168 *
169 * ARGUMENTS
170 *
171 * RETURN VALUE
172 *
173 */
174 VOID
175 STDCALL
176 FsRtlNotifyReportChange (
177 IN PNOTIFY_SYNC NotifySync,
178 IN PLIST_ENTRY NotifyList,
179 IN PSTRING FullTargetName,
180 IN PUSHORT FileNamePartLength,
181 IN ULONG FilterMatch
182 )
183 {
184 FsRtlNotifyFullReportChange (
185 NotifySync,
186 NotifyList,
187 FullTargetName,
188 (FullTargetName->Length - *FileNamePartLength), /*?*/
189 NULL,
190 NULL,
191 FilterMatch,
192 0, /* Action ? */
193 NULL
194 );
195 }
196
197
198 /**********************************************************************
199 * NAME EXPORTED
200 * FsRtlNotifyUninitializeSync@4
201 *
202 * DESCRIPTION
203 * Uninitialize a NOTIFY_SYNC object.
204 *
205 * ARGUMENTS
206 * NotifySync is the address of a pointer
207 * to a PNOTIFY_SYNC object previously initialized by
208 * FsRtlNotifyInitializeSync().
209 *
210 * RETURN VALUE
211 * None.
212 */
213 VOID
214 STDCALL
215 FsRtlNotifyUninitializeSync (
216 IN OUT PNOTIFY_SYNC * NotifySync
217 )
218 {
219 if (NULL != *NotifySync)
220 {
221 ExFreePool (*NotifySync);
222 *NotifySync = NULL;
223 }
224 }
225
226 /**********************************************************************
227 * NAME EXPORTED
228 * FsRtlNotifyVolumeEvent@8
229 *
230 * DESCRIPTION
231 * NOTE: Only present in NT 5+.
232 *
233 * ARGUMENTS
234 *
235 * RETURN VALUE
236 *
237 */
238 NTSTATUS
239 STDCALL
240 FsRtlNotifyVolumeEvent (
241 IN PFILE_OBJECT FileObject,
242 IN ULONG EventCode
243 )
244 {
245 return STATUS_NOT_IMPLEMENTED;
246 }
247
248 /* EOF */