85 { \
87 RtlZeroMemory((
AT), (BYTE_COUNT)); \
91}
92
93
94
95
96
97#define CollectReadStats(VCB,OPEN_TYPE,BYTE_COUNT) { \
98 PFILESYSTEM_STATISTICS Stats = &(VCB)->Statistics[KeGetCurrentProcessorNumber() % FatData.NumberProcessors].Common; \
99 if (((OPEN_TYPE) == UserFileOpen)) { \
100 Stats->UserFileReads += 1; \
101 Stats->UserFileReadBytes += (ULONG)(BYTE_COUNT); \
102 } else if (((OPEN_TYPE) == VirtualVolumeFile || ((OPEN_TYPE) == DirectoryFile))) { \
103 Stats->MetaDataReads += 1; \
104 Stats->MetaDataReadBytes += (ULONG)(BYTE_COUNT); \
105 } \
106}
107
108
109#ifdef ALLOC_PRAGMA
110#pragma alloc_text(PAGE, FatStackOverflowRead)
111#pragma alloc_text(PAGE, FatPostStackOverflowRead)
112#pragma alloc_text(PAGE, FatCommonRead)
113#endif
114
115
120FatFsdRead (
123 )
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149{
153
155
157
158
159
160
161
163
164
165
166
167
168
170
172
175
176
177
178
179
181
182
183
184
185
186
188
191
194
196
198
199
200
201
202
204
205 } else {
206
207
208
209
210
212 }
213
215
217 }
218 }
219
221
223
225
226
227
228
229
230
232
235 }
236
237
238
239
240
241
243
246 }
247
248 Status = FatCommonRead( IrpContext,
Irp );
249
252
253
254
255
256
257
258
259
262
264
266
267
268
269
270
272
274
276}
static PIO_STACK_LOCATION IoGetCurrentIrpStackLocation(PIRP Irp)
#define KeWaitForSingleObject(pEvt, foo, a, b, c)
#define KeInitializeEvent(pEvt, foo, foo2)
NTSTATUS FatCompleteMdl(IN PIRP_CONTEXT IrpContext, IN PIRP Irp)
VOID FatPagingFileIo(IN PIRP Irp, IN PFCB Fcb)
ULONG FatExceptionFilter(IN PIRP_CONTEXT IrpContext, IN PEXCEPTION_POINTERS ExceptionPointer)
BOOLEAN FatIsIrpTopLevel(IN PIRP Irp)
#define DebugTrace(INDENT, LEVEL, X, Y)
IN PFCB IN PCCB IN TYPE_OF_OPEN IN BOOLEAN IN BOOLEAN TopLevel
#define FatDeviceIsFatFsdo(D)
PIRP_CONTEXT FatCreateIrpContext(IN PIRP Irp, IN BOOLEAN Wait)
#define FCB_STATE_PAGING_FILE
#define OVERFLOW_READ_THRESHHOLD
VOID NTAPI FatOverflowPagingFileRead(IN PVOID Context, IN PKEVENT Event)
#define FsRtlEnterFileSystem
#define FsRtlExitFileSystem
#define _Function_class_(x)
_In_ NDIS_HANDLE _In_ PNDIS_PACKET Packet
DRIVER_DISPATCH(nfs41_FsdDispatch)
#define UNREFERENCED_PARAMETER(P)
VOID NTAPI IoSetTopLevelIrp(IN PIRP Irp)
#define _SEH2_GetExceptionCode()
#define _SEH2_GetExceptionInformation()
VOID NTAPI FsRtlPostPagingFileStackOverflow(IN PVOID Context, IN PKEVENT Event, IN PFSRTL_STACK_OVERFLOW_ROUTINE StackOverflowRoutine)
_In_ PDEVICE_OBJECT DeviceObject