Bluetooth HFP DDI IOCTLs
Windows 8 introduces a set of I/O control codes (IOCTLs) as part of a DDI that allows the audio driver to work with the Hands-free profile (HFP) class driver, to operate a Bluetooth audio bypass connection.
Unless otherwise stated, the following is true for all the IOCTLs in this section:
If the request is successful, the Information member of the STATUS_BLOCK structure is set to the size, in bytes, of the output buffer. Otherwise, the Information member is set to zero. The Status member is set to an NTSTATUS value.
All IOCTLS require IRQL <= PASSIVE_LEVEL.
The audio driver should use the IOCTLs with the IRP_MJ_DEVICE_CONTROL request.
For most of the IOCTL function codes, the audio driver must initialize the FileObject pointer in the IO_STACK_LOCATION for the HFP driver when the audio driver initializes a device control IRP to send to the HFP driver. The audio driver typically retrieves the file object pointer by calling IoGetDeviceObjectPointer.
The audio driver will likely send many of these requests on an arbitrary thread (in other words, an “asynchronous” request). In these cases the audio driver will need to build the IRP itself using the IoAllocateIrp method, and set fields in the IRP directly rather than calling IoBuildDeviceIoControlRequest.
The following topics provide more details about these Windows 8 IOCTLs:
Windows 8.1 has updated the set of IOCTLs by adding the following new ones:
Windows 10 has updated the set of IOCTLs by adding the following new one:
For information about the structures that work with these IOCTLs, see Bluetooth HFP DDI Structures.