[NTOSKRNL] Implement CcSetReadAheadGranularity()
authorPierre Schweitzer <pierre@reactos.org>
Thu, 8 Feb 2018 08:46:57 +0000 (09:46 +0100)
committerPierre Schweitzer <pierre@reactos.org>
Thu, 8 Feb 2018 10:02:26 +0000 (11:02 +0100)
ntoskrnl/cc/cacheman.c

index aacf818..5d7ff57 100644 (file)
@@ -243,10 +243,11 @@ CcSetReadAheadGranularity (
        IN      ULONG           Granularity
        )
 {
-    static ULONG Warn;
+    PPRIVATE_CACHE_MAP PrivateMap;
 
     CCTRACE(CC_API_DEBUG, "FileObject=%p Granularity=%lu\n",
         FileObject, Granularity);
 
-    if (!Warn++) UNIMPLEMENTED;
+    PrivateMap = FileObject->PrivateCacheMap;
+    PrivateMap->ReadAheadMask = Granularity - 1;
 }