PFNKSCLOCK_CORRELATEDTIME callback function (ks.h)

The routine is a system-supplied routine that retrieves and the following:

KStrClockGetCorrelatedTime is a system-supplied routine that retrieves both the current system time and the corresponding clock tick count since boot.

KStrClockGetCorrelatedPhysicalTime is a system-supplied routine that retrieves both the current system time minus suspended delta and the corresponding clock tick since boot.

Syntax

PFNKSCLOCK_CORRELATEDTIME PfnksclockCorrelatedtime;

LONGLONG PfnksclockCorrelatedtime(
  [in]  PFILE_OBJECT FileObject,
  [out] PLONGLONG SystemTime
)
{...}

Parameters

[in] FileObject

A pointer to the FILE_OBJECT structure to which a handle was returned when the clock instance was created.

[out] SystemTime

A pointer to a 64-bit integer containing the number of clock ticks since system boot.

Return value

This routine returns the current system time as a value of type LONGLONG. This value is specified in 100 nanosecond units.

Remarks

You can obtain an entry point for this routine by supplying a driver-allocated KSCLOCK_FUNCTIONTABLE structure in a KSPROPERTY_CLOCK_FUNCTIONTABLE request.

The system time is acquired from KeQueryPerformanceCounter.

Both time values are specified in 100 nanosecond units.

Requirements

Requirement Value
Target Platform Desktop
Header ks.h (include Ks.h)

See also

KSCLOCK_FUNCTIONTABLE

KSCORRELATED_TIME

KSPROPERTY_CLOCK_FUNCTIONTABLE

KeQueryPerformanceCounter