]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
platform/surface: aggregator: Add error injection capabilities
authorMaximilian Luz <luzmaximilian@gmail.com>
Mon, 21 Dec 2020 18:39:55 +0000 (19:39 +0100)
committerHans de Goede <hdegoede@redhat.com>
Wed, 6 Jan 2021 23:06:22 +0000 (00:06 +0100)
commit02be44f6b5a9e4ff1215d337ac4d2a6fbafc7874
treed9ca5068c272e80d1fb086ab93b6775abcd02f1d
parent0d21bb8560ef6bd09cab873120f940a939ad3aec
platform/surface: aggregator: Add error injection capabilities

This commit adds error injection hooks to the Surface Serial Hub
communication protocol implementation, to:

 - simulate simple serial transmission errors,

 - drop packets, requests, and responses, simulating communication
   failures and potentially trigger retransmission timeouts, as well as

 - inject invalid data into submitted and received packets.

Together with the trace points introduced in the previous commit, these
facilities are intended to aid in testing, validation, and debugging of
the Surface Aggregator communication layer.

Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Link: https://lore.kernel.org/r/20201221183959.1186143-6-luzmaximilian@gmail.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
drivers/platform/surface/aggregator/Kconfig
drivers/platform/surface/aggregator/ssh_packet_layer.c
drivers/platform/surface/aggregator/ssh_request_layer.c
drivers/platform/surface/aggregator/trace.h