KsSynchronousDeviceControl - NtDoc

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

KSDDKAPI HRESULT KsSynchronousDeviceControl(
  [in]            HANDLE Handle,
  [in]            ULONG  IoControl,
  [in, optional]  PVOID  InBuffer,
  [in]            ULONG  InLength,
  [out, optional] PVOID  OutBuffer,
  [in]            ULONG  OutLength,
  [in, out]       PULONG BytesReturned
);

View the official Windows Driver Kit DDI reference

NtDoc

No description available.

Windows Driver Kit DDI reference (nf-ksproxy-kssynchronousdevicecontrol)

KsSynchronousDeviceControl function

Description

The KsSynchronousDeviceControl function issues a synchronous device I/O control operation to the KS object that is specified by a file handle.

Parameters

Handle [in]

Handle to the KS object on which to perform the operation.

IoControl [in]

Control code that identifies a specific type of operation to perform on a KS object.

InBuffer [in, optional]

Pointer to a buffer that contains data that specifies the operation to perform.

InLength [in]

Size, in bytes, of the buffer at InBuffer.

OutBuffer [out, optional]

Pointer to a buffer that contains either data for the operation or buffer space that receives data for the operation.

OutLength [in]

Size, in bytes, of the buffer at OutBuffer.

BytesReturned [in, out]

Pointer to a variable that receives the size, in bytes, of the data that KsSynchronousDeviceControl stores in the buffer at OutBuffer.

Return value

Returns NOERROR if successful; otherwise, returns an error code.

Remarks

To retrieve the handle to the KS object, an application should call the IKsObject::KsGetObjectHandle method.

An application can set the control code in IoControl and the buffers at InBuffer and OutBuffer as follows to specify the operation to perform:

To retrieve a list of all properties, events, or methods supported by a filter, an application can set IoControl to IOCTL_KS_PROPERTY, IOCTL_KS_ENABLE_EVENT, or IOCTL_KS_METHOD. For the KSPROPERTY, KSEVENT, or KSMETHOD structure to which InBuffer points, set the Set member to GUID_NULL and set the Flags member to KSPROPERTY_TYPE_SETSUPPORT.

After the call to KsSynchronousDeviceControl, OutBuffer will contain an array of set GUIDs supported by the object specified by Handle.

See also

IKsObject::KsGetObjectHandle

IOCTL_KS_DISABLE_EVENT

IOCTL_KS_ENABLE_EVENT

IOCTL_KS_METHOD

IOCTL_KS_PROPERTY

KSEVENT

KSEVENTDATA

KSMETHOD

KSPROPERTY