WSL2-Linux-Kernel/drivers/platform/surface/aggregator
Maximilian Luz d9a477f643 platform/surface: aggregator: Do not check for repeated unsequenced packets
Currently, we check any received packet whether we have already seen it
previously, regardless of the packet type (sequenced / unsequenced). We
do this by checking the sequence number. This assumes that sequence
numbers are valid for both sequenced and unsequenced packets. However,
this assumption appears to be incorrect.

On some devices, the sequence number field of unsequenced packets (in
particular HID input events on the Surface Pro 9) is always zero. As a
result, the current retransmission check kicks in and discards all but
the first unsequenced packet, breaking (among other things) keyboard and
touchpad input.

Note that we have, so far, only seen packets being retransmitted in
sequenced communication. In particular, this happens when there is an
ACK timeout, causing the EC (or us) to re-send the packet waiting for an
ACK. Arguably, retransmission / duplication of unsequenced packets
should not be an issue as there is no logical condition (such as an ACK
timeout) to determine when a packet should be sent again.

Therefore, remove the retransmission check for unsequenced packets
entirely to resolve the issue.

Fixes: c167b9c7e3 ("platform/surface: Add Surface Aggregator subsystem")
Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/20221113185951.224759-1-luzmaximilian@gmail.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2022-11-15 17:18:26 +01:00
..
Kconfig platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
Makefile platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
bus.c platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
bus.h platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
controller.c platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
controller.h platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
core.c platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
ssh_msgb.h platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
ssh_packet_layer.c platform/surface: aggregator: Do not check for repeated unsequenced packets 2022-11-15 17:18:26 +01:00
ssh_packet_layer.h platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
ssh_parser.c platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
ssh_parser.h platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
ssh_request_layer.c platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
ssh_request_layer.h platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00
trace.h platform/surface: Update copyright year of various drivers 2022-07-02 11:23:30 +02:00