CcSetAdditionalCacheAttributes routine

Call the CcSetAdditionalCacheAttributes routine to enable or disable read-ahead (also called "lazy read") or write-behind (also called "lazy write") on a cached file.

Syntax


VOID CcSetAdditionalCacheAttributes(
  _In_  PFILE_OBJECT FileObject,
  _In_  BOOLEAN DisableReadAhead,
  _In_  BOOLEAN DisableWriteBehind
);

Parameters

FileObject [in]

Pointer to a file object for the cached file.

DisableReadAhead [in]

Set to TRUE to disable read-ahead, FALSE to enable it. The caller must specify a value for DisableReadAhead in each call to CcSetAdditionalCacheAttributes, even if a value was already specified in a previous call.

DisableWriteBehind [in]

Set to TRUE to disable write-behind, FALSE to enable it. The caller must specify a value for DisableWriteBehind in each call to CcSetAdditionalCacheAttributes, even if a value was already specified in a previous call.

Return value

None

Remarks

CcSetAdditionalCacheAttributes can be called any time after calling CcInitializeCacheMap. Initially, both read-ahead and write-behind are enabled.

Requirements

Header

Ntifs.h (include Ntifs.h)

Library

Ntoskrnl.lib

IRQL

<= APC_LEVEL

See also

CcInitializeCacheMap
CcReadAhead
CcSetReadAheadGranularity

 

 

Send comments about this topic to Microsoft

Show:
© 2014 Microsoft