Enable HID protocol handling in userspace when UserspaceHID=true in input.conf.
Benefits of userspace HID:
1. Persistent HID/input pipeline
For a Bluetooth HID device, the corresponding kernel HID/input devices are
created only once when the Bluetooth HID device is used the first time.
The HID/input pipeline is not destroyed and recreated every time when
the Bluetooth HID device disconnects and reconnects.
2. HID vs HoG parity
Enables HID and HoG devices to operate the same way in BlueZ stack, using
uHID kernel module (/dev/uhid) to pass HID report data between bluetoothd
and kernel HID subsystem.
3. Debugging
It is easier to debug HID protocol in userspace than in HIDP kernel module.
The autopair plugin tries standard pincodes for different devices with
dumb pincodes. It also generates a random 6 digit pincode for keyboards
that support any pincode but fallbacks to the agent call in case the
random generated pincode didn't work.
Change the btd_profile connect/disconnect callbacks to receive a
btd_service pointer. This should make it possible to handle multiple
instances of the same profile in a specific device.
The patch strongly influences how the profiles should interact with the
core. The state transitions, previously reported using the device.h API
(device_profile_connected() and device_profile_disconnected()), have
now been replaced by the btd_service API.
The transitions will then be propagated to device.c by means of the
conventional state-changed callback mechanism.
Since hog_manager.c and hog_device.h were merged into hog_device.c,
now the whole HoG logic is in this file. So, calling this file hog.c
instead of hog_device.c is more suitable.
This patch merges hog_device.h code into hog_device.c and removes
hog_device.h file. As long as hog_manager.c was merged into hog_
device.c, there is no need to have a header for hog_device.
This patch also adds the static modifier to functions which are
now used only in hog_device.c.
This patch merges hog_manager.c code into hog_device.c and removes
hog_manager.c file. hog_manager.c is a very small file, so there is
no need to keep it separated.