diff options
author | Ping Cheng <pinglinux@gmail.com> | 2023-02-24 17:26:43 +0100 |
---|---|---|
committer | Jiri Kosina <jkosina@suse.cz> | 2023-03-10 11:13:15 +0100 |
commit | 17d793f3ed53080dab6bbeabfc82de890c901001 (patch) | |
tree | 9b309b1e1d9eab0959a7bde47afb005a8f30911c /drivers/hid/wacom_wac.h | |
parent | Merge tag 'for-linus-2023030901' of git://git.kernel.org/pub/scm/linux/kernel... (diff) | |
download | linux-17d793f3ed53080dab6bbeabfc82de890c901001.tar.xz linux-17d793f3ed53080dab6bbeabfc82de890c901001.zip |
HID: wacom: insert timestamp to packed Bluetooth (BT) events
To fully utilize the BT polling/refresh rate, a few input events
are sent together to reduce event delay. This causes issue to the
timestamp generated by input_sync since all the events in the same
packet would pretty much have the same timestamp. This patch inserts
time interval to the events by averaging the total time used for
sending the packet.
This decision was mainly based on observing the actual time interval
between each BT polling. The interval doesn't seem to be constant,
due to the network and system environment. So, using solutions other
than averaging doesn't end up with valid timestamps.
Signed-off-by: Ping Cheng <ping.cheng@wacom.com>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid/wacom_wac.h')
-rw-r--r-- | drivers/hid/wacom_wac.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/hid/wacom_wac.h b/drivers/hid/wacom_wac.h index 16f221388563..1a40bb8c5810 100644 --- a/drivers/hid/wacom_wac.h +++ b/drivers/hid/wacom_wac.h @@ -324,6 +324,7 @@ struct hid_data { int ps_connected; bool pad_input_event_flag; unsigned short sequence_number; + int time_delayed; }; struct wacom_remote_data { |