PFN_HANDLE_KMD_MESSAGE callback function

Called by the operating system to handle the asynchronous kernel-mode message that the Miracast user-mode driver receives when the display miniport driver calls the DxgkCbMiracastSendMessage function.

Syntax

PFN_HANDLE_KMD_MESSAGE PfnHandleKmdMessage;

NTSTATUS PfnHandleKmdMessage(
  PVOID pMiracastContext,
  UINT InputBufferSize,
  VOID *pInputBuffer,
  UINT OutputBufferSize,
  VOID *pOutputBuffer,
  UINT *pBytesReturned
)
{...}

Parameters

pMiracastContext

A pointer to a context associated with a display adapter.

The operating system obtained the context when it called the Miracast user-mode driver's CreateMiracastContext function.

InputBufferSize

The size of the input buffer pInputBuffer, supplied by the operating system.

pInputBuffer

OutputBufferSize

The size of the output buffer pOutputBuffer, supplied by the operating system.

pOutputBuffer

pBytesReturned

Return Value

On success, this function returns STATUS_SUCCESS. Otherwise, the function returns an error code defined in the Ntstatus.h header.

Remarks

Thread Safety

When this function is called, it's possible that it has also been called in another thread. The driver is therefore responsible for synchronizing multiple calls to HandleKernelModeMessage if necessary.

The operating system guarantees that this function is not called when CreateMiracastContext, DestroyMiracastContext, StartMiracastSession, and StopMiracastSession are called. All the messages that the display miniport driver sends during the startup of a Miracast connected session (StartMiracastSession) are blocked until the session startup process has completed. The operating system also blocks all messages that the display miniport driver sends during or after a call to stop the Miracast session (StopMiracastSession).

Requirements

   
Minimum supported client Windows 8.1
Minimum supported server Windows Server 2012 R2
Target Platform Desktop
Header netdispumdddi.h (include Netdispumdddi.h)

See Also

CreateMiracastContext

DestroyMiracastContext

DxgkCbMiracastSendMessage

StartMiracastSession

StopMiracastSession