Timers in Video Miniport Drivers

Any video miniport driver can have a HwVidTimer function at the discretion of the driver writer. A HwVidTimer function allows the miniport driver to time out operations or to monitor state changes over a coarser-grained interval than is possible by calling VideoPortStallExecution. HwVidTimer also does not prevent other system operations from occurring as VideoPortStallExecution does.

For example, a miniport driver for an adapter that emulates VGA functionality might have a HwVidTimer function that monitors the status of its adapter's "VGA" registers periodically so the driver can emulate VGA-style graphics.

After a call to VideoPortStartTimer, the video port driver calls HwVidTimer once every second until the video miniport driver calls VideoPortStopTimer. A video miniport driver can enable and disable calls to the HwVidTimer function repeatedly.

Note that a HwVidTimer function cannot disable calls to itself with VideoPortStopTimer. Another video miniport driver function must control the enabling or disabling of calls to a HwVidTimer function through the use of VideoPortStartTimer and VideoPortStopTimer.