HWN_CLIENT_GET_STATE - NtDoc

Native API online documentation, based on the System Informer (formerly Process Hacker) phnt headers
// hwnclx.h

HWN_CLIENT_GET_STATE HwnClientGetState;

NTSTATUS HwnClientGetState(
  [in]  PVOID Context,
  [out] PVOID OutputBuffer,
  [in]  ULONG OutputBufferLength,
  [in]  PVOID InputBuffer,
  [in]  ULONG InputBufferLength,
  [out] PULONG BytesRead
)
{...}
View the official Windows Driver Kit DDI reference

NtDoc

No description available.

Windows Driver Kit DDI reference (nc-hwnclx-hwn_client_get_state)

HWN_CLIENT_GET_STATE callback

Description

Implemented by the client driver to get hardware notification component state. It is invoked when a user requests status information.

Parameters

Context [in]

Pointer to the client driver's context information. This memory space is available for use by the client driver. It is allocated as part of the framework object context space by WdfDeviceCreate. For more information, see HWN_CLIENT_REGISTRATION_PACKET and Framework Object Context Space.

OutputBuffer [out]

Buffer of OutputBufferLength bytes for writing hardware notification status. If the function succeeds, the buffer will contain a HWN_HEADER structure including one or more HWN_SETTINGS structures.

Note

OutputBufferLength must be large enough to contain all of the requested settings. For more information, see Remarks.

OutputBufferLength [in]

The size of OutputBuffer in bytes.

InputBuffer [in]

Buffer of InputBufferLength bytes containing a HWN_HEADER holding one or more HWN_SETTINGS structures where the IDs for the requested hardware notification components are stored in the HwNId field. This buffer can be NULL.

InputBufferLength [in]

The size of InputBuffer in bytes.

BytesRead [out]

Pointer to a variable that indicates the number of bytes read by the function.

Return value

Return STATUS_SUCCESS if the operation succeeds. Otherwise, return an appropriate NTSTATUS error code.

Prototype

HWN_CLIENT_GET_STATE HwnClientGetState;

NTSTATUS HwnClientGetState(
  _In_  PVOID  Context,
  _Out_ PVOID  OutputBuffer,
  _In_  ULONG  OutputBufferLength,
  _In_  PVOID  InputBuffer,
  _In_  ULONG  InputBufferLength,
  _Out_ PULONG BytesRead
)
{ ... }

typedef HWN_CLIENT_GET_STATE *PHWN_CLIENT_GET_STATE;

Remarks

Register your implementation of this callback function by setting the appropriate member of HWN_CLIENT_REGISTRATION_PACKET and then calling HwNRegisterClient.

See also

Hardware notifications support

Hardware notifications reference