119 "CCPF: InitializePrefetecher()\n");
171 Private = Private->
Flink)
210 if (IdenticalStreamFileObject)
211 Map = IdenticalStreamFileObject->SectionObjectPointer->SharedCacheMap;
214 DPRINT1(
"Linking SFO %x to previous SFO %x through cache map %x #\n",
216 IdenticalStreamFileObject,
223 DPRINT(
"Initializing file object for (%p) %wZ\n",
228 FileObject->SectionObjectPointer->SharedCacheMap = Map;
235 DPRINT(
"FileSizes->ValidDataLength %I64x\n",
241 DPRINT(
"New Map %p\n", Map);
246 if (!PrivateCacheMap)
249 sizeof(*PrivateCacheMap));
251 FileObject->PrivateCacheMap = PrivateCacheMap;
256 PrivateCacheMap->
Map = Map;
277 for (
Count = 0,
Entry = Map->AssociatedBcb.Flink;
278 Entry != &Map->AssociatedBcb;
294 DPRINT(
"Uninitializing file object for %wZ SectionObjectPointer %x\n",
310 ASSERT(!Map || Map == PrivateCacheMap->Map);
316 if (
IsListEmpty(&PrivateCacheMap->Map->PrivateCacheMaps))
319 while (!
IsListEmpty(&PrivateCacheMap->Map->AssociatedBcb))
340 DPRINT(
"Uninit complete\n");
424 PVOID PinnedBcb, PinnedBuffer;
427 DPRINT(
"S %I64x E %I64x\n",
428 StartOffset->QuadPart,
429 EndOffset->QuadPart);
451 DPRINT(
"Zero last half %I64x %lx\n",
468 DPRINT1(
"RtlZeroMemory(%p, %lx)\n",
495 DPRINT(
"Zero full page %I64x\n",
515 DPRINT(
"Zero first half %I64x %lx\n",
531 DPRINT1(
"RtlZeroMemory(%x,%x)\n", ZeroBuf, ToWrite);
559 if (
Bcb->FileOffset.QuadPart +
Bcb->Length >= LowerBound.
QuadPart &&
562 DPRINT(
"Bcb #%x (@%I64x)\n",
564 Bcb->FileOffset.QuadPart);
573 Bcb->FileOffset.QuadPart +
Bcb->Length);
591 ListEntry = ListEntry->
Flink;
static CC_FILE_SIZES FileSizes
const struct winhelp_callbacks Callbacks
_In_ PFCB _In_ LONGLONG FileOffset
#define NT_SUCCESS(StatCode)
#define UNIMPLEMENTED_DBGBREAK(...)
#define RemoveEntryList(Entry)
#define InsertTailList(ListHead, Entry)
#define IsListEmpty(ListHead)
#define KeInitializeEvent(pEvt, foo, foo2)
#define InitializeListHead(ListHead)
#define ROUND_UP(n, align)
IN PVCB IN VBO IN ULONG OUT PBCB * Bcb
#define ExAllocatePool(type, size)
_Must_inspect_result_ _In_ PDEVICE_OBJECT _In_ PSECTION_OBJECT_POINTERS SectionObjectPointer
FAST_MUTEX GlobalPageOperation
VOID NTAPI CcSetFileSizes(IN PFILE_OBJECT FileObject, IN PCC_FILE_SIZES FileSizes)
HANDLE CcUnmapThreadHandle
BOOLEAN NTAPI CcGetFileSizes(IN PFILE_OBJECT FileObject, IN PCC_FILE_SIZES FileSizes)
VOID NTAPI CcInitializeCacheMap(IN PFILE_OBJECT FileObject, IN PCC_FILE_SIZES FileSizes, IN BOOLEAN PinAccess, IN PCACHE_MANAGER_CALLBACKS Callbacks, IN PVOID LazyWriteContext)
PFSN_PREFETCHER_GLOBALS CcPfGlobals
PFILE_OBJECT NTAPI CcGetFileObjectFromBcb(PVOID Bcb)
PFILE_OBJECT CcpFindOtherStreamFileObject(PFILE_OBJECT FileObject)
CLIENT_ID CcLazyWriteThreadId
ULONG NTAPI CcpCountCacheSections(IN PNOCC_CACHE_MAP Map)
BOOLEAN NTAPI CcUninitializeCacheMap(IN PFILE_OBJECT FileObject, IN OPTIONAL PLARGE_INTEGER TruncateSize, IN OPTIONAL PCACHE_UNINITIALIZE_EVENT UninitializeEvent)
VOID NTAPI CcSetDirtyPageThreshold(IN PFILE_OBJECT FileObject, IN ULONG DirtyPageThreshold)
VOID NTAPI CcpReleaseFileLock(PNOCC_CACHE_MAP Map)
BOOLEAN NTAPI CcInitializeCacheManager(VOID)
BOOLEAN NTAPI CcZeroData(IN PFILE_OBJECT FileObject, IN PLARGE_INTEGER StartOffset, IN PLARGE_INTEGER EndOffset, IN BOOLEAN Wait)
CLIENT_ID CcUnmapThreadId
struct _NOCC_PRIVATE_CACHE_MAP * PNOCC_PRIVATE_CACHE_MAP
HANDLE CcLazyWriteThreadHandle
BOOLEAN NTAPI CcPurgeCacheSection(IN PSECTION_OBJECT_POINTERS SectionObjectPointer, IN OPTIONAL PLARGE_INTEGER FileOffset, IN ULONG Length, IN BOOLEAN UninitializeCacheMaps)
LONG CcOutstandingDeletes
PFILE_OBJECT NTAPI CcGetFileObjectFromSectionPtrs(IN PSECTION_OBJECT_POINTERS SectionObjectPointer)
LIST_ENTRY CcpAllSharedCacheMaps
VOID NTAPI CcpUnmapThread(PVOID Unused)
struct _NOCC_PRIVATE_CACHE_MAP NOCC_PRIVATE_CACHE_MAP
VOID NTAPI CcpLazyWriteThread(PVOID Unused)
VOID NTAPI CcPfInitializePrefetcher(VOID)
BOOLEAN NTAPI CcpAcquireFileLock(PNOCC_CACHE_MAP Map)
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define DPFLTR_TRACE_LEVEL
#define PAGE_ROUND_DOWN(x)
NTSYSAPI ULONG __cdecl DbgPrintEx(_In_ ULONG ComponentId, _In_ ULONG Level, _In_z_ _Printf_format_string_ PCSTR Format,...)
DECLSPEC_NORETURN NTSYSAPI VOID NTAPI RtlRaiseStatus(_In_ NTSTATUS Status)
#define CcpFlushCache(M, F, L, I, D)
BOOLEAN NTAPI CcpUnpinData(PNOCC_BCB Bcb, BOOLEAN ActuallyRelease)
NOCC_BCB CcCacheSections[CACHE_NUM_SECTIONS]
struct _NOCC_BCB * PNOCC_BCB
struct _NOCC_CACHE_MAP * PNOCC_CACHE_MAP
VOID CcpReferenceCache(ULONG Sector)
VOID CcpDereferenceCache(ULONG Sector, BOOLEAN Immediate)
PRTL_BITMAP CcCacheBitmap
#define CACHE_NUM_SECTIONS
NTSTATUS NTAPI MmExtendCacheSection(PSECTION Section, PLARGE_INTEGER NewSize, BOOLEAN ExtendFile)
#define MiSimpleWrite(F, O, B, L, R)
_In_ ULONG _In_ ULONG _In_ ULONG Length
NTSTATUS NTAPI MiSimpleRead(PFILE_OBJECT FileObject, PLARGE_INTEGER FileOffset, PVOID Buffer, ULONG Length, BOOLEAN Paging, PIO_STATUS_BLOCK ReadStatus)
PFILE_OBJECT NTAPI MmGetFileObjectForSection(IN PVOID Section)
BOOLEAN NTAPI CcPreparePinWrite(IN PFILE_OBJECT FileObject, IN PLARGE_INTEGER FileOffset, IN ULONG Length, IN BOOLEAN Zero, IN ULONG Flags, OUT PVOID *Bcb, OUT PVOID *Buffer)
PULONG MinorVersion OPTIONAL
base of all file and directory entries
PACQUIRE_FOR_LAZY_WRITE AcquireForLazyWrite
PRELEASE_FROM_LAZY_WRITE ReleaseFromLazyWrite
LARGE_INTEGER ValidDataLength
LARGE_INTEGER AllocationSize
struct _LIST_ENTRY * Flink
CACHE_MANAGER_CALLBACKS Callbacks
ULONG ReadAheadGranularity
LIST_ENTRY PrivateCacheMaps
LIST_ENTRY CompletedTraces
FAST_MUTEX CompletedTracesLock
#define RtlCopyMemory(Destination, Source, Length)
#define RtlZeroMemory(Destination, Length)
#define CONTAINING_RECORD(address, type, field)
#define STATUS_INSUFFICIENT_RESOURCES
_In_ WDFREQUEST _In_ WDFFILEOBJECT FileObject
_In_ WDFDPC _In_ BOOLEAN Wait
_At_(*)(_In_ PWSK_CLIENT Client, _In_opt_ PUNICODE_STRING NodeName, _In_opt_ PUNICODE_STRING ServiceName, _In_opt_ ULONG NameSpace, _In_opt_ GUID *Provider, _In_opt_ PADDRINFOEXW Hints, _Outptr_ PADDRINFOEXW *Result, _In_opt_ PEPROCESS OwningProcess, _In_opt_ PETHREAD OwningThread, _Inout_ PIRP Irp Result)(Mem)) NTSTATUS(WSKAPI *PFN_WSK_GET_ADDRESS_INFO
FORCEINLINE VOID ExInitializeFastMutex(_Out_ PFAST_MUTEX FastMutex)
#define ObDereferenceObject
#define ObReferenceObject