DxgkCbLogEtwEvent routine

The DxgkCbLogEtwEvent function logs an Event Tracing for Windows (ETW) event.

Syntax


DXGKCB_LOG_ETW_EVENT DxgkCbLogEtwEvent;

VOID DxgkCbLogEtwEvent(
  _In_  const LPCGUID EventGuid,
  _In_  UCHAR Type,
  _In_  USHORT EventBufferSize,
  _In_  PVOID EventBuffer
)
{ ... }

Parameters

EventGuid [in]

A GUID that identifies the event to be logged.

Type [in]

A constant that specifies the event type. These constants are defined in Evntrace.h and have the form of EVENT_TRACE_TYPE_XX.

EventBufferSize [in]

The size, in bytes, of the buffer pointed to by EventBuffer. There is a significant performance penalty if the buffer is larger than 256 bytes.

EventBuffer [in]

A pointer to a buffer that contains the information to be logged.

Return value

None

Remarks

If event logging is not enabled, DxgkCbLogEtwEvent returns immediately without logging the event.

To enable or disable event logging, call the DxgkDdiControlEtwLogging function.

If EventBufferSize is less than or equal to 256, DxgkCbLogEtwEvent can be called an any IRQL. If EventBufferSize is greater than 256, DxgkCbLogEtwEvent must be called at IRQL = PASSIVE_LEVEL.

Examples

The following code example shows how to log an event with the event logger.


// {A7BF27A0-7401-4733-9FED-FDB51067FECC}
DEFINE_GUID(R200_DUMMY_LOGGING,
0xa7bf27a0, 0x7401, 0x4733, 0x9f, 0xed, 0xfd, 0xb5, 0x10, 0x67, 0xfe, 0xcc);

VOID
DummyTrace(
    HW_DEVICE_EXTENSION* Adapter
    )
{
    Adapter->ddiCallback.DxgkCbLogEtwEvent(&R200_DUMMY_LOGGING,
  EVENT_TRACE_TYPE_INFO,
  0,
  NULL);
}

Requirements

Version

Available in Windows Vista and later versions of the Windows operating systems.

Header

Dispmprt.h (include Dispmprt.h)

IRQL

See Remarks section.

See also

DxgkDdiControlEtwLogging

 

 

Send comments about this topic to Microsoft

Show:
© 2014 Microsoft