]> Git Repo - linux.git/commit
platform/surface: aggregator: Do not check for repeated unsequenced packets
authorMaximilian Luz <[email protected]>
Sun, 13 Nov 2022 18:59:50 +0000 (19:59 +0100)
committerHans de Goede <[email protected]>
Tue, 15 Nov 2022 16:18:26 +0000 (17:18 +0100)
commitd9a477f643eb3de71fbea5ae6103b800ceb8f547
tree471f593981d39eede5b60ed79e4fe05317117061
parent1e817b889c7d8c14e7005258e15fec62edafe03c
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: c167b9c7e3d6 ("platform/surface: Add Surface Aggregator subsystem")
Signed-off-by: Maximilian Luz <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Reviewed-by: Hans de Goede <[email protected]>
Signed-off-by: Hans de Goede <[email protected]>
drivers/platform/surface/aggregator/ssh_packet_layer.c
This page took 0.062404 seconds and 4 git commands to generate.